You maybe use a display when you want to check the values without Serial Monitor.
But you can use OLED graphic display by using ‘u8glib library’. I was confused at first, because this library has some habits.
So I want to mention to the tips by this articles, as far as possible. At first, I apology to you if I had made wrong knowledge. Sorry.
“u8glib” is Arduino versatile library for graphic display. Nowaday, You can get “u8glib” from Arduino IDE. Also you can download from GitHub. Although there is new “version 2” on IDE installer. I use “version 1” in this article, because I have never use new one, sorry.
OLED is meant “organic light-emitting diode”. It’s very high luminance and beautiful. So many electric parts shop sells it. Probably it’s easy to find reasonable one.
I got these at japanese Amazon market.
Also there is SPI display at different price.
Try find it at yourself on web.
I2C and SPI are protocols used between devices. I recommend you SPI if you want faster refresh rate. Otherwise I2C is convenient for fewer pins.
There is video which I check the difference of transmit speed. Please check it.
SPI has advantage for general use to compatibles. Because I2C display didn’t work on SAMD21 or Teensy. Or “version 2” might solve this problem, I don’t know. Anyway, I can take operation guarantee on Arduino UNO and promini.
Watch sample sketches
Let’s watch samples to operation check, first.
This is illustration for wiring. Please check allowable voltage of your display. This wiring is specified to 5 voltage work.
Connect SDA pin and SCL pin if you use I2C display instead.
Then install “u8glib” library to your IDE if you haven’t it yet.
Open the sample sketch “GraphicTest”.
You need to change on the sketch. It does not work as it is.
Check codes at the beginning. There are lots of code for each setting. You have to remove ‘//’ mark. It depends on your display.
My SPI is, for example,
//U8GLIB_SSD1306_128X64 u8g(4, 5, 6, 7);
Then you can run the sketch. I couldn’t figure out this style and it took several time.
You know how to watch those sample sketches now. Try other samples.
Next, I will mentioned to how to draw graphics.