done
Diff: Font_7Seg.h
- Revision:
- 1:f63d87466f55
- Parent:
- 0:dc8789a6e21f
diff -r dc8789a6e21f -r f63d87466f55 Font_7Seg.h --- a/Font_7Seg.h Sat Jan 30 20:35:25 2016 +0000 +++ b/Font_7Seg.h Fri Oct 06 16:43:56 2017 +0000 @@ -1,5 +1,8 @@ /* mbed LED Font Library, for TM1637 LED Controller * Copyright (c) 2016, v01: WH, Initial version, Test in CATALEX + * 2017, v02: WH, Added RobotDyn 6 Digit module, + * Added Eyewink 6 Digit + 5 Keys module, + * Constructor adapted to 2 pins: dio, clk * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -25,8 +28,8 @@ // Select one of the testboards for TM1637 controller #include "TM1637_Config.h" -#if ((CATALEX_TEST == 1) || (TM1637_TEST == 1)) -// Segment bit positions for 7 Segment display using the CATALEX mapping for TM1637 +#if ((EYEWINK_TEST == 1) || (ROBOTDYN_TEST == 1) || (CATALEX_TEST == 1) || (TM1637_TEST == 1)) +// Segment bit positions for 7 Segment display using the CATALEX and ROBOTDYN mapping for TM1637 // Modify this table for different 'bit-to-segment' mappings. The ASCII character defines and the FONT_7S const table below // will be adapted automatically according to the bit-to-segment mapping. Obviously this will only work when the segment // mapping is identical for every digit position. This will be the case unless the hardware designer really hates software developers. @@ -55,6 +58,33 @@ //Mask for blending out and setting 7 segments digits #define MASK_7S_ALL = (S7_A | S7_B | S7_C | S7_D | S7_E | S7_F | S7_G} +//The CATALAX mapping between Digit positions or Columns (Left to Right) and Grids (ie memory address) are: +//The column numbers are: +// 0 1 2 3 +//The Grids are: +// GR1 GR2 GR3 GR4 +//The memory addresses are: +// 0 1 2 3 + + +//The ROBOTDYN mapping between Digit positions or columns (Left to Right) and Grids (ie memory address) are: +//The column numbers are: +// 0 1 2 3 4 5 +//The Grids are: +// GR3 GR2 GR1 GR6 GR5 GR4 +//The memory addresses are: +// 2 1 0 5 4 3 + + +//The EYEWINK mapping between Digit positions or columns (Left to Right) and Grids (ie memory address) are: +//The column numbers are: +// 0 1 2 3 4 5 +//The Grids are: +// GR1 GR2 GR3 GR4 GR5 GR6 +//The memory addresses are: +// 0 1 2 3 4 5 + + //Icons Grid 1 #define S7_DP1 0x0080 #define S7_ICON_GR1 (0x0000) @@ -69,13 +99,23 @@ //Icons Grid 3 #define S7_DP3 0x0080 #define S7_ICON_GR3 (0x0000) -//#define S7_ICON_GR3 (S7_LD3 | S7_DP3) +//#define S7_ICON_GR3 (S7_DP3) //Icons Grid 4 #define S7_DP4 0x0080 #define S7_ICON_GR4 (0x0000) //#define S7_ICON_GR4 (S7_DP4) +//Icons Grid 5 +#define S7_DP5 0x0080 +#define S7_ICON_GR5 (0x0000) +//#define S7_ICON_GR5 (S7_DP5) + +//Icons Grid 6 +#define S7_DP6 0x0080 +#define S7_ICON_GR6 (0x0000) +//#define S7_ICON_GR6 (S7_DP6) + //Mask for blending out and restoring Icons extern const char MASK_ICON_GRID[];