Place to put your Basic demos and examples

Moderator: Mmiscool

User avatar
By javagate
#71952 Hey!

I really like what you did here and I'm very new to coding and ESP could you send me the current code that works on a NodeMcu and Oled screen.

Thanks!
User avatar
By Mmiscool
#71970 To hook up the OLED screen refer to the esp8266 basic docs. The oled uses i2c protocol.


As to the example. I believe it can be improved.

The following will update the display every 15 seconds.


Code: Select alltimer 15, [showme]

[showme]
memclear
cls
oled.cls()

ret = wget("api.coindesk.com/v1/bpi/currentprice.json")
oled.print("ESP Basic 3.0.Alpha 69", 10,1)
oled.print("BTC Price", 10,18)
oled.print(json(ret,"EUR.rate_float"), 60,18)
oled.print("Your IP is:", 10,36)
oled.print(ip(), 30,48)
wait
User avatar
By denialthomus2
#79681 Hello,

Mmiscool wrote:To hook up the OLED screen refer to the esp8266 basic docs. The oled uses i2c protocol.


As to the example. I believe it can be improved.

The following will update the display every 15 seconds.


Code: Select alltimer 15, [showme]

[showme]
memclear
cls
oled.cls()

ret = wget("api.coindesk.com/v1/bpi/currentprice.json")
oled.print("ESP Basic 3.0.Alpha 69", 10,1)
oled.print("BTC Price", 10,18)
oled.print(json(ret,"EUR.rate_float"), 60,18)
oled.print("Your IP is:", 10,36)
oled.print(ip(), 30,48)
wait


Thanks for sharing this code is very nice but I have a question about which company to decide bitcoin price please suggest to me with sharing some details. Because of my company thinking in future invest payment for bitcoin.

Thanks again!