7 segment display reverse digits
Re: 7 segment display reverse digits
That instrument doesn't work with the tm 1637 6 digit units, so are you offering that as well?., and all versions of the 6 digit?... there is more than one.. what about the CC version TM 1638. ? There are about 6 versions of those,!!.. where are you fitting those options Keith? Hmm?
Oh, and the direct muxed version using discrete transistors?
How big is this option box of yours going to be?
Oh, how about the two blocks of four digit? One from pw and the other from ae? They each need different options. The problem is that your instrument is just so limited
I dont give a damn what mobiflight does or doesnt do really, this is a different product. YOU are free to code all the possible options in code and call a lovely happy camper setup screen from your code, one that YOU write. You can also open a nice piccy of the spoon to feed them
Oh, and the direct muxed version using discrete transistors?
How big is this option box of yours going to be?
Oh, how about the two blocks of four digit? One from pw and the other from ae? They each need different options. The problem is that your instrument is just so limited
I dont give a damn what mobiflight does or doesnt do really, this is a different product. YOU are free to code all the possible options in code and call a lovely happy camper setup screen from your code, one that YOU write. You can also open a nice piccy of the spoon to feed them
Joe. CISSP, MSc.
- Keith Baxter
- Posts: 4685
- Joined: Wed Dec 20, 2017 11:00 am
- Location: Botswana
Re: 7 segment display reverse digits
Joe,
You did not read this obviously.
And your thoughts on mobiflight remain yours. I do not care on those. But it remains that they have the foresight.
FFS it is a simple left/right indexing check box for the MAX7219.
Who said anything about anything else. The opening statement by the OP was...
"Have been using AM for many years. Recently purchase some high quality 4,5,6 digit 7 segment displays which have the Max7219 chips and board already attached."
Keith
You did not read this obviously.
And your thoughts on mobiflight remain yours. I do not care on those. But it remains that they have the foresight.
FFS it is a simple left/right indexing check box for the MAX7219.
Who said anything about anything else. The opening statement by the OP was...
"Have been using AM for many years. Recently purchase some high quality 4,5,6 digit 7 segment displays which have the Max7219 chips and board already attached."
Keith
AMD RYZEN 9 5950X CPU, Corsair H80I cooler, ASUS TUF GAMING B550-PLUS AMD Ryzen Mother Board, 32Gb ram Corsair Vengeance 3000Mh, MSI GTX960 4G graphics card
-
- Posts: 30
- Joined: Wed Dec 25, 2019 8:55 pm
Re: 7 segment display reverse digits
I am a loyal AM customer and will remain so. I did try the string.reverse before I made my initial post.
Mobiflight has now added a direct link to X-Plane. All that is needed is to place the dataref or command in a box.
The only reason I brought up the subject in the first place is to stimulate some discussion and thought about the future.
"Rock on" AM. Thanks all.
Mobiflight has now added a direct link to X-Plane. All that is needed is to place the dataref or command in a box.
The only reason I brought up the subject in the first place is to stimulate some discussion and thought about the future.
"Rock on" AM. Thanks all.
- Keith Baxter
- Posts: 4685
- Joined: Wed Dec 20, 2017 11:00 am
- Location: Botswana
Re: 7 segment display reverse digits
Hi,old pilot guy wrote: ↑Sun Aug 21, 2022 8:03 pm I am a loyal AM customer and will remain so. I did try the string.reverse before I made my initial post.
Mobiflight has now added a direct link to X-Plane. All that is needed is to place the dataref or command in a box.
The only reason I brought up the subject in the first place is to stimulate some discussion and thought about the future.
"Rock on" AM. Thanks all.
Yes, My argument is that one should be able to swap indexing in the hw_add()
Also, some peeps might build their own displays like I did. Some might build PCB's for others.
If code is written in a instrument then a index swap should not be a train smash to implement in the hardware output. It is not a instrument thing. it is a hardware thing. The style of the output should be determined in the output device. Not in code
Keith
AMD RYZEN 9 5950X CPU, Corsair H80I cooler, ASUS TUF GAMING B550-PLUS AMD Ryzen Mother Board, 32Gb ram Corsair Vengeance 3000Mh, MSI GTX960 4G graphics card
Re: 7 segment display reverse digits
Ralph already posted the sensible solution. Use a user property and provide support for both directions. You could do this for dial direction too if you wanted. It’s a bit naughty or lazy for the board makers to go opposite of the intended directions but I guess if it’s possible someone will do it.
Air Manager panels at https://www.experimentalsimavionics.com
Youtube Channel https://www.youtube.com/channel/UC8ZqXX ... kfZMq5BKig
Air Manager API Tutorial Video Series https://youtube.com/playlist?list=PLNr0 ... baT4gJKg5D
Youtube Channel https://www.youtube.com/channel/UC8ZqXX ... kfZMq5BKig
Air Manager API Tutorial Video Series https://youtube.com/playlist?list=PLNr0 ... baT4gJKg5D
- Keith Baxter
- Posts: 4685
- Joined: Wed Dec 20, 2017 11:00 am
- Location: Botswana
Re: 7 segment display reverse digits
Hi,
Whilst I get what all are saying I just feel that we are complicating things. I can tell you that a simple string reverse as a user property will not work.
The standard MAX7219 with 8 digits is wired like so. Pin from the IC to display digit
(max-disp) (0-8),(1-7),(2-6),(3-5),(4-4),(5-3),(6-2),(7-1)
The MAX7219 with 5 digits like the OP posted is wired like so.
(max-disp) (0-1),(1-2),(2-3),(3-4),(4-5)
I wire the MAX7219 with 5 digit like so.
(max-disp) (0-5),(1-4),(2-3),(3-2),(4-1)
Now by simply reversing the string then decimal places and string format go's out the window.
This is what
I will wire up two 5 digit displays later on today and take some images of what happens.
Keith
Whilst I get what all are saying I just feel that we are complicating things. I can tell you that a simple string reverse as a user property will not work.
The standard MAX7219 with 8 digits is wired like so. Pin from the IC to display digit
(max-disp) (0-8),(1-7),(2-6),(3-5),(4-4),(5-3),(6-2),(7-1)
The MAX7219 with 5 digits like the OP posted is wired like so.
(max-disp) (0-1),(1-2),(2-3),(3-4),(4-5)
I wire the MAX7219 with 5 digit like so.
(max-disp) (0-5),(1-4),(2-3),(3-2),(4-1)
Now by simply reversing the string then decimal places and string format go's out the window.
Code: Select all
display = hw_chr_display_add("MAX7219", 2, "ARDUINO_MEGA2560_A_A0", "ARDUINO_MEGA2560_A_A2","ARDUINO_MEGA2560_A_A1")
--hw_chr_display_set_text(display , 0, 0,string.format("% 9.02f",string.reverse(tostring(123.876))))
hw_chr_display_set_text(display , 0, 0,string.format("% 9.02f",tostring(123.876)))
--hw_chr_display_set_text(display , 1, 0,string.reverse(tostring(123.876)))
hw_chr_display_set_text(display , 1, 0,tostring(123.876))
Keith
AMD RYZEN 9 5950X CPU, Corsair H80I cooler, ASUS TUF GAMING B550-PLUS AMD Ryzen Mother Board, 32Gb ram Corsair Vengeance 3000Mh, MSI GTX960 4G graphics card
- Keith Baxter
- Posts: 4685
- Joined: Wed Dec 20, 2017 11:00 am
- Location: Botswana
Re: 7 segment display reverse digits
Hi,
Just in case anyone is wondering I have built many MAX display configuration radios.
Keith
Just in case anyone is wondering I have built many MAX display configuration radios.
Keith
AMD RYZEN 9 5950X CPU, Corsair H80I cooler, ASUS TUF GAMING B550-PLUS AMD Ryzen Mother Board, 32Gb ram Corsair Vengeance 3000Mh, MSI GTX960 4G graphics card
Re: 7 segment display reverse digits
Hi,
In this case the API very clearly states it supports the MAX7219. And the MAX7219 has 8 channels, ranging DIG0 to DIG7.
This is exactly what AM does.
It doesn't clame to support one of the many hardware boards build around the MAX7219.
And I would rather not do that. New hardware designs come and go all the time. It is not something that should be baked into the AM application I think. It might be usefull to add a user property that can handle mulitple hardware vendors though.
Corjan
In this case the API very clearly states it supports the MAX7219. And the MAX7219 has 8 channels, ranging DIG0 to DIG7.
This is exactly what AM does.
It doesn't clame to support one of the many hardware boards build around the MAX7219.
And I would rather not do that. New hardware designs come and go all the time. It is not something that should be baked into the AM application I think. It might be usefull to add a user property that can handle mulitple hardware vendors though.
Corjan
- Keith Baxter
- Posts: 4685
- Joined: Wed Dec 20, 2017 11:00 am
- Location: Botswana
Re: 7 segment display reverse digits
Corjan,Corjan wrote: ↑Mon Aug 22, 2022 8:29 am Hi,
In this case the API very clearly states it supports the MAX7219. And the MAX7219 has 8 channels, ranging DIG0 to DIG7.
This is exactly what AM does.
It doesn't clame to support one of the many hardware boards build around the MAX7219.
And I would rather not do that. New hardware designs come and go all the time. It is not something that should be baked into the AM application I think. It might be usefull to add a user property that can handle mulitple hardware vendors though.
Corjan
I understand. It is just that the standard MAX7219, The popular 8 digit one that we solder the cap on, works backwards.
In this diagram of the chip. DIG0 which is pin no 2 go's to digit no 8 on the display. That is the digit furthermost to the right. So the confusion now comes in when people buy a MAX7219 chip and a 5 digit led display. Logic tell us that the MAX DIG 0 pin should go to DIG1 on the display. But that is incorrect it should go to DIG5 on the display. So it might be that a person wires it up in reverse causing all sorts of confusion.
The OP bought MAX7219 that are wired max DIG0 -> display DIG1 hence the need to reverse the string and change string formatting.
I just thought that it might be easier to have direction argument than having to write code to swap or have a user prop.
But if that is not possible then at least this discussion has made peeps aware and how to overcome the situation.
Keith
AMD RYZEN 9 5950X CPU, Corsair H80I cooler, ASUS TUF GAMING B550-PLUS AMD Ryzen Mother Board, 32Gb ram Corsair Vengeance 3000Mh, MSI GTX960 4G graphics card
Re: 7 segment display reverse digits
Hi,
Yeah, so the conclusion here is that the board manufacturers don't make the most logical choices
It is very annoying to have to wait for a new build of AM/AP when there is a new hardware board.
So again this is easily fixed as user property, and hacking a bit with strings will get you there.
Might be smart for us to buy a couple of the most populair once, and support those in our hardware functions.
Corjan
Yeah, so the conclusion here is that the board manufacturers don't make the most logical choices
It is very annoying to have to wait for a new build of AM/AP when there is a new hardware board.
So again this is easily fixed as user property, and hacking a bit with strings will get you there.
Might be smart for us to buy a couple of the most populair once, and support those in our hardware functions.
Corjan