https://wiki.elecrow.com/index.php?title=Crowtail-_OLED&feed=atom&action=history
Crowtail- OLED - Revision history
2024-03-28T23:05:38Z
Revision history for this page on the wiki
MediaWiki 1.33.0
https://wiki.elecrow.com/index.php?title=Crowtail-_OLED&diff=181&oldid=prev
Admin: Created page with "== Description == Crowtail- OLED is constructed from 128 x 64 dot matrix OLED module. The display offers high brightness, self-emission, high contrast ratio, slim/thin outlin..."
2019-08-22T05:29:27Z
<p>Created page with "== Description == Crowtail- OLED is constructed from 128 x 64 dot matrix OLED module. The display offers high brightness, self-emission, high contrast ratio, slim/thin outlin..."</p>
<p><b>New page</b></p><div>== Description ==<br />
<br />
Crowtail- OLED is constructed from 128 x 64 dot matrix OLED module. The display offers high brightness, self-emission, high contrast ratio, slim/thin outline, wide viewing angle, wide temperature range and low power consumption.<br />
<br />
'''Model: [http://www.elecrow.com/crowtail-oled-p-1276.html CT0025OD]'''<br><br />
<br />
[[File: Crowtail-OLED.JPG |400px]]<br />
<br />
== Features ==<br />
*Connection Mode:I(IIC)<br />
*Voltage: 5V<br />
*Display Color:Bule/Black<br />
*Resolution:128x64<br />
*Interface:I2C<br />
*Wide range of operating temperature: : -20°C~70°C<br />
*Dimensions(mm):40.0(L)x20.0(W)x11.5(H)<br />
<br />
== Usage ==<br />
<br />
1.Hardware connection<br />
<br />
Connect the Crowtail- RGB-LED to I port.<br />
<br />
[[File:oledhware11.jpg |600px]]<br />
<br />
2.Connect the board to PC using USB cable.<br />
<br />
3.Download the library [http://www.elecrow.com/wiki/index.php?title=File:U8glib.zip OLED library];Unzip it into the libraries file of Arduino IDE by the path: ..\arduino-1.0.1\libraries.<br />
<br />
4.Open the code directly by the path:File -> Example ->U8glib->Ele_0_96_12864.<br />
#include "U8glib.h"<br />
U8GLIB_SSD1306_128X64 u8g(U8G_I2C_OPT_NONE); <br />
void drawColorBox(void)<br />
{<br />
u8g_uint_t w,h;<br />
u8g_uint_t r, g, b;<br />
w = u8g.getWidth()/32;<br />
h = u8g.getHeight()/8;<br />
for( b = 0; b < 4; b++ )<br />
for( g = 0; g < 8; g++ )<br />
for( r = 0; r < 8; r++ )<br />
{<br />
u8g.setColorIndex((r<<5) | (g<<2) | b );<br />
u8g.drawBox(g*w + b*w*8, r*h, w, h);<br />
}<br />
}<br />
void drawLogo(uint8_t d)<br />
{<br />
u8g.setFont(u8g_font_gdr25r);<br />
u8g.drawStr(8+d, 30+d, "E");<br />
u8g.setFont(u8g_font_gdr25r);<br />
u8g.drawStr(30+d,30+d,"l");<br />
u8g.setFont(u8g_font_gdr25r);<br />
u8g.drawStr(40+d,30+d,"e"); <br />
u8g.setFont(u8g_font_gdr25r);<br />
u8g.drawStr(55+d,30+d,"c");<br />
u8g.setFont(u8g_font_gdr25r);<br />
u8g.drawStr(70+d,30+d,"r");<br />
u8g.setFont(u8g_font_gdr25r);<br />
u8g.drawStr(85+d,30+d,"o");<br />
u8g.setFont(u8g_font_gdr25r);<br />
u8g.drawStr(100+d,30+d,"w");<br />
}<br />
<br />
void drawURL(void)<br />
{<br />
u8g.setFont(u8g_font_4x6);<br />
u8g.drawStr(35,54,"www.elecrow.com");<br />
<br />
}<br />
void draw(void) {<br />
if ( u8g.getMode() == U8G_MODE_R3G3B2 ) {<br />
drawColorBox();<br />
}<br />
u8g.setColorIndex(1);<br />
if ( U8G_MODE_GET_BITS_PER_PIXEL(u8g.getMode()) > 1 ) {<br />
drawLogo(2);<br />
u8g.setColorIndex(2);<br />
drawLogo(1);<br />
u8g.setColorIndex(3);<br />
}<br />
drawLogo(0);<br />
drawURL();<br />
<br />
}<br />
<br />
void setup(void) {<br />
}<br />
<br />
void loop(void) {<br />
// picture loop<br />
u8g.firstPage(); <br />
do {<br />
draw();<br />
u8g.setColorIndex(1);<br />
} while( u8g.nextPage() ); <br />
// rebuild the picture after some delay<br />
delay(200); <br />
}<br />
5.Upload the Code,you shoule see the display of OLED.<br />
<br />
<br><br />
[[File:OLED display11.jpg |600px]]<br />
<br />
== Resource ==<br />
<br />
*[http://www.elecrow.com/wiki/index.php?title=File:U8glib.zip OLED demo code]<br />
*[http://www.elecrow.com/wiki/index.php?title=File:Crowtail-_OLED_eagle_files.zip Crowtail- OLED eagle files]</div>
Admin