Random numbers: Done

So after much tinkering and coding I have a motor who’s speed is random and the amount of time it runs for at any given speed is also random.

The photo below show the finished article. The Green PCB is a Microchip Low Pin count prototyping board (came with the PICkit2) which contains a PIC16F690. A header splitter is then attached to the port on the side of the board giving me the ability to plug 2 daughter boards into the main board. On this there is a motor drive board and a hardware RNG. The RNG has already been explained, the motor drive board has a diode (1n4148) coming off the PWM output pin going to a simple low pass filter made from a 1nF cap and a 100R resistor which then drives a Darlington voltage follower to run the motor. the Darlington pair is infact a bc547 and a TIP31A since the motor is drawing up to 300mA and 2 x bc547s had a tendency to get a bit hot. There is no fly back since the LP filter should stop di/dt from getting to high (in theory). The other board is simply a LM7805 giving 5V for the PIC and 9v for the RNG. The rest, as they say, is software.
img_0971-1.JPG

Once my wee camera decides to work again, i shall take a video of the thing working.

Edit: 100_1584.MOV

Anyone wanting more info, leave a comment and I will do schematics and tidy up and post code.

Leave a Reply