7 segment display library for mbed This routine support 2,4 and 8 digit anode-common or cathode-common LED.
Diff: Sseg.h
- Revision:
- 7:a19431131213
- Parent:
- 6:1de2abf828d6
- Child:
- 10:1b8dbe52e5a8
--- a/Sseg.h Thu Aug 07 11:44:22 2014 +0000 +++ b/Sseg.h Sun Sep 21 08:32:50 2014 +0000 @@ -48,6 +48,7 @@ int _dig; // support 4 or 8 bool _zeroSupress; bool _kcommon; // Cathode-common flag + bool _sinkDriver; // invert segment drive, if true void initConv(void); Timer timer; public: @@ -129,6 +130,11 @@ * use Anode Common LED (default) */ void setAcommon(void); + + /** + * sink driver + */ + void setSinkDriver(void); /** * get a charcter pattern from a number