I'm playing with the idea to experiment with (semi-)high speed photography.
The idea is to capture arrows, darts, bb's shot at 400 feet per second, falling eggs etc on a picture.
In order to do this, one has to be extremely lucky while pressing the camera trigger or use some electronis to do the work for him. (I'm going with option 2
Anyway, the setup exists of a sensor part that has 2 sensors placed appart about 10 cm. When a object travels across the two sensors it will first trigger sensor A and then sensor B.
The PICAXE needs to measure this time and multiply it by 10, wait that ammount of time and then send a signal to the camera. The speed of the object varies but will never be realy slow.
The camera is places 1m after sensor B.
With this setup the PICAXE will first measure the speed of the object and then calculate how long to wait before it reaches the focus of the camera.
That's the theory.
However there are some possible issues.
1) speed: I'll probably have to run the picaxe in 8Mhz speed
2) accurate measuring: I'll have to find a fast way to measure time accuratly. Ideal would be to read the internal timer or so but I can't find if this is possible in picaxe 08M or 14M. (these are the only ones I have)
The code would look like this:
' Function
' ========
' - Measure time getween sensorA trigger and sensorB trigger
' - Wait 10 * time, then signal the camera/flash to take a picture
' Pins
' ====
' PIN1 = sensor A
' PIN2 = sensor B
' PIN3 = camera trigger
do
'Reset timer/counter
w0 = 0
'wait for sensorA
while pin1 = 0
wend
'count up while waiting for sensorB
while pin2 = 0
w0 = w0 + 1
wend
'increase time
w0 = w0 * 10
'count down untill time = 0
while w0 > 0
w0 = w0 - 1
wend
'signal camera or flash to take picture
high pin3
pause 500
low pin3
loop
Questions:
- will a picaxe be fast enough? I know it does not parse 4.000.000 commands per second but only a few 1000's
- Is there a better way to do this compared to my code?
many thanks for all feedback and insights..
The idea is to capture arrows, darts, bb's shot at 400 feet per second, falling eggs etc on a picture.
In order to do this, one has to be extremely lucky while pressing the camera trigger or use some electronis to do the work for him. (I'm going with option 2
Anyway, the setup exists of a sensor part that has 2 sensors placed appart about 10 cm. When a object travels across the two sensors it will first trigger sensor A and then sensor B.
The PICAXE needs to measure this time and multiply it by 10, wait that ammount of time and then send a signal to the camera. The speed of the object varies but will never be realy slow.
The camera is places 1m after sensor B.
With this setup the PICAXE will first measure the speed of the object and then calculate how long to wait before it reaches the focus of the camera.
That's the theory.
However there are some possible issues.
1) speed: I'll probably have to run the picaxe in 8Mhz speed
2) accurate measuring: I'll have to find a fast way to measure time accuratly. Ideal would be to read the internal timer or so but I can't find if this is possible in picaxe 08M or 14M. (these are the only ones I have)
The code would look like this:
' Function
' ========
' - Measure time getween sensorA trigger and sensorB trigger
' - Wait 10 * time, then signal the camera/flash to take a picture
' Pins
' ====
' PIN1 = sensor A
' PIN2 = sensor B
' PIN3 = camera trigger
do
'Reset timer/counter
w0 = 0
'wait for sensorA
while pin1 = 0
wend
'count up while waiting for sensorB
while pin2 = 0
w0 = w0 + 1
wend
'increase time
w0 = w0 * 10
'count down untill time = 0
while w0 > 0
w0 = w0 - 1
wend
'signal camera or flash to take picture
high pin3
pause 500
low pin3
loop
Questions:
- will a picaxe be fast enough? I know it does not parse 4.000.000 commands per second but only a few 1000's
- Is there a better way to do this compared to my code?
many thanks for all feedback and insights..