1 /* 2 * Copyright (c) 2020-2021 Huawei Device Co., Ltd. 3 * 4 * HDF is dual licensed: you can use it either under the terms of 5 * the GPL, or the BSD license, at your option. 6 * See the LICENSE file in the root of this repository for complete details. 7 */ 8 9 #ifndef PWM_TEST_H 10 #define PWM_TEST_H 11 12 #include "pwm_if.h" 13 14 #ifdef __cplusplus 15 extern "C" { 16 #endif 17 18 int32_t PwmTestExecute(int cmd); 19 20 enum PwmTestCmd { 21 PWM_SET_PERIOD_TEST = 0, 22 PWM_SET_DUTY_TEST, 23 PWM_SET_POLARITY_TEST, 24 PWM_ENABLE_TEST, 25 PWM_DISABLE_TEST, 26 PWM_SET_GET_CONFIG_TEST, 27 PWM_RELIABILITY_TEST, 28 PWM_IF_PERFORMANCE_TEST, 29 PWM_TEST_CMD_MAX, 30 }; 31 32 struct PwmTestConfig { 33 uint32_t num; 34 struct PwmConfig cfg; 35 }; 36 37 struct PwmTester { 38 struct PwmTestConfig config; 39 struct PwmConfig originCfg; 40 DevHandle handle; 41 }; 42 43 #ifdef __cplusplus 44 } 45 #endif 46 47 #endif /* PWM_TEST_H */ 48