electro-music.com   Dedicated to experimental electro-acoustic
and electronic music
 
    Front Page  |  Articles  |  Radio
 |  Media  |  Forum  |  Wiki  |  Links  |  Store
Forum with support of Syndicator RSS
 FAQFAQ   CalendarCalendar   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   LinksLinks
 RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in  Chat RoomChat Room 
 Forum index » DIY Hardware and Software
Using a numeric LED display to show program number
Post new topic   Reply to topic Moderators: jksuperstar, Scott Stites, Uncle Krunkus
Page 1 of 1 [10 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Author Message
gmeredith



Joined: Jun 28, 2006
Posts: 82
Location: Tasmania, Australia
Audio files: 1

PostPosted: Tue Jul 25, 2006 9:46 pm    Post subject: Using a numeric LED display to show program number Reply with quote  Mark this post and the followings unread

I was hoping someone could point me in the right direction here. I want to make a 2 digit LED display, to show a program number on a synth, from 1 to 16.

Here's the story: I am expanding the memory on my Casio SK8 sampler to 16x, using a large capacity RAM chip, with 16x the capacity of the old one. So it will now have 16 banks of sample storage.

The new RAM chip has 4 extra address lines (ie. 32 pins) than the old one (28 pins). Applying +5V to any one of these pins activates a certain bank of memory. So having 4 pins gives 2 ^EXP4 = 16 combinations of active pins, or memories. These can be manually accessed by using 4 on/off switches in the 16 possible combinations.

I want to connect a digital LED readout circuit to this bank of 4 switches somehow, so that the display will show each different combination, or memory bank, as a number from 1 to 16. Perhaps using 2 of these:

click here

I have seen this on these types of expansions before, although instead of using 2 LED digits, it only used 1, and it read in hexadecimal format. I would rather have 2 digits in decimal format, but even in hexadecimal/1 digit would be better than nothing. How is this sort of thing done?

Cheers, Graham
Back to top
View user's profile Send private message
ian-s



Joined: Apr 01, 2004
Posts: 2565
Location: Auckland, New Zealand
Audio files: 42
G2 patch files: 601

PostPosted: Tue Jul 25, 2006 11:11 pm    Post subject: Reply with quote  Mark this post and the followings unread

you could use a 4511 7 Segment decoder on the least significant bits. The msb could go direct to the Decimal place (or a dedicated 1 digit) so you have 2 banks of 8.
Might be too much like octal though Rolling Eyes
Back to top
View user's profile Send private message
Yorky



Joined: Feb 14, 2005
Posts: 244
Location: Boston, UK

PostPosted: Tue Jul 25, 2006 11:12 pm    Post subject: Reply with quote  Mark this post and the followings unread

http://www.allaboutcircuits.com/vol_6/chpt_7/9.html
Back to top
View user's profile Send private message
gmeredith



Joined: Jun 28, 2006
Posts: 82
Location: Tasmania, Australia
Audio files: 1

PostPosted: Tue Jul 25, 2006 11:39 pm    Post subject: Reply with quote  Mark this post and the followings unread

Hey guys!

Thanks! That's just the sort of thing I'm looking for! I'll study it more carefully and see how it goes.

Cheers, Graham
Back to top
View user's profile Send private message
State Machine
Janitor
Janitor


Joined: Apr 17, 2006
Posts: 2730
Location: New York
Audio files: 23

PostPosted: Sun Jul 30, 2006 9:00 am    Post subject: Reply with quote  Mark this post and the followings unread

If you have a PROM burner handy, I would use an 82S123 32x8 PROM as a look up table to translate the 4-bit binary to a BDC format. Just draw up a truth table and burn away. The PROM (D0-3) would be the LSD and (D4-D7) would be the MSD. Since you are only displaying 0 to 16, these outputs would then feed only one BDC to 7-SEGMENT decoder IC. The MSD nibble can just be simply a bit on the PROM's D4 output that goes high when any number at it's address inputs is >9 (10d-16d would be "0001b" on [D7-D4]). This would be hardwired and just illuminate segments b & c of the MSD 7-segment display to form the numeral "1". No decoder required for that

Here is the link to to the data sheet of the PROM chip. If you supply me with a truth table of what you want, I will burn one for you (I have a number of these IC's laying around) and send it to you. Just PM me if you want. You just would pay for the cost of shipping, no cost for the PROM Very Happy

http://www.jameco.com/wcsstore/Jameco/Products/ProdDS/27764.pdf


Bill
Back to top
View user's profile Send private message Send e-mail
jksuperstar



Joined: Aug 20, 2004
Posts: 2478
Location: Denver
Audio files: 1
G2 patch files: 18

PostPosted: Sun Jul 30, 2006 9:47 am    Post subject: Reply with quote  Mark this post and the followings unread

This isn't directly related to your problem, but I thought I'd post it so it makes it into the forum for someone else who might need it, before I forget about it, since I just read it the other day.

If you are low on pins for your microcontroller, you can use a circuit like this:
http://www.elecdesign.com/Articles/ArticleID/12896/12896.html

It basically has 1 signal that the uC pulses...or counts up the number you want to display. A longer pulse generates a reset, to clear the dislay so you can start over. You could omit this part of it, and just keep the number your displaying in local memory, and just count internally accounting for the roll-over from 16 ->0, and adjust the count of pulses sent out via that.
Back to top
View user's profile Send private message Visit poster's website
State Machine
Janitor
Janitor


Joined: Apr 17, 2006
Posts: 2730
Location: New York
Audio files: 23

PostPosted: Sun Jul 30, 2006 1:00 pm    Post subject: Reply with quote  Mark this post and the followings unread

Quote:
It basically has 1 signal that the uC pulses...or counts up the number you want to display. A longer pulse generates a reset, to clear the dislay so you can start over. You could omit this part of it, and just keep the number your displaying in local memory, and just count internally accounting for the roll-over from 16 ->0, and adjust the count of pulses sent out via that.


Good technique! I like that Very Happy For Graham's solution, a small inexpensive MCU can read in the 4-bit binary address, do the conversion and drive the 7-Segment display all in the same chip!

Graham, I am not what your resources are so one hardware and one hardware/firmware approach is what I can offer you. If you use the PROM decode technique and use the common anode displays, you should use the 74LS47 decoder IC to drive the segments since they are active low. Anyway, both solutions involve programming some IC of some type unless you build a decoder entirely from some combinatorial logic circuit. OK, break out those "Veitch diagrams" ! Shocked

Bill
Back to top
View user's profile Send private message Send e-mail
gmeredith



Joined: Jun 28, 2006
Posts: 82
Location: Tasmania, Australia
Audio files: 1

PostPosted: Sun Jul 30, 2006 6:45 pm    Post subject: Reply with quote  Mark this post and the followings unread

Thanks guys, for the wealth of information! I guess what I have to sort out now is which path to take. Over the weekend I've been thinking more about this. I want to do something more elegant than just a mechanical 4-bit binary switch (which is what I'm starting with, just to get the memory expansion working). I'm now leaning towards this:

Having a 2 digit LED display, showing 16 true numbers instead of hexadecimal numbers, and just an up button and a down button that you press to scroll through the different memories, such as 2 momentary pushbutton switches. I could then make something really classy looking and almost flush with the surface if I choose my switches carefully.

There has also been a slight change to my plans. Since posting the original post, i've found a bigger chip that has 32x memory capacity. It is basically the same chip but with 1 extra address pin. I've ordered this one, and it's on it's way. I've attached the datasheet if anyone needs to look at it.

However, this still can operate in the same way as the other scenario, I can just have a toggle "bank switch" to switch on the extra address line. That will give me 2 banks of 16 memories then. So the 16 memory banks part of it is still the same as the original request. Unless you can steer me on how to use this to display 32 memories as real numbers, and up/down buttons to scroll. That would be the ants pants Very Happy

Let's start with 16, just to make it less confusing, say.

Firstly, the display side of it.
If I were to control the 16 memories in a given bank with up/down buttons, then for the display, would I use an up/down decimal counter, and a multiplexer to drive the decoders, and a 2 digit display?

That being the case, now about the actual switch for the address pins.
I presume I could use the electronic equivalent of a 4-bit binary switch, such as some latching IC? Is there such a device?

Now, how would I control it to output +5V to the 4 address pins, in binary order, to access each combination of on/off positions for each of the 16 memories, by using an up/down set of momentary switches (in fact, the same ones that are being used for the up/down on the display)?

Is my line of thinking correct? I can go so much simpler than this with the mechanical 4-bit rotary switch, but I wanted to do this as an exercise in elegance and cleverness. If this can be done, then it opens up the possibilities of making really good looking and easy to use displays for just about any device. You could have an analog synth with a bank of different resistors to control parameters, which can be switched, and displayed as a patch number

If only my abilities matched my imagination

Cheers, Graham


bq4016y 8MBit.pdf
 Description:

Download
 Filename:  bq4016y 8MBit.pdf
 Filesize:  876.3 KB
 Downloaded:  98 Time(s)

Back to top
View user's profile Send private message
jksuperstar



Joined: Aug 20, 2004
Posts: 2478
Location: Denver
Audio files: 1
G2 patch files: 18

PostPosted: Sun Jul 30, 2006 7:14 pm    Post subject: Reply with quote  Mark this post and the followings unread

Graham, if you really want a challenge, AND want this to be generic enough to start using elsewhere, than I suggest you try some simple microcontroller, such as an Atmel AVR, a PIC, or an 8051. These all have freely available tools, and would allow you, in 1 single chip (probably low pincount also), to read the switches, drive the 7-segment displays, as well as drive the memory selects or any other device you so choose. Alot more complicated than a simple display, or the switch, but also alot more felxible if you're looking for such a thing.

As far as clever & simple, I suggest a rotary 16 step encoder. It has the display & control all built in! My Electrix MoFX has one to select the MIDI channel. A cheap one will probably cost ~$5.
Back to top
View user's profile Send private message Visit poster's website
State Machine
Janitor
Janitor


Joined: Apr 17, 2006
Posts: 2730
Location: New York
Audio files: 23

PostPosted: Mon Jul 31, 2006 6:37 am    Post subject: Reply with quote  Mark this post and the followings unread

I agree with "jksuperstar" on this. Microcontrollers are really very elegant solutions for this type of design and are the best choice for technology "reuse". Just change a little code here and there for intended application. The best thing is that these handy controllers are cheap! There is however a learning curve when dealing with how to use these devices properly but once you get past this, you will be putting microcontrollers in lots of your new designs! They are fun to work with and with the new FLASH devices, you literally get INSTANT gratification by writing and testing your code in system within a seconds after compile time!

We hope this encourages you to pursue this fascinating part of electronic design.

Bill
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic Moderators: jksuperstar, Scott Stites, Uncle Krunkus
Page 1 of 1 [10 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
 Forum index » DIY Hardware and Software
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum
emSynth

Please support our site. If you click through and buy from
our affiliate partners, we earn a small commission.


Forum with support of Syndicator RSS
Powered by phpBB © 2001, 2005 phpBB Group
Copyright © 2003 through 2009 by electro-music.com - Conditions Of Use