"Degree" char in seven_segment.jal

21 views
Skip to first unread message

funlw65

unread,
Jul 26, 2010, 11:43:42 AM7/26/10
to jallib
Hi Joep,

We don't have a "degree" char in seven_segment.jal library as here:
http://www.youtube.com/watch?v=Rp6EWOtN2PI

Vasi(funlw65)

funlw65

unread,
Jul 26, 2010, 12:14:40 PM7/26/10
to jallib
Also, here can be "J" char, from Joep :) (because I want to scrool
text "Hello JOEP" on 4 digit seven_segments using your library -
"LibrArY" :P )

funlw65

unread,
Jul 26, 2010, 12:18:22 PM7/26/10
to jallib
And also "N" char...

Joep Suijs

unread,
Jul 26, 2010, 12:24:45 PM7/26/10
to jal...@googlegroups.com
Hi Vasi,

I guess there can be 127 different chars. Feel free to add the ones you like.

Joep

2010/7/26 funlw65 <fun...@gmail.com>:

> --
> You received this message because you are subscribed to the Google Groups "jallib" group.
> To post to this group, send email to jal...@googlegroups.com.
> To unsubscribe from this group, send email to jallib+un...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/jallib?hl=en.
>
>

funlw65

unread,
Jul 26, 2010, 12:26:54 PM7/26/10
to jallib
Of course, also Vasile's library but I started from your example.
Sorry for omission.
Vasi(funlw65)

P.S. It is possible also "T" char? Of course, I can extend the library
for my needs but is better to have them for everybody if
modifications. are useful.

funlw65

unread,
Jul 26, 2010, 12:27:19 PM7/26/10
to jallib
Ok then!

On Jul 26, 7:24 pm, Joep Suijs <jsu...@gmail.com> wrote:
> Hi Vasi,
>
> I guess there can be 127 different chars. Feel free to add the ones you like.
>
> Joep
>
> 2010/7/26 funlw65 <funl...@gmail.com>:

Joep Suijs

unread,
Jul 26, 2010, 1:20:48 PM7/26/10
to jal...@googlegroups.com
> Of course, I can extend the library
> for my needs but is better to have them for everybody if
> modifications. are useful.

My suggestion would be to extend the library and add the improved
library to jallib.

Joep

Sunish Issac

unread,
Jul 26, 2010, 1:33:33 PM7/26/10
to jal...@googlegroups.com
How about having a function to pass value as ascii instead of some number ? Have a function like sevenfromascii("A") prints A or "1" prints 1, i would be easier to use as the seven_seg.. file need not be reffered to.

Sunish

vasile surducan

unread,
Jul 27, 2010, 3:49:10 AM7/27/10
to jal...@googlegroups.com
   For 7 seg display: celsius degree, J and n are OK and should be added, however you can't have a real t...
About sevenfromASCII, may be good if all non numbers will be ASCII, except the hexa simbols (0-F)...

Vasile

funlw65

unread,
Jul 27, 2010, 3:37:36 PM7/27/10
to jallib
"T" can be like this (and it looks quite nice on "THIS" word):

-- __
-- /
-- /
--

And I have a proposal for the comment from the library header - to
include this:
"
.................................................................................
-- Description: Translation routine for 7 segment display.
-- --
-- The seven segment display needs to be connected to a single port.
-- Define the pin layout of the seven segment display like:
-- _a_
-- / /
-- f b
-- / /
-- _g_
-- / /
-- e c
-- / /
-- _d_
--
-- -- constant for the segments gfe dcba
.............................
"

And, in general, maybe is of some use this utility:
http://www.tech-chat.de/download.html

Vasi(funlw65)

funlw65

unread,
Jul 27, 2010, 7:03:18 PM7/27/10
to jallib
Hi,

Apologies if this was discussed... but the code 25 is reserved in
library?

Vasi(funlw65)

vasile surducan

unread,
Jul 28, 2010, 1:55:30 AM7/28/10
to jal...@googlegroups.com
On Wed, Jul 28, 2010 at 2:03 AM, funlw65 <fun...@gmail.com> wrote:
Hi,

Apologies if this was discussed... but the code 25 is reserved in
library?

No, it's just missing by mistake. 

Vasi(funlw65)

vasi vasi

unread,
Jul 28, 2010, 2:42:11 PM7/28/10
to jal...@googlegroups.com
Hi Joep and Vasile,

This is the scrolling text:
"HELLO JOEP And VASILE _ THIS USE Your LibrArY"

http://www.youtube.com/watch?v=RatJm6wGxpI

I wanted to learn how to use 4 digits as a decent display and for this, I used also timer0_isr_interval.jal (to light another 8 LED's at different speed) because I don't know yet another method of "multitasking".
I use FreeJALduino with EvB 4.3 version 4 board (with already bricked ATmega :( ) and entire assembly draws very much current, the onboard 5V regulator gets very very HOT. An external source of 5V is obligatory for this kind of application.
Anyway, the conclusion is: It is too much trouble and too many pins allocated for this task. It require a separate microcontroller for this and in this case, you can transmit data on serial. For 4 digits and 8 LEDs I used all available pins on FreeJALduino and the DOT from digits remained unconnected. But the experience gained is invaluable.

The segments get lighted on 0 logic and also digit selection is made with 0 logic (I don't know how to draw a schematic for this). The LED's are lighted also on 0 logic (this is easy, but program inside is for 1 logic - I must negate the byte). In the movie, the digits are lighted one at the time, 350uS long each but I modified the program for 950uS each to get rid of that echo. If is useful, I think it can be easily modified for Jaluino. All required files attached.
--
Vasi
freejalduino4.jal
seven_segment.jal
scroll_on_seven_seg.jal

Florin Tanasa

unread,
Jul 28, 2010, 2:58:57 PM7/28/10
to jal...@googlegroups.com
Hi Vasi,
I like what you done.

2010/7/28 vasi vasi <fun...@gmail.com>

--

funlw65

unread,
Jul 28, 2010, 3:03:03 PM7/28/10
to jallib
Multumesc! - Thank you!

On Jul 28, 9:58 pm, Florin Tanasa <florin.tan...@gmail.com> wrote:
> Hi Vasi,
> I like what you done.
>
> 2010/7/28 vasi vasi <funl...@gmail.com>
> > jallib+un...@googlegroups.com<jallib%2Bunsu...@googlegroups.com>
> > .

vasile surducan

unread,
Jul 28, 2010, 3:28:39 PM7/28/10
to jal...@googlegroups.com
On Wed, Jul 28, 2010 at 11:42 AM, vasi vasi <fun...@gmail.com> wrote:
Hi Joep and Vasile,

This is the scrolling text:
"HELLO JOEP And VASILE _ THIS USE Your LibrArY"

http://www.youtube.com/watch?v=RatJm6wGxpI

Oh boy, you are a rested (hodinit) guy too...:)


I wanted to learn how to use 4 digits as a decent display and for this, I used also timer0_isr_interval.jal (to light another 8 LED's at different speed) because I don't know yet another method of "multitasking".
I use FreeJALduino with EvB 4.3 version 4 board (with already bricked ATmega :( ) and entire assembly draws very much current, the onboard 5V regulator gets very very HOT. An external source of 5V is obligatory for this kind of application.
Anyway, the conclusion is: It is too much trouble and too many pins allocated for this task.
 
:)
   search on the internet for "gugaplexing", "charlieplexing" and other "plexing" methodes...

 
It require a separate microcontroller for this and in this case, you can transmit data on serial. For 4 digits and 8 LEDs I used all available pins on FreeJALduino and the DOT from digits remained unconnected. But the experience gained is invaluable.

The segments get lighted on 0 logic and also digit selection is made with 0 logic (I don't know how to draw a schematic for this). The LED's are lighted also on 0 logic (this is easy, but program inside is for 1 logic - I must negate the byte). In the movie, the digits are lighted one at the time, 350uS long each but I modified the program for 950uS each to get rid of that echo. If is useful, I think it can be easily modified for Jaluino. All required files attached.

Vasi, this is calling "ghosting". I've written an article about this problem but right now is in evaluation at the IEEE-Micro magazine, maybe they will reject it too, so you'll see it on my blog.... (I really hope not).
In a few words: as you can see from your movie, even taking a photo or a movie to a multiplexed display is a difficult task. Depending how display is routed to the PIC IO, there will be a ghosting situation, except if using standalone 7seg drivers between the PIC and display.
The reason is the variable voltage level on pins when they are used as input (pseudo high impedance or highZ, PIC/Atmel does not have a true highZ output circuit as old logic buffers have). A LED connected between two input pins of a PIC will light, and this is ghosting caused by un-fixed voltage level (if all highZ would have for example the theoretical VDD/2 voltage level fixed -used in all drawings-, that would not happen). The second cause of a ghosting is a bad timing multiplexing. Switch from one segment to another using highZ (meaning input), switch from one anode(cathode) to another anode(cathode) through an OFF state.
The time which one display lights gave the overall current drawn. A good choice is 1mS to 3mS for standard display, less than 1mS for high efficiency display. Between switching a shut OFF time of 50-100uS is reasonable.

Vasile






funlw65

unread,
Jul 28, 2010, 3:56:47 PM7/28/10
to jallib
Thank you for valuable info. I think all of this (completed whit what
is missing) can be part of Jallib and Jaluino documentation to avoid
reinventing the wheel...

On Jul 28, 10:28 pm, vasile surducan <vsurdu...@gmail.com> wrote:

funlw65

unread,
Jul 28, 2010, 8:08:23 PM7/28/10
to jallib
I found the schematic for the digits (is an older version but I think
it still fits):
http://and-tech.pl/EvB4.3/schemat.png

The movie posted earlier does not reflect the last changes included in
the uploaded program. I reduced a little the "ghost" effect and moved
it above displayed character, in the scroll direction so, it is less
disturbing.
http://www.youtube.com/watch?v=DRSEFmG8M0E

vasi vasi

unread,
Jul 28, 2010, 9:30:10 PM7/28/10
to jal...@googlegroups.com
"A good
choice is 1mS to 3mS for standard display, less than 1mS for high efficiency
display. Between switching a shut OFF time of 50-100uS is reasonable. "

Yes, I can confirm, I have better results with 1.5ms displaying time on each digit:
http://www.youtube.com/watch?v=AdyRymK48JI

File attached.
scroll_on_seven_seg.jal

vasi vasi

unread,
Jul 28, 2010, 10:14:49 PM7/28/10
to jal...@googlegroups.com

ZERO "ghost" with this procedure:

Pseudocode:

- Put "space" code on buffer (this mean all segments are off)
- activate the current digit (the others are off in this moment)
- put the "real" character on buffer so will appear "instantly" on digit
- keep the digit lighted for 1.5ms

File attached
--
Vasi
scroll_on_seven_seg.jal

vasi vasi

unread,
Jul 28, 2010, 10:45:15 PM7/28/10
to jal...@googlegroups.com
Sorry, this is the correct file
--
Vasi
scroll_on_seven_seg.jal

vasile surducan

unread,
Jul 29, 2010, 2:46:41 AM7/29/10
to jal...@googlegroups.com
Whow, I didn't realize it can be written in this way, this is a good example for using two libraries...

--
You received this message because you are subscribed to the Google Groups "jallib" group.
To post to this group, send email to jal...@googlegroups.com.
To unsubscribe from this group, send email to jallib+un...@googlegroups.com.

funlw65

unread,
Jul 29, 2010, 9:32:49 AM7/29/10
to jallib
Yes, this is why I appreciate so much this "multitasking" library of
Joep. On Arduino, an alternative is "millis()" function.

On Jul 29, 9:46 am, vasile surducan <vsurdu...@gmail.com> wrote:
> Whow, I didn't realize it can be written in this way, this is a good example
> for using two libraries...
>
> On Thu, Jul 29, 2010 at 5:45 AM, vasi vasi <funl...@gmail.com> wrote:
> > Sorry, this is the correct file
>
> > On Thu, Jul 29, 2010 at 5:14 AM, vasi vasi <funl...@gmail.com> wrote:
>
> >> ZERO "ghost" with this procedure:
>
> >> Pseudocode:
>
> >> - Put "space" code on buffer (this mean all segments are off)
> >> - activate the current digit (the others are off in this moment)
> >> - put the "real" character on buffer so will appear "instantly" on digit
> >> - keep the digit lighted for 1.5ms
>
> >> File attached
> >> --
> >> Vasi
>
> > --
> > Vasi
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "jallib" group.
> > To post to this group, send email to jal...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > jallib+un...@googlegroups.com<jallib%2Bunsu...@googlegroups.com>
> > .
Reply all
Reply to author
Forward
0 new messages