This is a library for the JY-LKM1638 Display

Committer:
mr63
Date:
Mon Aug 19 17:09:38 2013 +0000
Revision:
0:c05022d4f68c
This is a library for the JY-LKM1638 Display

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mr63 0:c05022d4f68c 1 #include "mbed.h"
mr63 0:c05022d4f68c 2 #include "LKM1638.h"
mr63 0:c05022d4f68c 3 //Strobe //CLK //Data
mr63 0:c05022d4f68c 4 LKM1636 display(p23,p22,p21);
mr63 0:c05022d4f68c 5
mr63 0:c05022d4f68c 6 int main() {
mr63 0:c05022d4f68c 7
mr63 0:c05022d4f68c 8
mr63 0:c05022d4f68c 9
mr63 0:c05022d4f68c 10 while(1) //Do what ever is between these brackets forever or until the micro is reset.
mr63 0:c05022d4f68c 11 {
mr63 0:c05022d4f68c 12 for(unsigned char count = 0; count<225; count++)
mr63 0:c05022d4f68c 13 {
mr63 0:c05022d4f68c 14 display.Write_Short(count,0);
mr63 0:c05022d4f68c 15 display.Write_Short(225-count,1);
mr63 0:c05022d4f68c 16 display.LEDS (count);
mr63 0:c05022d4f68c 17 wait(.1);
mr63 0:c05022d4f68c 18 count++;
mr63 0:c05022d4f68c 19 }
mr63 0:c05022d4f68c 20 for(unsigned long int count = 65536; count<65700; count)
mr63 0:c05022d4f68c 21 {
mr63 0:c05022d4f68c 22 display.Write_Long(count);
mr63 0:c05022d4f68c 23 wait(.1);
mr63 0:c05022d4f68c 24 count++;
mr63 0:c05022d4f68c 25 display.Switch_To_LED(display.read_buttons ());
mr63 0:c05022d4f68c 26 }
mr63 0:c05022d4f68c 27 display.Clear();
mr63 0:c05022d4f68c 28
mr63 0:c05022d4f68c 29 }
mr63 0:c05022d4f68c 30 }
mr63 0:c05022d4f68c 31