Is there an easy way in electronics workbench to generate a random 4-digit binary input?

KingNothing

Diamond Member
Apr 6, 2002
7,141
1
0
I'm creating a math circuit using 5 8-1 multiplexers that's supposed to take two 4-digit binary inputs and do the AND, OR, NOT, add, and subtract operations on them. The multiplexers determine which function gets outputted.

Is there a better way to create the 8 inputs (2 sets of 4) than a Vdd source and 8 switches?
 

element

Diamond Member
Oct 9, 1999
4,635
0
0
That's one way to do it (switches). Another way is with microcontroller, probably overkill to do it with a microcontroller though unless you need to test a lot of variations of something, but then how many variation can you have of 2 4 digit binary anyway? 2^8? or is it 2^4 * 2 or something...I dunno but you get the idea.
 

KingNothing

Diamond Member
Apr 6, 2002
7,141
1
0
Originally posted by: element®
That's one way to do it (switches). Another way is with microcontroller, probably overkill to do it with a microcontroller though unless you need to test a lot of variations of something, but then how many variation can you have of 2 4 digit binary anyway? 2^8? or is it 2^4 * 2 or something...I dunno but you get the idea.

Is there a microcontroller in EW 5.12? I don't see it in the list.
 

element

Diamond Member
Oct 9, 1999
4,635
0
0
Oh you're doing this in electronics workbench? I thought you were actually creating the circuit in hardware. I doubt EW has a microcontroller. I guess just setting each bit high or low is your only choice then.
 

Yomicron

Golden Member
Mar 5, 2002
1,735
1
81
I've never used EW, but is it possible to make clocks? and view waveforms of the inputs/outputs?

If you can then put one clock on each input, make the period of the second input 2 twice as long as the first, the third as long as the second and so on and so forth. That way you will have all possible combinations tested.
 

element

Diamond Member
Oct 9, 1999
4,635
0
0
wow I just noticed that the thread title mentions EW. Hadn't noticed that before, dammit ....must...pay....attention....



ten hut!