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 » Lunettas - circuits inspired by Stanley Lunetta
LEDIL for Lunettas
Post new topic   Reply to topic Moderators: mosc
Page 1 of 1 [13 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Author Message
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Tue Jul 21, 2009 6:49 am    Post subject: LEDIL for Lunettas
Subject description: Light Emitting Diode Inverter Logic
Reply with quote  Mark this post and the followings unread

Hello fellow Lunetta heads,

Sometime soon, perhaps next month, I would like to buy the parts I need and construct a Boolean Sequencer Lunetta using what we might call LEDIL - Light Emitting Diode Inverter Logic. Basically it's DTL (Diode Transistor Logic) from the wayback machine with a twist.

The twist is that I'd like to use LEDs instead of diodes in DTL, and also use the more modern approach of replacing the inverting transistor circuit with a CMOS inverter. So without drawing a picture, here is a description of a two-input NAND gate:

Input A goes to a resistor in series with the anode of an LED, Input B to another such resistor-diode input branch, and the cathodes are tied together where a resistor acts as a pull-down. The cathode node is connected to the input of a CMOS inverter, whose output is the output of the NAND gate.

For a NOR gate, reverse the direction of the diodes. Add as many inputs as you want - though pull-down resistor value may depend on the number of inputs, I don't know for sure yet.

I plan to build a Lunetta / EChucK Boolean Sequencer using this LEDIL logic. It might be cool for a DIY logic family because every logic input is indicated by the LEDs, which for my purposes will probably be bar graph LEDs. Rather than go straight to a circuit board, this time I'm going to prototype it on a breadboard (duh).

So what do you think? Surely this has been done by others, does anyone know of some examples?

Les

_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
DGTom



Joined: Dec 08, 2008
Posts: 211
Location: Adelaide
Audio files: 3
G2 patch files: 1

PostPosted: Tue Jul 21, 2009 6:01 pm    Post subject: Reply with quote  Mark this post and the followings unread

Very cool idea! I might have to try this with something I've been messing with where I only need two logic functions.

I sometimes use LEDs when breadboarding just to quickly see if something works & I don't have any other diodes to hand, never occured to me to expand on it. Thanks for the inspiration Very Happy
Back to top
View user's profile Send private message
sizone



Joined: Jun 09, 2009
Posts: 132
Location: Honolulu HI
Audio files: 48

PostPosted: Tue Jul 21, 2009 6:19 pm    Post subject: Reply with quote  Mark this post and the followings unread

My lack of a background may hurt your more than help them, but I've been dealing with a number of the same things as your proposed circuit.
Here's the doubts/heads-ups I've run across.
The diode OR: The output I get when connecting together two signals, each through it's own diode, depends -strongly- on the frequency and amplitude of the two signals. My current set-up using 4148s, for example, when tying two signals of similar amplitude and frequency together, I get a rough summing of the signals. But a high-amplitude, low frequency pulse and lower amplitude, higher frequency signal gets me the audio rate signal rising in amplitude according to the frequency of the pulse signal. Putting a pull-down resistor on the output keeps the amplitude of the higher signal steady, but isn't enough (at least not in my ridiculous example) to keep the signal from gating on and off.
Regarding the use of an inverter to get a NAND output: Using the combined output of the cathode end of the inputs results in, as far as I can tell, an OR function (at least at the audio range, (it may be working as an AND gate, just switching fast enough to seem like an OR) again, unless one of the signals is significantly more powerful than the other, in which case it functions as a sort of AND). So inverting that output gives you a NOR out, not a NAND out.

Here's an audio demo of what I mean.
First is an audio signal and a slow pulse for inputs. First without the pull-down then with. Second is just the audio signal, then a second audio signal added for a second input.


inventexp.mp3
 Description:

Download
 Filename:  inventexp.mp3
 Filesize:  317.86 KB
 Downloaded:  424 Time(s)

Back to top
View user's profile Send private message
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Tue Jul 21, 2009 6:50 pm    Post subject: Reply with quote  Mark this post and the followings unread

Ty DGTom, done properly it might be kind of kewl for simple logic funtions.

sizone, you must be right, I reversed the NOR and NAND diode directions, duh. That's what I get for typing out loud and not methodically thinking something through. Also I just realized that if the diodes are reversed, the pull-down must be changed to a pull-up.

I don't really follow what you are saying about circuits without the pulldown resistor, it seems kind of necessary to me. The inverter is necessary if we want to chain logic together in series, ie in my case some NAND gates that are then all NANDed together, so two layers of logic. This is to prevent signal degradation.

Further, sizone, what values of supply voltage and resistance were you using? It's kind of important to make sure that the supply voltage is large enough that the LED voltage drop becomes well below 50% of the supply voltage, I would think. A 5V supply might not do that, I forget the diode drop of the various color LEDs - will have to dig that up.

Les

_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
sizone



Joined: Jun 09, 2009
Posts: 132
Location: Honolulu HI
Audio files: 48

PostPosted: Tue Jul 21, 2009 8:56 pm    Post subject: Reply with quote  Mark this post and the followings unread

I'm not running your exact set up (no leds, for instance, just 4148s). I guess the pull-down function is, in a sense, being accomplished by the audio connector's ground connection.
Be careful if you're using inversion as a sort signal clarification. I've found there can be a lot of unexpected asymmetry between the input and the expected inverted output (with my use of the 4069 at least). Examples:

Duty cycle

....''....''

''''..''''..


voltage (without attenuation or input buffering)

In= 0v
Inverted out= more-or-less supply v
(that's expected, but compare to the next one)

In=CV (say 0->2v)
Inverted out= a swing higher than CV (say 4v-> 0v)

Regarding my setup, it's 9v single supply in this case. The difference in the first part of the audio example is the addition of a 100k resistor between the out and ground.
The audio rate osc. is putting out about 0->2.5 volts. The pulse generator is putting out about 0->5 v. What I'm trying to draw attention to is that what I'm using as a signal source is, in my case at least, sufficient to alter the functioning of the "gate". When two audio signals are used (both roughly 0-2.5 v) the audible effect on the output is that of summation, -very- similar to an OR function (only false when no input is present) only not in a strict logic sense. The "truth table" for the output of the diode OR gate is this:

in 1 =signal 1
in 2=0v
out=signal 1

in 1=0v
in 2=signal 2
out= signal 2

in 1=signal 1
in 2= signal 2
out= signal 1 and signal 2, both slightly attenuated.

I won't bother going through what happens when there's no input on either channel. Briefly, this is working just like an OR gate should with the caveat that what you put in determines what you get out (in the ideal, all inputs consist of only one of two possible states, so the output in the last example should just be "on", "on1 + on2" is kind of a non-sequitor, but that's also exactly what the output stage consists of. Thank you Uncle Krunkus, I'm starting to see the light.)

Using the stronger pulse out in conjunction with an audio out, the pulse out (when it's high) is enough to cancel out the audio input. So the "truth table" for the OR gate when one input is a lower signal strength audio signal and the other input is a higher signal strength pulse is this:

in1=pulse (high)
in2=0v
out= pulse (high)

in1=pulse (low)
in2=CV
out=CV

in1=pulse (high)
in2=CV
out=pulse (high)

How to interpret this?
Something to note: A steady current of 0v "sounds" pretty much identical to a steady current at any other voltage. So what looks like an "on" state to the eye (the corresponding LED is lit up) may sound like an "off" to the ear (no audio output). How this gate is functioning could be considered dependent on -what- form of its output you're paying attention to.
Visually, it's still working like a normal OR gate (I misspoke somewhere in the last post as I thought the pulse being low was what was suppressing the audio out, causing me to confuse it for an AND gate) assuming your clocks are slow enough for it keep pace with.
In audio terms, the result's a bit harder to interpret as the status of high and low for the pulse generator is indifferent to our ears. Only the switch between states really matters.
On one interpretation it's acting as (I don't have the proper terminological jargon for it) a sort of input biased XOR gate. That is, you get either signal 1 or signal 2, but not both at the same time and signal 1 has priority. Were it a proper XOR gate, both the inputs being active should give a null output.
On the other interpretation, it's working exactly like an XOR gate should. As the first input is inaudible, when both inputs have signal the gate is, in audio terms, "off". The problem with both of these interpretations is that neither have a proper way of classifying what's going on when there's an inaudible, but present, current on the output.

I apologize for the next bit. It's ridiculously simple, but it's also so simple that I totally overlooked at first.

For a digital logic circuit this is "on"

----
***

and this is "off"
___
***

But to our ears, both of those are "off" and this is "on"

_--_--_--_
*********

So....Oh, wait. You're building a sequencer (where's the head-smacking emoticon when you need it?). I guess this still applies if it's generating an analog output. Otherwise, never mind, but you may find the duty cycle inversion to be useful.

You may want to consider ditching the idea of using diodes for AND gates and just pick up some 4081s. I don't know how good of an idea hooking the output of your clock to your supply rail is (unless you designed your clock sources accordingly).
OR gates for sequencer logic would seem pretty much useless (I guess my earlier ramblings did serve some point).
Back to top
View user's profile Send private message
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Tue Jul 21, 2009 10:22 pm    Post subject: Reply with quote  Mark this post and the followings unread

sizone, thank you for your detailed explanation. I would imagine that a 100 kOhm resistor to ground would be too large, I'd prefer to see something in the neighborhood of 1 kOhm or so for a 9V supply.

In the situation in which I am considering the use of this logic, the inputs will be from a CMOS counter running at supply voltage, so I'll have rail-to-rail inputs. Therefore issues like summation node voltage being in the neighborhood of the logic threshold of the inverter will not be present.

There is a bit of a flaw to this concept that comes to mind. The more inputs that are on, the dimmer the LEDs will be. This is because more inputs will drive more current into the pull-up / pull-down resistor, causing more voltage drop accross it. I'm not quite sure how to fix that, but definitely something interesting is in order here...

Thanks for your helpful testing, together we can figure out how to make this work I suppose...

Les

_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
droffset



Joined: Feb 02, 2009
Posts: 508
Location: London area
Audio files: 2

PostPosted: Tue Jul 21, 2009 11:04 pm    Post subject: Reply with quote  Mark this post and the followings unread

Glad to see you getting into this Les, wil be watching the progress.

I'm also curious to see what twisted things you'd make from a fistful of CMOS ICs. Smile
Back to top
View user's profile Send private message Visit poster's website
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Wed Jul 22, 2009 1:52 am    Post subject: Reply with quote  Mark this post and the followings unread

droffset wrote:
Glad to see you getting into this Les, wil be watching the progress.

I'm also curious to see what twisted things you'd make from a fistful of CMOS ICs. Smile


Thanks droffset. Wouldn't you just know it, I happened to find a fistful of CMOS ICs when I went through my old parts yesterday. I mean, some of those chips were purchased when I was in college 20 years ago. The rubber bands holding them in the static tubes had hardened and were brittle even.

About LEDIL, I have some more thoughts. The first is that the inverter could be replaced with a current mirror - sounds strange, but it would solve the problem of LEDs getting dimmer when more of them are on. I'll have to post a schematic of it.

Also in my case I'm looking at 8 to 12 inputs on up to six NAND gates, and the current will add up to quite a lot for the brief instant that all the LEDs are on - like up to half an amp total for the board! Fortunately this won't happen very often so I just have to make sure the components can take it instantaneously.

I think I'll go draw something up for this...

Les

_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Wed Jul 22, 2009 2:40 am    Post subject: Reply with quote  Mark this post and the followings unread

OK, shown below are two proposed LEDIL circuits using current mirrors. If either input is active, the current mirror turns on, driving a logic output from the output transistor. If not, the output resistor drives the opposite state.

This solves the problem of the diodes dimming when more than one diode is on. It does have a fanout limitation of one, and the following stage must either have a resistor or not depending on whether it's a NOR or a NAND. So care must be taken when chaining logic. For fanout greater than one, add an inverter to the output (or two depending on if you want inversion).

If you have some logic in your circuit, your supply is +9V or more, and you want to have LEDs on your inputs *anyway*, then this simple logic family might be a good choice. Certainly in my case where I want 10 inputs to 4 NAND gates that then all get NANDed together, it will simplify layout and prevent a more complex logic arrangement.

Les


LEDIL1.jpg
 Description:
Proposed LEDIL Circuit
 Filesize:  25.76 KB
 Viewed:  297 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

LEDIL1.jpg



_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
DGTom



Joined: Dec 08, 2008
Posts: 211
Location: Adelaide
Audio files: 3
G2 patch files: 1

PostPosted: Wed Jul 22, 2009 3:13 am    Post subject: Reply with quote  Mark this post and the followings unread

wheres the high five smiley!? anyway *high five*

I will give this a go tonight if I can shake this headache induced by "oh those can't possibly be shorting, that can't be it" (an hour or two later) "BLOODY HELL THEY WERE SHORTING!!!!"

this looks great for my uses, 9V; check. LEDs on the inputs; check. Don't really need 4 NANDs/NORs; check. Very Happy
Back to top
View user's profile Send private message
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Wed Jul 22, 2009 4:58 am    Post subject: Reply with quote  Mark this post and the followings unread

Thanks for the ^5, DGTom! I am a little bit excited about this too.

I thought about the current mirror, and basically it is being used as a switch. So I imagined putting an LED in place of the first transistor. This has the benefit of providing an output indicator. It might not work, or maybe it might need a resistor in series with and possibly in parallel with the added diode.

That's because without it, the output indicator receives a different amount of current depending on how many logic inputs are active. Then again, that could be a good thing because the output indicator then becomes analog in nature, displaying discretely the number of inputs that are active. Actually I kind of like that concept.

If the output LED were a higher brightness than the input LEDs, then it could handle the extra current even for my case of four to ten inputs. This little concept is getting more and more interesting as we go...

Les


LEDIL2.jpg
 Description:
Another proposed LEDIL circiut
 Filesize:  20.36 KB
 Viewed:  268 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

LEDIL2.jpg



_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Wed Jul 22, 2009 7:10 am    Post subject: Reply with quote  Mark this post and the followings unread

The attached circuit shows a 2x2 version of what I would like to build in 10x6 to create the Boolean Sequenced Guitar beginner DIY project board. The input is a two-bit counter, the product output is the logic result, and the sum output is the analog result.

The idea is to clock a decade counter as the input, have six switch selectable logic terms of 10 bits each, and drive the Karplus-Strong string synthesis circuit with the product and sum terms. This creates a Boolean Sequencer that plays a guitar sounding output.

You'll notice that the second stage requires no input resistors because the pulldown resistor of the previous stage limits the current. The sum term will vary from 0 to Vcc or so as the sum of the number of inputs which are active.

The product term will drive a short burst of noise pulsed by a 555 one-shot into the KS circuit to start a note. The sum term will drive a VCO that clocks a delay line, thus controlling the frequency of the note. The output of the KS circuit will go into an LM386 amplifier to drive a speaker.

I hope, if I can get it all to work, that this might be a really cool noisemaker project for DIY.

Les


LEDIL3.jpg
 Description:
A complete LEDIL Boolean Sequencer
 Filesize:  39.45 KB
 Viewed:  316 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

LEDIL3.jpg



_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Sun Jul 26, 2009 5:40 pm    Post subject: Reply with quote  Mark this post and the followings unread

Just FYI, I prototyped the LEDIL NAND gate and it worked just fine at DC. Output levels were nearly to the rail, LEDs working, logic function correct, etc.
_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic Moderators: mosc
Page 1 of 1 [13 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 » Lunettas - circuits inspired by Stanley Lunetta
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
e-m mkii

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