Radio control, clocks, sailboat etc etc
  • Home (Slideshow)
  • Wooden clock
    • Remontoire clock
    • Video of main clock
    • Impulse pendulum
    • Another one under construction
    • Paddy`s Clock
    • Clock time lapse
    • Number 6 Clock >
      • Second Number 6
    • Clock RE1-4
    • RE-3 Clock
  • Special needs child`s tractor conversion.
    • Special needs project 2
    • Lucy`s car
  • Videos
  • Comments
  • Contact
  • Picture hosting
  • Shed
  • Stove Installation
  • Fishing
  • Hobie T2
  • Home (New)
  • RE-6 Clock
  • Tramsit Conversion
    • Clear Van
    • Rear windows
    • Front windows
    • Fan

Impulse pendulum testing with a PIC12f675 micro-controller. The same type setup might be used for a battery powered clock at some stage, if I get around to designing one. 

To the right is the program written for the chip, and a circuit diagram is below the video.

;Chip Settings
#chip 12f675,4
#config MCLR=OFF, WDT=OFF

;Defines (Constants)
#define adc bits = 10
#define led gpio.0
#define led2 gpio.4
#define pb gpio.1
#define pb2 gpio.2
#define coil gpio.5

ansel = 0
dir gpio.0 out
dir gpio.1 in
dir gpio.2 in
dir gpio.4 out
dir gpio.5 out
set coil on
for f1 = 1 to 10
set led2 on
wait 50 ms
set led2 off
wait 50 ms
next f1
b1 = 1
start:
val = readad (an2)
if val < 2 then
goto start
end if
coilon:
set led on
set coil off
wait 5 ms
set led off
set coil on
goto start

Picture
Powered by Create your own unique website with customizable templates.