ESP resets on readvdd33()
Posted: Wed Jul 01, 2015 11:20 am
I use Arduino IDE 1.6.5 and have ESP-add-on version 1.6.4-673g8cd3697 installed (copied in the hardware folder).
I want to read the 3,3 volt so I added this code:
I call readVdd() in setup() and it perfectly prints the string on the display, so far so good but only in setup().
When I do this in the loop then the ESP resets most of the time with message: wdt reset ... etc .... etc
no difference if I ommit the dtostrf() and sendStrXY() functions, the vdd = readvdd33()/1000.0 make the ESP crash.
Is this a feature or is this not (yet) fully implemented in the ESP add-on ?
I want to read the 3,3 volt so I added this code:
Code: Select all
extern "C" {
#include "user_interface.h"
uint16 readvdd33(void);
}
and made :
void readVdd()
{
char buf[6]; // temporary buffer
float vdd = readvdd33()/1000.0;
dtostrf( vdd, 1 ,3, buf); // convert float to string
sendStrXY(buf,7,10); // print string on OLED
}
I call readVdd() in setup() and it perfectly prints the string on the display, so far so good but only in setup().
When I do this in the loop then the ESP resets most of the time with message: wdt reset ... etc .... etc
no difference if I ommit the dtostrf() and sendStrXY() functions, the vdd = readvdd33()/1000.0 make the ESP crash.
Is this a feature or is this not (yet) fully implemented in the ESP add-on ?