no-OS
ade9000.h
Go to the documentation of this file.
1 /***************************************************************************/
33 #ifndef __ADE9000_H__
34 #define __ADE9000_H__
35 
36 /******************************************************************************/
37 /***************************** Include Files **********************************/
38 /******************************************************************************/
39 #include <stdbool.h>
40 #include <stdint.h>
41 #include <string.h>
42 #include "no_os_util.h"
43 #include "no_os_spi.h"
44 
45 /******************************************************************************/
46 /********************** Macros and Constants Definitions **********************/
47 /******************************************************************************/
48 
49 /* SPI commands */
50 #define ADE9000_SPI_READ NO_OS_BIT(3)
51 
52 #define ENABLE 0x0001
53 #define DISABLE 0x0000
54 
55 /* ADE9000 Register Map */
56 #define ADE9000_REG_AIGAIN 0x0000
57 #define ADE9000_REG_AIGAIN0 0x0001
58 #define ADE9000_REG_AIGAIN1 0x0002
59 #define ADE9000_REG_AIGAIN2 0x0003
60 #define ADE9000_REG_AIGAIN3 0x0004
61 #define ADE9000_REG_AIGAIN4 0x0005
62 #define ADE9000_REG_APHCAL0 0x0006
63 #define ADE9000_REG_APHCAL1 0x0007
64 #define ADE9000_REG_APHCAL2 0x0008
65 #define ADE9000_REG_APHCAL3 0x0009
66 #define ADE9000_REG_APHCAL4 0x000A
67 #define ADE9000_REG_AVGAIN 0x000B
68 #define ADE9000_REG_AIRMSOS 0x000C
69 #define ADE9000_REG_AVRMSOS 0x000D
70 #define ADE9000_REG_APGAIN 0x000E
71 #define ADE9000_REG_AWATTOS 0x000F
72 #define ADE9000_REG_AVAROS 0x0010
73 #define ADE9000_REG_AFWATTOS 0x0011
74 #define ADE9000_REG_AFVAROS 0x0012
75 #define ADE9000_REG_AIFRMSOS 0x0013
76 #define ADE9000_REG_AVFRMSOS 0x0014
77 #define ADE9000_REG_AVRMSONEOS 0x0015
78 #define ADE9000_REG_AIRMSONEOS 0x0016
79 #define ADE9000_REG_AVRMS1012OS 0x0017
80 #define ADE9000_REG_AIRMS1012OS 0x0018
81 #define ADE9000_REG_BIGAIN 0x0020
82 #define ADE9000_REG_BIGAIN0 0x0021
83 #define ADE9000_REG_BIGAIN1 0x0022
84 #define ADE9000_REG_BIGAIN2 0x0023
85 #define ADE9000_REG_BIGAIN3 0x0024
86 #define ADE9000_REG_BIGAIN4 0x0025
87 #define ADE9000_REG_BPHCAL0 0x0026
88 #define ADE9000_REG_BPHCAL1 0x0027
89 #define ADE9000_REG_BPHCAL2 0x0028
90 #define ADE9000_REG_BPHCAL3 0x0029
91 #define ADE9000_REG_BPHCAL4 0x002A
92 #define ADE9000_REG_BVGAIN 0x002B
93 #define ADE9000_REG_BIRMSOS 0x002C
94 #define ADE9000_REG_BVRMSOS 0x002D
95 #define ADE9000_REG_BPGAIN 0x002E
96 #define ADE9000_REG_BWATTOS 0x002F
97 #define ADE9000_REG_BVAROS 0x0030
98 #define ADE9000_REG_BFWATTOS 0x0031
99 #define ADE9000_REG_BFVAROS 0x0032
100 #define ADE9000_REG_BIFRMSOS 0x0033
101 #define ADE9000_REG_BVFRMSOS 0x0034
102 #define ADE9000_REG_BVRMSONEOS 0x0035
103 #define ADE9000_REG_BIRMSONEOS 0x0036
104 #define ADE9000_REG_BVRMS1012OS 0x0037
105 #define ADE9000_REG_BIRMS1012OS 0x0038
106 #define ADE9000_REG_CIGAIN 0x0040
107 #define ADE9000_REG_CIGAIN0 0x0041
108 #define ADE9000_REG_CIGAIN1 0x0042
109 #define ADE9000_REG_CIGAIN2 0x0043
110 #define ADE9000_REG_CIGAIN3 0x0044
111 #define ADE9000_REG_CIGAIN4 0x0045
112 #define ADE9000_REG_CPHCAL0 0x0046
113 #define ADE9000_REG_CPHCAL1 0x0047
114 #define ADE9000_REG_CPHCAL2 0x0048
115 #define ADE9000_REG_CPHCAL3 0x0049
116 #define ADE9000_REG_CPHCAL4 0x004A
117 #define ADE9000_REG_CVGAIN 0x004B
118 #define ADE9000_REG_CIRMSOS 0x004C
119 #define ADE9000_REG_CVRMSOS 0x004D
120 #define ADE9000_REG_CPGAIN 0x004E
121 #define ADE9000_REG_CWATTOS 0x004F
122 #define ADE9000_REG_CVAROS 0x0050
123 #define ADE9000_REG_CFWATTOS 0x0051
124 #define ADE9000_REG_CFVAROS 0x0052
125 #define ADE9000_REG_CIFRMSOS 0x0053
126 #define ADE9000_REG_CVFRMSOS 0x0054
127 #define ADE9000_REG_CVRMSONEOS 0x0055
128 #define ADE9000_REG_CIRMSONEOS 0x0056
129 #define ADE9000_REG_CVRMS1012OS 0x0057
130 #define ADE9000_REG_CIRMS1012OS 0x0058
131 #define ADE9000_REG_CONFIG0 0x0060
132 #define ADE9000_REG_MTTHR_L0 0x0061
133 #define ADE9000_REG_MTTHR_L1 0x0062
134 #define ADE9000_REG_MTTHR_L2 0x0063
135 #define ADE9000_REG_MTTHR_L3 0x0064
136 #define ADE9000_REG_MTTHR_L4 0x0065
137 #define ADE9000_REG_MTTHR_H0 0x0066
138 #define ADE9000_REG_MTTHR_H1 0x0067
139 #define ADE9000_REG_MTTHR_H2 0x0068
140 #define ADE9000_REG_MTTHR_H3 0x0069
141 #define ADE9000_REG_MTTHR_H4 0x006A
142 #define ADE9000_REG_NIRMSOS 0x006B
143 #define ADE9000_REG_ISUMRMSOS 0x006C
144 #define ADE9000_REG_NIGAIN 0x006D
145 #define ADE9000_REG_NPHCAL 0x006E
146 #define ADE9000_REG_NIRMSONEOS 0x006F
147 #define ADE9000_REG_NIRMS1012OS 0x0070
148 #define ADE9000_REG_VNOM 0x0071
149 #define ADE9000_REG_DICOEFF 0x0072
150 #define ADE9000_REG_ISUMLVL 0x0073
151 #define ADE9000_REG_AI_PCF 0x020A
152 #define ADE9000_REG_AV_PCF 0x020B
153 #define ADE9000_REG_AIRMS 0x020C
154 #define ADE9000_REG_AVRMS 0x020D
155 #define ADE9000_REG_AIFRMS 0x020E
156 #define ADE9000_REG_AVFRMS 0x020F
157 #define ADE9000_REG_AWATT 0x0210
158 #define ADE9000_REG_AVAR 0x0211
159 #define ADE9000_REG_AVA 0x0212
160 #define ADE9000_REG_AFWATT 0x0213
161 #define ADE9000_REG_AFVAR 0x0214
162 #define ADE9000_REG_AFVA 0x0215
163 #define ADE9000_REG_APF 0x0216
164 #define ADE9000_REG_AVTHD 0x0217
165 #define ADE9000_REG_AITHD 0x0218
166 #define ADE9000_REG_AIRMSONE 0x0219
167 #define ADE9000_REG_AVRMSONE 0x021A
168 #define ADE9000_REG_AIRMS1012 0x021B
169 #define ADE9000_REG_AVRMS1012 0x021C
170 #define ADE9000_REG_AMTREGION 0x021D
171 #define ADE9000_REG_BI_PCF 0x022A
172 #define ADE9000_REG_BV_PCF 0x022B
173 #define ADE9000_REG_BIRMS 0x022C
174 #define ADE9000_REG_BVRMS 0x022D
175 #define ADE9000_REG_BIFRMS 0x022E
176 #define ADE9000_REG_BVFRMS 0x022F
177 #define ADE9000_REG_BWATT 0x0230
178 #define ADE9000_REG_BVAR 0x0231
179 #define ADE9000_REG_BVA 0x0232
180 #define ADE9000_REG_BFWATT 0x0233
181 #define ADE9000_REG_BFVAR 0x0234
182 #define ADE9000_REG_BFVA 0x0235
183 #define ADE9000_REG_BPF 0x0236
184 #define ADE9000_REG_BVTHD 0x0237
185 #define ADE9000_REG_BITHD 0x0238
186 #define ADE9000_REG_BIRMSONE 0x0239
187 #define ADE9000_REG_BVRMSONE 0x023A
188 #define ADE9000_REG_BIRMS1012 0x023B
189 #define ADE9000_REG_BVRMS1012 0x023C
190 #define ADE9000_REG_BMTREGION 0x023D
191 #define ADE9000_REG_CI_PCF 0x024A
192 #define ADE9000_REG_CV_PCF 0x024B
193 #define ADE9000_REG_CIRMS 0x024C
194 #define ADE9000_REG_CVRMS 0x024D
195 #define ADE9000_REG_CIFRMS 0x024E
196 #define ADE9000_REG_CVFRMS 0x024F
197 #define ADE9000_REG_CWATT 0x0250
198 #define ADE9000_REG_CVAR 0x0251
199 #define ADE9000_REG_CVA 0x0252
200 #define ADE9000_REG_CFWATT 0x0253
201 #define ADE9000_REG_CFVAR 0x0254
202 #define ADE9000_REG_CFVA 0x0255
203 #define ADE9000_REG_CPF 0x0256
204 #define ADE9000_REG_CVTHD 0x0257
205 #define ADE9000_REG_CITHD 0x0258
206 #define ADE9000_REG_CIRMSONE 0x0259
207 #define ADE9000_REG_CVRMSONE 0x025A
208 #define ADE9000_REG_CIRMS1012 0x025B
209 #define ADE9000_REG_CVRMS1012 0x025C
210 #define ADE9000_REG_CMTREGION 0x025D
211 #define ADE9000_REG_NI_PCF 0x0265
212 #define ADE9000_REG_NIRMS 0x0266
213 #define ADE9000_REG_NIRMSONE 0x0267
214 #define ADE9000_REG_NIRMS1012 0x0268
215 #define ADE9000_REG_ISUMRMS 0x0269
216 #define ADE9000_REG_VERSION2 0x026A
217 #define ADE9000_REG_AWATT_ACC 0x02E5
218 #define ADE9000_REG_AWATTHR_LO 0x02E6
219 #define ADE9000_REG_AWATTHR_HI 0x02E7
220 #define ADE9000_REG_AVAR_ACC 0x02EF
221 #define ADE9000_REG_AVARHR_LO 0x02F0
222 #define ADE9000_REG_AVARHR_HI 0x02F1
223 #define ADE9000_REG_AVA_ACC 0x02F9
224 #define ADE9000_REG_AVAHR_LO 0x02FA
225 #define ADE9000_REG_AVAHR_HI 0x02FB
226 #define ADE9000_REG_AFWATT_ACC 0x0303
227 #define ADE9000_REG_AFWATTHR_LO 0x0304
228 #define ADE9000_REG_AFWATTHR_HI 0x0305
229 #define ADE9000_REG_AFVAR_ACC 0x030D
230 #define ADE9000_REG_AFVARHR_LO 0x030E
231 #define ADE9000_REG_AFVARHR_HI 0x030F
232 #define ADE9000_REG_AFVA_ACC 0x0317
233 #define ADE9000_REG_AFVAHR_LO 0x0318
234 #define ADE9000_REG_AFVAHR_HI 0x0319
235 #define ADE9000_REG_BWATT_ACC 0x0321
236 #define ADE9000_REG_BWATTHR_LO 0x0322
237 #define ADE9000_REG_BWATTHR_HI 0x0323
238 #define ADE9000_REG_BVAR_ACC 0x032B
239 #define ADE9000_REG_BVARHR_LO 0x032C
240 #define ADE9000_REG_BVARHR_HI 0x032D
241 #define ADE9000_REG_BVA_ACC 0x0335
242 #define ADE9000_REG_BVAHR_LO 0x0336
243 #define ADE9000_REG_BVAHR_HI 0x0337
244 #define ADE9000_REG_BFWATT_ACC 0x033F
245 #define ADE9000_REG_BFWATTHR_LO 0x0340
246 #define ADE9000_REG_BFWATTHR_HI 0x0341
247 #define ADE9000_REG_BFVAR_ACC 0x0349
248 #define ADE9000_REG_BFVARHR_LO 0x034A
249 #define ADE9000_REG_BFVARHR_HI 0x034B
250 #define ADE9000_REG_BFVA_ACC 0x0353
251 #define ADE9000_REG_BFVAHR_LO 0x0354
252 #define ADE9000_REG_BFVAHR_HI 0x0355
253 #define ADE9000_REG_CWATT_ACC 0x035D
254 #define ADE9000_REG_CWATTHR_LO 0x035E
255 #define ADE9000_REG_CWATTHR_HI 0x035F
256 #define ADE9000_REG_CVAR_ACC 0x0367
257 #define ADE9000_REG_CVARHR_LO 0x0368
258 #define ADE9000_REG_CVARHR_HI 0x0369
259 #define ADE9000_REG_CVA_ACC 0x0371
260 #define ADE9000_REG_CVAHR_LO 0x0372
261 #define ADE9000_REG_CVAHR_HI 0x0373
262 #define ADE9000_REG_CFWATT_ACC 0x037B
263 #define ADE9000_REG_CFWATTHR_LO 0x037C
264 #define ADE9000_REG_CFWATTHR_HI 0x037D
265 #define ADE9000_REG_CFVAR_ACC 0x0385
266 #define ADE9000_REG_CFVARHR_LO 0x0386
267 #define ADE9000_REG_CFVARHR_HI 0x0387
268 #define ADE9000_REG_CFVA_ACC 0x038F
269 #define ADE9000_REG_CFVAHR_LO 0x0390
270 #define ADE9000_REG_CFVAHR_HI 0x0391
271 #define ADE9000_REG_PWATT_ACC 0x0397
272 #define ADE9000_REG_NWATT_ACC 0x039B
273 #define ADE9000_REG_PVAR_ACC 0x039F
274 #define ADE9000_REG_NVAR_ACC 0x03A3
275 #define ADE9000_REG_IPEAK 0x0400
276 #define ADE9000_REG_VPEAK 0x0401
277 #define ADE9000_REG_STATUS0 0x0402
278 #define ADE9000_REG_STATUS1 0x0403
279 #define ADE9000_REG_EVENT_STATUS 0x0404
280 #define ADE9000_REG_MASK0 0x0405
281 #define ADE9000_REG_MASK1 0x0406
282 #define ADE9000_REG_EVENT_MASK 0x0407
283 #define ADE9000_REG_OILVL 0x0409
284 #define ADE9000_REG_OIA 0x040A
285 #define ADE9000_REG_OIB 0x040B
286 #define ADE9000_REG_OIC 0x040C
287 #define ADE9000_REG_OIN 0x040D
288 #define ADE9000_REG_USER_PERIOD 0x040E
289 #define ADE9000_REG_VLEVEL 0x040F
290 #define ADE9000_REG_DIP_LVL 0x410
291 #define ADE9000_REG_DIPA 0x411
292 #define ADE9000_REG_DIPB 0x412
293 #define ADE9000_REG_DIPC 0x413
294 #define ADE9000_REG_SWELL_LVL 0x414
295 #define ADE9000_REG_SWELLA 0x415
296 #define ADE9000_REG_SWELLB 0x416
297 #define ADE9000_REG_SWELLC 0x417
298 #define ADE9000_REG_APERIOD 0x0418
299 #define ADE9000_REG_BPERIOD 0x0419
300 #define ADE9000_REG_CPERIOD 0x041A
301 #define ADE9000_REG_COM_PERIOD 0x041B
302 #define ADE9000_REG_ACT_NL_LVL 0x041C
303 #define ADE9000_REG_REACT_NL_LVL 0x041D
304 #define ADE9000_REG_APP_NL_LVL 0x041E
305 #define ADE9000_REG_PHNOLOAD 0x041F
306 #define ADE9000_REG_WTHR 0x0420
307 #define ADE9000_REG_VARTHR 0x0421
308 #define ADE9000_REG_VATHR 0x0422
309 #define ADE9000_REG_LAST_DATA_32 0x0423
310 #define ADE9000_REG_ADC_REDIRECT 0x0424
311 #define ADE9000_REG_CF_LCFG 0x0425
312 #define ADE9000_REG_PART_ID 0x0472
313 #define ADE9000_REG_TEMP_TRIM 0x0474
314 #define ADE9000_REG_RUN 0x0480
315 #define ADE9000_REG_CONFIG1 0x0481
316 #define ADE9000_REG_ANGL_VA_VB 0x0482
317 #define ADE9000_REG_ANGL_VB_VC 0x0483
318 #define ADE9000_REG_ANGL_VA_VC 0x0484
319 #define ADE9000_REG_ANGL_VB_IA 0x0485
320 #define ADE9000_REG_ANGL_VB_IB 0x0486
321 #define ADE9000_REG_ANGL_VC_IC 0x0487
322 #define ADE9000_REG_ANGL_IA_IB 0x0488
323 #define ADE9000_REG_ANGL_IB_IC 0x0489
324 #define ADE9000_REG_ANGL_IA_IC 0x048A
325 #define ADE9000_REG_DIP_CYC 0x048B
326 #define ADE9000_REG_SWELL_CYC 0x048C
327 #define ADE9000_REG_OISTATUS 0x048F
328 #define ADE9000_REG_CFMODE 0x0490
329 #define ADE9000_REG_COMPMODE 0x0491
330 #define ADE9000_REG_ACCMODE 0x0492
331 #define ADE9000_REG_CONFIG3 0x0493
332 #define ADE9000_REG_CF1DEN 0x0494
333 #define ADE9000_REG_CF2DEN 0x0495
334 #define ADE9000_REG_CF3DEN 0x0496
335 #define ADE9000_REG_CF4DEN 0x0497
336 #define ADE9000_REG_ZXTOUT 0x0498
337 #define ADE9000_REG_ZXTHRSH 0x0499
338 #define ADE9000_REG_ZX_LP_SEL 0x049A
339 #define ADE9000_REG_SEQ_CYC 0x049C
340 #define ADE9000_REG_PHSIGN 0x049D
341 #define ADE9000_REG_WFB_CFG 0x04A0
342 #define ADE9000_REG_WFB_PG_IRQEN 0x04A1
343 #define ADE9000_REG_WFB_TRG_CFG 0x04A2
344 #define ADE9000_REG_WFB_TRG_STAT 0x04A3
345 #define ADE9000_REG_CONFIG5 0x04A4
346 #define ADE9000_REG_CRC_RSLT 0x04A8
347 #define ADE9000_REG_CRC_SPI 0x04A9
348 #define ADE9000_REG_LAST_DATA_16 0x04AC
349 #define ADE9000_REG_LAST_CMD 0x04AE
350 #define ADE9000_REG_CONFIG2 0x04AF
351 #define ADE9000_REG_EP_CFG 0x04B0
352 #define ADE9000_REG_PWR_TIME 0x04B1
353 #define ADE9000_REG_EGY_TIME 0x04B2
354 #define ADE9000_REG_CRC_FORCE 0x04B4
355 #define ADE9000_REG_CRC_OPTEN 0x04B5
356 #define ADE9000_REG_TEMP_CFG 0x04B6
357 #define ADE9000_REG_TEMP_RSLT 0x04B7
358 #define ADE9000_REG_PGA_GAIN 0x04B9
359 #define ADE9000_REG_CHNL_DIS 0x04BA
360 #define ADE9000_REG_WR_LOCK 0x04BF
361 #define ADE9000_REG_VAR_DIS 0x04E0
362 #define ADE9000_REG_RESERVED1 0x04F0
363 #define ADE9000_REG_VERSION 0x04FE
364 #define ADE9000_REG_AI_SINC_DAT 0x0500
365 #define ADE9000_REG_AV_SINC_DAT 0x0501
366 #define ADE9000_REG_BI_SINC_DAT 0x0502
367 #define ADE9000_REG_BV_SINC_DAT 0x0503
368 #define ADE9000_REG_CI_SINC_DAT 0x0504
369 #define ADE9000_REG_CV_SINC_DAT 0x0505
370 #define ADE9000_REG_NI_SINC_DAT 0x0506
371 #define ADE9000_REG_AI_LPF_DAT 0x0510
372 #define ADE9000_REG_AV_LPF_DAT 0x0511
373 #define ADE9000_REG_BI_LPF_DAT 0x0512
374 #define ADE9000_REG_BV_LPF_DAT 0x0513
375 #define ADE9000_REG_CI_LPF_DAT 0x0514
376 #define ADE9000_REG_CV_LPF_DAT 0x0515
377 #define ADE9000_REG_NI_LPF_DAT 0x0516
378 #define ADE9000_REG_AV_PCF_1 0x0600
379 #define ADE9000_REG_BV_PCF_1 0x0601
380 #define ADE9000_REG_CV_PCF_1 0x0602
381 #define ADE9000_REG_NI_PCF_1 0x0603
382 #define ADE9000_REG_AI_PCF_1 0x0604
383 #define ADE9000_REG_BI_PCF_1 0x0605
384 #define ADE9000_REG_CI_PCF_1 0x0606
385 #define ADE9000_REG_AIRMS_1 0x0607
386 #define ADE9000_REG_BIRMS_1 0x0608
387 #define ADE9000_REG_CIRMS_1 0x0609
388 #define ADE9000_REG_AVRMS_1 0x060A
389 #define ADE9000_REG_BVRMS_1 0x060B
390 #define ADE9000_REG_CVRMS_1 0x060C
391 #define ADE9000_REG_NIRMS_1 0x060D
392 #define ADE9000_REG_AWATT_1 0x060E
393 #define ADE9000_REG_BWATT_1 0x060F
394 #define ADE9000_REG_CWATT_1 0x0610
395 #define ADE9000_REG_AVA_1 0x0611
396 #define ADE9000_REG_BVA_1 0x0612
397 #define ADE9000_REG_CVA_1 0x0613
398 #define ADE9000_REG_AVAR_1 0x0614
399 #define ADE9000_REG_BVAR_1 0x0615
400 #define ADE9000_REG_CVAR_1 0x0616
401 #define ADE9000_REG_AFVAR_1 0x0617
402 #define ADE9000_REG_BFVAR_1 0x0618
403 #define ADE9000_REG_CFVAR_1 0x0619
404 #define ADE9000_REG_APF_1 0x061A
405 #define ADE9000_REG_BPF_1 0x061B
406 #define ADE9000_REG_CPF_1 0x061C
407 #define ADE9000_REG_AVTHD_1 0x061D
408 #define ADE9000_REG_BVTHD_1 0x061E
409 #define ADE9000_REG_CVTHD_1 0x061F
410 #define ADE9000_REG_AITHD_1 0x0620
411 #define ADE9000_REG_BITHD_1 0x0621
412 #define ADE9000_REG_CITHD_1 0x0622
413 #define ADE9000_REG_AFWATT_1 0x0623
414 #define ADE9000_REG_BFWATT_1 0x0624
415 #define ADE9000_REG_CFWATT_1 0x0625
416 #define ADE9000_REG_AFVA_1 0x0626
417 #define ADE9000_REG_BFVA_1 0x0627
418 #define ADE9000_REG_CFVA_1 0x0628
419 #define ADE9000_REG_AFIRMS_1 0x0629
420 #define ADE9000_REG_BFIRMS_1 0x062A
421 #define ADE9000_REG_CFIRMS_1 0x062B
422 #define ADE9000_REG_AFVRMS_1 0x062C
423 #define ADE9000_REG_BFVRMS_1 0x062D
424 #define ADE9000_REG_CFVRMS_1 0x062E
425 #define ADE9000_REG_AIRMSONE_1 0x062F
426 #define ADE9000_REG_BIRMSONE_1 0x0630
427 #define ADE9000_REG_CIRMSONE_1 0x0631
428 #define ADE9000_REG_AVRMSONE_1 0x0622
429 #define ADE9000_REG_BVRMSONE_1 0x0633
430 #define ADE9000_REG_CVRMSONE_1 0x0634
431 #define ADE9000_REG_NIRSONE_1 0x0635
432 #define ADE9000_REG_AIRMS1012_1 0x0636
433 #define ADE9000_REG_BIRMS1012_1 0x0637
434 #define ADE9000_REG_CIRMS1012_1 0x0638
435 #define ADE9000_REG_AVRMS1012_1 0x0639
436 #define ADE9000_REG_BVRMS1012_1 0x063A
437 #define ADE9000_REG_CVRMS1012_1 0x063B
438 #define ADE9000_REG_NIRMS1012_1 0x063C
439 #define ADE9000_REG_AV_PCF_2 0x0680
440 #define ADE9000_REG_AI_PCF_2 0x0681
441 #define ADE9000_REG_AIRMS_2 0x0682
442 #define ADE9000_REG_AVRMS_2 0x0683
443 #define ADE9000_REG_AWATT_2 0x0684
444 #define ADE9000_REG_AVA_2 0x0685
445 #define ADE9000_REG_AVAR_2 0x0686
446 #define ADE9000_REG_AFVAR_2 0x0687
447 #define ADE9000_REG_APF_2 0x0688
448 #define ADE9000_REG_AVTHD_2 0x0689
449 #define ADE9000_REG_AITHD_2 0x068A
450 #define ADE9000_REG_AFWATT_2 0x068B
451 #define ADE9000_REG_AFVA_2 0x068C
452 #define ADE9000_REG_AFIRMS_2 0x068D
453 #define ADE9000_REG_AFVRMS_2 0x068E
454 #define ADE9000_REG_AIRMSONE_2 0x068F
455 #define ADE9000_REG_AVRMSONE_2 0x0690
456 #define ADE9000_REG_AIRMS1012_2 0x0691
457 #define ADE9000_REG_AVRMS1012_2 0x0692
458 #define ADE9000_REG_BV_PCF_2 0x0693
459 #define ADE9000_REG_BI_PCF_2 0x0694
460 #define ADE9000_REG_BIRMS_2 0x0695
461 #define ADE9000_REG_BVRMS_2 0x0696
462 #define ADE9000_REG_BWATT_2 0x0697
463 #define ADE9000_REG_BVA_2 0x0698
464 #define ADE9000_REG_BVAR_2 0x0699
465 #define ADE9000_REG_BFVAR_2 0x069A
466 #define ADE9000_REG_BPF_2 0x069B
467 #define ADE9000_REG_BVTHD_2 0x069C
468 #define ADE9000_REG_BITHD_2 0x069D
469 #define ADE9000_REG_BFWATT_2 0x069E
470 #define ADE9000_REG_BFVA_2 0x069F
471 #define ADE9000_REG_BFIRMS_2 0x06A0
472 #define ADE9000_REG_BFVRMS_2 0x06A1
473 #define ADE9000_REG_BIRMSONE_2 0x06A2
474 #define ADE9000_REG_BVRMSONE_2 0x06A3
475 #define ADE9000_REG_BIRMS1012_2 0x06A4
476 #define ADE9000_REG_BVRMS1012_2 0x06A5
477 #define ADE9000_REG_CV_PCF_2 0x06A6
478 #define ADE9000_REG_CI_PCF_2 0x06A7
479 #define ADE9000_REG_CIRMS_2 0x06A8
480 #define ADE9000_REG_CVRMS_2 0x06A9
481 #define ADE9000_REG_CWATT_2 0x06AA
482 #define ADE9000_REG_CVA_2 0x06AB
483 #define ADE9000_REG_CVAR_2 0x06AC
484 #define ADE9000_REG_CFVAR_2 0x06AD
485 #define ADE9000_REG_CPF_2 0x06AE
486 #define ADE9000_REG_CVTHD_2 0x06AF
487 #define ADE9000_REG_CITHD_2 0x06B0
488 #define ADE9000_REG_CFWATT_2 0x06B1
489 #define ADE9000_REG_CFVA_2 0x06B2
490 #define ADE9000_REG_CFIRMS_2 0x06B3
491 #define ADE9000_REG_CFVRMS_2 0x06B4
492 #define ADE9000_REG_CIRMSONE_2 0x06B5
493 #define ADE9000_REG_CVRMSONE_2 0x06B6
494 #define ADE9000_REG_CIRMS1012_2 0x06B7
495 #define ADE9000_REG_CVRMS1012_2 0x06B8
496 #define ADE9000_REG_NI_PCF_2 0x06B9
497 #define ADE9000_REG_NIRMS_2 0x06BA
498 #define ADE9000_REG_NIRMSONE_2 0x06BB
499 #define ADE9000_REG_NIRMS1012_2 0x06BC
500 
501 /* ADE9000_REG_CONFIG0 Bit Definition */
502 #define ADE9000_DISRPLPF NO_OS_BIT(13)
503 #define ADE9000_DISAPLPF NO_OS_BIT(12)
504 #define ADE9000_ININTEN NO_OS_BIT(11)
505 #define ADE9000_VNOMC_EN NO_OS_BIT(10)
506 #define ADE9000_VNOMB_EN NO_OS_BIT(9)
507 #define ADE9000_VNOMA_EN NO_OS_BIT(8)
508 #define ADE9000_RMS_SRC_SEL NO_OS_BIT(7)
509 #define ADE9000_ZX_SRC_SEL NO_OS_BIT(6)
510 #define ADE9000_INTEN NO_OS_BIT(5)
511 #define ADE9000_MTEN NO_OS_BIT(4)
512 #define ADE9000_HPFDIS NO_OS_BIT(3)
513 #define ADE9000_ISUM_CFG NO_OS_GENMASK(1, 0)
514 
515 /* ADE9000_REG_AMTREGION Bit Definition */
516 #define ADE9000_AREGION NO_OS_GENMASK(3, 0)
517 
518 /* ADE9000_REG_BMTREGION Bit Definition */
519 #define ADE9000_BREGION NO_OS_GENMASK(3, 0)
520 
521 /* ADE9000_REG_CMTREGION Bit Definition */
522 #define ADE9000_CREGION NO_OS_GENMASK(3, 0)
523 
524 /* ADE9000_REG_IPEAK Bit Definition */
525 #define ADE9000_IPPHASE NO_OS_GENMASK(26, 24)
526 #define ADE9000_IPEAKVAL NO_OS_GENMASK(23, 0)
527 
528 /* ADE9000_REG_VPEAK Bit Definition */
529 #define ADE9000_VPPHASE NO_OS_GENMASK(26, 24)
530 #define ADE9000_VPEAKVAL NO_OS_GENMASK(23, 0)
531 
532 /* ADE9000_REG_STATUS0 Bit Definition */
533 #define ADE9000_STATUS0_TEMP_RDY NO_OS_BIT(25)
534 #define ADE9000_STATUS0_MISMTCH NO_OS_BIT(24)
535 #define ADE9000_STATUS0_COH_PAGE_RDY NO_OS_BIT(23)
536 #define ADE9000_STATUS0_WFB_TRIG NO_OS_BIT(22)
537 #define ADE9000_STATUS0_THD_PF_RDY NO_OS_BIT(21)
538 #define ADE9000_STATUS0_RMS1012RDY NO_OS_BIT(20)
539 #define ADE9000_STATUS0_RMSONERDY NO_OS_BIT(19)
540 #define ADE9000_STATUS0_PWRRDY NO_OS_BIT(18)
541 #define ADE9000_STATUS0_PAGE_FULL NO_OS_BIT(17)
542 #define ADE9000_STATUS0_WFB_TRIG_IRQ NO_OS_BIT(16)
543 #define ADE9000_STATUS0_DREADY NO_OS_BIT(15)
544 #define ADE9000_STATUS0_CF4 NO_OS_BIT(14)
545 #define ADE9000_STATUS0_CF3 NO_OS_BIT(13)
546 #define ADE9000_STATUS0_CF2 NO_OS_BIT(12)
547 #define ADE9000_STATUS0_CF1 NO_OS_BIT(11)
548 #define ADE9000_STATUS0_REVPSUM4 NO_OS_BIT(10)
549 #define ADE9000_STATUS0_REVPSUM3 NO_OS_BIT(9)
550 #define ADE9000_STATUS0_REVPSUM2 NO_OS_BIT(8)
551 #define ADE9000_STATUS0_REVPSUM1 NO_OS_BIT(7)
552 #define ADE9000_STATUS0_REVRPC NO_OS_BIT(6)
553 #define ADE9000_STATUS0_REVRPB NO_OS_BIT(5)
554 #define ADE9000_STATUS0_REVRPA NO_OS_BIT(4)
555 #define ADE9000_STATUS0_REVAPC NO_OS_BIT(3)
556 #define ADE9000_STATUS0_REVAPB NO_OS_BIT(2)
557 #define ADE9000_STATUS0_REVAPA NO_OS_BIT(1)
558 #define ADE9000_STATUS0_EGYRDY NO_OS_BIT(0)
559 
560 /* ADE9000_REG_STATUS1 Bit Definition */
561 #define ADE9000_STATUS1_ERROR3 NO_OS_BIT(31)
562 #define ADE9000_STATUS1_ERROR2 NO_OS_BIT(30)
563 #define ADE9000_STATUS1_ERROR1 NO_OS_BIT(29)
564 #define ADE9000_STATUS1_ERROR0 NO_OS_BIT(28)
565 #define ADE9000_STATUS1_CRC_DONE NO_OS_BIT(27)
566 #define ADE9000_STATUS1_CRC_CHG NO_OS_BIT(26)
567 #define ADE9000_STATUS1_DIPC NO_OS_BIT(25)
568 #define ADE9000_STATUS1_DIPB NO_OS_BIT(24)
569 #define ADE9000_STATUS1_DIPA NO_OS_BIT(23)
570 #define ADE9000_STATUS1_SWELLC NO_OS_BIT(22)
571 #define ADE9000_STATUS1_SWELLB NO_OS_BIT(21)
572 #define ADE9000_STATUS1_SWELLA NO_OS_BIT(20)
573 #define ADE9000_STATUS1_SEQERR NO_OS_BIT(18)
574 #define ADE9000_STATUS1_OI NO_OS_BIT(17)
575 #define ADE9000_STATUS1_RSTDONE NO_OS_BIT(16)
576 #define ADE9000_STATUS1_ZXIC NO_OS_BIT(15)
577 #define ADE9000_STATUS1_ZXIB NO_OS_BIT(14)
578 #define ADE9000_STATUS1_ZXIA NO_OS_BIT(13)
579 #define ADE9000_STATUS1_ZXCOMB NO_OS_BIT(12)
580 #define ADE9000_STATUS1_ZXVC NO_OS_BIT(11)
581 #define ADE9000_STATUS1_ZXVB NO_OS_BIT(10)
582 #define ADE9000_STATUS1_ZXVA NO_OS_BIT(9)
583 #define ADE9000_STATUS1_ZXTOVC NO_OS_BIT(8)
584 #define ADE9000_STATUS1_ZXTOVB NO_OS_BIT(7)
585 #define ADE9000_STATUS1_ZXTOVA NO_OS_BIT(6)
586 #define ADE9000_STATUS1_VAFNOLOAD NO_OS_BIT(5)
587 #define ADE9000_STATUS1_RFNOLOAD NO_OS_BIT(4)
588 #define ADE9000_STATUS1_AFNOLOAD NO_OS_BIT(3)
589 #define ADE9000_STATUS1_VANLOAD NO_OS_BIT(2)
590 #define ADE9000_STATUS1_RNLOAD NO_OS_BIT(1)
591 #define ADE9000_STATUS1_ANLOAD NO_OS_BIT(0)
592 
593 /* ADE9000_REG_EVENT_STATUS Bit Definition */
594 #define ADE9000_EVENT_DREADY NO_OS_BIT(16)
595 #define ADE9000_EVENT_VAFNOLOAD NO_OS_BIT(15)
596 #define ADE9000_EVENT_RFNOLOAD NO_OS_BIT(14)
597 #define ADE9000_EVENT_AFNOLOAD NO_OS_BIT(13)
598 #define ADE9000_EVENT_VANLOAD NO_OS_BIT(12)
599 #define ADE9000_EVENT_RNLOAD NO_OS_BIT(11)
600 #define ADE9000_EVENT_ANLOAD NO_OS_BIT(10)
601 #define ADE9000_EVENT_REVPSUM4 NO_OS_BIT(9)
602 #define ADE9000_EVENT_REVPSUM3 NO_OS_BIT(8)
603 #define ADE9000_EVENT_REVPSUM2 NO_OS_BIT(7)
604 #define ADE9000_EVENT_REVPSUM1 NO_OS_BIT(6)
605 #define ADE9000_EVENT_SWELLC NO_OS_BIT(5)
606 #define ADE9000_EVENT_SWELLB NO_OS_BIT(4)
607 #define ADE9000_EVENT_SWELLA NO_OS_BIT(3)
608 #define ADE9000_EVENT_DIPC NO_OS_BIT(2)
609 #define ADE9000_EVENT_DIPB NO_OS_BIT(1)
610 #define ADE9000_EVENT_DIPA NO_OS_BIT(0)
611 
612 /* ADE9000_REG_MASK0 Bit Definition */
613 #define ADE9000_MASK0_TEMP_RDY NO_OS_BIT(25)
614 #define ADE9000_MASK0_MISMTCH NO_OS_BIT(24)
615 #define ADE9000_MASK0_COH_WFB_FULL NO_OS_BIT(23)
616 #define ADE9000_MASK0_WFB_TRIG NO_OS_BIT(22)
617 #define ADE9000_MASK0_THD_PF_RDY NO_OS_BIT(21)
618 #define ADE9000_MASK0_RMS1012RDY NO_OS_BIT(20)
619 #define ADE9000_MASK0_RMSONERDY NO_OS_BIT(19)
620 #define ADE9000_MASK0_PWRRDY NO_OS_BIT(18)
621 #define ADE9000_MASK0_PAGE_FULL NO_OS_BIT(17)
622 #define ADE9000_MASK0_WFB_TRIG_IRQ NO_OS_BIT(16)
623 #define ADE9000_MASK0_DREADY NO_OS_BIT(15)
624 #define ADE9000_MASK0_CF4 NO_OS_BIT(14)
625 #define ADE9000_MASK0_CF3 NO_OS_BIT(13)
626 #define ADE9000_MASK0_CF2 NO_OS_BIT(12)
627 #define ADE9000_MASK0_CF1 NO_OS_BIT(11)
628 #define ADE9000_MASK0_REVPSUM4 NO_OS_BIT(10)
629 #define ADE9000_MASK0_REVPSUM3 NO_OS_BIT(9)
630 #define ADE9000_MASK0_REVPSUM2 NO_OS_BIT(8)
631 #define ADE9000_MASK0_REVPSUM1 NO_OS_BIT(7)
632 #define ADE9000_MASK0_REVRPC NO_OS_BIT(6)
633 #define ADE9000_MASK0_REVRPB NO_OS_BIT(5)
634 #define ADE9000_MASK0_REVRPA NO_OS_BIT(4)
635 #define ADE9000_MASK0_REVAPC NO_OS_BIT(3)
636 #define ADE9000_MASK0_REVAPB NO_OS_BIT(2)
637 #define ADE9000_MASK0_REVAPA NO_OS_BIT(1)
638 #define ADE9000_MASK0_EGYRDY NO_OS_BIT(0)
639 
640 /* ADE9000_REG_MASK1 Bit Definition */
641 #define ADE9000_MASK1_ERROR3 NO_OS_BIT(31)
642 #define ADE9000_MASK1_ERROR2 NO_OS_BIT(30)
643 #define ADE9000_MASK1_ERROR1 NO_OS_BIT(29)
644 #define ADE9000_MASK1_ERROR0 NO_OS_BIT(28)
645 #define ADE9000_MASK1_CRC_DONE NO_OS_BIT(27)
646 #define ADE9000_MASK1_CRC_CHG NO_OS_BIT(26)
647 #define ADE9000_MASK1_DIPC NO_OS_BIT(25)
648 #define ADE9000_MASK1_DIPB NO_OS_BIT(24)
649 #define ADE9000_MASK1_DIPA NO_OS_BIT(23)
650 #define ADE9000_MASK1_SWELLC NO_OS_BIT(22)
651 #define ADE9000_MASK1_SWELLB NO_OS_BIT(21)
652 #define ADE9000_MASK1_SWELLA NO_OS_BIT(20)
653 #define ADE9000_MASK1_SEQERR NO_OS_BIT(18)
654 #define ADE9000_MASK1_OI NO_OS_BIT(17)
655 #define ADE9000_MASK1_ZXIC NO_OS_BIT(15)
656 #define ADE9000_MASK1_ZXIB NO_OS_BIT(14)
657 #define ADE9000_MASK1_ZXIA NO_OS_BIT(13)
658 #define ADE9000_MASK1_ZXCOMB NO_OS_BIT(12)
659 #define ADE9000_MASK1_ZXVC NO_OS_BIT(11)
660 #define ADE9000_MASK1_ZXVB NO_OS_BIT(10)
661 #define ADE9000_MASK1_ZXVA NO_OS_BIT(9)
662 #define ADE9000_MASK1_ZXTOVC NO_OS_BIT(8)
663 #define ADE9000_MASK1_ZXTOVB NO_OS_BIT(7)
664 #define ADE9000_MASK1_ZXTOVA NO_OS_BIT(6)
665 #define ADE9000_MASK1_VAFNOLOAD NO_OS_BIT(5)
666 #define ADE9000_MASK1_RFNOLOAD NO_OS_BIT(4)
667 #define ADE9000_MASK1_AFNOLOAD NO_OS_BIT(3)
668 #define ADE9000_MASK1_VANLOAD NO_OS_BIT(2)
669 #define ADE9000_MASK1_RNLOAD NO_OS_BIT(1)
670 #define ADE9000_MASK1_ANLOAD NO_OS_BIT(0)
671 
672 /* ADE9000_REG_EVENT_MASK Bit Definition */
673 #define ADE9000_EVENT_READY_MSK NO_OS_BIT(16)
674 #define ADE9000_EVENT_VAFNOLOAD_MSK NO_OS_BIT(15)
675 #define ADE9000_EVENT_RFNOLOAD_MSK NO_OS_BIT(14)
676 #define ADE9000_EVENT_AFNOLOAD_MSK NO_OS_BIT(13)
677 #define ADE9000_EVENT_VANLOAD_MSK NO_OS_BIT(12)
678 #define ADE9000_EVENT_RNLOAD_MSK NO_OS_BIT(11)
679 #define ADE9000_EVENT_ANLOAD_MSK NO_OS_BIT(10)
680 #define ADE9000_EVENT_REVPSUM4_MSK NO_OS_BIT(9)
681 #define ADE9000_EVENT_REVPSUM3_MSK NO_OS_BIT(8)
682 #define ADE9000_EVENT_REVPSUM2_MSK NO_OS_BIT(7)
683 #define ADE9000_EVENT_REVPSUM1_MSK NO_OS_BIT(6)
684 #define ADE9000_EVENT_SWELLCEN NO_OS_BIT(5)
685 #define ADE9000_EVENT_SWELLBEN NO_OS_BIT(4)
686 #define ADE9000_EVENT_SWELLAEN NO_OS_BIT(3)
687 #define ADE9000_EVENT_DIPCEN NO_OS_BIT(2)
688 #define ADE9000_EVENT_DIPBEN NO_OS_BIT(1)
689 #define ADE9000_EVENT_DIPAEN NO_OS_BIT(0)
690 
691 /* ADE9000_REG_OILVL Bit Definition */
692 #define ADE9000_OILVL_VAL NO_OS_GENMASK(23, 0)
693 
694 /* ADE9000_REG_OIA Bit Definition */
695 #define ADE9000_OI_VAL NO_OS_GENMASK(23, 0)
696 
697 /* ADE9000_REG_OIB Bit Definition */
698 #define ADE9000_OIB_VAL NO_OS_GENMASK(23, 0)
699 
700 /* ADE9000_REG_OIC Bit Definition */
701 #define ADE9000_OIC_VAL NO_OS_GENMASK(23, 0)
702 
703 /* ADE9000_REG_OIN Bit Definition */
704 #define ADE9000_OIN_VAL NO_OS_GENMASK(23, 0)
705 
706 /* ADE9000_REG_VLEVEL Bit Definition */
707 #define ADE9000_VLEVEL_VAL NO_OS_GENMASK(23, 0)
708 
709 /* ADE9000_REG_DIP_LVL Bit Definition */
710 #define ADE9000_DIPLVL NO_OS_GENMASK(23, 0)
711 
712 /* ADE9000_REG_DIPA Bit Definition */
713 #define ADE9000_DIPA_VAL NO_OS_GENMASK(23, 0)
714 
715 /* ADE9000_REG_DIPB Bit Definition */
716 #define ADE9000_DIPB_VAL NO_OS_GENMASK(23, 0)
717 
718 /* ADE9000_REG_DIPC Bit Definition */
719 #define ADE9000_DIPC_VAL NO_OS_GENMASK(23, 0)
720 
721 /* ADE9000_REG_SWELL_LVL Bit Definition */
722 #define ADE9000_SWELLLVL NO_OS_GENMASK(23, 0)
723 
724 /* ADE9000_REG_SWELLA Bit Definition */
725 #define ADE9000_SWELLA_VAL NO_OS_GENMASK(23, 0)
726 
727 /* ADE9000_REG_SWELLB Bit Definition */
728 #define ADE9000_SWELLB_VAL NO_OS_GENMASK(23, 0)
729 
730 /* ADE9000_REG_SWELLC Bit Definition */
731 #define ADE9000_SWELLC_VAL NO_OS_GENMASK(23, 0)
732 
733 /* ADE9000_REG_PHNOLOAD Bit Definition */
734 #define ADE9000_CFVANL NO_OS_BIT(17)
735 #define ADE9000_CFVARNL NO_OS_BIT(16)
736 #define ADE9000_CFWATTNL NO_OS_BIT(15)
737 #define ADE9000_CVANL NO_OS_BIT(14)
738 #define ADE9000_CVARNL NO_OS_BIT(13)
739 #define ADE9000_CWATTNL NO_OS_BIT(12)
740 #define ADE9000_BFVANL NO_OS_BIT(11)
741 #define ADE9000_BFVARNL NO_OS_BIT(10)
742 #define ADE9000_BFWATTNL NO_OS_BIT(9)
743 #define ADE9000_BVANL NO_OS_BIT(8)
744 #define ADE9000_BVARNL NO_OS_BIT(7)
745 #define ADE9000_BWATTNL NO_OS_BIT(6)
746 #define ADE9000_AFVANL NO_OS_BIT(5)
747 #define ADE9000_AFVARNL NO_OS_BIT(4)
748 #define ADE9000_AFWATTNL NO_OS_BIT(3)
749 #define ADE9000_AVANL NO_OS_BIT(2)
750 #define ADE9000_AVARNL NO_OS_BIT(1)
751 #define ADE9000_AWATTNL NO_OS_BIT(0)
752 
753 /* ADE9000_REG_ADC_REDIRECT Bit Definition */
754 #define ADE9000_VC_DIN NO_OS_GENMASK(20, 18)
755 #define ADE9000_VB_DIN NO_OS_GENMASK(17, 15)
756 #define ADE9000_VA_DIN NO_OS_GENMASK(14, 12)
757 #define ADE9000_IN_DIN NO_OS_GENMASK(11, 9)
758 #define ADE9000_IC_DIN NO_OS_GENMASK(8, 6)
759 #define ADE9000_IB_DIN NO_OS_GENMASK(5, 3)
760 #define ADE9000_IA_DIN NO_OS_GENMASK(2, 0)
761 
762 /* ADE9000_REG_CF_LCFG Bit Definition */
763 #define ADE9000_CF4_LT NO_OS_BIT(22)
764 #define ADE9000_CF3_LT NO_OS_BIT(21)
765 #define ADE9000_CF2_LT NO_OS_BIT(20)
766 #define ADE9000_CF1_LT NO_OS_BIT(19)
767 #define ADE9000_CF_LTMR NO_OS_GENMASK(18, 0)
768 
769 /* ADE9000_REG_PART_ID Bit Definition */
770 #define ADE9000_ADE9000_ID NO_OS_BIT(20)
771 
772 /* ADE9000_REG_TEMP_TRIM Bit Definition */
773 #define ADE9000_TEMP_OFFSET NO_OS_GENMASK(31, 16)
774 #define ADE9000_TEMP_GAIN NO_OS_GENMASK(15, 0)
775 
776 /* ADE9000_REG_CONFIG1 Bit Definition */
777 #define ADE9000_EXT_REF NO_OS_BIT(15)
778 #define ADE9000_IRQ0_ON_IRQ1 NO_OS_BIT(12)
779 #define ADE9000_BURST_EN NO_OS_BIT(11)
780 #define ADE9000_DIP_SWELL_IRQ_MODE NO_OS_BIT(10)
781 #define ADE9000_PWR_SETTLE NO_OS_GENMASK(9, 8)
782 #define ADE9000_CF_ACC_CLR NO_OS_BIT(5)
783 #define ADE9000_CF4_CFG NO_OS_GENMASK(3, 2)
784 #define ADE9000_CF3_CFG NO_OS_BIT(1)
785 #define ADE9000_SWRST NO_OS_BIT(0)
786 
787 /* ADE9000_REG_OISTATUS Bit Definition */
788 #define ADE9000_OIPHASE NO_OS_GENMASK(3, 0)
789 
790 /* ADE9000_REG_CFMODE Bit Definition */
791 #define ADE9000_CF4DIS NO_OS_BIT(15)
792 #define ADE9000_CF3DIS NO_OS_BIT(14)
793 #define ADE9000_CF2DIS NO_OS_BIT(13)
794 #define ADE9000_CF1DIS NO_OS_BIT(12)
795 #define ADE9000_CF4SEL NO_OS_GENMASK(11, 9)
796 #define ADE9000_CF3SEL NO_OS_GENMASK(8, 6)
797 #define ADE9000_CF2SEL NO_OS_GENMASK(5, 3)
798 #define ADE9000_CF1SEL NO_OS_GENMASK(2, 0)
799 
800 /* ADE9000_REG_COMPMODE Bit Definition */
801 #define ADE9000_TERMSEL4 NO_OS_GENMASK(11, 9)
802 #define ADE9000_TERMSEL3 NO_OS_GENMASK(8, 6)
803 #define ADE9000_TERMSEL2 NO_OS_GENMASK(5, 3)
804 #define ADE9000_TERMSEL1 NO_OS_GENMASK(2, 0)
805 
806 /* ADE9000_REG_ACCMODE Bit Definition */
807 #define ADE9000_SELFREQ NO_OS_BIT(8)
808 #define ADE9000_ICONSEL NO_OS_BIT(7)
809 #define ADE9000_VCONSEL NO_OS_GENMASK(6, 4)
810 #define ADE9000_VARACC NO_OS_GENMASK(3, 2)
811 #define ADE9000_WATTACC NO_OS_GENMASK(1, 0)
812 
813 /* ADE9000_REG_CONFIG3 Bit Definition */
814 #define ADE9000_OC_EN NO_OS_GENMASK(15, 12)
815 #define ADE9000_PEAKSEL NO_OS_GENMASK(4, 2)
816 
817 /* ADE9000_REG_ZX_LP_SEL Bit Definition */
818 #define ADE9000_LP_SEL NO_OS_GENMASK(4, 3)
819 #define ADE9000_ZX_SEL NO_OS_GENMASK(2, 1)
820 
821 /* ADE9000_REG_PHSIGN Bit Definition */
822 #define ADE9000_SUM4SIGN NO_OS_BIT(9)
823 #define ADE9000_SUM3SIGN NO_OS_BIT(8)
824 #define ADE9000_SUM2SIGN NO_OS_BIT(7)
825 #define ADE9000_SUM1SIGN NO_OS_BIT(6)
826 #define ADE9000_CVARSIGN NO_OS_BIT(5)
827 #define ADE9000_CWSIGN NO_OS_BIT(4)
828 #define ADE9000_BVARSIGN NO_OS_BIT(3)
829 #define ADE9000_BWSIGN NO_OS_BIT(2)
830 #define ADE9000_AVARSIGN NO_OS_BIT(1)
831 #define ADE9000_AWSIGN NO_OS_BIT(0)
832 
833 /* ADE9000_REG_WFB_CFG Bit Definition */
834 #define ADE9000_WF_IN_EN NO_OS_BIT(12)
835 #define ADE9000_WF_SRC NO_OS_GENMASK(9, 8)
836 #define ADE9000_WF_MODE NO_OS_BIT(7, 6)
837 #define ADE9000_WF_CAP_SEL NO_OS_BIT(5)
838 #define ADE9000_WF_CAP_EN NO_OS_BIT(4)
839 #define ADE9000_BURST_CHAN NO_OS_GENMASK(3, 0)
840 
841 /* ADE9000_WFB_TRG_CFG Bit Definition */
842 #define ADE9000_TRIG_FORCE NO_OS_BIT(10)
843 #define ADE9000_ZXCOMB NO_OS_BIT(9)
844 #define ADE9000_ZXVC NO_OS_BIT(8)
845 #define ADE9000_ZXVB NO_OS_BIT(7)
846 #define ADE9000_ZXVA NO_OS_BIT(6)
847 #define ADE9000_ZXIC NO_OS_BIT(5)
848 #define ADE9000_ZXIB NO_OS_BIT(4)
849 #define ADE9000_ZXIA NO_OS_BIT(3)
850 #define ADE9000_OI NO_OS_BIT(2)
851 #define ADE9000_SWELL NO_OS_BIT(1)
852 #define ADE9000_DIP NO_OS_BIT(0)
853 
854 /* ADE9000_WFB_TRG_STAT Bit Definition */
855 #define ADE9000_WFB_LAST_PAGE NO_OS_GENMASK(15, 12)
856 #define ADE9000_WFB_TRIG_ADDR NO_OS_GENMASK(10, 0)
857 
858 /* ADE9000_CONFIG2 Bit Definition */
859 #define ADE9000_UPERIOD_SEL NO_OS_BIT(12)
860 #define ADE9000_HPF_CRN NO_OS_GENMASK(11, 9)
861 
862 /* ADE9000_EP_CFG Bit Definition */
863 #define ADE9000_NOLOAD_TMR NO_OS_GENMASK(15, 13)
864 #define ADE9000_PWR_SIGN_SEL_1 NO_OS_BIT(7)
865 #define ADE9000_PWR_SIGN_SEL_0 NO_OS_BIT(6)
866 #define ADE9000_RD_RST_EN NO_OS_BIT(5)
867 #define ADE9000_EGY_LD_ACCUM NO_OS_BIT(4)
868 #define ADE9000_EGY_TMR_MODE NO_OS_BIT(1)
869 #define ADE9000_EGY_PWR_EN NO_OS_BIT(0)
870 
871 /* ADE9000_CRC_FORCE Bit Definition */
872 #define ADE9000_FORCE_CRC_UPDATE NO_OS_BIT(0)
873 
874 /* ADE9000_CRC_OPTEN Bit Definition */
875 #define ADE9000_CRC_WFB_TRG_CFG_EN NO_OS_BIT(15)
876 #define ADE9000_CRC_WFB_PG_IRQEN NO_OS_BIT(14)
877 #define ADE9000_CRC_WFB_CFG_EN NO_OS_BIT(13)
878 #define ADE9000_CRC_SEQ_CYC_EN NO_OS_BIT(12)
879 #define ADE9000_CRC_ZXLPSEL_EN NO_OS_BIT(11)
880 #define ADE9000_CRC_ZXTOUT_EN NO_OS_BIT(10)
881 #define ADE9000_CRC_APP_NL_LVL_EN NO_OS_BIT(9)
882 #define ADE9000_CRC_REACT_NL_LVL_EN NO_OS_BIT(8)
883 #define ADE9000_CRC_ACT_NL_LVL_EN NO_OS_BIT(7)
884 #define ADE9000_CRC_SWELL_CYC_EN NO_OS_BIT(6)
885 #define ADE9000_CRC_SWELL_LVL_EN NO_OS_BIT(5)
886 #define ADE9000_CRC_DIP_CYC_EN NO_OS_BIT(4)
887 #define ADE9000_CRC_DIP_LVL_EN NO_OS_BIT(3)
888 #define ADE9000_CRC_EVENT_MASK_EN NO_OS_BIT(2)
889 #define ADE9000_CRC_MASK1_EN NO_OS_BIT(1)
890 #define ADE9000_CRC_MASK0_EN NO_OS_BIT(0)
891 
892 /* ADE9000_TEMP_CFG Bit Definition */
893 #define ADE9000_TEMP_START NO_OS_BIT(3)
894 #define ADE9000_TEMP_EN NO_OS_BIT(2)
895 #define ADE9000_TEMP_TIME NO_OS_GENMASK(1, 0)
896 
897 /* ADE9000_TEMP_RSLT Bit Definition */
898 #define ADE9000_TEMP_RESULT NO_OS_GENMASK(11, 0)
899 
900 /* ADE9000_PGA_GAIN Bit Definition */
901 #define ADE9000_VC_GAIN NO_OS_GENMASK(13, 12)
902 #define ADE9000_VB_GAIN NO_OS_GENMASK(11, 10)
903 #define ADE9000_VA_GAIN NO_OS_GENMASK(9, 8)
904 #define ADE9000_IN_GAIN NO_OS_GENMASK(7, 6)
905 #define ADE9000_IC_GAIN NO_OS_GENMASK(5, 4)
906 #define ADE9000_IB_GAIN NO_OS_GENMASK(3, 2)
907 #define ADE9000_IA_GAIN NO_OS_GENMASK(1, 0)
908 
909 /* ADE9000_CHNL_DIS Bit Definition */
910 #define ADE9000_VC_DISADC NO_OS_BIT(6)
911 #define ADE9000_VB_DISADC NO_OS_BIT(5)
912 #define ADE9000_VA_DISADC NO_OS_BIT(4)
913 #define ADE9000_IN_DISADC NO_OS_BIT(3)
914 #define ADE9000_IC_DISADC NO_OS_BIT(2)
915 #define ADE9000_IB_DISADC NO_OS_BIT(1)
916 #define ADE9000_IA_DISADC NO_OS_BIT(0)
917 
918 /* ADE9000_VAR_DIS Bit Definition */
919 #define ADE9000_VARDIS NO_OS_BIT(0)
920 
921 /* Miscellaneous Definitions */
922 #define ADE9000_CHIP_ID 0x63
923 
924 /*Configuration registers*/
925 /*PGA@0x0000. Gain of all channels=1*/
926 #define ADE9000_PGA_GAIN 0x0000
927 /*Integrator disabled*/
928 #define ADE9000_CONFIG0 0x00000000
929 /*CF3/ZX pin outputs Zero crossing */
930 #define ADE9000_CONFIG1 0x0002
931 /*Default High pass corner frequency of 1.25Hz*/
932 #define ADE9000_CONFIG2 0x0C00
933 /*Peak and overcurrent detection disabled*/
934 #define ADE9000_CONFIG3 0x0000
935 /*50Hz operation, 3P4W Wye configuration, signed accumulation*/
936 #define ADE9000_ACCMODE 0x0000
937 /*Temperature sensor enabled*/
938 #define ADE9000_TEMP_CFG 0x000C
939 /*Line period and zero crossing obtained from combined signals VA,VB and VC*/
940 #define ADE9000_ZX_LP_SEL 0x001E
941 /*Enable EGYRDY interrupt*/
942 #define ADE9000_MASK0 0x00000001
943 /*MASK1 interrupts disabled*/
944 #define ADE9000_MASK1 0x00000000
945 /*Events disabled */
946 #define ADE9000_EVENT_MASK 0x00000000
947 /*Assuming Vnom=1/2 of full scale.*/
948 /*Refer Technical reference manual for detailed calculations.*/
949 #define ADE9000_VLEVEL 0x0022EA28
950 /* Set DICOEFF= 0xFFFFE000 when integrator is enabled*/
951 #define ADE9000_DICOEFF 0x00000000
952 /*Constant Definitions***/
953 /*DSP ON*/
954 #define ADE9000_RUN_ON 0x0001
955 /*Energy Accumulation Settings*/
956 /*Enable energy accumulation, accumulate samples at 8ksps*/
957 /*latch energy accumulation after EGYRDY*/
958 /*If accumulation is changed to half line cycle mode, change EGY_TIME*/
959 #define ADE9000_EP_CFG 0x0011
960 /*Accumulate 8000 samples*/
961 #define ADE9000_EGY_TIME 0x1F3F
962 /*Waveform buffer Settings*/
963 /*Neutral current samples enabled, Resampled data enabled*/
964 /*Burst all channels*/
965 #define ADE9000_WFB_CFG 0x1000
966 /*size of buffer to read. 512 Max.Each element IA,VA...IN has max 512 points*/
967 /*[Size of waveform buffer/number of sample sets = 2048/4 = 512]*/
968 /*(Refer ADE9000 technical reference manual for more details)*/
969 #define WFB_ELEMENT_ARRAY_SIZE 512
970 /*Full scale Codes (FS) referred from Datasheet.*/
971 /*Respective digital codes are produced when ADC inputs*/
972 /*are at full scale. Do not Change. */
973 #define ADE9000_RMS_FS_CODES 52702092
974 #define ADE9000_WATT_FS_CODES 20694066
975 #define ADE9000_RESAMPLED_FS_CODES 18196
976 #define ADE9000_PCF_FS_CODES 74532013
977 /* Assuming a transformer ratio of 3000:1 and 10 ohms burden resistance value */
978 #define ADE9000_BURDEN_RES 10
979 #define ADE9000_CURRENT_TR_RATIO 3000
980 #define ADE9000_CURRENT_TR_FCN (ADE9000_CURRENT_TR_RATIO / ADE9000_BURDEN_RES)
981 /* Assuming a voltage divider with Rlow 1k and Rup 800k*/
982 #define ADE9000_UP_RES 800000
983 #define ADE9000_DOWN_RES 1000
984 #define ADE9000_VOLTAGE_TR_FCN ((ADE9000_DOWN_RES + ADE9000_UP_RES) / ADE9000_DOWN_RES)
985 
986 // 0.707V rms full scale * 1000 for mili units
987 #define ADE9000_FS_VOLTAGE 707
988 
989 /******************************************************************************/
990 /*************************** Types Declarations *******************************/
991 /******************************************************************************/
992 
998  /* Approximated neutral current rms calculation */
1000  /* Determine mismatch between neutral and
1001  phase currents).*/
1003  /* determine mismatch between neutral and
1004  phase currents) */
1006  /* approximated neutral current rms calculation */
1008 };
1009 
1016  /* 0 */
1018  /* 1 */
1020  /* 2 */
1022  /* 3 */
1024  /* 4 */
1026  /* function disabled */
1028 };
1029 
1036  /* 0 */
1038  /* 1 */
1040  /* 2 */
1042  /* 3 */
1044  /* 4 */
1046  /* function disabled */
1048 };
1049 
1056  /* 0 */
1058  /* 1 */
1060  /* 2 */
1062  /* 3 */
1064  /* 4 */
1066  /* function disabled */
1068 };
1069 
1076  /* Digital to freq converter */
1078  /* Digital to freq converter */
1080  /* Event */
1082  /* Dready */
1084 };
1085 
1092  /* Digital to freq converter */
1094  /* Zero corssing out selected by ZX_SEL bits */
1096 };
1097 
1105  /* Total active power */
1107  /* Total reactive power */
1109  /* Total apparent power */
1111  /* Fundamental active power */
1113  /* Fundamental reactive power */
1115  /* Fundamental apparent power */
1117  /* Total active power */
1119  /* Total active power2 */
1121 };
1122 
1128  /* 50 Hz */
1130  /* 60 Hz */
1132 };
1133 
1139  /* 4 wire wye */
1141  /* 3-wire delta. VB' = VA − VC */
1143  /* 4-wire wye, nonBlondel compliant. VB' = −VA − VC */
1145  /* 4-wire delta, nonBlondel compliant. VB' = −VA */
1147  /* 3-wire delta. VA' = VA − VB; VB' = VA − VC; VC' = VC − VB*/
1149 };
1150 
1157  /* signed acc mode */
1159  /* absolute value acc mode */
1161  /* positive acc mode */
1163  /* negative acc mode */
1165 };
1166 
1174  /* signed acc mode */
1176  /* absolute value acc mode */
1178  /* positive acc mode */
1180  /* negative acc mode */
1182 };
1183 
1191  /* Phase A voltage zero-crossing signal */
1193  /* Phase B voltage zero-crossing signal */
1195  /* Phase C voltage zero-crossing signal */
1197  /* Zero-crossing on combined signal from VA, VB, and VC */
1199 };
1200 
1207  /* Sinc4 output at 32 kSPS */
1209  /* Sinc4 + IIR LPF output at 8 kSPS */
1211  /* Current and voltage channel waveform samples,
1212  processed by the DSP (xI_PCF, xV_PCF) at 8 kSPS */
1214 };
1215 
1222  /* Stop when waveform buffer is full */
1224  /* Continuous fill—stop only on enabled trigger
1225  events */
1227  /* Continuous filling—center capture around
1228  enabled trigger events. */
1230  /* Continuous fill—save event address of enabled
1231  trigger events */
1233 };
1234 
1241  /* All channels */
1243  /* IA and VA */
1245  /* IB and VB */
1247  /* IC and VC */
1249  /* IA */
1251  /* VA */
1253  /* IB */
1255  /* VB */
1257  /* IC */
1259  /* VC */
1261  /* IN if WF_IN_EN = 1*/
1263  /* Burst Disable read single addr */
1265 };
1266 
1273  /* 77.39 Hz. */
1275  /* 39.275 Hz. */
1277  /* 19.79 Hz. */
1279  /* 9.935 Hz. */
1281  /* 4.98 Hz. */
1283  /* 2.495 Hz. */
1285  /* 1.25 Hz. */
1287  /* 0.625 Hz. */
1289 };
1290 
1297  /* 64 samples */
1299  /* 128 samples */
1301  /* 256 samples */
1303  /* 512 samples */
1305  /* 1024 samples */
1307  /* 2048 samples */
1309  /* 4096 samples */
1311  /* disable no load threshold */
1313 };
1314 
1321  /* 1 sample. New temperature measurement every
1322  1.25 ms. */
1324  /* 256 samples. New temperature measurement
1325  every 320 ms */
1327  /* 512 samples. New temperature measurement
1328  every 640 ms*/
1330  /* 1024 samples. New temperature measurement
1331  every 1.3 sec. */
1333 };
1334 
1340  /* Gain = 1 */
1342  /* Gain = 2 */
1344  /* Gain = 3 */
1346  /* Gain = 4 */
1348 };
1349 
1358 };
1359 
1368 };
1369 
1378  bool temp_en;
1379 };
1380 
1385 struct ade9000_dev {
1389  uint32_t watt_val;
1391  uint32_t irms_val;
1393  uint32_t vrms_val;
1395  int32_t temp_deg;
1396 };
1397 
1398 /******************************************************************************/
1399 /************************ Functions Declarations ******************************/
1400 /******************************************************************************/
1401 
1402 /* Read device register. */
1403 int ade9000_read(struct ade9000_dev *dev, uint16_t reg_addr,
1404  uint32_t *reg_data);
1405 
1406 /* Write device register. */
1407 int ade9000_write(struct ade9000_dev *dev, uint16_t reg_addr,
1408  uint32_t reg_data);
1409 
1410 /* Update specific register bits. */
1411 int ade9000_update_bits(struct ade9000_dev *dev, uint16_t reg_addr,
1412  uint32_t mask, uint32_t reg_data);
1413 
1414 /* Read temperature */
1415 int ade9000_read_temp(struct ade9000_dev *dev);
1416 
1417 /* Read Energy/Power for specific phase */
1418 int ade9000_read_data_ph(struct ade9000_dev *dev, enum ade9000_phase phase);
1419 
1420 /* Set User Energy use model */
1421 int ade9000_set_egy_model(struct ade9000_dev *dev, enum ade9000_egy_model model,
1422  uint16_t value);
1423 
1424 /* Initialize the device. */
1425 int ade9000_init(struct ade9000_dev **device,
1427 
1428 /* Setup the device */
1429 int ade9000_setup(struct ade9000_dev *dev);
1430 
1431 /* Remove the device and release resources. */
1432 int ade9000_remove(struct ade9000_dev *dev);
1433 
1434 /* Get interrupt indicator from STATUS0 register. */
1435 int ade9000_get_int_status0(struct ade9000_dev *dev, uint32_t msk,
1436  uint8_t *status);
1437 
1438 #endif // __ADE9000_H__
ADE9000_ISUM_DET_MISM_POS
@ ADE9000_ISUM_DET_MISM_POS
Definition: ade9000.h:1002
ade9000_setup
int ade9000_setup(struct ade9000_dev *dev)
Setup the device.
Definition: ade9000.c:441
no_os_put_unaligned_be16
void no_os_put_unaligned_be16(uint16_t val, uint8_t *buf)
ADE9000_SRC_SINC4_IIR
@ ADE9000_SRC_SINC4_IIR
Definition: ade9000.h:1210
ade9000_set_egy_model
int ade9000_set_egy_model(struct ade9000_dev *dev, enum ade9000_egy_model model, uint16_t value)
Set User Energy use model.
Definition: ade9000.c:322
timeout
uint32_t timeout
Definition: ad413x.c:49
ade9000_no_load_tmr_e
ade9000_no_load_tmr_e
This register configures how many 8 kSPS samples to evaluate the no load condition over.
Definition: ade9000.h:1296
no_os_alloc.h
ADE9000_TEMP_START
#define ADE9000_TEMP_START
Definition: ade9000.h:893
ADE9000_ACC_SIGNED
@ ADE9000_ACC_SIGNED
Definition: ade9000.h:1158
ADE9000_HPF_1_25
@ ADE9000_HPF_1_25
Definition: ade9000.h:1286
ADE9000_MODE_CENTER_CAPTURE
@ ADE9000_MODE_CENTER_CAPTURE
Definition: ade9000.h:1229
ADE9000_MASK0_TEMP_RDY
#define ADE9000_MASK0_TEMP_RDY
Definition: ade9000.h:613
ADE9000_MODE_TRIG_EN_EVENTS
@ ADE9000_MODE_TRIG_EN_EVENTS
Definition: ade9000.h:1226
ADE9000_ACC_ABSOLUTE
@ ADE9000_ACC_ABSOLUTE
Definition: ade9000.h:1160
ade9000_init_param::temp_en
bool temp_en
Definition: ade9000.h:1378
ADE9000_APERIOD
@ ADE9000_APERIOD
Definition: ade9000.h:1175
ADE9000_REG_DICOEFF
#define ADE9000_REG_DICOEFF
Definition: ade9000.h:149
ADE9000_REG_RUN
#define ADE9000_REG_RUN
Definition: ade9000.h:314
ade9000_read
int ade9000_read(struct ade9000_dev *dev, uint16_t reg_addr, uint32_t *reg_data)
Read device register.
Definition: ade9000.c:55
ADE9000_ISUM_DET_MISM_NEG
@ ADE9000_ISUM_DET_MISM_NEG
Definition: ade9000.h:1005
ADE9000_REG_VLEVEL
#define ADE9000_REG_VLEVEL
Definition: ade9000.h:289
ADE9000_BIGAIN_BPHCAL_DISABLE
@ ADE9000_BIGAIN_BPHCAL_DISABLE
Definition: ade9000.h:1047
ADE9000_CF4_EVENT
@ ADE9000_CF4_EVENT
Definition: ade9000.h:1081
ade9000_var_acc_mode_e
ade9000_var_acc_mode_e
ADE9000 Total and fundamental reactive power accumulation mode for energy registers and CFx pulses.
Definition: ade9000.h:1156
NO_OS_GENMASK
#define NO_OS_GENMASK(h, l)
Definition: no_os_util.h:82
no_os_spi_write_and_read
int32_t no_os_spi_write_and_read(struct no_os_spi_desc *desc, uint8_t *data, uint16_t bytes_number)
Write and read data to/from SPI.
Definition: no_os_spi.c:159
ade9000_aregion_sel_e
ade9000_aregion_sel_e
ADE9000 These bits indicate which AIGAINx and APHCALx is currently being used.
Definition: ade9000.h:1015
ADE9000_TEMP_GAIN
#define ADE9000_TEMP_GAIN
Definition: ade9000.h:774
ADE9000_CF4_SEL_APPARENT_P
@ ADE9000_CF4_SEL_APPARENT_P
Definition: ade9000.h:1110
ADE9000_PGA_GAIN_1
@ ADE9000_PGA_GAIN_1
Definition: ade9000.h:1341
ADE9000_NOLOAD_SAMPLES_64
@ ADE9000_NOLOAD_SAMPLES_64
Definition: ade9000.h:1298
ADE9000_COM_PERIOD
@ ADE9000_COM_PERIOD
Definition: ade9000.h:1181
no_os_spi.h
Header file of SPI Interface.
ade9000_read_data_ph
int ade9000_read_data_ph(struct ade9000_dev *dev, enum ade9000_phase phase)
Read the power/energy for specific phase.
Definition: ade9000.c:245
ADE9000_SELFREQ_60
@ ADE9000_SELFREQ_60
Definition: ade9000.h:1131
ADE9000_HPF_2_495
@ ADE9000_HPF_2_495
Definition: ade9000.h:1284
ADE9000_SRC_SINC4
@ ADE9000_SRC_SINC4
Definition: ade9000.h:1208
ADE9000_CF4_SEL_FUN_APPARENT_P
@ ADE9000_CF4_SEL_FUN_APPARENT_P
Definition: ade9000.h:1116
ADE9000_REG_VERSION
#define ADE9000_REG_VERSION
Definition: ade9000.h:363
ADE9000_REG_TEMP_CFG
#define ADE9000_REG_TEMP_CFG
Definition: ade9000.h:356
ADE9000_REG_CONFIG0
#define ADE9000_REG_CONFIG0
Definition: ade9000.h:131
ADE9000_EGY_TMR_MODE
#define ADE9000_EGY_TMR_MODE
Definition: ade9000.h:868
ADE9000_CF4_DREADY
@ ADE9000_CF4_DREADY
Definition: ade9000.h:1083
ADE9000_CF4_SEL_FUN_ACTIVE_P
@ ADE9000_CF4_SEL_FUN_ACTIVE_P
Definition: ade9000.h:1112
no_os_units.h
Header file of Units.
ADE9000_ZXVB_SEL
@ ADE9000_ZXVB_SEL
Definition: ade9000.h:1194
ADE9000_AIGAIN_APHCAL_3
@ ADE9000_AIGAIN_APHCAL_3
Definition: ade9000.h:1023
ADE9000_TEMP_TIME_512
@ ADE9000_TEMP_TIME_512
Definition: ade9000.h:1329
ADE9000_BURST_ALL_CH
@ ADE9000_BURST_ALL_CH
Definition: ade9000.h:1242
ADE9000_EGY_LD_ACCUM
#define ADE9000_EGY_LD_ACCUM
Definition: ade9000.h:867
ade9000_wf_src_e
ade9000_wf_src_e
Waveform buffer source and DREADY (data ready update rate) selection.
Definition: ade9000.h:1206
ADE9000_AIGAIN_APHCAL_4
@ ADE9000_AIGAIN_APHCAL_4
Definition: ade9000.h:1025
no_os_delay.h
Header file of Delay functions.
ADE9000_REG_AWATT
#define ADE9000_REG_AWATT
Definition: ade9000.h:157
ADE9000_WATT_FS_CODES
#define ADE9000_WATT_FS_CODES
Definition: ade9000.h:974
ADE9000_CF3_D_F_CONV
@ ADE9000_CF3_D_F_CONV
Definition: ade9000.h:1093
ade9000_egy_model
ade9000_egy_model
ADE9000 available user energy use models.
Definition: ade9000.h:1364
ADE9000_NOLOAD_SAMPLES_512
@ ADE9000_NOLOAD_SAMPLES_512
Definition: ade9000.h:1304
device
Definition: ad9361_util.h:69
ADE9000_REG_AIRMS
#define ADE9000_REG_AIRMS
Definition: ade9000.h:153
ADE9000_ZXVC_SEL
@ ADE9000_ZXVC_SEL
Definition: ade9000.h:1196
ADE9000_BURST_IN
@ ADE9000_BURST_IN
Definition: ade9000.h:1262
ADE9000_4WIRE_WYE_VA_VC
@ ADE9000_4WIRE_WYE_VA_VC
Definition: ade9000.h:1144
ade9000_cf3_pin_out_cfg_e
ade9000_cf3_pin_out_cfg_e
ADE9000 These bits indicate which function to output on CF3 pin.
Definition: ade9000.h:1091
ADE9000_PHASE_C
@ ADE9000_PHASE_C
Definition: ade9000.h:1357
ade9000_freq_sel_e
ade9000_freq_sel_e
ADE9000 Freq value.
Definition: ade9000.h:1127
no_os_calloc
void * no_os_calloc(size_t nitems, size_t size)
Allocate memory and return a pointer to it, set memory to 0.
Definition: chibios_alloc.c:54
ade9000_pga_gain_e
ade9000_pga_gain_e
PGA gain.
Definition: ade9000.h:1339
ADE9000_EGY_TIME
#define ADE9000_EGY_TIME
Definition: ade9000.h:961
ADE9000_NOLOAD_SAMPLES_1024
@ ADE9000_NOLOAD_SAMPLES_1024
Definition: ade9000.h:1306
ADE9000_REG_PGA_GAIN
#define ADE9000_REG_PGA_GAIN
Definition: ade9000.h:358
ade9000_get_int_status0
int ade9000_get_int_status0(struct ade9000_dev *dev, uint32_t msk, uint8_t *status)
Get interrupt indicator from STATUS0 register.
Definition: ade9000.c:157
ADE9000_REG_CWATT
#define ADE9000_REG_CWATT
Definition: ade9000.h:197
ade9000_init
int ade9000_init(struct ade9000_dev **device, struct ade9000_init_param init_param)
Initialize the device.
Definition: ade9000.c:383
ADE9000_REG_BWATT
#define ADE9000_REG_BWATT
Definition: ade9000.h:177
ade9000_read_temp
int ade9000_read_temp(struct ade9000_dev *dev)
Read the temperature.
Definition: ade9000.c:183
ADE9000_REG_BVRMS
#define ADE9000_REG_BVRMS
Definition: ade9000.h:174
ADE9000_CF4_SEL_TOTAL_ACTIVE_P_2
@ ADE9000_CF4_SEL_TOTAL_ACTIVE_P_2
Definition: ade9000.h:1120
ADE9000_REG_ACCMODE
#define ADE9000_REG_ACCMODE
Definition: ade9000.h:330
ade9000_get_int_status0
int ade9000_get_int_status0(struct ade9000_dev *dev, uint32_t msk, uint8_t *status)
Get interrupt indicator from STATUS0 register.
Definition: ade9000.c:157
ADE9000_BURST_IA_VA
@ ADE9000_BURST_IA_VA
Definition: ade9000.h:1244
ADE9000_BURST_IB
@ ADE9000_BURST_IB
Definition: ade9000.h:1254
ade9000_init
int ade9000_init(struct ade9000_dev **device, struct ade9000_init_param init_param)
Initialize the device.
Definition: ade9000.c:383
ADE9000_DICOEFF
#define ADE9000_DICOEFF
Definition: ade9000.h:951
ADE9000_REG_BIRMS
#define ADE9000_REG_BIRMS
Definition: ade9000.h:173
ADE9000_WFB_CFG
#define ADE9000_WFB_CFG
Definition: ade9000.h:965
ADE9000_MASK1
#define ADE9000_MASK1
Definition: ade9000.h:944
no_os_mdelay
void no_os_mdelay(uint32_t msecs)
Wait until msecs milliseconds passed.
Definition: aducm3029_delay.c:126
ADE9000_BURST_DISABLED
@ ADE9000_BURST_DISABLED
Definition: ade9000.h:1264
no_os_field_prep
uint32_t no_os_field_prep(uint32_t mask, uint32_t val)
ade9000_zx_select_e
ade9000_zx_select_e
Selects the zero-crossing signal, which can be routed to the CF3/ZX output pin and used for line cycl...
Definition: ade9000.h:1190
ADE9000_ISUM_APROX_N_RMS
@ ADE9000_ISUM_APROX_N_RMS
Definition: ade9000.h:1007
ADE9000_HPF_77_39
@ ADE9000_HPF_77_39
Definition: ade9000.h:1274
ADE9000_BIGAIN_BPHCAL_0
@ ADE9000_BIGAIN_BPHCAL_0
Definition: ade9000.h:1037
ADE9000_BIGAIN_BPHCAL_3
@ ADE9000_BIGAIN_BPHCAL_3
Definition: ade9000.h:1043
ADE9000_CONFIG2
#define ADE9000_CONFIG2
Definition: ade9000.h:932
ADE9000_CIGAIN_CPHCAL_3
@ ADE9000_CIGAIN_CPHCAL_3
Definition: ade9000.h:1063
ADE9000_BURST_VB
@ ADE9000_BURST_VB
Definition: ade9000.h:1256
ADE9000_CONFIG0
#define ADE9000_CONFIG0
Definition: ade9000.h:928
ADE9000_SWRST
#define ADE9000_SWRST
Definition: ade9000.h:785
ADE9000_BIGAIN_BPHCAL_2
@ ADE9000_BIGAIN_BPHCAL_2
Definition: ade9000.h:1041
ADE9000_CF4_SEL_FUN_REACTIVE_P
@ ADE9000_CF4_SEL_FUN_REACTIVE_P
Definition: ade9000.h:1114
ADE9000_ACC_NEGATIVE
@ ADE9000_ACC_NEGATIVE
Definition: ade9000.h:1164
ADE9000_CF4_SEL_REACTIV_P
@ ADE9000_CF4_SEL_REACTIV_P
Definition: ade9000.h:1108
ade9000_setup
int ade9000_setup(struct ade9000_dev *dev)
Setup the device.
Definition: ade9000.c:441
ADE9000_AIGAIN_APHCAL_2
@ ADE9000_AIGAIN_APHCAL_2
Definition: ade9000.h:1021
ADE9000_3WIRE_DELTA_2
@ ADE9000_3WIRE_DELTA_2
Definition: ade9000.h:1148
no_os_put_unaligned_be32
void no_os_put_unaligned_be32(uint32_t val, uint8_t *buf)
ade9000_wf_mode_e
ade9000_wf_mode_e
Fixed data rate waveforms filling and trigger based modes.
Definition: ade9000.h:1221
ADE9000_TEMP_TIME_256
@ ADE9000_TEMP_TIME_256
Definition: ade9000.h:1326
ade9000_cf4_sel_e
ade9000_cf4_sel_e
ADE9000 Type of energy output on the CF4 pin. Configure TERMSEL4 in the COMPMODE register to select w...
Definition: ade9000.h:1104
ade9000_line_period_sel_e
ade9000_line_period_sel_e
Selects line period measurement used for VRMS½ cycle, 10 cycle rms/12 cycle rms, and resampling.
Definition: ade9000.h:1173
ADE9000_CIGAIN_CPHCAL_1
@ ADE9000_CIGAIN_CPHCAL_1
Definition: ade9000.h:1059
ADE9000_REG_MASK1
#define ADE9000_REG_MASK1
Definition: ade9000.h:281
ADE9000_CF4_D_F_CONV
@ ADE9000_CF4_D_F_CONV
Definition: ade9000.h:1077
ADE9000_CURRENT_TR_FCN
#define ADE9000_CURRENT_TR_FCN
Definition: ade9000.h:980
ade9000_dev::temp_deg
int32_t temp_deg
Definition: ade9000.h:1395
ADE9000_EP_CFG
#define ADE9000_EP_CFG
Definition: ade9000.h:959
ADE9000_REG_MASK0
#define ADE9000_REG_MASK0
Definition: ade9000.h:280
ADE9000_BURST_IA
@ ADE9000_BURST_IA
Definition: ade9000.h:1250
ade9000_dev::irms_val
uint32_t irms_val
Definition: ade9000.h:1391
ade9000_init_param::spi_init
struct no_os_spi_init_param * spi_init
Definition: ade9000.h:1376
ADE9000_HPF_0_625
@ ADE9000_HPF_0_625
Definition: ade9000.h:1288
ade9000_write
int ade9000_write(struct ade9000_dev *dev, uint16_t reg_addr, uint32_t reg_data)
Write device register.
Definition: ade9000.c:100
ade9000_read_data_ph
int ade9000_read_data_ph(struct ade9000_dev *dev, enum ade9000_phase phase)
Read the power/energy for specific phase.
Definition: ade9000.c:245
ADE9000_REG_TEMP_TRIM
#define ADE9000_REG_TEMP_TRIM
Definition: ade9000.h:313
ADE9000_NOLOAD_SAMPLES_4096
@ ADE9000_NOLOAD_SAMPLES_4096
Definition: ade9000.h:1310
ade9000_read_temp
int ade9000_read_temp(struct ade9000_dev *dev)
Read the temperature.
Definition: ade9000.c:183
no_os_spi_desc
Structure holding SPI descriptor.
Definition: no_os_spi.h:192
ade9000_phase
ade9000_phase
ADE9000 available phases.
Definition: ade9000.h:1354
ADE9000_NOLOAD_SAMPLES_128
@ ADE9000_NOLOAD_SAMPLES_128
Definition: ade9000.h:1300
ADE9000_TEMP_RESULT
#define ADE9000_TEMP_RESULT
Definition: ade9000.h:898
ADE9000_TEMP_EN
#define ADE9000_TEMP_EN
Definition: ade9000.h:894
ADE9000_AIGAIN_APHCAL_1
@ ADE9000_AIGAIN_APHCAL_1
Definition: ade9000.h:1019
ADE9000_REG_WFB_CFG
#define ADE9000_REG_WFB_CFG
Definition: ade9000.h:341
ADE9000_CIGAIN_CPHCAL_4
@ ADE9000_CIGAIN_CPHCAL_4
Definition: ade9000.h:1065
ADE9000_BURST_IB_VB
@ ADE9000_BURST_IB_VB
Definition: ade9000.h:1246
ADE9000_VOLTAGE_TR_FCN
#define ADE9000_VOLTAGE_TR_FCN
Definition: ade9000.h:984
ADE9000_PHASE_B
@ ADE9000_PHASE_B
Definition: ade9000.h:1356
ADE9000_REG_STATUS0
#define ADE9000_REG_STATUS0
Definition: ade9000.h:277
ADE9000_ZXVA_SEL
@ ADE9000_ZXVA_SEL
Definition: ade9000.h:1192
ade9000_dev::watt_val
uint32_t watt_val
Definition: ade9000.h:1389
ADE9000_REG_CVRMS
#define ADE9000_REG_CVRMS
Definition: ade9000.h:194
ADE9000_PHASE_A
@ ADE9000_PHASE_A
Definition: ade9000.h:1355
ADE9000_AIGAIN_APHCAL_0
@ ADE9000_AIGAIN_APHCAL_0
Definition: ade9000.h:1017
ADE9000_BURST_IC
@ ADE9000_BURST_IC
Definition: ade9000.h:1258
ADE9000_SPI_READ
#define ADE9000_SPI_READ
Definition: ade9000.h:50
ADE9000_ISUM_APROX_N
@ ADE9000_ISUM_APROX_N
Definition: ade9000.h:999
ade9000.h
Header file of ADE9000 Driver.
ADE9000_MODE_STOP_FULL
@ ADE9000_MODE_STOP_FULL
Definition: ade9000.h:1223
ADE9000_TEMP_TIME_1024
@ ADE9000_TEMP_TIME_1024
Definition: ade9000.h:1332
ade9000_init_param
ADE9000 Device initialization parameters.
Definition: ade9000.h:1374
ADE9000_SELFREQ_50
@ ADE9000_SELFREQ_50
Definition: ade9000.h:1129
ADE9000_EGY_PWR_EN
#define ADE9000_EGY_PWR_EN
Definition: ade9000.h:869
ADE9000_REG_EVENT_MASK
#define ADE9000_REG_EVENT_MASK
Definition: ade9000.h:282
ADE9000_REG_CONFIG5
#define ADE9000_REG_CONFIG5
Definition: ade9000.h:345
ade9000_read
int ade9000_read(struct ade9000_dev *dev, uint16_t reg_addr, uint32_t *reg_data)
Read device register.
Definition: ade9000.c:55
ADE9000_ACC_POSITIVE
@ ADE9000_ACC_POSITIVE
Definition: ade9000.h:1162
ade9000_write
int ade9000_write(struct ade9000_dev *dev, uint16_t reg_addr, uint32_t reg_data)
Write device register.
Definition: ade9000.c:100
ADE9000_RD_RST_EN
#define ADE9000_RD_RST_EN
Definition: ade9000.h:866
ADE9000_HPF_19_79
@ ADE9000_HPF_19_79
Definition: ade9000.h:1278
ade9000_cregion_sel_e
ade9000_cregion_sel_e
ADE9000 These bits indicate which CIGAINx and CPHCALx is currently being used.
Definition: ade9000.h:1055
ade9000_bregion_sel_e
ade9000_bregion_sel_e
ADE9000 These bits indicate which BIGAINx and BPHCALx is currently being used.
Definition: ade9000.h:1035
no_os_field_get
uint32_t no_os_field_get(uint32_t mask, uint32_t word)
ADE9000_TEMP_TIME_1
@ ADE9000_TEMP_TIME_1
Definition: ade9000.h:1323
ade9000_remove
int ade9000_remove(struct ade9000_dev *dev)
Remove the device and release resources.
Definition: ade9000.c:506
ADE9000_SRC_DSP
@ ADE9000_SRC_DSP
Definition: ade9000.h:1213
ADE9000_NOLOAD_SAMPLES_DISABLE
@ ADE9000_NOLOAD_SAMPLES_DISABLE
Definition: ade9000.h:1312
ADE9000_REG_CONFIG2
#define ADE9000_REG_CONFIG2
Definition: ade9000.h:350
ADE9000_BURST_VC
@ ADE9000_BURST_VC
Definition: ade9000.h:1260
ADE9000_HPF_4_98
@ ADE9000_HPF_4_98
Definition: ade9000.h:1282
no_os_free
void no_os_free(void *ptr)
Deallocate memory previously allocated by a call to no_os_calloc or no_os_malloc.
Definition: chibios_alloc.c:69
ade9000_dev::spi_desc
struct no_os_spi_desc * spi_desc
Definition: ade9000.h:1387
ADE9000_VLEVEL
#define ADE9000_VLEVEL
Definition: ade9000.h:949
ADE9000_CF3_ZX
@ ADE9000_CF3_ZX
Definition: ade9000.h:1095
ADE9000_ACCMODE
#define ADE9000_ACCMODE
Definition: ade9000.h:936
ADE9000_PGA_GAIN_2
@ ADE9000_PGA_GAIN_2
Definition: ade9000.h:1343
ade9000_burst_ch_e
ade9000_burst_ch_e
Selects which data to read out of the waveform buffer through SPI.
Definition: ade9000.h:1240
ade9000_remove
int ade9000_remove(struct ade9000_dev *dev)
Remove the device and release resources.
Definition: ade9000.c:506
ade9000_dev::vrms_val
uint32_t vrms_val
Definition: ade9000.h:1393
ADE9000_ZXCOMB_SEL
@ ADE9000_ZXCOMB_SEL
Definition: ade9000.h:1198
ADE9000_AIGAIN_APHCAL_DISABLE
@ ADE9000_AIGAIN_APHCAL_DISABLE
Definition: ade9000.h:1027
ADE9000_CIGAIN_CPHCAL_0
@ ADE9000_CIGAIN_CPHCAL_0
Definition: ade9000.h:1057
ADE9000_PGA_GAIN
#define ADE9000_PGA_GAIN
Definition: ade9000.h:926
no_os_get_unaligned_be32
uint32_t no_os_get_unaligned_be32(uint8_t *buf)
ADE9000_REG_EGY_TIME
#define ADE9000_REG_EGY_TIME
Definition: ade9000.h:353
init_param
struct ad7616_init_param init_param
Definition: ad7616_sdz.c:113
ADE9000_BPERIOD
@ ADE9000_BPERIOD
Definition: ade9000.h:1177
ADE9000_HPF_9_935
@ ADE9000_HPF_9_935
Definition: ade9000.h:1280
ADE9000_CIGAIN_CPHCAL_DISABLE
@ ADE9000_CIGAIN_CPHCAL_DISABLE
Definition: ade9000.h:1067
ADE9000_REG_ZX_LP_SEL
#define ADE9000_REG_ZX_LP_SEL
Definition: ade9000.h:338
ADE9000_REG_CONFIG1
#define ADE9000_REG_CONFIG1
Definition: ade9000.h:315
ade9000_hpf_freq_e
ade9000_hpf_freq_e
High-pass filter corner (f3dB) enabled when the HPFDIS bit in the CONFIG0 register is equal to zero.
Definition: ade9000.h:1272
ADE9000_RMS_FS_CODES
#define ADE9000_RMS_FS_CODES
Definition: ade9000.h:973
ADE9000_RUN_ON
#define ADE9000_RUN_ON
Definition: ade9000.h:954
no_os_spi_remove
int32_t no_os_spi_remove(struct no_os_spi_desc *desc)
Free the resources allocated by no_os_spi_init().
Definition: no_os_spi.c:116
ADE9000_REG_CONFIG3
#define ADE9000_REG_CONFIG3
Definition: ade9000.h:331
ADE9000_REG_TEMP_RSLT
#define ADE9000_REG_TEMP_RSLT
Definition: ade9000.h:357
ADE9000_CF4_SEL_TOTAL_ACTIVE_P
@ ADE9000_CF4_SEL_TOTAL_ACTIVE_P
Definition: ade9000.h:1118
ade9000_temp_time_e
ade9000_temp_time_e
Select the number of temperature readings to average.
Definition: ade9000.h:1320
ADE9000_EGY_WITH_RESET
@ ADE9000_EGY_WITH_RESET
Definition: ade9000.h:1365
ADE9000_4WIRE_WYE_VA
@ ADE9000_4WIRE_WYE_VA
Definition: ade9000.h:1146
no_os_spi_init
int32_t no_os_spi_init(struct no_os_spi_desc **desc, const struct no_os_spi_init_param *param)
Initialize the SPI communication peripheral.
Definition: no_os_spi.c:52
no_os_get_unaligned_be16
uint16_t no_os_get_unaligned_be16(uint8_t *buf)
ADE9000_FS_VOLTAGE
#define ADE9000_FS_VOLTAGE
Definition: ade9000.h:987
ade9000_isum_cfg_e
ade9000_isum_cfg_e
ADE9000 isum calculation configuration.
Definition: ade9000.h:997
ADE9000_PGA_GAIN_3
@ ADE9000_PGA_GAIN_3
Definition: ade9000.h:1345
ADE9000_3WIRE_DELTA
@ ADE9000_3WIRE_DELTA
Definition: ade9000.h:1142
ADE9000_NOLOAD_SAMPLES_256
@ ADE9000_NOLOAD_SAMPLES_256
Definition: ade9000.h:1302
ade9000_update_bits
int ade9000_update_bits(struct ade9000_dev *dev, uint16_t reg_addr, uint32_t mask, uint32_t reg_data)
Update specific register bits.
Definition: ade9000.c:130
ADE9000_EGY_HALF_LINE_CYCLES
@ ADE9000_EGY_HALF_LINE_CYCLES
Definition: ade9000.h:1366
ADE9000_EGY_NR_SAMPLES
@ ADE9000_EGY_NR_SAMPLES
Definition: ade9000.h:1367
no_os_util.h
Header file of utility functions.
ADE9000_ZX_LP_SEL
#define ADE9000_ZX_LP_SEL
Definition: ade9000.h:940
no_os_find_first_set_bit
uint32_t no_os_find_first_set_bit(uint32_t word)
ADE9000_4WIRE_WYE
@ ADE9000_4WIRE_WYE
Definition: ade9000.h:1140
ade9000_set_egy_model
int ade9000_set_egy_model(struct ade9000_dev *dev, enum ade9000_egy_model model, uint16_t value)
Set User Energy use model.
Definition: ade9000.c:322
ADE9000_CONFIG3
#define ADE9000_CONFIG3
Definition: ade9000.h:934
ADE9000_CPERIOD
@ ADE9000_CPERIOD
Definition: ade9000.h:1179
ade9000_cf4_pin_out_cfg_e
ade9000_cf4_pin_out_cfg_e
ADE9000 These bits indicate which function to output on CF4 pin.
Definition: ade9000.h:1075
ADE9000_CF4_SEL_ACTIV_P
@ ADE9000_CF4_SEL_ACTIV_P
Definition: ade9000.h:1106
ADE9000_MODE_SAVE_EVENT_ADDR
@ ADE9000_MODE_SAVE_EVENT_ADDR
Definition: ade9000.h:1232
ADE9000_TEMP_OFFSET
#define ADE9000_TEMP_OFFSET
Definition: ade9000.h:773
ADE9000_BIGAIN_BPHCAL_1
@ ADE9000_BIGAIN_BPHCAL_1
Definition: ade9000.h:1039
ade9000_update_bits
int ade9000_update_bits(struct ade9000_dev *dev, uint16_t reg_addr, uint32_t mask, uint32_t reg_data)
Update specific register bits.
Definition: ade9000.c:130
ADE9000_CONFIG1
#define ADE9000_CONFIG1
Definition: ade9000.h:930
ADE9000_REG_AVRMS
#define ADE9000_REG_AVRMS
Definition: ade9000.h:154
ade9000_vconsel_e
ade9000_vconsel_e
ADE9000 3-wire and 4-wire hardware configuration selection.
Definition: ade9000.h:1138
no_os_test_bit
int no_os_test_bit(int pos, const volatile void *addr)
Definition: no_os_util.h:132
ade9000_dev
ADE9000 Device structure.
Definition: ade9000.h:1385
ADE9000_BIGAIN_BPHCAL_4
@ ADE9000_BIGAIN_BPHCAL_4
Definition: ade9000.h:1045
ADE9000_CHIP_ID
#define ADE9000_CHIP_ID
Definition: ade9000.h:922
errno.h
Error macro definition for ARM Compiler.
ADE9000_REG_CIRMS
#define ADE9000_REG_CIRMS
Definition: ade9000.h:193
ADE9000_NOLOAD_SAMPLES_2048
@ ADE9000_NOLOAD_SAMPLES_2048
Definition: ade9000.h:1308
ADE9000_CF4_D_F_CONV2
@ ADE9000_CF4_D_F_CONV2
Definition: ade9000.h:1079
ADE9000_REG_EP_CFG
#define ADE9000_REG_EP_CFG
Definition: ade9000.h:351
ADE9000_PGA_GAIN_4
@ ADE9000_PGA_GAIN_4
Definition: ade9000.h:1347
ADE9000_BURST_VA
@ ADE9000_BURST_VA
Definition: ade9000.h:1252
chip_id
chip_id
Definition: ad9172.h:51
no_os_spi_init_param
Structure holding the parameters for SPI initialization.
Definition: no_os_spi.h:140
ADE9000_CIGAIN_CPHCAL_2
@ ADE9000_CIGAIN_CPHCAL_2
Definition: ade9000.h:1061
ADE9000_EVENT_MASK
#define ADE9000_EVENT_MASK
Definition: ade9000.h:946
ADE9000_BURST_IC_VC
@ ADE9000_BURST_IC_VC
Definition: ade9000.h:1248
ADE9000_HPF_39_275
@ ADE9000_HPF_39_275
Definition: ade9000.h:1276