Analog Input test of nanoWipom board.
The test checks 4 analog inputs (AN0-3).
Install X8,X9,X11,X12 jumpers.
Connect 1K between AIx+ and AIx-.
Toolkit:STM Development System
Location:/bipom/devtools/STM32/examples/nanoWipom/an_input
int main(void) { int ndx; /* Initialize all port pins */ NWDIO_Init(); delayMs(250); /* Initialize ADC */ NWAI_Init(); /* Enable Loop Power */ NWAI_EnableLoopPower(); // tprintf("\n\rNanoWipom %s %s",__DATE__,__TIME__); tprintf("\n\rANALOG INPUT TEST REV 1.01"); for(;;) { tprintf("\n\r"); // tprintf("\n\rVIN = %05dmV",NWAI_GetVin()); tprintf("\n\rP5V = %05dmV",NWAI_Get5V()); // for (ndx = 2; ndx <4; ndx++) tprintf("\n\rAN%d current = %05duA",ndx,NWAI_GetCurrent(ndx)); // delayMs(1000); } return 0; }