sensor_epsonCommon.h
Go to the documentation of this file.
1 //==============================================================================
2 //
3 // sensor_epsonCommon.h - Epson IMU sensor specific definitions common
4 // for all IMU models
5 //
6 //
7 // THE SOFTWARE IS RELEASED INTO THE PUBLIC DOMAIN.
8 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
9 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
10 // NONINFRINGEMENT, SECURITY, SATISFACTORY QUALITY, AND FITNESS FOR A
11 // PARTICULAR PURPOSE. IN NO EVENT SHALL EPSON BE LIABLE FOR ANY LOSS, DAMAGE
12 // OR CLAIM, ARISING FROM OR IN CONNECTION WITH THE SOFTWARE OR THE USE OF THE
13 // SOFTWARE.
14 //
15 //==============================================================================
16 #pragma once
17 
18 #include <stdbool.h>
19 
20 #ifdef SPI
21 #include "sensor_epsonSpi.h"
22 #else
23 #include "sensor_epsonUart.h"
24 #endif // #ifdef SPI
25 
26 #ifndef TRUE
27 #define TRUE (true)
28 #endif
29 
30 #ifndef FALSE
31 #define FALSE (false)
32 #endif
33 
34 #define BIT0 (1)
35 #define BIT1 (1 << 1)
36 #define BIT2 (1 << 2)
37 #define BIT3 (1 << 3)
38 #define BIT4 (1 << 4)
39 #define BIT5 (1 << 5)
40 #define BIT6 (1 << 6)
41 #define BIT7 (1 << 7)
42 #define BIT8 (1 << 8)
43 #define BIT9 (1 << 9)
44 #define BIT10 (1 << 10)
45 #define BIT11 (1 << 11)
46 #define BIT12 (1 << 12)
47 #define BIT13 (1 << 13)
48 #define BIT14 (1 << 14)
49 #define BIT15 (1 << 15)
50 
51 #define EPSON_RESET_LOW_WIDTH_MS (100)
52 #define EPSON_RESET_DELAY_MS (3000) // G570PR20 has max delay of 3000 msecs
53 
54 // Conversion constants
55 #define DEG2RAD (3.14159 / 180.0) // Degrees to radians
56 #define RAD2DEG (180.0 / 3.14159) // Radians to degrees
57 #define MG2MPS2 (9.80665 / 1000.0) // milli-G to meters/sec^2
58 #define MPS22MG (1000.0 / 9.80665) // meters/sec^2 to milli-G
59 
60 /* -- Commands --
61 - ADDR_ address byte of transfer to select the register to access
62 
63 - All accesses are 16 bit transfers
64 - For SPI IF:
65  - For SPI write accesses
66  - 8-bit address with msb=1b (even or odd) + write byte
67  - No response
68  - For SPI read accesses
69  - 8-bit address with msb=0b(even only) + dummy byte
70  - Response is transferred on MOSI on next SPI access
71  - Return value is 16-bit read data (high byte + low byte)
72 - For UART IF:
73  - For UART write accesses
74  - 8-bit address with msb=1b(even or odd) + write byte + delimiter
75  - No response
76  - For UART read accesses
77  - 8-bit address with msb=0b(even only) + dummy byte + delimiter
78  - Response is transferred immediately
79  - Return value
80  - Address + 16-bit read data (high byte + low byte) + delimiter
81 
82 - NOTE: Register Address Maps that depend on the WINDOW_ID (page)
83 - NOTE: Not all registers listed are supported by all device models */
84 
85 // WINDOW_ID 0
86 #define ADDR_MODE_CTRL_LO 0x02 // MODE_CTRL Byte0 (W0)
87 #define ADDR_MODE_CTRL_HI 0x03 // MODE_CTRL Byte1 (W0)
88 #define ADDR_DIAG_STAT 0x04 // DIAG_STAT Byte0 (W0)
89 #define ADDR_FLAG 0x06 // FLAG(ND/EA) (W0)
90 #define ADDR_GPIO 0x08 // GPIO (W0)
91 #define ADDR_COUNT 0x0A // COUNT (W0)
92 #define ADDR_RANGE_OVER 0x0C // RANGE_OVER (W0)
93 #define ADDR_TEMP_HIGH 0x0E // TEMPC HIGH (W0)
94 #define ADDR_TEMP_LOW 0x10 // TEMPC LOW (W0)
95 #define ADDR_XGYRO_HIGH 0x12 // XGYRO HIGH (W0)
96 #define ADDR_XGYRO_LOW 0x14 // XGYRO LOW (W0)
97 #define ADDR_YGYRO_HIGH 0x16 // YGYRO HIGH (W0)
98 #define ADDR_YGYRO_LOW 0x18 // YGYRO LOW (W0)
99 #define ADDR_ZGYRO_HIGH 0x1A // ZGYRO HIGH (W0)
100 #define ADDR_ZGYRO_LOW 0x1C // ZGYRO LOW (W0)
101 #define ADDR_XACCL_HIGH 0x1E // XACCL HIGH (W0)
102 #define ADDR_XACCL_LOW 0x20 // XACCL LOW (W0)
103 #define ADDR_YACCL_HIGH 0x22 // YACCL HIGH (W0)
104 #define ADDR_YACCL_LOW 0x24 // YACCL LOW (W0)
105 #define ADDR_ZACCL_HIGH 0x26 // ZACCL HIGH (W0)
106 #define ADDR_ZACCL_LOW 0x28 // ZACCL LOW (W0)
107 
108 #define ADDR_RT_DIAG 0x2B // RT_DIAG LOW (W0)
109 
110 #define ADDR_ID 0x4C // ID LOW (W0)
111 #define ADDR_QTN0_HIGH 0x50 // QTN0 HIGH (W0)
112 #define ADDR_QTN0_LOW 0x52 // QTN0 LOW (W0)
113 #define ADDR_QTN1_HIGH 0x54 // QTN1 HIGH (W0)
114 #define ADDR_QTN1_LOW 0x56 // QTN1 LOW (W0)
115 #define ADDR_QTN2_HIGH 0x58 // QTN2 HIGH (W0)
116 #define ADDR_QTN2_LOW 0x5A // QTN2 LOW (W0)
117 #define ADDR_QTN3_HIGH 0x5C // QTN3 HIGH (W0)
118 #define ADDR_QTN3_LOW 0x5E // QTN3 LOW (W0)
119 
120 #define ADDR_ANG1_HIGH 0x64 // ANG1 HIGH (W0)
121 #define ADDR_ANG1_LOW 0x66 // ANG1 LOW (W0)
122 #define ADDR_ANG2_HIGH 0x68 // ANG2 HIGH (W0)
123 #define ADDR_ANG2_LOW 0x6A // ANG2 LOW (W0)
124 #define ADDR_ANG3_HIGH 0x6C // ANG3 HIGH (W0)
125 #define ADDR_ANG3_LOW 0x6E // ANG3 LOW (W0)
126 
127 #define ADDR_XDLTA_HIGH 0x64 // XDLTA HIGH (W0)
128 #define ADDR_XDLTA_LOW 0x66 // XDLTA LOW (W0)
129 #define ADDR_YDLTA_HIGH 0x68 // YDLTA HIGH (W0)
130 #define ADDR_YDLTA_LOW 0x6A // YDLTA LOW (W0)
131 #define ADDR_ZDLTA_HIGH 0x6C // ZDLTA HIGH (W0)
132 #define ADDR_ZDLTA_LOW 0x6E // ZDLTA LOW (W0)
133 #define ADDR_XDLTV_HIGH 0x70 // XDLTV HIGH (W0)
134 #define ADDR_XDLTV_LOW 0x72 // XDLTV LOW (W0)
135 #define ADDR_YDLTV_HIGH 0x74 // YDLTV HIGH (W0)
136 #define ADDR_YDLTV_LOW 0x76 // YDLTV LOW (W0)
137 #define ADDR_ZDLTV_HIGH 0x78 // ZDLTV HIGH (W0)
138 #define ADDR_ZDLTV_LOW 0x7A // ZDLTV LOW (W0)
139 
140 // WINDOW_ID 1
141 #define ADDR_SIG_CTRL_LO 0x00 // SIG_CTRL Byte0 (W1)
142 #define ADDR_SIG_CTRL_HI 0x01 // SIG_CTRL Byte1 (W1)
143 #define ADDR_MSC_CTRL_LO 0x02 // MSC_CTRL Byte0 (W1)
144 #define ADDR_MSC_CTRL_HI 0x03 // MSC_CTRL Byte1 (W1)
145 #define ADDR_SMPL_CTRL_LO 0x04 // SMPL_CTRL Byte0 (W1)
146 #define ADDR_SMPL_CTRL_HI 0x05 // SMPL_CTRL Byte1 (W1)
147 #define ADDR_FILTER_CTRL_LO 0x06 // FILTER_CTRL Byte0 (W1)
148 #define ADDR_FILTER_CTRL_HI 0x07 // FILTER_CTRL Byte1 (W1)
149 #define ADDR_UART_CTRL_LO 0x08 // UART_CTRL Byte0 (W1)
150 #define ADDR_UART_CTRL_HI 0x09 // UART_CTRL Byte1 (W1)
151 #define ADDR_GLOB_CMD_LO 0x0A // GLOB_CMD Byte0 (W1)
152 #define ADDR_GLOB_CMD_HI 0x0B // GLOB_CMD Byte1 (W1)
153 #define ADDR_BURST_CTRL1_LO 0x0C // BURST_CTRL1 Byte0 (W1)
154 #define ADDR_BURST_CTRL1_HI 0x0D // BURST_CTRL1 Byte1 (W1)
155 #define ADDR_BURST_CTRL2_LO 0x0E // BURST_CTRL2 Byte0 (W1)
156 #define ADDR_BURST_CTRL2_HI 0x0F // BURST_CTRL2 Byte1 (W1)
157 #define ADDR_POL_CTRL_LO 0x10 // POL_CTRL Byte0 (W1)
158 #define ADDR_POL_CTRL_HI 0x11 // POL_CTRL Byte1 (W1)
159 
160 #define ADDR_DLT_CTRL_LO 0x12 // DLT_CTRL Byte0 (W1)
161 #define ADDR_DLT_CTRL_HI 0x13 // DLT_CTRL Byte1 (W1)
162 #define ADDR_GLOB_CMD3_LO 0x12 // GLOB_CMD3 Byte0 (W1) Same address as DLT_CTRL
163 #define ADDR_GLOB_CMD3_HI 0x13 // GLOB_CMD3 Byte1 (W1) Same address as DLT_CTRL
164 
165 #define ADDR_ATTI_CTRL_LO 0x14 // ATTI_CTRL Byte0 (W1)
166 #define ADDR_ATTI_CTRL_HI 0x15 // ATTI_CTRL Byte1 (W1)
167 #define ADDR_GLOB_CMD2_LO 0x16 // ATTI_GLOB_CMD2 Byte0 (W1)
168 #define ADDR_GLOB_CMD2_HI 0x17 // ATTI_GLOB_CMD2 Byte1 (W1)
169 
170 // For G330PDG0, G366PDG0, G370PDG0, G370PDT0 Rotation Matrix for both Gyro and
171 // Accel
172 #define ADDR_R_MATRIX_M11_LO 0x38 // R_MATRIX_M11 Byte0 (W1)
173 #define ADDR_R_MATRIX_M11_HI 0x39 // R_MATRIX_M11 Byte1 (W1)
174 #define ADDR_R_MATRIX_M12_LO 0x3A // R_MATRIX_M12 Byte0 (W1)
175 #define ADDR_R_MATRIX_M12_HI 0x3B // R_MATRIX_M12 Byte1 (W1)
176 #define ADDR_R_MATRIX_M13_LO 0x3C // R_MATRIX_M13 Byte0 (W1)
177 #define ADDR_R_MATRIX_M13_HI 0x3D // R_MATRIX_M13 Byte1 (W1)
178 #define ADDR_R_MATRIX_M21_LO 0x3E // R_MATRIX_M21 Byte0 (W1)
179 #define ADDR_R_MATRIX_M21_HI 0x3F // R_MATRIX_M21 Byte1 (W1)
180 #define ADDR_R_MATRIX_M22_LO 0x40 // R_MATRIX_M22 Byte0 (W1)
181 #define ADDR_R_MATRIX_M22_HI 0x41 // R_MATRIX_M22 Byte1 (W1)
182 #define ADDR_R_MATRIX_M23_LO 0x42 // R_MATRIX_M23 Byte0 (W1)
183 #define ADDR_R_MATRIX_M23_HI 0x43 // R_MATRIX_M23 Byte1 (W1)
184 #define ADDR_R_MATRIX_M31_LO 0x44 // R_MATRIX_M31 Byte0 (W1)
185 #define ADDR_R_MATRIX_M31_HI 0x45 // R_MATRIX_M31 Byte1 (W1)
186 #define ADDR_R_MATRIX_M32_LO 0x46 // R_MATRIX_M32 Byte0 (W1)
187 #define ADDR_R_MATRIX_M32_HI 0x47 // R_MATRIX_M32 Byte1 (W1)
188 #define ADDR_R_MATRIX_M33_LO 0x48 // R_MATRIX_M33 Byte0 (W1)
189 #define ADDR_R_MATRIX_M33_HI 0x49 // R_MATRIX_M33 Byte1 (W1)
190 
191 // For G365PDC1, G365PDF1, G370PDF1, G370PDS0 Rotation Matrix for Accel
192 #define R_MATRIX_A_M11_LO 0x4A // R_MATRIX_A_M11 Byte0 (W1)
193 #define R_MATRIX_A_M11_HI 0x4B // R_MATRIX_A_M11 Byte1 (W1)
194 #define R_MATRIX_A_M12_LO 0x4C // R_MATRIX_A_M12 Byte0 (W1)
195 #define R_MATRIX_A_M12_HI 0x4D // R_MATRIX_A_M12 Byte1 (W1)
196 #define R_MATRIX_A_M13_LO 0x4E // R_MATRIX_A_M13 Byte0 (W1)
197 #define R_MATRIX_A_M13_HI 0x4F // R_MATRIX_A_M13 Byte1 (W1)
198 #define R_MATRIX_A_M21_LO 0x50 // R_MATRIX_A_M21 Byte0 (W1)
199 #define R_MATRIX_A_M21_HI 0x51 // R_MATRIX_A_M21 Byte1 (W1)
200 #define R_MATRIX_A_M22_LO 0x52 // R_MATRIX_A_M22 Byte0 (W1)
201 #define R_MATRIX_A_M22_HI 0x53 // R_MATRIX_A_M22 Byte1 (W1)
202 #define R_MATRIX_A_M23_LO 0x54 // R_MATRIX_A_M23 Byte0 (W1)
203 #define R_MATRIX_A_M23_HI 0x55 // R_MATRIX_A_M23 Byte1 (W1)
204 #define R_MATRIX_A_M31_LO 0x56 // R_MATRIX_A_M31 Byte0 (W1)
205 #define R_MATRIX_A_M31_HI 0x57 // R_MATRIX_A_M31 Byte1 (W1)
206 #define R_MATRIX_A_M32_LO 0x58 // R_MATRIX_A_M32 Byte0 (W1)
207 #define R_MATRIX_A_M32_HI 0x59 // R_MATRIX_A_M32 Byte1 (W1)
208 #define R_MATRIX_A_M33_LO 0x5A // R_MATRIX_A_M33 Byte0 (W1)
209 #define R_MATRIX_A_M33_HI 0x5B // R_MATRIX_A_M33 Byte1 (W1)
210 
211 #define ADDR_PROD_ID1 0x6A // PROD_ID1(W1)
212 #define ADDR_PROD_ID2 0x6C // PROD_ID2(W1)
213 #define ADDR_PROD_ID3 0x6E // PROD_ID3(W1)
214 #define ADDR_PROD_ID4 0x70 // PROD_ID4(W1)
215 #define ADDR_VERSION 0x72 // VERSION(W1)
216 #define ADDR_SERIAL_NUM1 0x74 // SERIAL_NUM1(W1)
217 #define ADDR_SERIAL_NUM2 0x76 // SERIAL_NUM2(W1)
218 #define ADDR_SERIAL_NUM3 0x78 // SERIAL_NUM3(W1)
219 #define ADDR_SERIAL_NUM4 0x7A // SERIAL_NUM4(W1)
220 #define ADDR_WIN_CTRL 0x7E // WIN_CTRL(W0 or W1)
221 
222 #define WIN_ID0 0x00
223 #define WIN_ID1 0x01
224 
225 #define CMD_BURST 0x80 // Write value to Issue Burst Read
226 #define CMD_SAMPLING 0x01 // Write value for MODE_CMD_HI to begin sampling
227 #define CMD_CONFIG 0x02 // Write value for MODE_CMD_HI to stop sampling
228 
229 // Write values for ADDR_SMPL_CTRL_HI to set Output Rate
230 #define CMD_RATE2000 0x00 // TAP>=0
231 #define CMD_RATE1000 0x01 // TAP>=2
232 #define CMD_RATE500 0x02 // TAP>=4
233 #define CMD_RATE250 0x03 // TAP>=8
234 #define CMD_RATE125 0x04 // TAP>=16
235 #define CMD_RATE62_5 0x05 // TAP>=32
236 #define CMD_RATE31_25 0x06 // TAP>=64
237 #define CMD_RATE15_625 0x07 // TAP=128
238 #define CMD_RATE400 0x08 // TAP>=8
239 #define CMD_RATE200 0x09 // TAP>=16
240 #define CMD_RATE100 0x0A // TAP>=32
241 #define CMD_RATE80 0x0B // TAP>=32
242 #define CMD_RATE50 0x0C // TAP>=64
243 #define CMD_RATE40 0x0D // TAP>=64
244 #define CMD_RATE25 0x0E // TAP=128
245 #define CMD_RATE20 0x0F // TAP=128
246 
247 // Write values for FILTER_CTRL_LO to set Filter
248 #define CMD_FLTAP0 0x00
249 #define CMD_FLTAP2 0x01
250 #define CMD_FLTAP4 0x02
251 #define CMD_FLTAP8 0x03
252 #define CMD_FLTAP16 0x04
253 #define CMD_FLTAP32 0x05
254 #define CMD_FLTAP64 0x06
255 #define CMD_FLTAP128 0x07
256 #define CMD_FIRTAP32FC50 0x08
257 #define CMD_FIRTAP32FC100 0x09
258 #define CMD_FIRTAP32FC200 0x0A
259 #define CMD_FIRTAP32FC400 0x0B
260 #define CMD_FIRTAP64FC50 0x0C
261 #define CMD_FIRTAP64FC100 0x0D
262 #define CMD_FIRTAP64FC200 0x0E
263 #define CMD_FIRTAP64FC400 0x0F
264 #define CMD_FIRTAP128FC50 0x10
265 #define CMD_FIRTAP128FC100 0x11
266 #define CMD_FIRTAP128FC200 0x12
267 #define CMD_FIRTAP128FC400 0x13
268 
269 // Write values for ATTITUDE_MOTION_PROFILE
270 #define CMD_ATM_MODEA 0x00
271 #define CMD_ATM_MODEB 0x10
272 #define CMD_ATM_MODEC 0x20
273 
274 // MODE STAT
275 #define VAL_SAMPLING_MODE 0x00
276 #define VAL_CONFIG_MODE 0x04
277 
278 #ifdef __cplusplus
279 extern "C" {
280 #endif
281 
300 };
301 
311 };
312 
313 // Epson sensor model specific properties
315  int model;
316  const char* product_id;
318  double gyro_sf_dps;
319  double accl_sf_mg;
323  double ang_sf_deg;
324  double qtn_sf;
325  double dlta0_sf_deg;
326  double dltv0_sf_mps;
333 };
334 
335 // Array of EpsonProperties structs
336 extern struct EpsonProperties
337  epson_sensors[G_UNKNOWN + 1]; // number of items in enum EpsonModels
338 
339 // Epson sensor initialization options
340 struct EpsonOptions {
341  // MSC_CTRL
342  int ext_sel;
343  int ext_pol;
344  int drdy_on;
345  int drdy_pol;
346 
347  // SMPL_CTRL
349 
350  // FILTER_CTRL
352 
353  // BURST_CTRL1
354  int flag_out;
355  int temp_out;
356  int gyro_out;
360  int qtn_out;
361  int atti_out;
362 
363  int gpio_out;
366 
367  // BURST_CTRL2
368  int temp_bit;
369  int gyro_bit;
373  int qtn_bit;
374  int atti_bit;
375 
376  // POL_CTRL
383 
385 
386  // DLT_CTRL
389 
390  // ATTI_CTRL
393 
394  // ATTI_MOTION_PROFILE
396 };
397 
398 // Epson sensor burst data storage structure
399 struct EpsonData {
400  unsigned short ndflags;
401  double temperature;
402  double gyro_x, gyro_y, gyro_z;
406  double qtn0, qtn1, qtn2, qtn3;
407  double ang1, ang2, ang3;
408  unsigned short gpio;
409  int count;
410  unsigned short chksm;
411 };
412 
413 // ***************************************************
414 // Defined in sensor_epsonUart.c or sensor_epsonSpi.c
415 void writeByte(unsigned char, unsigned char, unsigned int);
416 void registerWriteByte(unsigned char, unsigned char, unsigned char,
417  unsigned int);
418 unsigned short read16(unsigned char, unsigned int);
419 unsigned short registerRead16(unsigned char, unsigned char, unsigned int);
421  const struct EpsonOptions*, struct EpsonData*);
422 // ***************************************************
423 
424 int sensorHWReset(void);
425 int sensorPowerOn(void);
426 void sensorStart(void);
427 void sensorStop(void);
428 void sensorReset(const struct EpsonProperties*);
429 int sensorFlashTest(const struct EpsonProperties*);
430 int sensorSelfTest(const struct EpsonProperties*);
431 int sensorInitialBackup(const struct EpsonProperties*);
432 int sensorFlashBackup(const struct EpsonProperties*);
433 unsigned int sensorDataByteLength(const struct EpsonProperties*,
434  const struct EpsonOptions*);
435 void sensorDummyWrite(void);
436 char* sensorGetProductId(char* prod_id);
437 char* sensorGetSerialId(char* serial_id);
438 int sensorInitOptions(const struct EpsonProperties*, struct EpsonOptions*);
439 void sensorDumpRegisters(const struct EpsonProperties*);
440 int sensorGetDeviceModel(struct EpsonProperties*, char* prod_id,
441  char* serial_id);
442 
443 #ifdef __cplusplus
444 }
445 #endif
EpsonData::qtn1
double qtn1
Definition: sensor_epsonCommon.h:406
G370PDG0
@ G370PDG0
Definition: sensor_epsonCommon.h:296
EpsonProperties
Definition: sensor_epsonCommon.h:314
EpsonOptions::invert_xgyro
int invert_xgyro
Definition: sensor_epsonCommon.h:377
EpsonOptions::accel_delta_bit
int accel_delta_bit
Definition: sensor_epsonCommon.h:372
EpsonData::ang2
double ang2
Definition: sensor_epsonCommon.h:407
EpsonData::accel_y
double accel_y
Definition: sensor_epsonCommon.h:403
sensorSelfTest
int sensorSelfTest(const struct EpsonProperties *)
Definition: sensor_epsonCommon.c:570
G370PDFN
@ G370PDFN
Definition: sensor_epsonCommon.h:292
epson_sensors
struct EpsonProperties epson_sensors[G_UNKNOWN+1]
Definition: sensor_epsonCommon.c:28
EpsonOptions::ext_pol
int ext_pol
Definition: sensor_epsonCommon.h:343
EpsonProperties::delay_filter_ms
int delay_filter_ms
Definition: sensor_epsonCommon.h:331
EpsonModels
EpsonModels
Definition: sensor_epsonCommon.h:282
G370PDF1
@ G370PDF1
Definition: sensor_epsonCommon.h:291
EpsonProperties::dlta0_sf_deg
double dlta0_sf_deg
Definition: sensor_epsonCommon.h:325
EpsonOptions::atti_mode
int atti_mode
Definition: sensor_epsonCommon.h:391
EpsonOptions::drdy_on
int drdy_on
Definition: sensor_epsonCommon.h:344
EpsonOptions::ext_sel
int ext_sel
Definition: sensor_epsonCommon.h:342
EpsonOptions::filter_sel
int filter_sel
Definition: sensor_epsonCommon.h:351
HAS_ATTI_ON_REG
@ HAS_ATTI_ON_REG
Definition: sensor_epsonCommon.h:305
EpsonOptions::invert_ygyro
int invert_ygyro
Definition: sensor_epsonCommon.h:378
G370PDT0
@ G370PDT0
Definition: sensor_epsonCommon.h:297
sensorDataReadBurstNOptions
int sensorDataReadBurstNOptions(const struct EpsonProperties *, const struct EpsonOptions *, struct EpsonData *)
Definition: sensor_epsonSpi.c:451
EpsonData::chksm
unsigned short chksm
Definition: sensor_epsonCommon.h:410
sensorStop
void sensorStop(void)
Definition: sensor_epsonCommon.c:504
registerRead16
unsigned short registerRead16(unsigned char, unsigned char, unsigned int)
Definition: sensor_epsonSpi.c:101
EpsonProperties::delay_reset_ms
int delay_reset_ms
Definition: sensor_epsonCommon.h:327
sensor_epsonUart.h
registerWriteByte
void registerWriteByte(unsigned char, unsigned char, unsigned char, unsigned int)
Definition: sensor_epsonSpi.c:60
EpsonOptions::temp_bit
int temp_bit
Definition: sensor_epsonCommon.h:368
EpsonProperties::delay_atti_profile_ms
int delay_atti_profile_ms
Definition: sensor_epsonCommon.h:332
sensorInitialBackup
int sensorInitialBackup(const struct EpsonProperties *)
Definition: sensor_epsonCommon.c:603
EpsonOptions::drdy_pol
int drdy_pol
Definition: sensor_epsonCommon.h:345
HAS_ATTITUDE_OUTPUT
@ HAS_ATTITUDE_OUTPUT
Definition: sensor_epsonCommon.h:303
EpsonData::gyro_delta_z
double gyro_delta_z
Definition: sensor_epsonCommon.h:404
EpsonOptions::gpio_out
int gpio_out
Definition: sensor_epsonCommon.h:363
EpsonOptions
Definition: sensor_epsonCommon.h:340
sensorGetSerialId
char * sensorGetSerialId(char *serial_id)
Definition: sensor_epsonCommon.c:808
EpsonData::accel_delta_y
double accel_delta_y
Definition: sensor_epsonCommon.h:405
EpsonData::gyro_x
double gyro_x
Definition: sensor_epsonCommon.h:402
EpsonData::gyro_delta_y
double gyro_delta_y
Definition: sensor_epsonCommon.h:404
EpsonProperties::dltv0_sf_mps
double dltv0_sf_mps
Definition: sensor_epsonCommon.h:326
EpsonOptions::dout_rate
int dout_rate
Definition: sensor_epsonCommon.h:348
EpsonOptions::gyro_bit
int gyro_bit
Definition: sensor_epsonCommon.h:369
EpsonData::temperature
double temperature
Definition: sensor_epsonCommon.h:401
EpsonOptions::qtn_out
int qtn_out
Definition: sensor_epsonCommon.h:360
HAS_RANGE_OVER
@ HAS_RANGE_OVER
Definition: sensor_epsonCommon.h:307
read16
unsigned short read16(unsigned char, unsigned int)
Definition: sensor_epsonSpi.c:75
EpsonOptions::accel_out
int accel_out
Definition: sensor_epsonCommon.h:357
EpsonData::gyro_delta_x
double gyro_delta_x
Definition: sensor_epsonCommon.h:404
sensorPowerOn
int sensorPowerOn(void)
Definition: sensor_epsonCommon.c:445
EpsonOptions::atti_profile
int atti_profile
Definition: sensor_epsonCommon.h:395
EpsonOptions::invert_yaccel
int invert_yaccel
Definition: sensor_epsonCommon.h:381
sensorDummyWrite
void sensorDummyWrite(void)
Definition: sensor_epsonCommon.c:766
EpsonProperties::qtn_sf
double qtn_sf
Definition: sensor_epsonCommon.h:324
EpsonOptions::count_out
int count_out
Definition: sensor_epsonCommon.h:364
EpsonProperties::delay_flashtest_ms
int delay_flashtest_ms
Definition: sensor_epsonCommon.h:328
HAS_INITIAL_BACKUP
@ HAS_INITIAL_BACKUP
Definition: sensor_epsonCommon.h:310
EpsonFeatureFlags
EpsonFeatureFlags
Definition: sensor_epsonCommon.h:302
sensorDataByteLength
unsigned int sensorDataByteLength(const struct EpsonProperties *, const struct EpsonOptions *)
Definition: sensor_epsonCommon.c:671
G_EMPTY
@ G_EMPTY
Definition: sensor_epsonCommon.h:283
sensorDumpRegisters
void sensorDumpRegisters(const struct EpsonProperties *)
Definition: sensor_epsonCommon.c:1061
EpsonData::gpio
unsigned short gpio
Definition: sensor_epsonCommon.h:408
EpsonData::ang1
double ang1
Definition: sensor_epsonCommon.h:407
EpsonData::accel_delta_x
double accel_delta_x
Definition: sensor_epsonCommon.h:405
EpsonData::accel_x
double accel_x
Definition: sensor_epsonCommon.h:403
EpsonOptions::flag_out
int flag_out
Definition: sensor_epsonCommon.h:354
EpsonOptions::checksum_out
int checksum_out
Definition: sensor_epsonCommon.h:365
EpsonData::gyro_z
double gyro_z
Definition: sensor_epsonCommon.h:402
EpsonData
Definition: sensor_epsonCommon.h:399
EpsonProperties::feature_flags
int feature_flags
Definition: sensor_epsonCommon.h:317
EpsonOptions::atti_bit
int atti_bit
Definition: sensor_epsonCommon.h:374
EpsonData::ang3
double ang3
Definition: sensor_epsonCommon.h:407
G365PDF1
@ G365PDF1
Definition: sensor_epsonCommon.h:290
sensorReset
void sensorReset(const struct EpsonProperties *)
Definition: sensor_epsonCommon.c:522
EpsonOptions::invert_zgyro
int invert_zgyro
Definition: sensor_epsonCommon.h:379
EpsonData::count
int count
Definition: sensor_epsonCommon.h:409
EpsonData::qtn3
double qtn3
Definition: sensor_epsonCommon.h:406
EpsonData::ndflags
unsigned short ndflags
Definition: sensor_epsonCommon.h:400
EpsonProperties::gyro_sf_dps
double gyro_sf_dps
Definition: sensor_epsonCommon.h:318
HAS_DLT_OUTPUT
@ HAS_DLT_OUTPUT
Definition: sensor_epsonCommon.h:304
G364PDC0
@ G364PDC0
Definition: sensor_epsonCommon.h:288
G320PDGN
@ G320PDGN
Definition: sensor_epsonCommon.h:285
EpsonProperties::delay_flashbackup_ms
int delay_flashbackup_ms
Definition: sensor_epsonCommon.h:329
sensorGetDeviceModel
int sensorGetDeviceModel(struct EpsonProperties *, char *prod_id, char *serial_id)
Definition: sensor_epsonCommon.c:1192
EpsonProperties::rstcnt_sf_micros
int rstcnt_sf_micros
Definition: sensor_epsonCommon.h:322
sensorStart
void sensorStart(void)
Definition: sensor_epsonCommon.c:490
HAS_RTDIAG
@ HAS_RTDIAG
Definition: sensor_epsonCommon.h:308
EpsonData::qtn2
double qtn2
Definition: sensor_epsonCommon.h:406
EpsonOptions::a_range_ctrl
int a_range_ctrl
Definition: sensor_epsonCommon.h:384
G370PDS0
@ G370PDS0
Definition: sensor_epsonCommon.h:293
EpsonProperties::tempc_sf_degc
double tempc_sf_degc
Definition: sensor_epsonCommon.h:320
sensorFlashTest
int sensorFlashTest(const struct EpsonProperties *)
Definition: sensor_epsonCommon.c:539
EpsonData::qtn0
double qtn0
Definition: sensor_epsonCommon.h:406
sensorHWReset
int sensorHWReset(void)
Definition: sensor_epsonCommon.c:413
EpsonOptions::atti_out
int atti_out
Definition: sensor_epsonCommon.h:361
EpsonOptions::gyro_delta_out
int gyro_delta_out
Definition: sensor_epsonCommon.h:358
EpsonData::gyro_y
double gyro_y
Definition: sensor_epsonCommon.h:402
EpsonOptions::gyro_out
int gyro_out
Definition: sensor_epsonCommon.h:356
EpsonProperties::accl_sf_mg
double accl_sf_mg
Definition: sensor_epsonCommon.h:319
EpsonOptions::temp_out
int temp_out
Definition: sensor_epsonCommon.h:355
EpsonOptions::dlta_range_ctrl
int dlta_range_ctrl
Definition: sensor_epsonCommon.h:387
G_UNKNOWN
@ G_UNKNOWN
Definition: sensor_epsonCommon.h:299
EpsonOptions::accel_bit
int accel_bit
Definition: sensor_epsonCommon.h:370
EpsonData::accel_z
double accel_z
Definition: sensor_epsonCommon.h:403
EpsonProperties::model
int model
Definition: sensor_epsonCommon.h:315
sensorInitOptions
int sensorInitOptions(const struct EpsonProperties *, struct EpsonOptions *)
Definition: sensor_epsonCommon.c:835
sensor_epsonSpi.h
writeByte
void writeByte(unsigned char, unsigned char, unsigned int)
Definition: sensor_epsonSpi.c:39
EpsonOptions::dltv_range_ctrl
int dltv_range_ctrl
Definition: sensor_epsonCommon.h:388
EpsonOptions::atti_conv
int atti_conv
Definition: sensor_epsonCommon.h:392
G570PR20
@ G570PR20
Definition: sensor_epsonCommon.h:298
HAS_ROT_MATRIX
@ HAS_ROT_MATRIX
Definition: sensor_epsonCommon.h:306
G365PDC1
@ G365PDC1
Definition: sensor_epsonCommon.h:289
G330PDG0
@ G330PDG0
Definition: sensor_epsonCommon.h:294
EpsonOptions::invert_zaccel
int invert_zaccel
Definition: sensor_epsonCommon.h:382
sensorFlashBackup
int sensorFlashBackup(const struct EpsonProperties *)
Definition: sensor_epsonCommon.c:638
G366PDG0
@ G366PDG0
Definition: sensor_epsonCommon.h:295
EpsonOptions::accel_delta_out
int accel_delta_out
Definition: sensor_epsonCommon.h:359
EpsonOptions::qtn_bit
int qtn_bit
Definition: sensor_epsonCommon.h:373
EpsonData::accel_delta_z
double accel_delta_z
Definition: sensor_epsonCommon.h:405
G364PDCA
@ G364PDCA
Definition: sensor_epsonCommon.h:287
EpsonOptions::invert_xaccel
int invert_xaccel
Definition: sensor_epsonCommon.h:380
EpsonOptions::gyro_delta_bit
int gyro_delta_bit
Definition: sensor_epsonCommon.h:371
EpsonProperties::ang_sf_deg
double ang_sf_deg
Definition: sensor_epsonCommon.h:323
HAS_ARANGE
@ HAS_ARANGE
Definition: sensor_epsonCommon.h:309
EpsonProperties::tempc_25c_offset
int tempc_25c_offset
Definition: sensor_epsonCommon.h:321
sensorGetProductId
char * sensorGetProductId(char *prod_id)
Definition: sensor_epsonCommon.c:782
G354PDH0
@ G354PDH0
Definition: sensor_epsonCommon.h:286
EpsonProperties::delay_selftest_ms
int delay_selftest_ms
Definition: sensor_epsonCommon.h:330
G320PDG0
@ G320PDG0
Definition: sensor_epsonCommon.h:284
EpsonProperties::product_id
const char * product_id
Definition: sensor_epsonCommon.h:316


ess_imu_driver
Author(s):
autogenerated on Wed Dec 11 2024 03:06:30