suu pen さんのライブラリをフォークしました。 このライブラリは1桁から8桁までのSeven segment Numeric LEDを制御します。 LEDはanode commonとcathode common を使用することができます。 LEDの表示は1秒で表示をスムースに切り替えるモードと、直ぐに切り替えるモードの2つのモードを選択することができます。 This library to control the Seven segment Numeric LED 8 digit of 1. You can use the LED cathode common and anode common. Switch mode LED display and a second displayed a smooth, you can choose two modes to switch modes quickly.

Dependents:   HumidifierController_LPC824

Fork of SevenSegLed by suu pen

Files at this revision

API Documentation at this revision

Comitter:
kyun_kun
Date:
Mon Feb 13 16:56:16 2017 +0000
Parent:
6:a1eb5de4146f
Commit message:
change to GPIO timing

Changed in this revision

SevenSegLed.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r a1eb5de4146f -r 74862b3cd837 SevenSegLed.cpp
--- a/SevenSegLed.cpp	Fri Dec 27 23:23:34 2013 +0000
+++ b/SevenSegLed.cpp	Mon Feb 13 16:56:16 2017 +0000
@@ -28,7 +28,7 @@
 #endif // USECOM4
     
 //@SS131223    timer.attach_us(this, &SevenSegLed::segmentGrayDataKosin, 10000);       // led smooth control 10ms timer inttruupt   //@SS131223
-    timer.attach_us(this, &SevenSegLed::output, 1000);       // led output process 1ms timer inttruupt      //@SS131223
+    timer.attach_us(this, &SevenSegLed::output, 2000);       // led output process 1ms timer inttruupt      //@SS131223
     // data table set of Brightness
     // DT_pwmGray[] = i ^ 2
     for(uint32_t i = 0; i < Z_grayMax + 1; i++){
@@ -113,17 +113,18 @@
     #define D_d (0x7a)        // d             0 1 1 1  1 0 1 0        
     #define D_E (0x9e)        // E             1 0 0 1  1 1 1 0    
     #define D_F (0x8e)        // F             1 0 0 0  1 1 1 0
+    #define D_H (0x6e)        // H             0 1 1 0  1 1 1 0
     #define D_NULL (0x00)     // NULL          0 0 0 0  0 0 0 0
                               // (No indication)
         
         
-    const unsigned char DT_segData[17] = {D_0, D_1, D_2, D_3, D_4, D_5, D_6, D_7, D_8, D_9, D_A, D_b, D_C, D_d, D_E, D_F, D_NULL};
+    const unsigned char DT_segData[18] = {D_0, D_1, D_2, D_3, D_4, D_5, D_6, D_7, D_8, D_9, D_A, D_b, D_C, D_d, D_E, D_F, D_H, D_NULL};
     uint8_t work;
 
     for(keta = 0; keta < Z_ketaSuu; keta++){
         // number data set
         work = D_7seg[keta];
-        if(work > 0x10){work = 0x10;}       // error data then NULL
+        if(work > 0x11){work = 0x11;}       // error data then NULL
         segData = DT_segData[work];
         
         // dot data set