Difference between revisions of "Lesson 25--Microduino 5*7 Lattice Static Display"
(Created page with "{{Language|第二十五课--Microduino 5*7点阵静态显示}} {| style="width: 800px;" |- | ==Objective== This experiment will introduce how to use the Microduino I/O port to...") |
|||
(One intermediate revision by one other user not shown) | |||
Line 19: | Line 19: | ||
*Drive Mode | *Drive Mode | ||
− | Common | + | Common cathode: All the cathode of LED connect together, and use high level to light the LED. |
− | Common | + | Common anode: All the anode of LED connect together, and use low level to light the LED. |
==Debug== | ==Debug== | ||
===Measure lattice pin=== | ===Measure lattice pin=== | ||
− | If you don't have | + | If you don't have the lattice pin diagram, measure it by yourself. Detailed step, please refer to 8*8 lattice. |
+ | |||
− | |||
===Set up circuit=== | ===Set up circuit=== | ||
− | *Connect the column pin to D2-D6 and row pin to D7- | + | *Connect the column pin to D2-D6 and row pin to D7-D13; |
{|class="wikitable" | {|class="wikitable" | ||
|- | |- | ||
Line 43: | Line 43: | ||
===Program=== | ===Program=== | ||
− | *Prepared | + | *Prepared Work: |
− | **Download test | + | **Download test program: '''[[File:.led_5_7_static.zip]]''' |
− | **Modulus | + | **Modulus software: '''[[File:PCtolCD.zip]]''' |
− | Step | + | Step 1: Download test program, and open it; |
− | Step | + | Step 2: Select the board type and download directly, after download a picture will be shown on lattice |
*Note: | *Note: | ||
**duan[] array use to store column data, data[] array use to store row data; | **duan[] array use to store column data, data[] array use to store row data; | ||
Line 53: | Line 53: | ||
**leddisplay() function configures the lattice row pin. Function ledduan() uses to configure lattice column pin; | **leddisplay() function configures the lattice row pin. Function ledduan() uses to configure lattice column pin; | ||
**Use the right shift operation ">>" to move out the data and output to I/O port, then light the LED. | **Use the right shift operation ">>" to move out the data and output to I/O port, then light the LED. | ||
− | **This experiment uses the common cathode lattice, if use the common anode lattice with the same pin | + | **This experiment uses the common cathode lattice, if use the common anode lattice with the same pin definition, need reverse the array data. For example, change the "data[i]" to "~data[i]". If the pin definition is different, need change the pin's configuration in function leddisplay() and ledduan(). |
==Change the font== | ==Change the font== | ||
− | Detailed information, please refer | + | Detailed information, please refer to: http://www.microduino.cc/wiki/index.php?title=%E7%AC%AC%E4%BA%8C%E8%AF%BE--Microduino_OLED%E4%BD%BF%E7%94%A8 |
− | + | Note: Need to replace modulus with image model, and new a 5*7 image. Draw a image, then the modulus way changed to: Yin, column type, reverse. | |
Change the font code in data[], download directly and then display the new image on lattice. | Change the font code in data[], download directly and then display the new image on lattice. |
Latest revision as of 08:32, 12 September 2016
Language: | English • 中文 |
---|
ContentsObjectiveThis experiment will introduce how to use the Microduino I/O port to control 5*7 lattice and without drive chip. Equipment
Schematic
Common cathode: All the cathode of LED connect together, and use high level to light the LED. Common anode: All the anode of LED connect together, and use low level to light the LED. DebugMeasure lattice pinIf you don't have the lattice pin diagram, measure it by yourself. Detailed step, please refer to 8*8 lattice.
Set up circuit
Program
Step 1: Download test program, and open it; Step 2: Select the board type and download directly, after download a picture will be shown on lattice
Change the fontDetailed information, please refer to: http://www.microduino.cc/wiki/index.php?title=%E7%AC%AC%E4%BA%8C%E8%AF%BE--Microduino_OLED%E4%BD%BF%E7%94%A8 Note: Need to replace modulus with image model, and new a 5*7 image. Draw a image, then the modulus way changed to: Yin, column type, reverse. Change the font code in data[], download directly and then display the new image on lattice. ResultBy testing, lattice can display an image and each LED's brightness is uniform, very beautiful. Video |