YAW - ESP8266

Yet Another Weather station that is updated by internet.
This one runs on a standalone ESP8266 with an OLED display

Similar projects worth following
There are published many weather display projects. Most use an Arduino for the sketch to run on.
These Arduino based projects often use the spartan AT-command set.
This project uses the ESP8266WiFi.h library with the Arduino-ESP8266 IDE add-on
The component count is really very small. Just a ESP8266 and a small Oled display. A few resistors and a capacitor.
Ofcourse you need a 3.3V powersupply or 3 Ni-Mh batteries. Probably a Li-ion battery of 3.6V will be good too. Because a fully charged Li-ion cell will be around 4V a simple diode can be put in series with the cell to bring voltage down to less than 3.6V.

Code can be found on:
  • 1 × ESP8266
  • 1 × 128x64 I2C OLED
  • 2 × resistor 3k3 to 10k pullup resistors for SCL & SDA
  • 1 × tantalium capacitor 2u2 to 4u7 directly soldered on module between Vcc and ground for stability
  • 1 × resistor 10k pull-up resistor for the reset pin

Enjoy this project?



co sto wrote 12/08/2015 at 00:38 point

Hi Nick and chiprobot.

Sorry to hear you have problems getting this working.
I downloaded the files from github to check if the sketch is still working and the IP is right. I can confirm that everything is still working so you must make an error somewhere.

Maybe you use the wrong Json library.
Make sure you have the one from this url: "";
Also make sure you have this line in the IDE-preferences as additional Boards manager URL's:
Recently there is a new release 2.0.0 , uninstall the old one and reinstall the new one with the board manager.
And last if you use a ESP07 or 12 you better change the I2C lines to pin 4 and 5.
Change the line in the setup() for the different pins.
Wire.begin(4,5);   // I2C for ESP-01: (SDA,SCL)

I hope this solves your problems and reset instabilities.

  Are you sure? yes | no

Nick wrote 11/05/2015 at 21:08 point

Thanks for the prompt response. The initial problem was my bad - copying text from web pages sometimes introduces stuff that is not intended. At my age I should have realised...

Your original sketch has the i/p address for the wunderground api as But this currently resolves to a sub-domain of "Akamitechnologies". Your original sketch simply hangs with the serial monitor saying "connecting to".

So I changed that line to read "#define HOST ""    

It compiles, and starts but when it successfully connects to, the ESP chip throws out a lot of digits to the serial consol and then resets - an endless reset loop.

If I change the sketch so that it tries to connect to (i.e. add one character so that the system will not find the address) and the unit does not reset but simply says "connection faailed" and tries again.

I thought it might be that the increased power drain when the wifi got active may have caused transients on the power lines - but it still does this with a considerably more 'beefy' PSU and more decoupling. In other words, the reset behaviour seems independent of PSU used.

My instincts are that it is a software related glitch AFTER it has successfully pulled data from Wunderground that is causing the internal reset..

My ESP is an ESP07 - I could send the crash output if that would help, but I suspect that still not enough is known about these units for it to make much difference!

(I just realised that in fact the i/p for is also an Akamitechnologies address! - but obviously a different one - I guess they changed their network after you published the sketch...?

Is there a reason you hard-coded an i/p addres into the sketch?

Anyway, thanks for any ideas you may have for me to try...


  Are you sure? yes | no


[this comment has been deleted]

Nick wrote 11/28/2015 at 07:11 point

Thanks for the info... 

Unfortunately I don't have time right now to try some software investigations on the project code. 

But one thing that could be tried would be to play around with the code inside wunderground() function. There is a lot of parsing and string building goes on in there and I suspect that if the api has changedd, then the parsing will break and if not trapped properly could generate an exception.

It is a shame it doesn't work "out of the box" because it is just SO neat!

Feel free to PM me if you maake any discoveries - if i do get time to play furthe and make progress, I will let you know...

Co sto:  any insights as the project developer?


  Are you sure? yes | no

co sto wrote 11/03/2015 at 11:30 point

tnx for the report.

I compiled it with version 1.6.5 and it compiles fine exept for a few not so important warnings about " deprecated conversion from string constant to 'char* ".

I looked for the variable myDegree and it is not used, instead there is a variable myDregree (the extra 'r' is obviously a mistype) which is used in font.h 

line 179: {SendChar(pgm_read_byte(myDregree+i));}

line 102 in font.h const char myDregree [8] PROGMEM = {

If you change both to the same name it will compile

Make sure font.h is included as a separate file/tab in your sketch.

  Are you sure? yes | no

Nick wrote 11/03/2015 at 10:58 point


I am playing with the ESP8266 - using Arduino IDE version 1.6.5  

All the included sample sketches in the IDE for the ESP8266 compile fine.

Bbut when I try to use your sketch I get a bunch of compiler errors. I tried using some other sketches for similar projects and they too throw up compiler errors. As far as I can tell they are NOT simply related to missing libraries.

For example in your sketch, I get a bunch of advisory warinigs:

"YAWD.ino: In function 'void setup()':
YAWD.ino:52:37: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]"

Also this for line 176:

"YAWD:179: error: 'myDregree' was not declared in this scope"

I am guessing that you compiled your sketch on an earlier version of the IDE - could it be that since the IDE was changed, it became more sensitive to deprecated constructions etc?

But this doesn't explain the 'myDregree' missing error 

It's driving me crazy because this seems like such a cool and simple project - any ideas welcome!!


  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates