Skip to content

Commit 5df0336

Browse files
committed
found a workaround supported by Arduino bugfix #182 (arduino/arduino-builder#182 (comment))
1 parent 15fde31 commit 5df0336

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

libraries/MonSens/MonSens_ESP8266.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@
3030
#ifndef MONSENS_ESP8266_H
3131
#define MONSENS_ESP8266_H
3232

33+
// needs to be set before including the ESP libraries
34+
#ifdef MONSENS_ESP8266_VCC_H
35+
ADC_MODE(ADC_VCC);
36+
#endif
37+
3338
#include <MonSens.h>
3439
#include <ESP8266WiFi.h>
3540

libraries/MonSens/MonSens_ESP8266_Vcc.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,6 @@
3131

3232
#include <MonSens.h>
3333

34-
/* as of Arduino IDE 1.6.8, the below sequence doesn't work:
35-
ADC_MODE(ADC_VCC);
36-
*/
37-
3834
/**
3935
* MonSens implementation for a Photoresistor
4036
*/

0 commit comments

Comments
 (0)