原廠連結:http://www.seeedstudio.com/wiki/index.php?title=Grove_-_LCD_RGB_Backlight_-_RGB背光LCD&uselang=zh
Grove - LCD RGB Backlight是一款16x2的LCD顯示器。如果你之前使用過Grove - Serial LCD, 那麼你應該對1602的LCD不會陌生,不同的是Grove - LCD RGB Backlight採用了RGB的背光燈. Grove - LCD RGB Backlight內部使用低功耗CMOS技術的AIP31068L作為控制芯片. 整個模塊使用I2C的通信方式,只需兩個IO口即可完成控制,省下來的IO,你可以用來做更多有意義的事情。支持用戶自定義字符,想在LCD上打出一個愛心?這只是一件很簡單的事情。另外,多彩的RGB背光,使你的應用更加奪目絢麗。Grove - LCD RGB Backlight 採用標準的4pin Grove 接口,可以方便的和Arduino/Seeeduino連接,這是你在一些只需要顯示少量信息的場合的最佳選擇。
這個實例會向你展示如何使用Grove - LCD RGB Backlight, 另外,我們需要一塊Seeeduino V3.0。
連接非常簡單,只需要通過一根Grove線連接到Seeeduino的I2C接口。
你可以到github下載驅動庫,點這裡。下載完之後,把它放到Arduino的libraries裡面。
在庫裡面有個Hello World的example,我們將他打開,並且燒錄燒錄到Seeeduino V3.0。
你可以看到在LCD的第一排顯示了「Hello world」, 第二排顯示的是開機時間。
Grove - LCD RGB Backlight很重要的一個特點在於可以改變背光的顏色,可以使用一下的函數方便改變背光顏色:
void setRGB(int r, int g, int b);
換個紅色的背光試試吧。
把代碼的顏色部分改成:
const int colorR = 255; const int colorG = 0; const int colorB = 0;
重新燒錄代碼,你可以看到,背光變成紅色的了,接下來,試試其他的顏色吧,讓你的LCD炫起來。
This example will change backlight color and display text. You should connect to GrovePi+ with it like the following picture.
# Grovepi + grove RGB LCD module # Example for using the Grove I2C color LCD from grove_rgb_lcd import * while(True): setText("Hello world\nLCD test") setRGB(0,128,64) for c in range(0,255): setRGB(c,255-c,0) time.sleep(0.01) setRGB(0,255,0) setText("Bye bye, this should wrap") time.sleep(1.5)
cd GrovePi/Software/Python/grove_rgb_lcd/
sudo python example.py
The best way to learn something, is to create a project with it.
Recipe Community is a place which gathers a lot of amazing projects with step-by-step tutorials. Makers in the community have made a lot of awesome projects with the Grove - LCD RGB Backlight , check this out!
Make a focused antenna with a pringles can.
Get to know the temperature and pressure around you with a smart DIY home monitor
Find out even more awesome projects on Recipe.
Born with the spirit of making and sharing, that is what we believe makes a maker.
And only because of this , the open source community can be as prosperous as it is today.
It does not matter what you are and what you have made, hacker, maker, artist and engineers,
as long as you start sharing your works with others, you are being part of the open source community and you are making your contributions.
Now share you awesome projects with us on Recipe, and win a chance to become the Core User of Seeed.
Get more information about Core User please email to: recipe@seeed.cc
資料來源:https://www.seeedstudio.com/Grove---LCD-RGB-Backlight-p-1643.html
Done with tedious mono color backlight? This Grove enables you to set the color to whatever you like via the simple and concise Grove interface. It takes I2C as communication method with your microcontroller. So number of pins required for data exchange and backlight control shrinks from ~10 to 2, relieving IOs for other challenging tasks.
Besides, Grove - LCD RGB Backlight supports user-defined characters. Want to get a love heart or some other foreign characters? Just take advantage of this feature and design it!
This product is a replacement of Grove - Serial LCD. If you are looking for primitive 16x2 LCD modules, we have green yellow backlight version and blue backlight version on sale also.
Features
Colorful RGB Backlight
Built-in English and Japanese fonts
I2C communication, uses only two IOs
Automatic power-on reset
For all Grove users (especially beginners), we provide you guidance PDF documents. Please download and read through Preface - Getting StartedandIntroduction to Grove before your using of the product.
Dimensions | 83mm x 44mm x 13mm |
Weight | G.W 42g |
Battery | Exclude |
Input Voltage | 5V |
CGROM | 10880 bit |
CGRAM | 64*8 bit |
Grove - LCD RGB Backlight | 1 |