Maxim Integrated / Mbed OS MAX11410BOB_Serial_Tester

Dependencies:   MaximTinyTester MAX11410 CmdLine USBDevice

Revision:
64:5e9555fda955
Parent:
63:708490d6a29f
Child:
68:f98c73c824e1
--- a/Test_Menu_MAX11410.cpp	Mon Apr 13 03:02:14 2020 +0000
+++ b/Test_Menu_MAX11410.cpp	Mon Apr 13 11:16:21 2020 +0000
@@ -106,7 +106,7 @@
 // CODE GENERATOR:           CommandDocTest '@test group POR RegRead(MAX11410::CMD_r000_1011_dddd_dddd_MUX_CTRL0, buffer) expect 1 expect-buffer 0x0000ff'
 // CODE GENERATOR:           CommandDocTest '@test group POR RegRead(MAX11410::CMD_r000_1100_dddd_dddd_MUX_CTRL1, buffer) expect 1 expect-buffer 0x0000ff'
 // CODE GENERATOR:           CommandDocTest '@test group POR RegRead(MAX11410::CMD_r000_1101_dddd_dddd_MUX_CTRL2, buffer) expect 1 expect-buffer 0x00'
-// CODE GENERATOR:           CommandDocTest '@test group POR RegRead(MAX11410::CMD_r000_1110_xxdd_xddd_PGA, buffer) expect 1 expect-buffer 0x00'
+// CODE GENERATOR:           CommandDocTest '@test group POR RegRead(MAX11410::CMD_r000_1110_00ss_0ggg_PGA, buffer) expect 1 expect-buffer 0x00'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGND // measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v (disabled by default)'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE // measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v in more detail'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE tinyTester.print("measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v")'
@@ -115,19 +115,16 @@
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE RegWrite(0x0A, 0x03) expect 1 // *source=0x03 idac_mode=100uA, 1k resistor 0.1V'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=100uA, 1k resistor 0.1V")'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE tinyTester.Wait_Output_Settling()'
-// CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE Measure_Voltage(0,10) expect 0.1'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)337731 within 33773 // idac_mode=100uA, 1k resistor 0.1V'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE RegWrite(0x0A, 0x0D) expect 1 // *source=0x0d idac_mode=800uA, 1k resistor 0.8V'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=800uA, 1k resistor 0.8V")'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE tinyTester.Wait_Output_Settling()'
-// CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE Measure_Voltage(0,10) expect 0.8'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)2724467 within 33773 // idac_mode=800uA, 1k resistor 0.8V'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGND RegWrite(0x0A, 0x0B) expect 1 // *source=0x0b idac_mode=400uA, 1k resistor 0.4V'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=400uA, 1k resistor 0.4V")'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGND tinyTester.Wait_Output_Settling()'
-// CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGND Measure_Voltage(0,10) expect 0.4'
 // CODE GENERATOR:           CommandDocTest '@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)1343163 within 33773 // idac_mode=400uA, 1k resistor 0.4V'
 // CODE GENERATOR:           CommandDocTest '@test tinyTester.print("check filter register is writeable")'
@@ -386,8 +383,6 @@
 // CODE GENERATOR:           CommandDocParamOut ''
 // CODE GENERATOR:           CommandPost ''
 // CODE GENERATOR:           CommandReturn '@return 1 on success; 0 on failure'
-// CODE GENERATOR: MAX11410 Command Name = Configure_Voltage (MAX11410_AINP_SEL_enum_t ainp, MAX11410_AINN_SEL_enum_t ainn) --> uint8_t
-// CODE GENERATOR: no Menu item hint in description
 // CODE GENERATOR: MAX11410 Command Name = Read_All_Voltages (void) --> uint8_t
 // CODE GENERATOR: Menu item hint description Menu item '$' -> AINcode[0], AINcode[1], AINcode[2], AINcode[3], AINcode[4], AINcode[5], AINcode[6], AINcode[7], AINcode[8], AINcode[9], AINcode[10]
 // CODE GENERATOR: Menu item '$' -> AINcode[0], AINcode[1], AINcode[2], AINcode[3], AINcode[4], AINcode[5], AINcode[6], AINcode[7], AINcode[8], AINcode[9], AINcode[10] -- Menu item $
@@ -433,6 +428,8 @@
 // CODE GENERATOR:           CommandReturnType 'double'
 // CODE GENERATOR:           CommandPre '@pre external connection REF1P-REF1N is a reference resistor'
 // CODE GENERATOR:           CommandPre '@pre ref1_v = reference resistance in ohms, default=4999'
+// CODE GENERATOR:           CommandPre '@pre rtd_filter = filter register configuration, 0x34 for LINEF_11_SINC4 RATE_0100 output data rate 60SPS'
+// CODE GENERATOR:           CommandPre '@pre rtd_ctrl = ctrl register configuration, 0x40 for ref0_v, 0x41 for ref1_v, 0x42 for ref2_v'
 // CODE GENERATOR:           CommandDocParamIn '@param[in] rtd_iout = channel RTD high side force, default=AINP_SEL_0111_AIN7'
 // CODE GENERATOR:           CommandDocParamIn '@param[in] rtd_ainp = channel RTD high side sense, default=AINP_SEL_1000_AIN8'
 // CODE GENERATOR:           CommandDocParamIn '@param[in] rtd_ainn = channel RTD low side, default=AINN_SEL_1001_AIN9'
@@ -546,6 +543,34 @@
 // CODE GENERATOR: testMenuGlobalArgsDict['rtd_degc']['usedByCommandName'] = 'None'
 // CODE GENERATOR: testMenuGlobalArgsDict['rtd_degc']['usedBytestMenuItemName'] = 'None'
 
+// CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.rtd_filter
+// CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.rtd_filter argname = rtd_filter
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_filter']['alias'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_filter']['argtype'] = 'uint8_t'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_filter']['usedByCommandName'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_filter']['usedBytestMenuItemName'] = 'None'
+
+// CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.rtd_ctrl
+// CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.rtd_ctrl argname = rtd_ctrl
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_ctrl']['alias'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_ctrl']['argtype'] = 'uint8_t'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_ctrl']['usedByCommandName'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_ctrl']['usedBytestMenuItemName'] = 'None'
+
+// CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.rtd_source
+// CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.rtd_source argname = rtd_source
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_source']['alias'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_source']['argtype'] = 'uint8_t'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_source']['usedByCommandName'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_source']['usedBytestMenuItemName'] = 'None'
+
+// CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.rtd_pga
+// CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.rtd_pga argname = rtd_pga
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_pga']['alias'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_pga']['argtype'] = 'uint8_t'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_pga']['usedByCommandName'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_pga']['usedBytestMenuItemName'] = 'None'
+
 // CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.tc_v
 // CODE GENERATOR: testMenuGlobalArgsDict add global property g_MAX11410_device.tc_v argname = tc_v
 // CODE GENERATOR: testMenuGlobalArgsDict['tc_v']['alias'] = 'None'
@@ -701,10 +726,10 @@
 // CODE GENERATOR: testMenuGlobalArgsDict['ctrl']['usedByCommandName'] = 'None'
 // CODE GENERATOR: testMenuGlobalArgsDict['ctrl']['usedBytestMenuItemName'] = 'None'
                     // parse argument uint32_t ctrl
-        uint32_t ctrl = g_MAX11410_device.ctrl; // default to global property value
+        uint32_t ctrl = g_MAX11410_device.rtd_ctrl; // default to global property value
         if (cmdLine.parse_uint32_dec("ctrl", ctrl))
         {
-            g_MAX11410_device.ctrl = ctrl; // update global property value
+            g_MAX11410_device.rtd_ctrl = ctrl; // update global property value
         }
 
 // CODE GENERATOR: testMenuGlobalArgsDict['loop_limit']['alias'] = 'None'
@@ -751,6 +776,17 @@
             g_MAX11410_device.ref2_v = ref2_v; // update global property value
         }
 
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_ctrl']['alias'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_ctrl']['argtype'] = 'uint8_t'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_ctrl']['usedByCommandName'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_ctrl']['usedBytestMenuItemName'] = 'None'
+                    // parse argument uint8_t rtd_ctrl
+        uint8_t rtd_ctrl = g_MAX11410_device.rtd_ctrl; // default to global property value
+        if (cmdLine.parse_uint8_dec("rtd_ctrl", rtd_ctrl))
+        {
+            g_MAX11410_device.rtd_ctrl = rtd_ctrl; // update global property value
+        }
+
 // CODE GENERATOR: testMenuGlobalArgsDict['rtd_degc']['alias'] = 'None'
 // CODE GENERATOR: testMenuGlobalArgsDict['rtd_degc']['argtype'] = 'double'
 // CODE GENERATOR: testMenuGlobalArgsDict['rtd_degc']['usedByCommandName'] = 'None'
@@ -762,6 +798,17 @@
             g_MAX11410_device.rtd_degc = rtd_degc; // update global property value
         }
 
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_filter']['alias'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_filter']['argtype'] = 'uint8_t'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_filter']['usedByCommandName'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_filter']['usedBytestMenuItemName'] = 'None'
+                    // parse argument uint8_t rtd_filter
+        uint8_t rtd_filter = g_MAX11410_device.rtd_filter; // default to global property value
+        if (cmdLine.parse_uint8_dec("rtd_filter", rtd_filter))
+        {
+            g_MAX11410_device.rtd_filter = rtd_filter; // update global property value
+        }
+
 // CODE GENERATOR: testMenuGlobalArgsDict['rtd_ms']['alias'] = 'None'
 // CODE GENERATOR: testMenuGlobalArgsDict['rtd_ms']['argtype'] = 'int'
 // CODE GENERATOR: testMenuGlobalArgsDict['rtd_ms']['usedByCommandName'] = 'None'
@@ -784,6 +831,28 @@
             g_MAX11410_device.rtd_ohm = rtd_ohm; // update global property value
         }
 
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_pga']['alias'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_pga']['argtype'] = 'uint8_t'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_pga']['usedByCommandName'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_pga']['usedBytestMenuItemName'] = 'None'
+                    // parse argument uint8_t rtd_pga
+        uint8_t rtd_pga = g_MAX11410_device.rtd_pga; // default to global property value
+        if (cmdLine.parse_uint8_dec("rtd_pga", rtd_pga))
+        {
+            g_MAX11410_device.rtd_pga = rtd_pga; // update global property value
+        }
+
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_source']['alias'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_source']['argtype'] = 'uint8_t'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_source']['usedByCommandName'] = 'None'
+// CODE GENERATOR: testMenuGlobalArgsDict['rtd_source']['usedBytestMenuItemName'] = 'None'
+                    // parse argument uint8_t rtd_source
+        uint8_t rtd_source = g_MAX11410_device.rtd_source; // default to global property value
+        if (cmdLine.parse_uint8_dec("rtd_source", rtd_source))
+        {
+            g_MAX11410_device.rtd_source = rtd_source; // update global property value
+        }
+
 // CODE GENERATOR: testMenuGlobalArgsDict['tc_degc']['alias'] = 'None'
 // CODE GENERATOR: testMenuGlobalArgsDict['tc_degc']['argtype'] = 'double'
 // CODE GENERATOR: testMenuGlobalArgsDict['tc_degc']['usedByCommandName'] = 'None'
@@ -929,6 +998,22 @@
                     cmdLine.serial().printf("rtd_degc = ");
 // CODE GENERATOR: @ command print double g_MAX11410_device.rtd_degc property name ending in physical units degc
                     cmdLine.serial().printf("%f\r\n", g_MAX11410_device.rtd_degc);
+// CODE GENERATOR: @ command print uint8_t g_MAX11410_device.rtd_filter
+                    cmdLine.serial().printf("rtd_filter = ");
+// CODE GENERATOR: @ command print uint8_t g_MAX11410_device.rtd_filter no recognized physical unit, show both decimal and hexadecimal
+                    cmdLine.serial().printf("%d = 0x%2.2x\r\n", g_MAX11410_device.rtd_filter, g_MAX11410_device.rtd_filter);
+// CODE GENERATOR: @ command print uint8_t g_MAX11410_device.rtd_ctrl
+                    cmdLine.serial().printf("rtd_ctrl = ");
+// CODE GENERATOR: @ command print uint8_t g_MAX11410_device.rtd_ctrl no recognized physical unit, show both decimal and hexadecimal
+                    cmdLine.serial().printf("%d = 0x%2.2x\r\n", g_MAX11410_device.rtd_ctrl, g_MAX11410_device.rtd_ctrl);
+// CODE GENERATOR: @ command print uint8_t g_MAX11410_device.rtd_source
+                    cmdLine.serial().printf("rtd_source = ");
+// CODE GENERATOR: @ command print uint8_t g_MAX11410_device.rtd_source property name ending in physical units s
+                    cmdLine.serial().printf("%d\r\n", g_MAX11410_device.rtd_source);
+// CODE GENERATOR: @ command print uint8_t g_MAX11410_device.rtd_pga
+                    cmdLine.serial().printf("rtd_pga = ");
+// CODE GENERATOR: @ command print uint8_t g_MAX11410_device.rtd_pga no recognized physical unit, show both decimal and hexadecimal
+                    cmdLine.serial().printf("%d = 0x%2.2x\r\n", g_MAX11410_device.rtd_pga, g_MAX11410_device.rtd_pga);
 // CODE GENERATOR: @ command print double g_MAX11410_device.tc_v
                     cmdLine.serial().printf("tc_v = ");
 // CODE GENERATOR: @ command print double g_MAX11410_device.tc_v property name ending in physical units v
@@ -975,7 +1060,7 @@
 // CODE GENERATOR:           CommandTest '@test group POR RegRead(MAX11410::CMD_r000_1011_dddd_dddd_MUX_CTRL0, buffer) expect 1 expect-buffer 0x0000ff'
 // CODE GENERATOR:           CommandTest '@test group POR RegRead(MAX11410::CMD_r000_1100_dddd_dddd_MUX_CTRL1, buffer) expect 1 expect-buffer 0x0000ff'
 // CODE GENERATOR:           CommandTest '@test group POR RegRead(MAX11410::CMD_r000_1101_dddd_dddd_MUX_CTRL2, buffer) expect 1 expect-buffer 0x00'
-// CODE GENERATOR:           CommandTest '@test group POR RegRead(MAX11410::CMD_r000_1110_xxdd_xddd_PGA, buffer) expect 1 expect-buffer 0x00'
+// CODE GENERATOR:           CommandTest '@test group POR RegRead(MAX11410::CMD_r000_1110_00ss_0ggg_PGA, buffer) expect 1 expect-buffer 0x00'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGND // measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v (disabled by default)'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE // measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v in more detail'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE tinyTester.print("measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v")'
@@ -984,19 +1069,16 @@
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE RegWrite(0x0A, 0x03) expect 1 // *source=0x03 idac_mode=100uA, 1k resistor 0.1V'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=100uA, 1k resistor 0.1V")'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE tinyTester.Wait_Output_Settling()'
-// CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE Measure_Voltage(0,10) expect 0.1'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)337731 within 33773 // idac_mode=100uA, 1k resistor 0.1V'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE RegWrite(0x0A, 0x0D) expect 1 // *source=0x0d idac_mode=800uA, 1k resistor 0.8V'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=800uA, 1k resistor 0.8V")'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE tinyTester.Wait_Output_Settling()'
-// CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE Measure_Voltage(0,10) expect 0.8'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)2724467 within 33773 // idac_mode=800uA, 1k resistor 0.8V'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGND RegWrite(0x0A, 0x0B) expect 1 // *source=0x0b idac_mode=400uA, 1k resistor 0.4V'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=400uA, 1k resistor 0.4V")'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGND tinyTester.Wait_Output_Settling()'
-// CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGND Measure_Voltage(0,10) expect 0.4'
 // CODE GENERATOR:           CommandTest '@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)1343163 within 33773 // idac_mode=400uA, 1k resistor 0.4V'
 // CODE GENERATOR:           CommandTest '@test tinyTester.print("check filter register is writeable")'
@@ -1037,7 +1119,7 @@
                     // @Test='@test group POR RegRead(MAX11410::CMD_r000_1011_dddd_dddd_MUX_CTRL0, buffer) expect 1 expect-buffer 0x0000ff'
                     // @Test='@test group POR RegRead(MAX11410::CMD_r000_1100_dddd_dddd_MUX_CTRL1, buffer) expect 1 expect-buffer 0x0000ff'
                     // @Test='@test group POR RegRead(MAX11410::CMD_r000_1101_dddd_dddd_MUX_CTRL2, buffer) expect 1 expect-buffer 0x00'
-                    // @Test='@test group POR RegRead(MAX11410::CMD_r000_1110_xxdd_xddd_PGA, buffer) expect 1 expect-buffer 0x00'
+                    // @Test='@test group POR RegRead(MAX11410::CMD_r000_1110_00ss_0ggg_PGA, buffer) expect 1 expect-buffer 0x00'
                     // @Test='@test group RES1KA0A1TOGND // measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v (disabled by default)'
                     // @Test='@test group RES1KA0A1TOGNDMORE // measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v in more detail'
                     // @Test='@test group RES1KA0A1TOGNDMORE tinyTester.print("measure a 1kohm resistor between (AIN0,AIN1) and AGND to verify ref2_v")'
@@ -1046,19 +1128,16 @@
                     // @Test='@test group RES1KA0A1TOGNDMORE RegWrite(0x0A, 0x03) expect 1 // *source=0x03 idac_mode=100uA, 1k resistor 0.1V'
                     // @Test='@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=100uA, 1k resistor 0.1V")'
                     // @Test='@test group RES1KA0A1TOGNDMORE tinyTester.Wait_Output_Settling()'
-                    // @Test='@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
                     // @Test='@test group RES1KA0A1TOGNDMORE Measure_Voltage(0,10) expect 0.1'
                     // @Test='@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)337731 within 33773 // idac_mode=100uA, 1k resistor 0.1V'
                     // @Test='@test group RES1KA0A1TOGNDMORE RegWrite(0x0A, 0x0D) expect 1 // *source=0x0d idac_mode=800uA, 1k resistor 0.8V'
                     // @Test='@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=800uA, 1k resistor 0.8V")'
                     // @Test='@test group RES1KA0A1TOGNDMORE tinyTester.Wait_Output_Settling()'
-                    // @Test='@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
                     // @Test='@test group RES1KA0A1TOGNDMORE Measure_Voltage(0,10) expect 0.8'
                     // @Test='@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)2724467 within 33773 // idac_mode=800uA, 1k resistor 0.8V'
                     // @Test='@test group RES1KA0A1TOGND RegWrite(0x0A, 0x0B) expect 1 // *source=0x0b idac_mode=400uA, 1k resistor 0.4V'
                     // @Test='@test group RES1KA0A1TOGNDMORE tinyTester.print("idac_mode=400uA, 1k resistor 0.4V")'
                     // @Test='@test group RES1KA0A1TOGND tinyTester.Wait_Output_Settling()'
-                    // @Test='@test group RES1KA0A1TOGND_BAD Measure_Voltage(0,10) // TODO1 #175 MAX11410 Self Test why does Measure_Voltage(0,10) without expect cause an mbed hard fault?'
                     // @Test='@test group RES1KA0A1TOGND Measure_Voltage(0,10) expect 0.4'
                     // @Test='@test group RES1KA0A1TOGNDMORE AINcode[0] expect (uint32_t)1343163 within 33773 // idac_mode=400uA, 1k resistor 0.4V'
                     // @Test='@test tinyTester.print("check filter register is writeable")'
@@ -1138,6 +1217,8 @@
 // CODE GENERATOR:           CommandReturnType 'double'
 // CODE GENERATOR:           CommandPre '@pre external connection REF1P-REF1N is a reference resistor'
 // CODE GENERATOR:           CommandPre '@pre ref1_v = reference resistance in ohms, default=4999'
+// CODE GENERATOR:           CommandPre '@pre rtd_filter = filter register configuration, 0x34 for LINEF_11_SINC4 RATE_0100 output data rate 60SPS'
+// CODE GENERATOR:           CommandPre '@pre rtd_ctrl = ctrl register configuration, 0x40 for ref0_v, 0x41 for ref1_v, 0x42 for ref2_v'
 // CODE GENERATOR:           CommandDocParamIn '@param[in] rtd_iout = channel RTD high side force, default=AINP_SEL_0111_AIN7'
 // CODE GENERATOR:           CommandDocParamIn '@param[in] rtd_ainp = channel RTD high side sense, default=AINP_SEL_1000_AIN8'
 // CODE GENERATOR:           CommandDocParamIn '@param[in] rtd_ainn = channel RTD low side, default=AINN_SEL_1001_AIN9'
@@ -1157,6 +1238,8 @@
                     // CommandReturnType='double'
                     // @Pre='@pre external connection REF1P-REF1N is a reference resistor'
                     // @Pre='@pre ref1_v = reference resistance in ohms, default=4999'
+                    // @Pre='@pre rtd_filter = filter register configuration, 0x34 for LINEF_11_SINC4 RATE_0100 output data rate 60SPS'
+                    // @Pre='@pre rtd_ctrl = ctrl register configuration, 0x40 for ref0_v, 0x41 for ref1_v, 0x42 for ref2_v'
                     // @Param[in]='@param[in] rtd_iout = channel RTD high side force, default=AINP_SEL_0111_AIN7'
                     // @Param[in]='@param[in] rtd_ainp = channel RTD high side sense, default=AINP_SEL_1000_AIN8'
                     // @Param[in]='@param[in] rtd_ainn = channel RTD low side, default=AINN_SEL_1001_AIN9'