5

I'm doing this on esp8266 with micro python and there is a way to clear OLED display in Arduino but I don't know how to clear display in micropython i used ssd1306 library to control my OLED

and this is my error I've written a code that prints on OLED from a list loop, but OLED prints it on the text that was printed before it (print one on top of the other not clear and printing) 7enter image description here

display = [ip, request_uri, country, region, city]

for real_time in display:
  oled.text(real_time, 0, 20)
  oled.show()
  time.sleep(2)
  print(real_time)

1 Answer 1

9

The fill() method is used to clean the OLED screen:

oled.fill(0)
oled.show()
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.