• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 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 DAC_TEST_H
10 #define DAC_TEST_H
11 
12 #include "dac_if.h"
13 
14 #ifdef __cplusplus
15 #if __cplusplus
16 extern "C" {
17 #endif
18 #endif /* __cplusplus */
19 
20 struct DacTestConfig {
21     uint32_t devNum;
22     uint32_t channel;
23     uint32_t maxChannel;
24     uint32_t dataWidth;
25     uint32_t rate;
26 };
27 
28 struct DacTester {
29     struct DacTestConfig config;
30     DevHandle handle;
31 };
32 
33 enum DacTestCmd {
34     DAC_TEST_CMD_WRITE = 0,
35     DAC_TEST_CMD_MULTI_THREAD,
36     DAC_TEST_CMD_RELIABILITY,
37     DAC_TEST_CMD_IF_PERFORMANCE,
38     DAC_TEST_CMD_MAX,
39 };
40 
41 int32_t DacTestExecute(int cmd);
42 
43 #ifdef __cplusplus
44 #if __cplusplus
45 }
46 #endif
47 #endif /* __cplusplus */
48 
49 #endif /* DAC_TEST_H */
50