From 472b559293cde83bb1f8eeae22fbc60f4a655b1f Mon Sep 17 00:00:00 2001 From: ROY Date: Tue, 25 Oct 2022 13:40:21 +0800 Subject: [PATCH 1/6] [update] new RT mode --- .../cc26xx/app/headstage/EliteADC.h | 2 +- .../cc26xx/app/headstage/EliteLED.h | 1 + .../cc26xx/app/headstage/EliteWorkData.h | 6 ++- .../cc26xx/app/headstage/Elite_def.h | 1 + .../cc26xx/app/headstage/Elite_mode_ADC_DAC.h | 48 ++++++++++--------- .../cc26xx/app/headstage/headstage.h | 15 ++++++ .../cc26xx/app/headstage/impedance_meter.h | 31 +++++++++++- .../cc26xx/app/headstage/mode_ca.h | 16 +++++++ 8 files changed, 94 insertions(+), 26 deletions(-) diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteADC.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteADC.h index 6898af4..a9713b7 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteADC.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteADC.h @@ -337,7 +337,7 @@ static int32_t read_LPTIA_Iin(){ Iin = Cali_LPTIA(ADCraw, instru.gain_lv_lptia); InputNotify(NOTIFY_CURRENT, Iin); - InputNotify(NOTIFY_IMPEDANCE, instru.gain_lv_lptia); + // InputNotify(NOTIFY_IMPEDANCE, instru.gain_lv_lptia); return Iin; } diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteLED.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteLED.h index 7f7fbc4..c606457 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteLED.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteLED.h @@ -70,6 +70,7 @@ static void WorkModeLED() case CURVE_EIS_CV: case CURVE_CA: case CURVE_VT: + case CURVE_RT: led_color_set(LED_NB_MAX, LED_BR_LV1, LED_CLR_CYAN); break; diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteWorkData.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteWorkData.h index be28a65..39868e8 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteWorkData.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/EliteWorkData.h @@ -330,7 +330,7 @@ static int __rt_create(void) m->_measureBat = 0; m->_VoViSwitch = instru.VoViSwitch; - p->_Vinit = (instru.Vinit - 25000) * 4 * 10000; //[5nV] + p->_Vinit = (instru.Vinit - 25000) * 4 * 4000; //[5nV] p->_Vset = 0; *wm = p; @@ -576,6 +576,10 @@ int wm_init(void) if (__vt_create()) return -2; break; + case CURVE_RT: + if (__rt_create()) return -2; + break; + default: // printf("DO NOT support!!"); return -3; diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_def.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_def.h index 3cf671d..b1e277a 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_def.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_def.h @@ -20,6 +20,7 @@ enum all_mode_e { CURVE_EIS = 0xD1, //Should Change to 0xD1 CURVE_EIS_CV = 0xD2, CURVE_CA = 0xD3, + CURVE_RT = 0x04, CURVE_VT = 0x05, // CURVE_CALI_ADC = 0xF1, SET_SAMPLE_RATE = 0xE0, diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_mode_ADC_DAC.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_mode_ADC_DAC.h index e206caf..6775196 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_mode_ADC_DAC.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_mode_ADC_DAC.h @@ -27,6 +27,14 @@ static void vscan_volt_out(void) void *wm = wm_get(); + /* in [5nV] ver */ + MEAS_VOUT(wm) = DAC_outputV(Vset); + InputNotify(NOTIFY_VOLT, Vset/200); + } else if (instru.eliteFxn == CURVE_RT) { + struct wm_rt_ctx_t *rt = (struct wm_rt_ctx_t *)wm_get(); + + void *wm = wm_get(); + /* in [5nV] ver */ MEAS_VOUT(wm) = DAC_outputV(Vset); InputNotify(NOTIFY_VOLT, Vset/200); @@ -36,28 +44,6 @@ static void vscan_volt_out(void) return; } -static void CalcuResistance() -{ - /* Elite 100 = 100R - Elite 1000 = 1KR - Elite 10000 = 10KR - Elite 100000 = 100KR - Elite 1000000 = 1MR - */ - - struct wm_rt_ctx_t *rt = (struct wm_rt_ctx_t *)wm_get(); - struct wm_meas_t *m = &rt->measure; - int64_t resist; - int64_t volt = (int64_t)(m->_measureVout) ; - int64_t current = (int64_t)(m->_measureCurrent); - - resist = volt * 1000000 / current; //R = V / Iin; [mOhm] - InputNotify(NOTIFY_IMPEDANCE, resist); - - return; -} - - //////EIS PLOT RELATED FUNCTION START////// static uint8_t CalcDecade(uint32_t f1, uint32_t f2) { @@ -216,6 +202,24 @@ static void VT_Plot(void) return; } +static void RT_Plot(void) +{ + struct wm_cv_ctx_t *rt = (struct wm_cv_ctx_t *)wm_get(); + static uint8_t ADC_cnt = 0; + void *wm = wm_get(); + + if (ADC_cnt == 0) { + LPTIA_change_gain(); + ADC_cnt++; + + } else if (ADC_cnt == 1) { + read_LPTIA_Iin(); + ADC_cnt = 0; + } + + return; +} + static void EIS_Plot(void) //real and imag impedance plot { struct wm_eis_ctx_t *eis = (struct wm_eis_ctx_t *)wm_get(); diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h index 1d5dcc9..e1b6490 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h @@ -119,6 +119,7 @@ static void EliteADCControl(void); static void cv_vscan(void); static void ca_vscan(void); +static void rt_vscan(void); static void mode_done(void); //mode (DAC) @@ -283,6 +284,20 @@ static void update_ZM_instruction(uint8 *ins) { break; } + case CURVE_RT: { //350605 + instru.eliteFxn = CURVE_RT; + instru.notifyRate = (uint32_t)ins[5] << 8 | (uint32_t)ins[6]; + instru.notifyRate = 10000 / instru.notifyRate * 10; + // instru.notifyRate = 100; + // instru.measure_vin_range = ins[7]; + // instru.measure_vin_range = 0; + setEIS_CV(); + instru.Vinit = 37500; + + ModeLED(WORKING); + break; + } + case SET_SAMPLE_RATE: { instru.notifyRate = (uint32_t)ins[3] << 8 | (uint32_t)ins[4]; instru.notifyRate = 10000 / instru.notifyRate * 10; diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/impedance_meter.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/impedance_meter.h index f40bb11..224725d 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/impedance_meter.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/impedance_meter.h @@ -32,7 +32,8 @@ static void vscan_ctrl(void); instru.eliteFxn == CURVE_EIS || \ instru.eliteFxn == CURVE_EIS_CV || \ instru.eliteFxn == CURVE_CA || \ -instru.eliteFxn == CURVE_VT \ +instru.eliteFxn == CURVE_VT || \ +instru.eliteFxn == CURVE_RT \ ) #define Ve1MatchVe2Mode() ( \ @@ -234,7 +235,9 @@ static void EliteADCControl(void) //CURVE_IV => CC_Plot() | CURVE_CV => Iin_Vin_ VT_Plot(); break; - + case CURVE_RT: + RT_Plot(); + break; // case CURVE_CALI_ADC: // if (instru.AdcChannel == IIN_ADC) { // cali_IT_plot(); @@ -269,6 +272,25 @@ static void mode_done(void) //finishMode = 1, SendNotify(), reset() } } +static void CalcuResistance() +{ + /* Elite 100000 = 100R + Elite 1000000 = 1KR + Elite 10000000 = 10KR + Elite 100000000 = 100KR + Elite 1000000000 = 1MR + */ + + struct wm_rt_ctx_t *rt = (struct wm_rt_ctx_t *)wm_get(); + struct wm_meas_t *m = &rt->measure; + int64_t resist; + int64_t volt = Vset / 200; // [uV] + int64_t current = (int64_t)(m->_measureCurrent); + + resist = volt * 1000000 / current; //R = V / Iin; [mOhm] + InputNotify(NOTIFY_IMPEDANCE, resist); +} + static void vscan_ctrl(void) { switch (instru.eliteFxn) { @@ -284,6 +306,11 @@ static void vscan_ctrl(void) ca_vscan(); break; + case CURVE_RT: + CalcuResistance(); + rt_vscan(); + break; + default:{ break; } diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/mode_ca.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/mode_ca.h index caa8166..b806d64 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/mode_ca.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/mode_ca.h @@ -17,4 +17,20 @@ static void ca_vscan(void) return; } + +static void rt_vscan(void) +{ + struct wm_rt_ctx_t *rt = (struct wm_rt_ctx_t *)wm_get(); + + if(vscanReset){ + Vset = rt->_Vinit; + } + + if(!vscanReset){ + Vset = rt->_Vinit; + } + + return; +} + #endif From 2eddaf000b77bf1a53d4c82ed57c761950274acc Mon Sep 17 00:00:00 2001 From: ROY Date: Thu, 27 Oct 2022 11:11:04 +0800 Subject: [PATCH 2/6] [update] update cali value for BOARD_EIS002, BOARD_EIS005, BOARD_EIS006, BOARD_EIS007 and BOARD_EISM001~BOARD_EISM008. --- .../cc26xx/app/headstage/Elite_version.h | 6 +- .../cc26xx/app/headstage/eis_cali_table.h | 1224 ++++++++++++++++- 2 files changed, 1156 insertions(+), 74 deletions(-) diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h index 809afc0..93fc7f2 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h @@ -4,9 +4,9 @@ #define VERSION_DATE_YEAR 22 #define VERSION_DATE_MONTH 10 -#define VERSION_DATE_DAY 7 -#define VERSION_DATE_HOUR 10 -#define VERSION_DATE_MINUTE 49 +#define VERSION_DATE_DAY 27 +#define VERSION_DATE_HOUR 11 +#define VERSION_DATE_MINUTE 11 // this is NOT the version hash !! // it's the last version hash diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h index 903df76..3738d69 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h @@ -1,7 +1,7 @@ #ifndef EIS_CALI_TABLE #define EIS_CALI_TABLE -#define BOARD_CALI_BOARD +#define BOARD_EISM008 typedef struct _SingleFilterCali{ int32_t Phase_coeff; @@ -31,6 +31,8 @@ struct _CaliTable{ long long HSDAC_AMP_a; long long HSDAC_AMP_b; long long HSDAC_AMP_c; + long long HSDAC_AMP_d; + long long DAC_offset_a; long long DAC_offset_b; @@ -300,54 +302,53 @@ struct _CaliTable{ { .DeviceName = "BOARD_e755", - - .DAC_offset_a = 111758028118, - .DAC_offset_b = -3145521615133850, - - .HSDAC_AMP_a = 9717505, + .DAC_offset_a = 111730766111, + .DAC_offset_b = -3144949453753438, + .HSDAC_AMP_a = 9740888, .HSDAC_AMP_b = 0, + .OffsetZero = 22707, - .Ft[0][0].Phase_coeff = 0, - .Ft[0][0].Phase_offset = 0, - .Ft[0][1].Phase_coeff = 0, - .Ft[0][1].Phase_offset = 0, - .Ft[0][2].Phase_coeff = 0, - .Ft[0][2].Phase_offset = 0, - .Ft[0][3].Phase_coeff = 0, - .Ft[0][3].Phase_offset = 0, + .Ft[0][0].Phase_coeff = 148458, + .Ft[0][0].Phase_offset = -89697082, + .Ft[0][1].Phase_coeff = 342057, + .Ft[0][1].Phase_offset = -89922491, + .Ft[0][2].Phase_coeff = 20587633, + .Ft[0][2].Phase_offset = -90025556, + .Ft[0][3].Phase_coeff = 101852632, + .Ft[0][3].Phase_offset = -90098007, - .Ft[1][0].Phase_coeff = 0, - .Ft[1][0].Phase_offset = 0, - .Ft[1][1].Phase_coeff = 0, - .Ft[1][1].Phase_offset = 0, - .Ft[1][2].Phase_coeff = 0, - .Ft[1][2].Phase_offset = 0, - .Ft[1][3].Phase_coeff = 0, - .Ft[1][3].Phase_offset = 0, + .Ft[1][0].Phase_coeff = 144051, + .Ft[1][0].Phase_offset = -89676178, + .Ft[1][1].Phase_coeff = 337358, + .Ft[1][1].Phase_offset = -89897762, + .Ft[1][2].Phase_coeff = 20537388, + .Ft[1][2].Phase_offset = -89988105, + .Ft[1][3].Phase_coeff = 99519253, + .Ft[1][3].Phase_offset = -89925063, - .Ft[2][0].Phase_coeff = 0, - .Ft[2][0].Phase_offset = 0, - .Ft[2][1].Phase_coeff = 0, - .Ft[2][1].Phase_offset = 0, - .Ft[2][2].Phase_coeff = 0, - .Ft[2][2].Phase_offset = 0, - .Ft[2][3].Phase_coeff = 0, - .Ft[2][3].Phase_offset = 0, + .Ft[2][0].Phase_coeff = 138633, + .Ft[2][0].Phase_offset = -89685181, + .Ft[2][1].Phase_coeff = 331966, + .Ft[2][1].Phase_offset = -89900981, + .Ft[2][2].Phase_coeff = 20548492, + .Ft[2][2].Phase_offset = -90000752, + .Ft[2][3].Phase_coeff = 101044825, + .Ft[2][3].Phase_offset = -90039161, - .Ft[3][0].Phase_coeff = 0, - .Ft[3][0].Phase_offset = 0, - .Ft[3][1].Phase_coeff = 0, - .Ft[3][1].Phase_offset = 0, - .Ft[3][2].Phase_coeff = 0, - .Ft[3][2].Phase_offset = 0, - .Ft[3][3].Phase_coeff = 0, - .Ft[3][3].Phase_offset = 0, + .Ft[3][0].Phase_coeff = 138829, + .Ft[3][0].Phase_offset = -89665935, + .Ft[3][1].Phase_coeff = 332426, + .Ft[3][1].Phase_offset = -89905848, + .Ft[3][2].Phase_coeff = 20570385, + .Ft[3][2].Phase_offset = -90011769, + .Ft[3][3].Phase_coeff = 101674510, + .Ft[3][3].Phase_offset = -90079983, - .CutoffFreq = 271200, + .CutoffFreq = 277298000, .Lv[0][0].HSRTIA_a = 0, - .Lv[0][0].HSRTIA_b = 0, + .Lv[0][0].HSRTIA_b = 5710680, .Lv[0][0].HSRTIA_c = 0, .Lv[1][0].HSRTIA_a = 0, .Lv[1][0].HSRTIA_b = 0, @@ -359,8 +360,8 @@ struct _CaliTable{ .Lv[3][0].HSRTIA_b = 0, .Lv[3][0].HSRTIA_c = 0, - .Lv[0][1].HSRTIA_a = 0, - .Lv[0][1].HSRTIA_b = 0, + .Lv[0][1].HSRTIA_a = 2, + .Lv[0][1].HSRTIA_b = 44375440, .Lv[0][1].HSRTIA_c = 0, .Lv[1][1].HSRTIA_a = 0, .Lv[1][1].HSRTIA_b = 0, @@ -373,7 +374,7 @@ struct _CaliTable{ .Lv[3][1].HSRTIA_c = 0, .Lv[0][2].HSRTIA_a = 0, - .Lv[0][2].HSRTIA_b = 0, + .Lv[0][2].HSRTIA_b = 178245458, .Lv[0][2].HSRTIA_c = 0, .Lv[1][2].HSRTIA_a = 0, .Lv[1][2].HSRTIA_b = 0, @@ -385,8 +386,8 @@ struct _CaliTable{ .Lv[3][2].HSRTIA_b = 0, .Lv[3][2].HSRTIA_c = 0, - .Lv[0][3].HSRTIA_a = 0, - .Lv[0][3].HSRTIA_b = 0, + .Lv[0][3].HSRTIA_a = 392, + .Lv[0][3].HSRTIA_b = 4452303635, .Lv[0][3].HSRTIA_c = 0, .Lv[1][3].HSRTIA_a = 0, .Lv[1][3].HSRTIA_b = 0, @@ -398,21 +399,22 @@ struct _CaliTable{ .Lv[3][3].HSRTIA_b = 0, .Lv[3][3].HSRTIA_c = 0, - .LP[0].LPTIA_coeff_a = 0, - .LP[0].LPTIA_coeff_b = 0, - .LP[0].LPTIA_coeff_c = 0, - .LP[1].LPTIA_coeff_a = 0, - .LP[1].LPTIA_coeff_b = 0, - .LP[1].LPTIA_coeff_c = 0, + .LP[0].LPTIA_coeff_a = 3, + .LP[0].LPTIA_coeff_b = 54233788, + .LP[0].LPTIA_coeff_c = -178049203, - .LP[2].LPTIA_coeff_a = 0, - .LP[2].LPTIA_coeff_b = 0, - .LP[2].LPTIA_coeff_c = 0, + .LP[1].LPTIA_coeff_a = -14, + .LP[1].LPTIA_coeff_b = 440305463, + .LP[1].LPTIA_coeff_c = -1440791990, - .LP[3].LPTIA_coeff_a = 0, - .LP[3].LPTIA_coeff_b = 0, - .LP[3].LPTIA_coeff_c = 0, + .LP[2].LPTIA_coeff_a = 46, + .LP[2].LPTIA_coeff_b = 3489511386, + .LP[2].LPTIA_coeff_c = -11437577842, + + .LP[3].LPTIA_coeff_a = -5095, + .LP[3].LPTIA_coeff_b = 31381126836, + .LP[3].LPTIA_coeff_c = -102260080764, }; @@ -787,14 +789,14 @@ struct _CaliTable{ .OffsetZero = 22707, - .Ft[0][0].Phase_coeff = 149206, - .Ft[0][0].Phase_offset = -89686268, - .Ft[0][1].Phase_coeff = 284180, - .Ft[0][1].Phase_offset = -86491077, - .Ft[0][2].Phase_coeff = 20546468, - .Ft[0][2].Phase_offset = -89997059, - .Ft[0][3].Phase_coeff = -22784892, - .Ft[0][3].Phase_offset = -81442228, + .Ft[0][0].Phase_coeff = 149087, + .Ft[0][0].Phase_offset = -89684072, + .Ft[0][1].Phase_coeff = 342135, + .Ft[0][1].Phase_offset = -89885792, + .Ft[0][2].Phase_coeff = 20579479, + .Ft[0][2].Phase_offset = -90015253, + .Ft[0][3].Phase_coeff = 101036503, + .Ft[0][3].Phase_offset = -90035185, .Ft[1][0].Phase_coeff = 145203, .Ft[1][0].Phase_offset = -89650316, @@ -823,10 +825,10 @@ struct _CaliTable{ .Ft[3][3].Phase_coeff = 96688907, .Ft[3][3].Phase_offset = -89856240, - .CutoffFreq = 272856000, + .CutoffFreq = 272966000, .Lv[0][0].HSRTIA_a = 0, - .Lv[0][0].HSRTIA_b = 5698671, + .Lv[0][0].HSRTIA_b = 5670003, .Lv[0][0].HSRTIA_c = 0, .Lv[1][0].HSRTIA_a = 0, .Lv[1][0].HSRTIA_b = 0, @@ -1378,16 +1380,1096 @@ struct _CaliTable{ }; -#elif defined(boardEISM001) +#elif defined(BOARD_EISM001) { - .DeviceName = "BOARD_EISM001", - + .DeviceName = "BOARD_e6df", .DAC_offset_a = 111713333849, .DAC_offset_b = -3138765191344248, - .HSDAC_AMP_a = 9725854, .HSDAC_AMP_b = 0, + + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 147412, + .Ft[0][0].Phase_offset = -89692492, + .Ft[0][1].Phase_coeff = 340584, + .Ft[0][1].Phase_offset = -89890192, + .Ft[0][2].Phase_coeff = 20588051, + .Ft[0][2].Phase_offset = -90025181, + .Ft[0][3].Phase_coeff = 100685274, + .Ft[0][3].Phase_offset = -90004624, + + .Ft[1][0].Phase_coeff = 143429, + .Ft[1][0].Phase_offset = -89682170, + .Ft[1][1].Phase_coeff = 336631, + .Ft[1][1].Phase_offset = -89890234, + .Ft[1][2].Phase_coeff = 20512962, + .Ft[1][2].Phase_offset = -89971981, + .Ft[1][3].Phase_coeff = 99919183, + .Ft[1][3].Phase_offset = -89950694, + + .Ft[2][0].Phase_coeff = 137979, + .Ft[2][0].Phase_offset = -89691999, + .Ft[2][1].Phase_coeff = 331242, + .Ft[2][1].Phase_offset = -89899138, + .Ft[2][2].Phase_coeff = 20548976, + .Ft[2][2].Phase_offset = -90001859, + .Ft[2][3].Phase_coeff = 100956985, + .Ft[2][3].Phase_offset = -90032471, + + .Ft[3][0].Phase_coeff = 144321, + .Ft[3][0].Phase_offset = -94929901, + .Ft[3][1].Phase_coeff = 438793, + .Ft[3][1].Phase_offset = -108070038, + .Ft[3][2].Phase_coeff = 19286517, + .Ft[3][2].Phase_offset = -90001581, + .Ft[3][3].Phase_coeff = 97275372, + .Ft[3][3].Phase_offset = -89860947, + + .CutoffFreq = 273630000, + + .Lv[0][0].HSRTIA_a = 0, + .Lv[0][0].HSRTIA_b = 5717473, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = -1, + .Lv[0][1].HSRTIA_b = 44355875, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = 6, + .Lv[0][2].HSRTIA_b = 178119950, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = -20227, + .Lv[0][3].HSRTIA_b = 5083445608, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + + .LP[0].LPTIA_coeff_a = 11, + .LP[0].LPTIA_coeff_b = 53110408, + .LP[0].LPTIA_coeff_c = -175311181, + + .LP[1].LPTIA_coeff_a = 29, + .LP[1].LPTIA_coeff_b = 432561008, + .LP[1].LPTIA_coeff_c = -1421291177, + + .LP[2].LPTIA_coeff_a = -27, + .LP[2].LPTIA_coeff_b = 3452772393, + .LP[2].LPTIA_coeff_c = -11314081169, + + .LP[3].LPTIA_coeff_a = 2743, + .LP[3].LPTIA_coeff_b = 30536149999, + .LP[3].LPTIA_coeff_c = -100386784194, + +}; + +#elif defined(BOARD_EISM002) +{ + .DeviceName = "BOARD_e7f7", + + .DAC_offset_a = 111484346885, + .DAC_offset_b = -3126538964061724, + .HSDAC_AMP_a = 9712357, + .HSDAC_AMP_b = 0, + + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 146932, + .Ft[0][0].Phase_offset = -89684931, + .Ft[0][1].Phase_coeff = 340121, + .Ft[0][1].Phase_offset = -89896163, + .Ft[0][2].Phase_coeff = 20544331, + .Ft[0][2].Phase_offset = -89988436, + .Ft[0][3].Phase_coeff = 99999409, + .Ft[0][3].Phase_offset = -89961693, + + .Ft[1][0].Phase_coeff = 143787, + .Ft[1][0].Phase_offset = -89681902, + .Ft[1][1].Phase_coeff = 337137, + .Ft[1][1].Phase_offset = -89900326, + .Ft[1][2].Phase_coeff = 20525087, + .Ft[1][2].Phase_offset = -89980562, + .Ft[1][3].Phase_coeff = 98560232, + .Ft[1][3].Phase_offset = -89863037, + + .Ft[2][0].Phase_coeff = 137979, + .Ft[2][0].Phase_offset = -89689498, + .Ft[2][1].Phase_coeff = 331264, + .Ft[2][1].Phase_offset = -89899682, + .Ft[2][2].Phase_coeff = 20551151, + .Ft[2][2].Phase_offset = -90002830, + .Ft[2][3].Phase_coeff = 100419400, + .Ft[2][3].Phase_offset = -89994907, + + .Ft[3][0].Phase_coeff = 143886, + .Ft[3][0].Phase_offset = -94597002, + .Ft[3][1].Phase_coeff = 434284, + .Ft[3][1].Phase_offset = -107165553, + .Ft[3][2].Phase_coeff = 19302308, + .Ft[3][2].Phase_offset = -89995271, + .Ft[3][3].Phase_coeff = 98131507, + .Ft[3][3].Phase_offset = -89915479, + + .CutoffFreq = 272281000, + + .Lv[0][0].HSRTIA_a = -1, + .Lv[0][0].HSRTIA_b = 5847999, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = -3, + .Lv[0][1].HSRTIA_b = 45705520, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = 7, + .Lv[0][2].HSRTIA_b = 183403377, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = 12964, + .Lv[0][3].HSRTIA_b = 5249712855, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + + .LP[0].LPTIA_coeff_a = -16, + .LP[0].LPTIA_coeff_b = 56177550, + .LP[0].LPTIA_coeff_c = -182288756, + + .LP[1].LPTIA_coeff_a = 9, + .LP[1].LPTIA_coeff_b = 445278127, + .LP[1].LPTIA_coeff_c = -1460358950, + + .LP[2].LPTIA_coeff_a = 39, + .LP[2].LPTIA_coeff_b = 3537809304, + .LP[2].LPTIA_coeff_c = -11600497243, + + .LP[3].LPTIA_coeff_a = 3083, + .LP[3].LPTIA_coeff_b = 31318102463, + .LP[3].LPTIA_coeff_c = -102976446015, + +}; + +#elif defined(BOARD_EISM003) +{ + .DeviceName = "BOARD_e764", + + .DAC_offset_a = 111362936625, + .DAC_offset_b = -3123309265347064, + .HSDAC_AMP_a = 9712830, + .HSDAC_AMP_b = 0, + + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 146961, + .Ft[0][0].Phase_offset = -89689819, + .Ft[0][1].Phase_coeff = 340194, + .Ft[0][1].Phase_offset = -89891610, + .Ft[0][2].Phase_coeff = 20546014, + .Ft[0][2].Phase_offset = -89997647, + .Ft[0][3].Phase_coeff = 98165000, + .Ft[0][3].Phase_offset = -89830914, + + .Ft[1][0].Phase_coeff = 144218, + .Ft[1][0].Phase_offset = -89677466, + .Ft[1][1].Phase_coeff = 337933, + .Ft[1][1].Phase_offset = -89920960, + .Ft[1][2].Phase_coeff = 20515921, + .Ft[1][2].Phase_offset = -89973311, + .Ft[1][3].Phase_coeff = 101303046, + .Ft[1][3].Phase_offset = -90055781, + + .Ft[2][0].Phase_coeff = 139304, + .Ft[2][0].Phase_offset = -89687366, + .Ft[2][1].Phase_coeff = 332719, + .Ft[2][1].Phase_offset = -89906999, + .Ft[2][2].Phase_coeff = 20537343, + .Ft[2][2].Phase_offset = -89992869, + .Ft[2][3].Phase_coeff = 101122830, + .Ft[2][3].Phase_offset = -90044615, + + .Ft[3][0].Phase_coeff = 147674, + .Ft[3][0].Phase_offset = -97977044, + .Ft[3][1].Phase_coeff = 465790, + .Ft[3][1].Phase_offset = -115247503, + .Ft[3][2].Phase_coeff = 18950023, + .Ft[3][2].Phase_offset = -90001943, + .Ft[3][3].Phase_coeff = 96450516, + .Ft[3][3].Phase_offset = -89830725, + + .CutoffFreq = 272182000, + + .Lv[0][0].HSRTIA_a = -1, + .Lv[0][0].HSRTIA_b = 5863564, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = -5, + .Lv[0][1].HSRTIA_b = 45952041, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = 4, + .Lv[0][2].HSRTIA_b = 183026097, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = 6276, + .Lv[0][3].HSRTIA_b = 3395123658, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + + .LP[0].LPTIA_coeff_a = 0, + .LP[0].LPTIA_coeff_b = 55190789, + .LP[0].LPTIA_coeff_c = -180768488, + + .LP[1].LPTIA_coeff_a = -23, + .LP[1].LPTIA_coeff_b = 447266762, + .LP[1].LPTIA_coeff_c = -1463085893, + + .LP[2].LPTIA_coeff_a = -24, + .LP[2].LPTIA_coeff_b = 3543502661, + .LP[2].LPTIA_coeff_c = -11609527753, + + .LP[3].LPTIA_coeff_a = -2804, + .LP[3].LPTIA_coeff_b = 31732296422, + .LP[3].LPTIA_coeff_c = -103691262754, + +}; + +#elif defined(BOARD_EISM004) +{ + .DeviceName = "BOARD_e88c", + + .DAC_offset_a = 111399400040, + .DAC_offset_b = -3120588752087674, + .HSDAC_AMP_a = 9663478, + .HSDAC_AMP_b = 0, + + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 148882, + .Ft[0][0].Phase_offset = -89671371, + .Ft[0][1].Phase_coeff = 341931, + .Ft[0][1].Phase_offset = -89883654, + .Ft[0][2].Phase_coeff = 20604978, + .Ft[0][2].Phase_offset = -90034228, + .Ft[0][3].Phase_coeff = 99784573, + .Ft[0][3].Phase_offset = -89941448, + + .Ft[1][0].Phase_coeff = 144654, + .Ft[1][0].Phase_offset = -89631350, + .Ft[1][1].Phase_coeff = 338420, + .Ft[1][1].Phase_offset = -89906935, + .Ft[1][2].Phase_coeff = 20534093, + .Ft[1][2].Phase_offset = -89986158, + .Ft[1][3].Phase_coeff = 97742620, + .Ft[1][3].Phase_offset = -89816977, + + .Ft[2][0].Phase_coeff = 139059, + .Ft[2][0].Phase_offset = -89675564, + .Ft[2][1].Phase_coeff = 332404, + .Ft[2][1].Phase_offset = -89899413, + .Ft[2][2].Phase_coeff = 20545919, + .Ft[2][2].Phase_offset = -89999357, + .Ft[2][3].Phase_coeff = 100891173, + .Ft[2][3].Phase_offset = -90025909, + + .Ft[3][0].Phase_coeff = 139033, + .Ft[3][0].Phase_offset = -89653499, + .Ft[3][1].Phase_coeff = 332447, + .Ft[3][1].Phase_offset = -89894098, + .Ft[3][2].Phase_coeff = 20544742, + .Ft[3][2].Phase_offset = -89989310, + .Ft[3][3].Phase_coeff = 100640884, + .Ft[3][3].Phase_offset = -90008456, + + .CutoffFreq = 267934000, + + .Lv[0][0].HSRTIA_a = -1, + .Lv[0][0].HSRTIA_b = 5678210, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = -6, + .Lv[0][1].HSRTIA_b = 43966318, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = 6, + .Lv[0][2].HSRTIA_b = 175691723, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = -167, + .Lv[0][3].HSRTIA_b = 4397038103, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + + .LP[0].LPTIA_coeff_a = 4, + .LP[0].LPTIA_coeff_b = 53278364, + .LP[0].LPTIA_coeff_c = -175121708, + + .LP[1].LPTIA_coeff_a = 42, + .LP[1].LPTIA_coeff_b = 428660172, + .LP[1].LPTIA_coeff_c = -1409909846, + + .LP[2].LPTIA_coeff_a = 11, + .LP[2].LPTIA_coeff_b = 3429837502, + .LP[2].LPTIA_coeff_c = -11241926318, + + .LP[3].LPTIA_coeff_a = -2652, + .LP[3].LPTIA_coeff_b = 30636729169, + .LP[3].LPTIA_coeff_c = -100119453561, + +}; + +#elif defined(BOARD_EISM005) +{ + .DeviceName = "BOARD_e77e", + + .DAC_offset_a = 111629406294, + .DAC_offset_b = -3135380204174598, + .HSDAC_AMP_a = 9737436, + .HSDAC_AMP_b = 0, + + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 147397, + .Ft[0][0].Phase_offset = -89687189, + .Ft[0][1].Phase_coeff = 340829, + .Ft[0][1].Phase_offset = -89909006, + .Ft[0][2].Phase_coeff = 20610538, + .Ft[0][2].Phase_offset = -90034214, + .Ft[0][3].Phase_coeff = 96739578, + .Ft[0][3].Phase_offset = -89724003, + + .Ft[1][0].Phase_coeff = 143468, + .Ft[1][0].Phase_offset = -89680444, + .Ft[1][1].Phase_coeff = 336611, + .Ft[1][1].Phase_offset = -89890172, + .Ft[1][2].Phase_coeff = 20516354, + .Ft[1][2].Phase_offset = -89976517, + .Ft[1][3].Phase_coeff = 101430402, + .Ft[1][3].Phase_offset = -90069207, + + .Ft[2][0].Phase_coeff = 138542, + .Ft[2][0].Phase_offset = -89687905, + .Ft[2][1].Phase_coeff = 331838, + .Ft[2][1].Phase_offset = -89900399, + .Ft[2][2].Phase_coeff = 20548153, + .Ft[2][2].Phase_offset = -90000578, + .Ft[2][3].Phase_coeff = 100455816, + .Ft[2][3].Phase_offset = -89996852, + + .Ft[3][0].Phase_coeff = 138210, + .Ft[3][0].Phase_offset = -89668063, + .Ft[3][1].Phase_coeff = 332024, + .Ft[3][1].Phase_offset = -89913909, + .Ft[3][2].Phase_coeff = 20580182, + .Ft[3][2].Phase_offset = -90011154, + .Ft[3][3].Phase_coeff = 100932683, + .Ft[3][3].Phase_offset = -90028394, + + .CutoffFreq = 272330000, + + .Lv[0][0].HSRTIA_a = 0, + .Lv[0][0].HSRTIA_b = 5860547, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = -1, + .Lv[0][1].HSRTIA_b = 45754611, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = 12, + .Lv[0][2].HSRTIA_b = 183887029, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = -14049, + .Lv[0][3].HSRTIA_b = 4694057006, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + + .LP[0].LPTIA_coeff_a = 5, + .LP[0].LPTIA_coeff_b = 54816728, + .LP[0].LPTIA_coeff_c = -180074208, + + .LP[1].LPTIA_coeff_a = 1, + .LP[1].LPTIA_coeff_b = 446143038, + .LP[1].LPTIA_coeff_c = -1461481601, + + .LP[2].LPTIA_coeff_a = -143, + .LP[2].LPTIA_coeff_b = 3558051999, + .LP[2].LPTIA_coeff_c = -11636449033, + + .LP[3].LPTIA_coeff_a = 11612, + .LP[3].LPTIA_coeff_b = 30808709507, + .LP[3].LPTIA_coeff_c = -102188905110, + +}; + +#elif defined(BOARD_EISM006) +{ + .DeviceName = "BOARD_e7fb", + + .DAC_offset_a = 111756504956, + .DAC_offset_b = -3143394213290862, + .HSDAC_AMP_a = 9737952, + .HSDAC_AMP_b = 0, + + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 148123, + .Ft[0][0].Phase_offset = -89677179, + .Ft[0][1].Phase_coeff = 341515, + .Ft[0][1].Phase_offset = -89902472, + .Ft[0][2].Phase_coeff = 20536886, + .Ft[0][2].Phase_offset = -89992358, + .Ft[0][3].Phase_coeff = 100141669, + .Ft[0][3].Phase_offset = -89967808, + + .Ft[1][0].Phase_coeff = 144360, + .Ft[1][0].Phase_offset = -89672469, + .Ft[1][1].Phase_coeff = 337641, + .Ft[1][1].Phase_offset = -89893112, + .Ft[1][2].Phase_coeff = 20523054, + .Ft[1][2].Phase_offset = -89980219, + .Ft[1][3].Phase_coeff = 101349617, + .Ft[1][3].Phase_offset = -90062667, + + .Ft[2][0].Phase_coeff = 138833, + .Ft[2][0].Phase_offset = -89683271, + .Ft[2][1].Phase_coeff = 332126, + .Ft[2][1].Phase_offset = -89899155, + .Ft[2][2].Phase_coeff = 20544592, + .Ft[2][2].Phase_offset = -89997735, + .Ft[2][3].Phase_coeff = 100585269, + .Ft[2][3].Phase_offset = -90006598, + + .Ft[3][0].Phase_coeff = 139297, + .Ft[3][0].Phase_offset = -89657957, + .Ft[3][1].Phase_coeff = 332830, + .Ft[3][1].Phase_offset = -89902220, + .Ft[3][2].Phase_coeff = 20542771, + .Ft[3][2].Phase_offset = -89991626, + .Ft[3][3].Phase_coeff = 100544842, + .Ft[3][3].Phase_offset = -89991958, + + .CutoffFreq = 270550000, + + .Lv[0][0].HSRTIA_a = 0, + .Lv[0][0].HSRTIA_b = 5636905, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = 2, + .Lv[0][1].HSRTIA_b = 43929422, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = 6, + .Lv[0][2].HSRTIA_b = 176695522, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = 60, + .Lv[0][3].HSRTIA_b = 4392060112, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + + .LP[0].LPTIA_coeff_a = 9, + .LP[0].LPTIA_coeff_b = 52666729, + .LP[0].LPTIA_coeff_c = -173570465, + + .LP[1].LPTIA_coeff_a = -2, + .LP[1].LPTIA_coeff_b = 429381361, + .LP[1].LPTIA_coeff_c = -1406588851, + + .LP[2].LPTIA_coeff_a = 26, + .LP[2].LPTIA_coeff_b = 3412528534, + .LP[2].LPTIA_coeff_c = -11181737048, + + .LP[3].LPTIA_coeff_a = -1135, + .LP[3].LPTIA_coeff_b = 30478651790, + .LP[3].LPTIA_coeff_c = -99714920052, + +}; + +#elif defined(BOARD_EISM007) +{ + .DeviceName = "BOARD_e74d", + + .DAC_offset_a = 111482490539, + .DAC_offset_b = -3128358265947820, + .HSDAC_AMP_a = 9734652, + .HSDAC_AMP_b = 0, + + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 147696, + .Ft[0][0].Phase_offset = -89684021, + .Ft[0][1].Phase_coeff = 341191, + .Ft[0][1].Phase_offset = -89909340, + .Ft[0][2].Phase_coeff = 20567265, + .Ft[0][2].Phase_offset = -90006589, + .Ft[0][3].Phase_coeff = 99121904, + .Ft[0][3].Phase_offset = -89899165, + + .Ft[1][0].Phase_coeff = 143350, + .Ft[1][0].Phase_offset = -89671889, + .Ft[1][1].Phase_coeff = 336471, + .Ft[1][1].Phase_offset = -89881858, + .Ft[1][2].Phase_coeff = 20543534, + .Ft[1][2].Phase_offset = -89994035, + .Ft[1][3].Phase_coeff = 98701075, + .Ft[1][3].Phase_offset = -89874445, + + .Ft[2][0].Phase_coeff = 139086, + .Ft[2][0].Phase_offset = -89683362, + .Ft[2][1].Phase_coeff = 332368, + .Ft[2][1].Phase_offset = -89898241, + .Ft[2][2].Phase_coeff = 20544361, + .Ft[2][2].Phase_offset = -89997410, + .Ft[2][3].Phase_coeff = 99745227, + .Ft[2][3].Phase_offset = -89947421, + + .Ft[3][0].Phase_coeff = 138942, + .Ft[3][0].Phase_offset = -89663450, + .Ft[3][1].Phase_coeff = 332588, + .Ft[3][1].Phase_offset = -89909222, + .Ft[3][2].Phase_coeff = 20544878, + .Ft[3][2].Phase_offset = -89993708, + .Ft[3][3].Phase_coeff = 98903026, + .Ft[3][3].Phase_offset = -89885553, + + .CutoffFreq = 271441000, + + .Lv[0][0].HSRTIA_a = -1, + .Lv[0][0].HSRTIA_b = 5862728, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = -2, + .Lv[0][1].HSRTIA_b = 45907805, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = 4, + .Lv[0][2].HSRTIA_b = 183582836, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = -567, + .Lv[0][3].HSRTIA_b = 4558577009, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + + .LP[0].LPTIA_coeff_a = -6, + .LP[0].LPTIA_coeff_b = 55541011, + .LP[0].LPTIA_coeff_c = -181395273, + + .LP[1].LPTIA_coeff_a = -4, + .LP[1].LPTIA_coeff_b = 444907192, + .LP[1].LPTIA_coeff_c = -1457381715, + + .LP[2].LPTIA_coeff_a = -12, + .LP[2].LPTIA_coeff_b = 3536216752, + .LP[2].LPTIA_coeff_c = -11585577256, + + .LP[3].LPTIA_coeff_a = 60, + .LP[3].LPTIA_coeff_b = 31479470344, + .LP[3].LPTIA_coeff_c = -103147376132, + +}; + +#elif defined(BOARD_EISM008) +{ + .DeviceName = "BOARD_e7eb", + + .DAC_offset_a = 111845364898, + .DAC_offset_b = -3145956528724723, + .HSDAC_AMP_a = 9743398, + .HSDAC_AMP_b = 0, + + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 147765, + .Ft[0][0].Phase_offset = -89682646, + .Ft[0][1].Phase_coeff = 341027, + .Ft[0][1].Phase_offset = -89897001, + .Ft[0][2].Phase_coeff = 20539165, + .Ft[0][2].Phase_offset = -89976920, + .Ft[0][3].Phase_coeff = 97330923, + .Ft[0][3].Phase_offset = -89779868, + + .Ft[1][0].Phase_coeff = 143768, + .Ft[1][0].Phase_offset = -89671087, + .Ft[1][1].Phase_coeff = 336856, + .Ft[1][1].Phase_offset = -89882011, + .Ft[1][2].Phase_coeff = 20552503, + .Ft[1][2].Phase_offset = -89998798, + .Ft[1][3].Phase_coeff = 99652687, + .Ft[1][3].Phase_offset = -89942230, + + .Ft[2][0].Phase_coeff = 139777, + .Ft[2][0].Phase_offset = -89680933, + .Ft[2][1].Phase_coeff = 333115, + .Ft[2][1].Phase_offset = -89901109, + .Ft[2][2].Phase_coeff = 20547130, + .Ft[2][2].Phase_offset = -90000112, + .Ft[2][3].Phase_coeff = 100360718, + .Ft[2][3].Phase_offset = -89991261, + + .Ft[3][0].Phase_coeff = 139129, + .Ft[3][0].Phase_offset = -89659427, + .Ft[3][1].Phase_coeff = 332449, + .Ft[3][1].Phase_offset = -89886429, + .Ft[3][2].Phase_coeff = 20519813, + .Ft[3][2].Phase_offset = -89974923, + .Ft[3][3].Phase_coeff = 97882801, + .Ft[3][3].Phase_offset = -89811326, + + .CutoffFreq = 270521000, + + .Lv[0][0].HSRTIA_a = 0, + .Lv[0][0].HSRTIA_b = 5692493, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = 1, + .Lv[0][1].HSRTIA_b = 44077790, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = -1, + .Lv[0][2].HSRTIA_b = 176975226, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = 352, + .Lv[0][3].HSRTIA_b = 4432378475, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + + .LP[0].LPTIA_coeff_a = -15, + .LP[0].LPTIA_coeff_b = 54907239, + .LP[0].LPTIA_coeff_c = -178362814, + + .LP[1].LPTIA_coeff_a = -12, + .LP[1].LPTIA_coeff_b = 435902989, + .LP[1].LPTIA_coeff_c = -1427238086, + + .LP[2].LPTIA_coeff_a = 59, + .LP[2].LPTIA_coeff_b = 3450994892, + .LP[2].LPTIA_coeff_c = -11317795380, + + .LP[3].LPTIA_coeff_a = 2282, + .LP[3].LPTIA_coeff_b = 30595231381, + .LP[3].LPTIA_coeff_c = -100526303505, + +}; + +#elif defined(boardEISM009) +{ + .DeviceName = "BOARD_EISM009", + + + .DAC_offset_a = 111698223764, + .DAC_offset_b = -3142172129542342, + + .HSDAC_AMP_a = 9755045, + .HSDAC_AMP_b = 0, + .OffsetZero = 22707, + + .Ft[0][0].Phase_coeff = 0, + .Ft[0][0].Phase_offset = 0, + .Ft[0][1].Phase_coeff = 0, + .Ft[0][1].Phase_offset = 0, + .Ft[0][2].Phase_coeff = 0, + .Ft[0][2].Phase_offset = 0, + .Ft[0][3].Phase_coeff = 0, + .Ft[0][3].Phase_offset = 0, + + .Ft[1][0].Phase_coeff = 0, + .Ft[1][0].Phase_offset = 0, + .Ft[1][1].Phase_coeff = 0, + .Ft[1][1].Phase_offset = 0, + .Ft[1][2].Phase_coeff = 0, + .Ft[1][2].Phase_offset = 0, + .Ft[1][3].Phase_coeff = 0, + .Ft[1][3].Phase_offset = 0, + + .Ft[2][0].Phase_coeff = 0, + .Ft[2][0].Phase_offset = 0, + .Ft[2][1].Phase_coeff = 0, + .Ft[2][1].Phase_offset = 0, + .Ft[2][2].Phase_coeff = 0, + .Ft[2][2].Phase_offset = 0, + .Ft[2][3].Phase_coeff = 0, + .Ft[2][3].Phase_offset = 0, + + .Ft[3][0].Phase_coeff = 0, + .Ft[3][0].Phase_offset = 0, + .Ft[3][1].Phase_coeff = 0, + .Ft[3][1].Phase_offset = 0, + .Ft[3][2].Phase_coeff = 0, + .Ft[3][2].Phase_offset = 0, + .Ft[3][3].Phase_coeff = 0, + .Ft[3][3].Phase_offset = 0, + + .CutoffFreq = 271200, + + .Lv[0][0].HSRTIA_a = 0, + .Lv[0][0].HSRTIA_b = 0, + .Lv[0][0].HSRTIA_c = 0, + .Lv[1][0].HSRTIA_a = 0, + .Lv[1][0].HSRTIA_b = 0, + .Lv[1][0].HSRTIA_c = 0, + .Lv[2][0].HSRTIA_a = 0, + .Lv[2][0].HSRTIA_b = 0, + .Lv[2][0].HSRTIA_c = 0, + .Lv[3][0].HSRTIA_a = 0, + .Lv[3][0].HSRTIA_b = 0, + .Lv[3][0].HSRTIA_c = 0, + + .Lv[0][1].HSRTIA_a = 0, + .Lv[0][1].HSRTIA_b = 0, + .Lv[0][1].HSRTIA_c = 0, + .Lv[1][1].HSRTIA_a = 0, + .Lv[1][1].HSRTIA_b = 0, + .Lv[1][1].HSRTIA_c = 0, + .Lv[2][1].HSRTIA_a = 0, + .Lv[2][1].HSRTIA_b = 0, + .Lv[2][1].HSRTIA_c = 0, + .Lv[3][1].HSRTIA_a = 0, + .Lv[3][1].HSRTIA_b = 0, + .Lv[3][1].HSRTIA_c = 0, + + .Lv[0][2].HSRTIA_a = 0, + .Lv[0][2].HSRTIA_b = 0, + .Lv[0][2].HSRTIA_c = 0, + .Lv[1][2].HSRTIA_a = 0, + .Lv[1][2].HSRTIA_b = 0, + .Lv[1][2].HSRTIA_c = 0, + .Lv[2][2].HSRTIA_a = 0, + .Lv[2][2].HSRTIA_b = 0, + .Lv[2][2].HSRTIA_c = 0, + .Lv[3][2].HSRTIA_a = 0, + .Lv[3][2].HSRTIA_b = 0, + .Lv[3][2].HSRTIA_c = 0, + + .Lv[0][3].HSRTIA_a = 0, + .Lv[0][3].HSRTIA_b = 0, + .Lv[0][3].HSRTIA_c = 0, + .Lv[1][3].HSRTIA_a = 0, + .Lv[1][3].HSRTIA_b = 0, + .Lv[1][3].HSRTIA_c = 0, + .Lv[2][3].HSRTIA_a = 0, + .Lv[2][3].HSRTIA_b = 0, + .Lv[2][3].HSRTIA_c = 0, + .Lv[3][3].HSRTIA_a = 0, + .Lv[3][3].HSRTIA_b = 0, + .Lv[3][3].HSRTIA_c = 0, + + .LP[0].LPTIA_coeff_a = 0, + .LP[0].LPTIA_coeff_b = 0, + .LP[0].LPTIA_coeff_c = 0, + + .LP[1].LPTIA_coeff_a = 0, + .LP[1].LPTIA_coeff_b = 0, + .LP[1].LPTIA_coeff_c = 0, + + .LP[2].LPTIA_coeff_a = 0, + .LP[2].LPTIA_coeff_b = 0, + .LP[2].LPTIA_coeff_c = 0, + + .LP[3].LPTIA_coeff_a = 0, + .LP[3].LPTIA_coeff_b = 0, + .LP[3].LPTIA_coeff_c = 0, + +}; + +#elif defined(boardEISM010) +{ + .DeviceName = "BOARD_EISM010", + + + .DAC_offset_a = 111771164547, + .DAC_offset_b = -3143934463179714, + + .HSDAC_AMP_a = 9765208, + .HSDAC_AMP_b = 0, .OffsetZero = 22707, .Ft[0][0].Phase_coeff = 0, From c6aca9c17b475870cdc21069fe8953c1d6aa8677 Mon Sep 17 00:00:00 2001 From: ROY Date: Thu, 27 Oct 2022 11:13:20 +0800 Subject: [PATCH 3/6] [update] update cali_table define --- .../simple_peripheral/cc26xx/app/headstage/Elite_version.h | 2 +- .../simple_peripheral/cc26xx/app/headstage/eis_cali_table.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h index 93fc7f2..b8ffa33 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h @@ -6,7 +6,7 @@ #define VERSION_DATE_MONTH 10 #define VERSION_DATE_DAY 27 #define VERSION_DATE_HOUR 11 -#define VERSION_DATE_MINUTE 11 +#define VERSION_DATE_MINUTE 13 // this is NOT the version hash !! // it's the last version hash diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h index 3738d69..3064f51 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h @@ -1,7 +1,7 @@ #ifndef EIS_CALI_TABLE #define EIS_CALI_TABLE -#define BOARD_EISM008 +#define BOARD_CALI_BOARD typedef struct _SingleFilterCali{ int32_t Phase_coeff; From 32a7580115149924779830cc2b08e0655f5d7334 Mon Sep 17 00:00:00 2001 From: ROY Date: Thu, 27 Oct 2022 16:13:58 +0800 Subject: [PATCH 4/6] [update] update RT mode --- .../simple_peripheral/cc26xx/app/headstage/headstage.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h index e1b6490..afdb30d 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h @@ -284,15 +284,15 @@ static void update_ZM_instruction(uint8 *ins) { break; } - case CURVE_RT: { //350605 + case CURVE_RT: { //350604 instru.eliteFxn = CURVE_RT; - instru.notifyRate = (uint32_t)ins[5] << 8 | (uint32_t)ins[6]; + instru.notifyRate = (uint32_t)ins[7] << 8 | (uint32_t)ins[8]; instru.notifyRate = 10000 / instru.notifyRate * 10; // instru.notifyRate = 100; // instru.measure_vin_range = ins[7]; // instru.measure_vin_range = 0; setEIS_CV(); - instru.Vinit = 37500; + instru.Vinit = (uint32_t)ins[3] << 8 | (uint32_t)ins[4];; ModeLED(WORKING); break; From 166b4667768cb1e8616f59f476e0085074834de8 Mon Sep 17 00:00:00 2001 From: ROY Date: Thu, 27 Oct 2022 17:08:40 +0800 Subject: [PATCH 5/6] [update] short instruction for RT mode --- .../cc26xx/app/headstage/Elite_mode_ADC_DAC.h | 2 +- .../cc26xx/app/headstage/Elite_version.h | 4 ++-- .../cc26xx/app/headstage/headstage.h | 11 ++++++++++- .../simple_peripheral/cc26xx/app/headstage/mode_ca.h | 12 ++++++++++++ 4 files changed, 25 insertions(+), 4 deletions(-) diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_mode_ADC_DAC.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_mode_ADC_DAC.h index 6775196..0c92d92 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_mode_ADC_DAC.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_mode_ADC_DAC.h @@ -204,7 +204,7 @@ static void VT_Plot(void) static void RT_Plot(void) { - struct wm_cv_ctx_t *rt = (struct wm_cv_ctx_t *)wm_get(); + struct wm_rt_ctx_t *rt = (struct wm_rt_ctx_t *)wm_get(); static uint8_t ADC_cnt = 0; void *wm = wm_get(); diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h index b8ffa33..b90415e 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h @@ -5,8 +5,8 @@ #define VERSION_DATE_YEAR 22 #define VERSION_DATE_MONTH 10 #define VERSION_DATE_DAY 27 -#define VERSION_DATE_HOUR 11 -#define VERSION_DATE_MINUTE 13 +#define VERSION_DATE_HOUR 17 +#define VERSION_DATE_MINUTE 8 // this is NOT the version hash !! // it's the last version hash diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h index afdb30d..9d88033 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h @@ -292,12 +292,21 @@ static void update_ZM_instruction(uint8 *ins) { // instru.measure_vin_range = ins[7]; // instru.measure_vin_range = 0; setEIS_CV(); - instru.Vinit = (uint32_t)ins[3] << 8 | (uint32_t)ins[4];; + instru.Vinit = (uint32_t)ins[3] << 8 | (uint32_t)ins[4]; ModeLED(WORKING); break; } + case 0xE2:{ //SET_PARA: { 0xE2 + int32_t volt; + + volt = (int32_t)ins[4] << 8 | (int32_t)ins[5]; + + set_rt_volt(volt); + break; + } + case SET_SAMPLE_RATE: { instru.notifyRate = (uint32_t)ins[3] << 8 | (uint32_t)ins[4]; instru.notifyRate = 10000 / instru.notifyRate * 10; diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/mode_ca.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/mode_ca.h index b806d64..17b0c0e 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/mode_ca.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/mode_ca.h @@ -33,4 +33,16 @@ static void rt_vscan(void) return; } +static void set_rt_volt(int32_t volt) +{ + struct wm_rt_ctx_t *rt = (struct wm_rt_ctx_t *)wm_get(); + + volt = (volt - 25000) * 4 * 4000; + + rt->_Vinit = volt; + + return; +} + + #endif From d9a7152d73fe924381a16948ccb7263294630056 Mon Sep 17 00:00:00 2001 From: ROY Date: Mon, 31 Oct 2022 17:20:04 +0800 Subject: [PATCH 6/6] [update] update headstage file --- .../cc26xx/app/headstage/eis_cali_table.h | 2 +- .../cc26xx/app/headstage/headstage.h | 295 ++++++++++-------- 2 files changed, 167 insertions(+), 130 deletions(-) diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h index 3064f51..b7c3fc2 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/eis_cali_table.h @@ -1,7 +1,7 @@ #ifndef EIS_CALI_TABLE #define EIS_CALI_TABLE -#define BOARD_CALI_BOARD +#define BOARD_EIS001 typedef struct _SingleFilterCali{ int32_t Phase_coeff; diff --git a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h index 9d88033..ce9f313 100644 --- a/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h +++ b/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/headstage.h @@ -173,130 +173,151 @@ static void step2VsetRate(uint32_t step){ } } -// update instruction for Z meter -static void update_ZM_instruction(uint8 *ins) { - uint8_t ins_type = ins[0] & 0b11110000; - uint8_t chip_ID = ins[0] & 0b00001111; - uint8_t oper = ins[1] & 0xF0; // this is don't care in RISASD;// - instru.chip_id = chip_ID; - - switch (ins_type) { - - case INS_TYPE_RIS: { - switch (ins[2]) { - case CURVE_EIS: { //0xD1 - if (ins[3] == PARA_1) { //3000D1 01 - instru.f1 = (uint32_t)ins[4] << 24 | (uint32_t)ins[5] << 16 | (uint32_t)ins[6] << 8 | (uint32_t)ins[7]; //FREQ_START - instru.f2 = (uint32_t)ins[8] << 24 | (uint32_t)ins[9] << 16 | (uint32_t)ins[10] << 8 | (uint32_t)ins[11]; //FREQ_STOP - //instru.sampleRate = 15;//CalcDelayTime(User2Freq(instru.f1), true); //ms //read - instru.fmax = (uint32_t)VMAX(instru.f1, instru.f2); - instru.fmin = (uint32_t)VMIN(instru.f1, instru.f2); - instru.delay = (uint16_t)ins[12] << 8 | (uint16_t)ins[13]; //DELAY/10 how many periods - if (instru.f1 > instru.f2){ - instru.directionInit = 0; //0:reverse 1:forward - } else if (instru.f1 <= instru.f2){ - instru.directionInit = 1; - } - } else if (ins[3] == PARA_2) { //3000D1 02 - instru.eliteFxn = CURVE_EIS; - instru.dcbias = (uint16_t)ins[4] << 8 | (uint16_t)ins[5]; - instru.acamp = (uint16_t)ins[6] << 8 | (uint16_t)ins[7]; - instru.avgnum = (uint8_t)ins[8]; - instru.rtia = (uint8_t)ins[9]; - instru.ppd = (uint16_t)ins[10] << 8 | (uint16_t)ins[11]; - instru.scale = (uint8_t)ins[12]; - - instru.gain_lv_hstia = instru.rtia; - - setEIS_EIS(); - - ModeLED(WORKING); - } - break; +static void decode_eis_mode(uint8 *ins) +{ + if (ins[3] == PARA_1) { //3000D1 01 + instru.f1 = (uint32_t)ins[4] << 24 | (uint32_t)ins[5] << 16 | (uint32_t)ins[6] << 8 | (uint32_t)ins[7]; //FREQ_START + instru.f2 = (uint32_t)ins[8] << 24 | (uint32_t)ins[9] << 16 | (uint32_t)ins[10] << 8 | (uint32_t)ins[11]; //FREQ_STOP + //instru.sampleRate = 15;//CalcDelayTime(User2Freq(instru.f1), true); //ms //read + instru.fmax = (uint32_t)VMAX(instru.f1, instru.f2); + instru.fmin = (uint32_t)VMIN(instru.f1, instru.f2); + instru.delay = (uint16_t)ins[12] << 8 | (uint16_t)ins[13]; //DELAY/10 how many periods + if (instru.f1 > instru.f2){ + instru.directionInit = 0; //0:reverse 1:forward + } else if (instru.f1 <= instru.f2){ + instru.directionInit = 1; } + } else if (ins[3] == PARA_2) { //3000D1 02 + instru.eliteFxn = CURVE_EIS; + instru.dcbias = (uint16_t)ins[4] << 8 | (uint16_t)ins[5]; + instru.acamp = (uint16_t)ins[6] << 8 | (uint16_t)ins[7]; + instru.avgnum = (uint8_t)ins[8]; + instru.rtia = (uint8_t)ins[9]; + instru.ppd = (uint16_t)ins[10] << 8 | (uint16_t)ins[11]; + instru.scale = (uint8_t)ins[12]; - case CURVE_EIS_CV: { - if (ins[3] == PARA_1) { - instru.Vinit = (int32_t)ins[4] << 8 | (int32_t)ins[5]; - instru.Ve1 = (uint16_t)ins[6] << 8 | (uint16_t)ins[7]; - instru.Ve2 = (uint16_t)ins[8] << 8 | (uint16_t)ins[9]; - instru.Vmax = (int32_t)VMAX(instru.Ve1,instru.Ve2); - instru.Vmin = (int32_t)VMIN(instru.Ve1,instru.Ve2); - if (instru.Vinit > instru.Ve1 || instru.Vinit == instru.Vmax){ - instru.directionInit = 0;//0:reverse 1:forward - } else if (instru.Vinit <= instru.Ve1 || instru.Vinit == instru.Vmin){ - instru.directionInit = 1; - } - } else if (ins[3] == PARA_2) { - instru.eliteFxn = CURVE_EIS_CV; - instru.notifyRate = (uint32_t)ins[8] << 8 | (uint32_t)ins[9]; - instru.notifyRate = 10000 / instru.notifyRate * 10; - //controller UI 0.01~1000mv send to Elite 1~100000 - instru.step = (uint32_t)ins[4] << 24 | (uint32_t)ins[5] << 16 | (uint32_t)ins[6] << 8 | (uint32_t)ins[7]; - STEP_TO_VSETRATE(instru.step); //step2VsetRate - instru.VsetRate = VsetRateTable[instru.VsetRateIndex];//N - instru.cycleNumber = (uint16_t)ins[10] << 8 | (uint16_t)ins[11]; + instru.gain_lv_hstia = instru.rtia; - setEIS_CV(); - ModeLED(WORKING); - } + setEIS_EIS(); - break; + ModeLED(WORKING); + } + + return; +} + +static void decode_cv_mode(uint8 *ins) +{ + if (ins[3] == PARA_1) { + instru.Vinit = (int32_t)ins[4] << 8 | (int32_t)ins[5]; + instru.Ve1 = (uint16_t)ins[6] << 8 | (uint16_t)ins[7]; + instru.Ve2 = (uint16_t)ins[8] << 8 | (uint16_t)ins[9]; + instru.Vmax = (int32_t)VMAX(instru.Ve1,instru.Ve2); + instru.Vmin = (int32_t)VMIN(instru.Ve1,instru.Ve2); + if (instru.Vinit > instru.Ve1 || instru.Vinit == instru.Vmax){ + instru.directionInit = 0;//0:reverse 1:forward + } else if (instru.Vinit <= instru.Ve1 || instru.Vinit == instru.Vmin){ + instru.directionInit = 1; } + } else if (ins[3] == PARA_2) { + instru.eliteFxn = CURVE_EIS_CV; + instru.notifyRate = (uint32_t)ins[8] << 8 | (uint32_t)ins[9]; + instru.notifyRate = 10000 / instru.notifyRate * 10; + //controller UI 0.01~1000mv send to Elite 1~100000 + instru.step = (uint32_t)ins[4] << 24 | (uint32_t)ins[5] << 16 | (uint32_t)ins[6] << 8 | (uint32_t)ins[7]; + STEP_TO_VSETRATE(instru.step); //step2VsetRate + instru.VsetRate = VsetRateTable[instru.VsetRateIndex];//N + instru.cycleNumber = (uint16_t)ins[10] << 8 | (uint16_t)ins[11]; - case CURVE_CA: { //3707D3 927C432103E8 //"4XD3927C43;3X2103E8" 3407D3 927C 4321 03E8 - instru.eliteFxn = CURVE_CA; - instru.Vinit = (int32_t)ins[3] << 8 | (int32_t)ins[4]; //37500 - instru.notifyRate = (uint32_t)ins[7] << 8 | (uint32_t)ins[8]; //1000 - instru.notifyRate = 10000 / instru.notifyRate * 10; //100 - instru.VsetRate = VsetRateTable[0]; //2 - //instru.hign_z_en = ins[6] & 0x0F; + setEIS_CV(); + ModeLED(WORKING); + } - //instru.VoutGainLv = VOUT_GAIN_240K; + return; +} - setEIS_CV(); - ModeLED(WORKING); +static void decode_ca_mode(uint8 *ins) +{ + instru.eliteFxn = CURVE_CA; + instru.Vinit = (int32_t)ins[3] << 8 | (int32_t)ins[4]; //37500 + instru.notifyRate = (uint32_t)ins[7] << 8 | (uint32_t)ins[8]; //1000 + instru.notifyRate = 10000 / instru.notifyRate * 10; //100 + instru.VsetRate = VsetRateTable[0]; //2 + //instru.hign_z_en = ins[6] & 0x0F; + + //instru.VoutGainLv = VOUT_GAIN_240K; + + setEIS_CV(); + ModeLED(WORKING); + + return; +} + +static void decode_vt_mode(uint8 *ins) +{ + instru.eliteFxn = CURVE_VT; + instru.notifyRate = (uint32_t)ins[5] << 8 | (uint32_t)ins[6]; + instru.notifyRate = 10000 / instru.notifyRate * 10; + instru.measure_vin_range = ins[7]; + setEIS_CV(); + AD5940_SPIWriteReg(ADCCON, 0x0001080E); //PGA = 1.5 //VT + uint8_t z; + uint16_t b; + if (instru.measure_vin_range == 0) { //measure +volt + z = 0; + b = 0; + } else if (instru.measure_vin_range == 1) { //measure +-1V + z = 32; + b = 2048; + } else if (instru.measure_vin_range == 2) { //measure -volt + z = 62; + b = 3910; + } + set_lpdac_ce_1100mv(z, b); + disconnect_rtia(); + ModeLED(WORKING); + + return; +} + +static void decode_rt_mode(uint8 *ins) +{ + instru.eliteFxn = CURVE_RT; + instru.notifyRate = (uint32_t)ins[7] << 8 | (uint32_t)ins[8]; + instru.notifyRate = 10000 / instru.notifyRate * 10; + // instru.notifyRate = 100; + // instru.measure_vin_range = ins[7]; + // instru.measure_vin_range = 0; + setEIS_CV(); + instru.Vinit = (uint32_t)ins[3] << 8 | (uint32_t)ins[4]; + + ModeLED(WORKING); + + return; +} + +static void decode_ris_ins(uint8 *ins) +{ + switch (ins[2]) { + case CURVE_EIS: + decode_eis_mode(ins); break; - } - case CURVE_VT: { //350605430103E800 - instru.eliteFxn = CURVE_VT; - instru.notifyRate = (uint32_t)ins[5] << 8 | (uint32_t)ins[6]; - instru.notifyRate = 10000 / instru.notifyRate * 10; - instru.measure_vin_range = ins[7]; - setEIS_CV(); - AD5940_SPIWriteReg(ADCCON, 0x0001080E); //PGA = 1.5 //VT - uint8_t z; - uint16_t b; - if (instru.measure_vin_range == 0) { //measure +volt - z = 0; - b = 0; - } else if (instru.measure_vin_range == 1) { //measure +-1V - z = 32; - b = 2048; - } else if (instru.measure_vin_range == 2) { //measure -volt - z = 62; - b = 3910; - } - set_lpdac_ce_1100mv(z, b); - disconnect_rtia(); - ModeLED(WORKING); + case CURVE_EIS_CV: + decode_cv_mode(ins); break; - } - case CURVE_RT: { //350604 - instru.eliteFxn = CURVE_RT; - instru.notifyRate = (uint32_t)ins[7] << 8 | (uint32_t)ins[8]; - instru.notifyRate = 10000 / instru.notifyRate * 10; - // instru.notifyRate = 100; - // instru.measure_vin_range = ins[7]; - // instru.measure_vin_range = 0; - setEIS_CV(); - instru.Vinit = (uint32_t)ins[3] << 8 | (uint32_t)ins[4]; - - ModeLED(WORKING); + case CURVE_CA: + decode_ca_mode(ins); + break; + + case CURVE_VT: + decode_vt_mode(ins); + break; + + case CURVE_RT: + decode_rt_mode(ins); break; - } case 0xE2:{ //SET_PARA: { 0xE2 int32_t volt; @@ -443,9 +464,9 @@ static void update_ZM_instruction(uint8 *ins) { case 0x03: { // ble write: 0x3000FF 03 if (ins[4] == 1) { - led_color_set(LED_NB_MAX, LED_BR_LV1, LED_CLR_RED); //0301 + led_color_set(LED_NB_MAX, LED_BR_LV1, LED_CLR_RED); } else if (ins[4] == 2){ - led_color_set(LED_NB_MAX, LED_BR_LV1, LED_CLR_ORANGE); //0302 + led_color_set(LED_NB_MAX, LED_BR_LV1, LED_CLR_ORANGE); } else if (ins[4] == 3){ led_color_set(LED_NB_MAX, LED_BR_LV1, LED_CLR_YELLOW); } else if (ins[4] == 4){ @@ -545,15 +566,14 @@ static void update_ZM_instruction(uint8 *ins) { break; } - default: { - /** **/ + default: break; - } - } - break; } +} - case INS_TYPE_VIS: { +static void decode_vis_ins(uint8 *ins) +{ + uint8_t oper = ins[1] & 0xF0; // this is don't care in RISASD;// switch (oper) { // reset all variables ( Ins = 0xC0F0) case VIS_RST: { @@ -608,10 +628,14 @@ static void update_ZM_instruction(uint8 *ins) { break; } } - break; - } - case INS_TYPE_CIS: { + return; +} + + +static void decode_cis_ins(uint8 *ins) +{ + uint8_t oper = ins[1] & 0xF0; switch (oper) { case CIS_VERSION: { initCISBuf(); @@ -667,15 +691,28 @@ static void update_ZM_instruction(uint8 *ins) { break; } } - break; - } - - default: { - // unknown instruction - break; - } +} + +// update instruction for Z meter +static void update_ZM_instruction(uint8 *ins) { + uint8_t ins_type = ins[0] & 0b11110000; + instru.chip_id = ins[0] & 0b00001111; + + switch (ins_type) { + case INS_TYPE_RIS: + decode_ris_ins(ins); + break; + + case INS_TYPE_VIS: + decode_vis_ins(ins); + break; + + case INS_TYPE_CIS: + decode_cis_ins(ins); + break; } + return; } static void ZM_instruction_update_handle(uint8_t characteristic) {