Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Using analogue components to generate a random voltage to vary the time for capacitor charging

Status
Not open for further replies.

undelivered

New Member
Hi,

I am a student of EEE.

I want to generate a random voltage 0-6V to charge a capacitor for a reaction timer game I am designing only using simple analogue components. I need to vary the charging time of the capacitor randomly.

For learning, I wanted to avoid using digital logic so I attempted to do this with an CE amplifier with 2 stages of BC108C's trying to amplify the noise from a 4V7 Zener diode but whilst the noise is random, the rate of change is so fast that I end up with an average voltage that is the same and therefore the capacitor charges in the same time, each time.

All suggestions gratefully received.
 
Post your circuit schematic.
 
Chaotic Oscillator .....attached.

Also see the references at end of paper for other possibilities.


Regards, Dana.
 

Attachments

  • S0218127414501557.pdf
    636 KB · Views: 279
Hi, apologies for the delay in response, I had to draw up the circuit in Proteus from the iterated steps I've completed over the past weeks. See the schematic here.

Screenshot 2022-10-08 at 20.09.46.png


The previous revision of the circuit used the capacitor C1 to provide a timer circuit and once a reference voltage of 2.7V has been achieve the comparator turns on U3 SCR and D3 lights, signalling that you can now press one of the press buttons to be first to react in this game. The use of MOSFETS there is to ground the gate of U1 and U2 SCR's until the capacitor is charged so that you can't cheat and keep the button pressed down (to be first!) Once the capacitor is charged and someone pressed their button first, U1 or U2 will be latched and it's respective LED lit, showing who won.

So this gives around a 4 second timer but I wanted to make it random, maybe 1-10 seconds or more so it is less predictable. I don't want to use digital logic as I'm focussed on learning analogue techniques (even if not so efficient here). I attempted to use the zener diode D5 to generate noise, which I amplified, to give a voltage to charge the timing capacitor C1....but I always get around 12 seconds. Looking at the waveform, it is amplified and random, but perhaps the speed of change is so high that I still get an average after all. I need a random amount of time to charge C1 and I'm using a single rail source of 6V.

Thanks for any help or ideas. I am a student and my knowledge is limited but I am learning.
 
The only thing I can think of is to add a comparator to the output of the noise generator, with the other input from a pot across the supply, to set an adjustable reference level, so you can get just the rarer high amplitude noise spikes.

Then feed that to a voltage doubler - a series cap & two diodes to charge the existing C1.
That would act as a kind of charge pump, adding a small amount to C1 every time a spike above the set threshold occurred.

C2 on this would be the input from the comparator, and C1 is C1; no RL as it's manual discharge.


Configuration-of-a-voltage-doubler-rectifier-circuit.png
 
Sounds like you want a sample-and-hold circuit, which can be as simple as a switch from the output of the noise source to a capacitor to 0V. When the switch is closed, the capacitor voltage tracks the noise source voltage; when the switch is opened, the capacitor retains the whatever voltage it last had. An opamp can buffer the capacitor voltage to the next stage. If you use a double-pole switch, you can enable the sampling, and your present 'reset' function with a single switch.
 
A triangle wave generator might be a better source than a noise generator as that will be at a random voltage when you press the button.

Mike.
 
All great ideas thanks danadak, rjenkinsgb, dougy83, and Pommie. I'm not sure at this point which will be the best one to start experimenting with and I might have to work through all of them to find that out. Any more detail schematics would be appreciated but I've got quite a bit to go on there already I think!
 
Keep thinking about the problem and define ALL input variables and outputs with time , voltage etc tolerances. Write a better design spec. for an acceptable solution. Then the implementation will be easier without guesswork. Stop thinking about specific implementations until that part is done. Separate MUST HAVE from NICE TO HAVES in a list. Then budget ,time, cost and anything else that matters.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top