Test program running on MAX32625MBED. Control through USB Serial commands using a terminal emulator such as teraterm or putty.
Dependencies: MaximTinyTester CmdLine MAX541 USBDevice
Diff: Test_Main_MAX11043.cpp
- Revision:
- 88:e4fd5033a55f
- Parent:
- 83:29bb86cc45bc
- Child:
- 89:20fd6ce5e4dd
--- a/Test_Main_MAX11043.cpp Thu Feb 27 03:42:16 2020 +0000 +++ b/Test_Main_MAX11043.cpp Fri Feb 28 00:59:24 2020 +0000 @@ -1849,7 +1849,49 @@ void onButton2FallingEdge(void) { // TBD demo configuration +#if 1 + // MAX11043 Demo Configuration + //g_MAX11043_device.RegWrite(MAX11043_CMD_enum_t commandByte, uint32_t regData); + // + // *Config=0x6000 (POR default, slowest conversion rate 1:6 = 9us) + g_MAX11043_device.RegWrite(MAX11043::CMD_0010_0000_d16_Wr08_Configuration, 0x6000); + // + // *ConfigA=0x0018 (Bypass PGA and filters, Gain=1V/V) + g_MAX11043_device.RegWrite(MAX11043::CMD_0011_0000_d16_Wr0C_ConfigA, 0x0018); + // + // *AGain=0x1000 (0.5) (default is 0x2000=1.0) + g_MAX11043_device.RegWrite(MAX11043::CMD_0100_0100_d16_Wr11_AGain, 0x1000); + // + // *ConfigB=0x0018 (Bypass PGA and filters, Gain=1V/V) + g_MAX11043_device.RegWrite(MAX11043::CMD_0011_0100_d16_Wr0D_ConfigB, 0x0018); + // + // *BGain=0x1000 (0.5) (default is 0x2000=1.0) + g_MAX11043_device.RegWrite(MAX11043::CMD_0100_1000_d16_Wr12_BGain, 0x1000); + // + // *ConfigC=0x0018 (Bypass PGA and filters, Gain=1V/V) + g_MAX11043_device.RegWrite(MAX11043::CMD_0011_1000_d16_Wr0E_ConfigC, 0x0018); + // + // *CGain=0x1000 (0.5) (default is 0x2000=1.0) + g_MAX11043_device.RegWrite(MAX11043::CMD_0100_1100_d16_Wr13_CGain, 0x1000); + // + // *ConfigD=0x0018 (Bypass PGA and filters, Gain=1V/V) + g_MAX11043_device.RegWrite(MAX11043::CMD_0011_1100_d16_Wr0F_ConfigD, 0x0018); + // + // *DGain=0x1000 (0.5) (default is 0x2000=1.0) + g_MAX11043_device.RegWrite(MAX11043::CMD_0101_0000_d16_Wr14_DGain, 0x1000); + // + // *DacHDacL=0xFF00 + g_MAX11043_device.RegWrite(MAX11043::CMD_0010_1100_d16_Wr0B_DACHDACL, 0xFF00); + // + // *DacStep=0x0001 + g_MAX11043_device.RegWrite(MAX11043::CMD_0010_1000_d16_Wr0A_DACStep, 0x0001); + // + // *Dac=0x0ccc + g_MAX11043_device.RegWrite(MAX11043::CMD_0010_0100_d16_Wr09_DAC, 0x0ccc); + // +#endif // TODO diagnostic LED + led1 = LED_OFF; led2 = LED_OFF; led3 = LED_ON; // diagnostic rbg led BLUE } #endif // HAS_BUTTON2_DEMO_INTERRUPT