radonk1979 Posted March 19, 2023 Posted March 19, 2023 Hi everyone, Again thank you for your help with this post. I got everything to work as desired. When putting the display it looked a bit small to me as its using the 0.36inch modules. I was looking for the MAX7219 with 0.56inch but could not find anything. Instead I found these: https://www.aliexpress.com/item/1005001953449345.html?spm=a2g0o.order_list.order_list_main.11.245f1802ul3vC0 I am trying to get these to work using the different examples I could find onine. But not being a programmer is making this really challenging. I hope that someone could help me to get one as an example to work. Its not even showing anything My code: /* use '#define DCSBIOS_DEFAULT_SERIAL' instead if your Arduino board * does not feature an ATMega328 or ATMega2650 controller. */ #define DCSBIOS_DEFAULT_SERIAL #include "DcsBios.h" #include <TM1637TinyDisplay.h> #define CLK 2 #define DIO 3 TM1637TinyDisplay display(CLK, DIO); //set up the 4-Digit Display //Display top line text void onPviLine1TextChange(char* newValue) { /* your code here */ display.showNumber(newValue[5]); } DcsBios::StringBuffer<6> pviLine1TextBuffer(0x1924, onPviLine1TextChange); void setup() { DcsBios::setup(); display.setBrightness(7); } void loop() { DcsBios::loop(); }
No1sonuk Posted March 19, 2023 Posted March 19, 2023 Try changing: display.showNumber(newValue[5]); To display.showNumber(newValue); "newValue[5]" means just character number 5 in the string.
Vinc_Vega Posted March 19, 2023 Posted March 19, 2023 (edited) Consider to use the TM1637TinyDisplay6 library as that is for the big six digits displays. Have a look here: https://github.com/jasonacox/TM1637TinyDisplay#tm1637-6-digit-display---tm1637tinydisplay6 Regards, Vinc Edited March 19, 2023 by Vinc_Vega Regards, Vinc real life: Royal Bavarian Airforce online: VJS-GermanKnights.de [sIGPIC][/sIGPIC]
radonk1979 Posted March 20, 2023 Author Posted March 20, 2023 On 3/19/2023 at 8:23 PM, Vinc_Vega said: TM1637TinyDisplay6 I got it to work My code /* use '#define DCSBIOS_DEFAULT_SERIAL' instead if your Arduino board * does not feature an ATMega328 or ATMega2650 controller. */ #define DCSBIOS_DEFAULT_SERIAL #include "DcsBios.h" #include <TM1637TinyDisplay6.h> #define CLK 2 #define DIO 3 TM1637TinyDisplay6 display(CLK, DIO); // 6-Digit Display Class //Display top line text void onPviLine1TextChange(char* newValue) { /* your code here */ display.showString(newValue); } DcsBios::StringBuffer<6> pviLine1TextBuffer(0x1924, onPviLine1TextChange); void setup() { DcsBios::setup(); display.begin(); display.setBrightness(2); } void loop() { DcsBios::loop(); }
Recommended Posts