Modify single 7 Segment LED
Moderator: Benj
Modify single 7 Segment LED
I have never modified a component so wouldn't know where to begin, but is it possible to modify the LED display so that I do not have to specify connections for pin7 (DP) and Pin8 (Common)
I was hoping I could leave them assigned as Unconnected, but of course it will not compile. Because the project I'm working on is to upgrade software on existing PCBs, then hardware redesign is not an option.
Thanks in advance for any help offered. Carl.
I was hoping I could leave them assigned as Unconnected, but of course it will not compile. Because the project I'm working on is to upgrade software on existing PCBs, then hardware redesign is not an option.
Thanks in advance for any help offered. Carl.
-
- Matrix Staff
- Posts: 9521
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
Re: Modify single 7 Segment LED
Hi Carl,
Problem is common and DP are required.
If DP are all assigned to an unused pin then all the DP's will be on instead of off.
Common is vital for the working of 7seg.
If no common is connected of a 7seg then that 7seg will not work at all.
So not sure why would not want to connect a common?
Unless I have misunderstood?
Perhaps a circuit diagram of your hardware may help?
Martin
Problem is common and DP are required.
If DP are all assigned to an unused pin then all the DP's will be on instead of off.
Common is vital for the working of 7seg.
If no common is connected of a 7seg then that 7seg will not work at all.
So not sure why would not want to connect a common?
Unless I have misunderstood?
Perhaps a circuit diagram of your hardware may help?
Martin
Martin
Re: Modify single 7 Segment LED
Hi Martin,
Thanks for the quick reply.
The circuit board connects to 1 single 7 segment display whose common anode is permanently connected to the +VE supply rail, so no microprocessor control is required for the common.
The DP of the display is not connected to anything as it is not used.
It is the connection properties of the 7 seg LED component within Flowcode that I would like to be able to modify.
Thanks, Carl.
Thanks for the quick reply.
The circuit board connects to 1 single 7 segment display whose common anode is permanently connected to the +VE supply rail, so no microprocessor control is required for the common.
The DP of the display is not connected to anything as it is not used.
It is the connection properties of the 7 seg LED component within Flowcode that I would like to be able to modify.
Thanks, Carl.
- STibor
- Posts: 263
- Joined: Fri Dec 16, 2011 3:20 pm
- Has thanked: 116 times
- Been thanked: 113 times
- Contact:
Re: Modify single 7 Segment LED
Hello!
Without component.
Without component.
- Attachments
-
- seg_7_man.fcfx
- (13.69 KiB) Downloaded 432 times
-
- Matrix Staff
- Posts: 9521
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
Re: Modify single 7 Segment LED
Oh right.sptcarl wrote:The circuit board connects to 1 single 7 segment display whose common anode is permanently connected to the +VE supply rail, so no microprocessor control is required for the common.
In that case does your microcontroller on your hardware have an unused pin?
If so can assign common and dp to them.
Or you could try the Flowchart STibor posted.
Martin
Martin
Re: Modify single 7 Segment LED
Hi Martin,
No there are no unused pins to connect them to (that's how I have got around it in the past with other projects).
I could be wrong, but I was certain that back in Flowcode V3, there was no common connection for the LED display, so I was assuming that it would be easy to get rid of it now with a bit of editing. To be honest it does seem a bit pointless and a waste of resources having to assign a pin to control a single display which is not multiplexed.
Anyway...
I hadn't even thought of STibr's method, yet it is such a simple solution and for that I give thanks.
Cheers guys. Carl.
No there are no unused pins to connect them to (that's how I have got around it in the past with other projects).
I could be wrong, but I was certain that back in Flowcode V3, there was no common connection for the LED display, so I was assuming that it would be easy to get rid of it now with a bit of editing. To be honest it does seem a bit pointless and a waste of resources having to assign a pin to control a single display which is not multiplexed.
Anyway...
I hadn't even thought of STibr's method, yet it is such a simple solution and for that I give thanks.
Cheers guys. Carl.
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Modify single 7 Segment LED
I will see if I can make the common pin optional via a property.To be honest it does seem a bit pointless and a waste of resources having to assign a pin to control a single display which is not multiplexed.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- STibor
- Posts: 263
- Joined: Fri Dec 16, 2011 3:20 pm
- Has thanked: 116 times
- Been thanked: 113 times
- Contact:
Re: Modify single 7 Segment LED
This example is simpler than the previous one.
An example includes two variable arrays. Common anode or common cathode display.
Previous examples can be problematic (stack owerflow) interruption.
An example includes two variable arrays. Common anode or common cathode display.
Previous examples can be problematic (stack owerflow) interruption.
- Attachments
-
- seg_7_man_2.fcfx
- (19.84 KiB) Downloaded 362 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Modify single 7 Segment LED
Hello,
Here is a version of the component with a optional common pin which should also hopefully perform better with the simulation.
Let me know how you get on if you give it a go.
Here is a version of the component with a optional common pin which should also hopefully perform better with the simulation.
Let me know how you get on if you give it a go.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- STibor
- Posts: 263
- Joined: Fri Dec 16, 2011 3:20 pm
- Has thanked: 116 times
- Been thanked: 113 times
- Contact:
Re: Modify single 7 Segment LED
Hello!
Clear digits macros will not work?
If there is no common inputs, you can not negated the common input output.
Clear digits macros will not work?
If there is no common inputs, you can not negated the common input output.
-
- Matrix Staff
- Posts: 9521
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
Re: Modify single 7 Segment LED
They do with the latest update Ben posted above.STibor wrote:Clear digits macros will not work?
With that update you can select Yes or No for a Common Pin option.
Perhaps you have not over written original file with the updated one?
Martin
- STibor
- Posts: 263
- Joined: Fri Dec 16, 2011 3:20 pm
- Has thanked: 116 times
- Been thanked: 113 times
- Contact:
Re: Modify single 7 Segment LED
Simulation image attached.
- Attachments
-
- 7seg_new.pdf
- (210.25 KiB) Downloaded 375 times
-
- seg_7_new_nocompin.fcfx
- (4.88 KiB) Downloaded 281 times
-
- Matrix Staff
- Posts: 9521
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
Re: Modify single 7 Segment LED
Hmm thats odd.
I was basing my comment on the attached flowchart in which clear digit does work fine.
I was basing my comment on the attached flowchart in which clear digit does work fine.
- Attachments
-
- Multiple 7Seg Example3_v6.fcfx
- (11.6 KiB) Downloaded 270 times
Martin
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Modify single 7 Segment LED
Hello,
Right this should hopefully improve things and allow the clear digit to function correctly.
Right this should hopefully improve things and allow the clear digit to function correctly.
- Attachments
-
- led_7seg_single.fcpx
- (12.42 KiB) Downloaded 248 times
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 129
- Joined: Wed Jul 04, 2012 11:21 pm
- Location: Greece
- Has thanked: 51 times
- Been thanked: 19 times
Re: Modify single 7 Segment LED
Hello, i was trying to display characters like "C" , "A", "n" using output component and by setting equivalent pins Hi or Low. It is very weird that in FC4 this works fine but not in FC6!
Attached pictures show the FC4 components and the connections of the 7seg display in order to display character "o" (works fine).
Using Output component to obtain a characters on a 7seg display seems to have some issues in FC6 or am i doing something wrong?
Thanks
George
Attached pictures show the FC4 components and the connections of the 7seg display in order to display character "o" (works fine).
Using Output component to obtain a characters on a 7seg display seems to have some issues in FC6 or am i doing something wrong?
Thanks
George
- Attachments
-
- CommonAnode.png
- (4.65 KiB) Downloaded 5317 times
-
- Connection 7-Seg.png
- (31.18 KiB) Downloaded 5317 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Modify single 7 Segment LED
Hi George,
It should be working ok in v6. Can you attach your v6 program so we can take a look for you.
It should be working ok in v6. Can you attach your v6 program so we can take a look for you.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 129
- Joined: Wed Jul 04, 2012 11:21 pm
- Location: Greece
- Has thanked: 51 times
- Been thanked: 19 times
Re: Modify single 7 Segment LED
Hi Benj,
you can find attached the FC6 file with a simple program showing letter "o" and after 1 sec the letter "F".
you can find attached the FC6 file with a simple program showing letter "o" and after 1 sec the letter "F".
- Attachments
-
- 7seg_CA_Output.fcfx
- (5.82 KiB) Downloaded 281 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Modify single 7 Segment LED
Hi George,
Thanks for the file,
Thanks for the file,
Can you explain what issues your having in v6, it seems to be working correctly for me.Using Output component to obtain a characters on a 7seg display seems to have some issues in FC6 or am i doing something wrong?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 129
- Joined: Wed Jul 04, 2012 11:21 pm
- Location: Greece
- Has thanked: 51 times
- Been thanked: 19 times
Re: Modify single 7 Segment LED
Hi Benj , thanks for your attention and your help.
when you simulated the attached program, did you get a proper 'o' letter and after one second a proper 'F' letter and so on?
I think the issue that i am facing in FC6 is that the output state of the pins does not change with the "ClearDigit" component command.
In other words segments equivalent to letter 'o' (C,D,E,G) and segments equivalent to letter 'F' (A,E,F,G) are all light up simultaneously and therefore the result on the 7 seg display is always '6' which means segments A,C,D,E,F and G is always LOW (if we suppose that our Segment is Common Anode as is in the attached file).
If i am not very clear please let me know and i will try to explain with a different approach.
Thank you
George
when you simulated the attached program, did you get a proper 'o' letter and after one second a proper 'F' letter and so on?
I think the issue that i am facing in FC6 is that the output state of the pins does not change with the "ClearDigit" component command.
In other words segments equivalent to letter 'o' (C,D,E,G) and segments equivalent to letter 'F' (A,E,F,G) are all light up simultaneously and therefore the result on the 7 seg display is always '6' which means segments A,C,D,E,F and G is always LOW (if we suppose that our Segment is Common Anode as is in the attached file).
If i am not very clear please let me know and i will try to explain with a different approach.
Thank you
George
Re: Modify single 7 Segment LED
Wow this has moved on a bit since I was last on here!
Ben, I used your original modified component and it worked fine (I didn't need the clear digit part, although it would still be nice to have the DP connection as optional). I will try your latest one when I get chance.
I might be mistaken George_b but I'm sure someone once edited the display component to allow It to display a range of letters.
I never realised until the other day that the 7SEG also displays the hex values of 10 to 15, I always assumed it went blank with values above 9!
Ben, Martin and STibor, thanks for your help.
Ben, I used your original modified component and it worked fine (I didn't need the clear digit part, although it would still be nice to have the DP connection as optional). I will try your latest one when I get chance.
I might be mistaken George_b but I'm sure someone once edited the display component to allow It to display a range of letters.
I never realised until the other day that the 7SEG also displays the hex values of 10 to 15, I always assumed it went blank with values above 9!
Ben, Martin and STibor, thanks for your help.
-
- Posts: 129
- Joined: Wed Jul 04, 2012 11:21 pm
- Location: Greece
- Has thanked: 51 times
- Been thanked: 19 times
Re: Modify single 7 Segment LED
Hello, after some testing with 7seg component on hardware, i found that in order to display a custom character correctly you have to define the status for all segments using output component. For example if we want to display letter 'C' (on a common anode 7seg display), we simply use the output component as follows:
1. Output component to enable common pin(HI)
2. Output component to set A segment (Low)
3. Output component to set B segment( Hi)
4. Output component to set C segment (Hi)
5. Output component to set D segment (Low)
6. Output component to srt E segment (Low)
7. Output component to set F segment (Low)
8. Output component to set G segment (Hi)
9. Output component to set DP segment (Hi)
I hope this helps anyone that will come across this.
Thank you all for help.
1. Output component to enable common pin(HI)
2. Output component to set A segment (Low)
3. Output component to set B segment( Hi)
4. Output component to set C segment (Hi)
5. Output component to set D segment (Low)
6. Output component to srt E segment (Low)
7. Output component to set F segment (Low)
8. Output component to set G segment (Hi)
9. Output component to set DP segment (Hi)
I hope this helps anyone that will come across this.
Thank you all for help.