Difference between revisions of "OLED Display 0.96"
(→Code) |
(→Grove - OLED Display 0.96 inches (Seeed-Studio)) |
||
| Line 9: | Line 9: | ||
[[File:OLED Display 128x64 recto.jpg|300px]] | [[File:OLED Display 128x64 recto.jpg|300px]] | ||
[[File:OLED Display 128x64 verso.jpg|300px]] | [[File:OLED Display 128x64 verso.jpg|300px]] | ||
| + | |||
| + | === Tableau === | ||
| + | {| class="wikitable centre" width="250" | ||
| + | |+ Seeed-Studio | ||
| + | |- | ||
| + | ! scope=col | Seeeduino | ||
| + | ! scope=col | Sensor | ||
| + | |- | ||
| + | | width="33%" | | ||
| + | 5V | ||
| + | | width="34%" | | ||
| + | Red | ||
| + | |- | ||
| + | | width="33%" | | ||
| + | GND | ||
| + | | width="34%" | | ||
| + | Black | ||
| + | |- | ||
| + | | width="33%" | | ||
| + | SDA | ||
| + | | width="34%" | | ||
| + | White | ||
| + | |- | ||
| + | | width="33%" | | ||
| + | SCL | ||
| + | | width="34%" | | ||
| + | Yellow | ||
| + | |- | ||
| + | | align="center" colspan="3" | | ||
| + | Grove - Temperature Sensor - | ||
| + | |} | ||
| + | |||
=== Drivers === | === Drivers === | ||
Revision as of 18:40, 28 December 2024
Contents
Grove - OLED Display 0.96 inches (Seeed-Studio)
Caractéristiques
Dot Matrix 128×64
I2C : Adresse 0x3C
Support
Tableau
| Seeeduino | Sensor | |
|---|---|---|
|
5V |
Red | |
|
GND |
Black | |
|
SDA |
White | |
|
SCL |
Yellow | |
|
Grove - Temperature Sensor - | ||
Drivers
SSD1308 chip
LY190-128064
Voltage
3.3 ~ 5.5V
Code
Exemple "Hello World!"
il faut sauvegarde sous 'OLED_Hello_World.ino'
on trouve Wire.h ici C:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\Wire\src\Wire.h
#include <Wire.h>
#include <SeeedOLED.h>
void setup()
{
Wire.begin();
SeeedOled.init(); //initialze SEEED OLED display
SeeedOled.clearDisplay(); //clear the screen and set start position to top left corner
SeeedOled.setNormalDisplay(); //Set display to normal mode (i.e non-inverse mode)
SeeedOled.setPageMode(); //Set addressing mode to Page Mode
SeeedOled.setTextXY(0,0); //Set the cursor to Xth Page, Yth Column
SeeedOled.putString("Hello World!"); //Print the String
}
void loop()
{
}
Hello World!
- include <Arduino.h>
- include <U8g2lib.h>
- ifdef U8X8_HAVE_HW_SPI
- include <SPI.h>
- endif
- ifdef U8X8_HAVE_HW_I2C
- include <Wire.h>
- endif
U8G2_SSD1306_128X64_ALT0_F_HW_I2C u8g2(U8G2_R0, /* reset=*/ U8X8_PIN_NONE); // SSD1306 and SSD1308Z are compatible
// U8G2_SSD1306_128X64_NONAME_F_SW_I2C u8g2(U8G2_R0, /* clock=*/ SCL, /* data=*/ SDA, /* reset=*/ U8X8_PIN_NONE); //Low spped I2C
void setup(void) {
u8g2.begin();
}
void loop(void) {
u8g2.clearBuffer(); // clear the internal memory
u8g2.setFont(u8g2_font_ncenB08_tr); // choose a suitable font
u8g2.drawStr(0,10,"Hello World!"); // write something to the internal memory
u8g2.sendBuffer(); // transfer internal memory to the display
delay(1000);
}
OLED_Hello_World.ino
Télécharger les sources sur GitHub
Liens internes
Liens externes
www.seeedstudio.com/Grove-OLED-Display-0-96.html shop
wiki.seeedstudio.com/Grove-OLED_Display_0.96inchwiki
github.com/Seeed-Studio/OLED_Display_128X64 github