radonk1979 Posted March 10, 2023 Share Posted March 10, 2023 Hi everyone, I am currently using for the PVI 800 a 7 Segment 8Bit Display (MAX7219) to display the coordinate and the part in red works fine. What I know would like to do is to display the Selected WP2 on the last digit of the display. I am really struggeling to get this to work. How to use the display so that the first digits are being used for the cooridnates and the last one for the Selected Waypoint. I hope that someone can point me in the right direction Link to comment Share on other sites More sharing options...
Vinc_Vega Posted March 10, 2023 Share Posted March 10, 2023 (edited) Just use the first 6 digits to display your "Line1Text" and the 8th digit to display the waypoint number. Spare out the 7th digit, set a space charracter to it or use it for a two digits waypoint number. something like that (just a rough estimate) void onPviLine1TextChange(char* new value) { lc.setChar(0,7,newValue[0],false); lc.setChar(0,6,newValue[1],false); lc.setChar(0,5,newValue[2],false); lc.setChar(0,4,newValue[3],false); lc.setChar(0,3,newValue[4],false); lc.setChar(0,2,newValue[5],false); } DcsBios::StringBuffer ... ... void onPviLine1PointChange(char* newValue) { lc.setChar(0,0,newValue,false); } DcsBios::StringBuffer ... EDIT: if "new Value" would be an integer (int) use the lc.setDigit command. Btw. the "true" or "false" within the brackets switches the decimal point of the respective digit on or off. Have a look ->here<- for reference of the ledcontrol-library. Regards, Vinc Edited March 11, 2023 by Vinc_Vega Regards, Vinc real life: Royal Bavarian Airforce online: VJS-GermanKnights.de [sIGPIC][/sIGPIC] Link to comment Share on other sites More sharing options...
radonk1979 Posted March 14, 2023 Author Share Posted March 14, 2023 Thank you so much @Vinc_Vega I was able to get it to work. Link to comment Share on other sites More sharing options...
Recommended Posts