Random Time Delay Circuit

Discussion in 'The Projects Forum' started by brockapplegate, Jan 27, 2009.

  1. brockapplegate

    Thread Starter New Member

    Jan 27, 2009
    3
    0
    Im designing a reaction timer circuit and i need a pseudo random timer.

    There will be an on switch to start the "game", when this is pressed i want it to wait for about 5 seconds, then switch on an LED for a random time between 2-10 seconds.
    When the LED switches back off it will start a counter which is connected to the reaction switch.

    I am struggling with getting the random timer working, ive looked at using a pseduo random timer but im not sure how to set it up on breadboard.

    any help would be useful.
     
  2. eblc1388

    Senior Member

    Nov 28, 2008
    1,542
    102
    Here is my idea of how it can be done.

    A fast clock is driving a 8-bit binary counter so the counter is rolling over from 255 back to zero in a second or so. A R-2R network is connected at the counter outputs to convert the binary count result into a DC voltage proportional to the count value. Therefore the voltage would varies between Vcc and 0V every second or faster.

    Of course one can replace the counter and R-2R network with a sawtooth ramp generator or a triangular wave generator. The function is the same. The idea is to get a certain voltage on a timing capacitor.

    When P.B. is pushed, 555 monostable #1 is triggered. Its output goes HIGH for 5 seconds. This switches the main timing capacitor controlled by the electronic switch 4066(or a relay driven via 555#1 output), from 555#2 to the output of the R-2R network voltage divider. Thus the voltage of this capacitor now follows the binary count values and is constantly changing between 0V and half Vcc.

    When 5 seconds elasped, the 555#1 times out. Two events then happens. Firstly the 555#2 is triggered. Its output goes high and lights the LED. Secondly, the 4066 electronic switch reconnects the timing capacitor back to the 555#2 so that it would now works as a simple monostable. However, because of the DC voltage already on the timing capacitor, the monostable timing is variable but shorter then when the capacitor is starting from 0V. It would be any where from 100% to X% of the original timing determined by RxC. The X% is adjustable via the voltage divider after the R-2R network. If this divider voltage is set higher but less than 2/3 Vcc, then minimum time that the LED will lights will be shorter as less time is required for the 555#2 to charge the timing capacitor up to 2/3 Vcc.

    The Cx = 0.1C is there is prevent 555#2 timeout during capacitor changeover. By using correct value for R and C, the max timing can be adjust to 10 seconds as per normal monostable timing calculation. The 2 second minimum is then set via the R-2R voltage divider.

    [​IMG]
     
  3. brockapplegate

    Thread Starter New Member

    Jan 27, 2009
    3
    0
    thanks for the help, looks like it should do the job, only thing i dont know is what does R-2R stand for?
     
  4. eblc1388

    Senior Member

    Nov 28, 2008
    1,542
    102
    A R-2R ladder is a means to convert binary output, usually from a counter, into a DC voltage proportional to the binary count value, so in effect a type of digital to analog converter.

    It uses only two values of resistors, one being double in value of the other. For example, 10K and 20K. Thus the name "R-2R". You connect them in such a way to make a ladder network.

    More information here by Wiki:

    R-2R ladder
     
Loading...