아두이노 > Cheap OLED Displays and Arduino

TODAY324 TOTAL270,840
사이트 이용안내
Login▼/회원가입
포럼 동영상강좌 회원가입


▼ BASIC4MCU 후원업체 최신 정보 ▼

▲ BASIC4MCU 후원업체 최신 정보 ▲

BASIC4MCU | 아두이노 | 아두이노 | Cheap OLED Displays and Arduino

페이지 정보

작성자 키트 작성일2017-09-13 15:38 조회929회 댓글0건

본문

	

 

 3660040649_DrK8v7Oj_AskQuestionButton_reset.gif
this message might be for you!

oledWe all like cheap items off eBay especially if they do cool and unusual things, sometimes we get so carried away by the price that we do not even realize that fact that we do not know anything about making the product work. A while back, I was browsing through eBay dreaming of all the stuff I can buy if I become rich. Then I came across something very interesting. A set of two OLED displays with a 1.3” screen size. Very small but should be good for some Arduino projects, right? After a quick skim over the description, I found a few words that said here is the link to the library… In no time, the OLEDs where sold.

Let us talk a little more about what OLED displays are and why anyone would consider using them in their projects. OLED stands for organic light emitting diode. On the microscopic level, an OLED display is a matrix of organic LEDs that light up when they emit energy. Old LCD (Liquid Crystal Display) technology uses electronically controlled polarizers to change the way light passes or does not pass through them. This requires an external backlight the lights up the whole display underneath. This uses a lot of energy because at the time the display is on, enough light for all pixels must be provided. The new OLED technology only uses electricity per pixel. Because each pixel creates its own light, only the pixels that are on use electricity. This makes OLED technology very efficient; also, the way these types of OLEDs are built allows them to be very thin compared to LCD. That is why all the new TVs that are coming out are super thin. There is more to OLED technology but “HowStuffWorks” does a good job at explaining all the fine details of OLED technology.

After waiting almost a month, I opened up the OLED and went right to testing it out. The link in the description pointed me to this website, which is a tutorial from Adafruit. Apparently, Adafruit also makes small OLEDs displays that are very similar to the ones I received. After going through the tutorial, adding the library, and setting up all connections, I load the Arduino example file and get something like this.

arduino oled

Very useless… however the image above shows a good example of the limitations of OLED displays because Of the way they’re built OLEDs have s slower refresh rate which is seen as darker lines on the OLED in the picture. At this point, I got very discouraged, set this OLED in my electronics box, and forgot about it. A few months past and I gained some interest in making this OLED work. Therefore, I started to do some research. I found a library that supports all sorts of displays for Arduino, and it supports Adafruit’s OLED. I loaded it up and got it to turn on, very exciting!

Here is what I did…

1. Connect the OLED as follows:

OLEDArduino
GNDGND
VCCVCC
SCLpin 5
SDApin 4
RSTpin 3
D/Cpin 2
CSpin 10 (optional)

To add CS (chip select) you have to solder a wire to the back of the OLED where it says chip select.

2. Download the U8glib library from their website and place it into libraries folder of your Arduino.

3. Now here is the tricky part that will make your OLED work perfect:
– Go into the libraries folder
– Open U8glib library folder
– Now open Utility folder
– Scroll down till you find the file with the name “u8g_dev_ssd1306_128x64”
– There are actually two of them… One of them is bigger, open the BIGGER one. Right about line 186 you will see this:

  1. 0x000, /* set lower 4 bit of the col adr to 0 */

Change it to this…

  1. 0x002, /* set lower 4 bit of the col adr to 0 */

4. Open Arduino IDE
5. In examples under U8glib, you will see a “Hello World” example… Open it
6. Now if you look through the code you will see that in the beginning there is a lot of commented out code that allows the user to select what display they want to use. Right under all that add a new line and put this in. This tells the code how you connected your OLED.

  1. U8GLIB_SSD1306_128X64 u8g(5, 4, 10, 2, 3);

7. Click upload and you are all set.

arduino oled hello world

A so-called garbage OLED is not really garbage after all. The HelTec OLED that I got has 128×64 pixels, which is not much, but you can actually play chess on it. Just look through the examples in this library and find the cool things you can do with this small OLED that I got from eBay. It was actually quite hard to get it to work for the first time because information about making it work was found scattered around all over the internet; this small write-up combines it all in one simple to read tutorial.


http://www.electroschematics.com/11150/cheap-oled-displays-arduino/ 

댓글 0

조회수 929

등록된 댓글이 없습니다.

아두이노HOME > 아두이노 > 전체 목록

아두이노 목록
제목 작성자 작성일 조회
305 아두이노 작동 중인 팬모터를 블루투스와 연결된 앱으로 RPM 조절하는 코드를 추가해야하는데요. 새글 RobustWalKeR 18-10-19 7
답변 답변글 답변 : 작동 중인 팬모터를 블루투스와 연결된 앱으로 RPM 조절하는 코드를 추가해야하는데요. 새글 master 18-10-19 5
303 아두이노 master님 rc카 적외선센서 추가 질문 해도될까요? ㅠㅠ 새글 윤재 18-10-19 7
답변 답변글 답변 : master님 rc카 적외선센서 추가 질문 해도될까요? ㅠㅠ 댓글[1] 새글 master 18-10-19 6
301 아두이노 앱인벤터 스크린마다 블루투스 댓글[1] 새글 intoo07 18-10-19 11
300 아두이노 온도가 특정 온도 이상이면 팬이 동작하지 않고, 그 온도로 코드를 수정하면 팬이 작동합니다. 새글 RobustWalKeR 18-10-18 8
답변 답변글 답변 : 온도가 특정 온도 이상이면 팬이 동작하지 않고, 그 온도로 코드를 수정하면 팬이 작동합니다. 새글 master 18-10-18 6
298 아두이노 앱인벤터를 이용해 블루투스 통신 오류해결 댓글[1] 새글 개준범 18-10-18 10
297 아두이노 아두이노 우노보드R3 로 블루투스 스피커를 만들려고 하는데요 댓글[2] 새글 ㅁㅋㄴㅌ 18-10-18 14
296 아두이노 12v 팬 구동하려고합니다. 새글 zi9104 18-10-18 14
답변 답변글 답변 : 12v 팬 구동하려고합니다. 댓글[7] 새글 master 18-10-18 26
294 아두이노 아두이노 I2C.h 댓글[5] 김리락 18-10-18 13
293 아두이노 2축 엑츄에이터 사용법 댓글[1] 이미지 날다람쥐 18-10-17 20
292 아두이노 온습도출력까진 되는데 그 뒤에 팬이 동작하지를 않습니다. 이미지첨부파일 RobustWalKeR 18-10-17 14
답변 답변글 답변 : 온습도출력까진 되는데 그 뒤에 팬이 동작하지를 않습니다. 댓글[5] master 18-10-17 23
게시물 검색

Privacy Policy
MCU BASIC ⓒ 2017