jakwnd
Posts: 5
Joined: Fri Oct 25, 2013 2:24 am

RPi timing system

Sat May 17, 2014 1:52 am

Hey all, I am trying to design a FAT (fully automatic timing) system around the RPi and camera module, like the ones used at track and swimming events. I do not have much experience with kernels and RTOS's however I understand that I will need one for my project. I have just started experimenting with machinoid, however I'm not sure if there is support for the camera, which is essential for the track.

The only real limitation I need from the RTOS is to reliably start the camera recording when the gun fires (GPIO). the rest of the timing can be assured from the elapsed time of the video.

If anyone has any input on the subject it would be much appreciated :D I'll keep this thread updated as I progress.

suicidal_orange
Posts: 217
Joined: Sun Mar 16, 2014 10:56 am

Re: RPi FAT system

Sat May 17, 2014 9:13 am

You need something to happen when a button is pressed? That's pretty normal and reliable, just get a decent switch. The only problem could be if you're aiming for world record standard precision with your timings and there is a delay when you say "start recording," but that could be compensated for by adding a fixed value to add on to the video length. Not sure how you'd get that value though...

I searched for machinoid to see what it was but got everything from a CNC controller to video games, nothing that looked relevant to your question?

User avatar
DougieLawson
Posts: 37095
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: RPi FAT system

Sat May 17, 2014 9:39 am

jakwnd wrote: The only real limitation I need from the RTOS is to reliably start the camera recording when the gun fires (GPIO). the rest of the timing can be assured from the elapsed time of the video.
If you look at modern timing system you'll see that the starter's pistol has a switch (or other sensor) that is activated by the trigger/hammer mechanism that fires the blank round.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

jakwnd
Posts: 5
Joined: Fri Oct 25, 2013 2:24 am

Re: RPi FAT system

Sun May 18, 2014 12:45 am

suicidal_orange wrote: I searched for machinoid to see what it was but got everything from a CNC controller to video games, nothing that looked relevant to your question?
This post has all the info on Machinoid:
http://www.raspberrypi.org/forums/viewt ... 56&t=49373

As long as any possible delay is under a hundreth of a second then it can still qualify for the standard. This is going to be a cheap alternative for the 2 grand FAT systems on the market.

User avatar
FLYFISH TECHNOLOGIES
Posts: 1750
Joined: Thu Oct 03, 2013 7:48 am
Location: Ljubljana, Slovenia
Contact: Website

Re: RPi timing system

Sun May 18, 2014 1:20 am

Hi,
jakwnd wrote:Hey all, I am trying to design a FAT (fully automatic timing) system around the RPi and camera module, like the ones used at track and swimming events.
Automatic timing equipment used on swimming events detects competitors with plates (+ backup buttons for judges).
Using camera(s) for fully automatic timing system is very challenging... you could get rich. ;-) Even on track&field running events, where you have much less "environment noise", times are read manually. (The exception are distances over 10.000m and/or where part of the run is performed outside stadium. In this case times obtained automatically by RFID tags are official... and they are not measured in hundredth of seconds anymore.)

I have strong doubts that your approach can pass any certificate procedure, but during this development you will gain some new technical knowledge and skills...
jakwnd wrote:As long as any possible delay is under a hundreth of a second then it can still qualify for the standard.
:D
Just a small detail: typical certified timekeeping system contains time-base circuit with a heated crystal to maintain very constant temperature -> clock stability.


Best wishes, Ivan Zilic.
Running out of GPIO pins and/or need to read analog values?
Solution: http://www.flyfish-tech.com/FF32

jakwnd
Posts: 5
Joined: Fri Oct 25, 2013 2:24 am

Re: RPi timing system

Sun May 18, 2014 1:50 am

FLYFISH TECHNOLOGIES wrote: I have strong doubts that your approach can pass any certificate procedure, but during this development you will gain some new technical knowledge and skills...
Thanks for the reply! I read through the NCAA rule book regarding timing. you can download it here [http://www.ncaapublications.com/product ... s/TF14.pdf]
Section 12 is timing, and it seems that It could possibly pass a certificate procedure if any exists. This is mainly for High School meets. Most High schools don't have a budget for a 2-3 thousand dollar FAT system, so even if this can only qualify for AT (automatic timing - 1/60 of a second) it could still be a good alternative.
FLYFISH TECHNOLOGIES wrote: Just a small detail: typical certified timekeeping system contains time-base circuit with a heated crystal to maintain very constant temperature -> clock stability.
Do you think using a reliable RTC could suffice? Heck with the new compute module one could work one into a design.

User avatar
FLYFISH TECHNOLOGIES
Posts: 1750
Joined: Thu Oct 03, 2013 7:48 am
Location: Ljubljana, Slovenia
Contact: Website

Re: RPi timing system

Sun May 18, 2014 2:13 am

Hi,
jakwnd wrote:I read through the NCAA rule book regarding timing.
Section 12 is timing, and it seems that It could possibly pass a certificate procedure if any exists.
Ok, you can try...
Be aware that there are cases where you'll probably need to prove that the equipment is certified... like best results/records, or when a result causes some bonuses to the competitor (eg. scholarship), etc.
jakwnd wrote:Do you think using a reliable RTC could suffice?
Define "reliable". ;-)
Additionally, RTC (as I understand the naming) has a resolution of one second.


Best wishes, Ivan Zilic.
Running out of GPIO pins and/or need to read analog values?
Solution: http://www.flyfish-tech.com/FF32

jakwnd
Posts: 5
Joined: Fri Oct 25, 2013 2:24 am

Re: RPi timing system

Sun May 18, 2014 2:21 am

FLYFISH TECHNOLOGIES wrote: Be aware that there are cases where you'll probably need to prove that the equipment is certified... like best results/records, or when a result causes some bonuses to the competitor (eg. scholarship), etc.
I see your point. But I simply cannot seem to find any evidence of a certification or anything of the sort. I'm sure I will have to do extensive tests to ensure the accuracy. Researching all the other systems on the market, I do not see anything related to a 'certification' only a guarantee of accuracy.

Thanks again for the replies! :)

User avatar
FLYFISH TECHNOLOGIES
Posts: 1750
Joined: Thu Oct 03, 2013 7:48 am
Location: Ljubljana, Slovenia
Contact: Website

Re: RPi timing system

Sun May 18, 2014 2:44 am

Hi,
jakwnd wrote:But I simply cannot seem to find any evidence of a certification or anything of the sort.
Sports federations/associations don't perform time accuracy/precision/etc. certification tests.

A vendor must take care that the equipment is verified by an appropriate organization accredited by the national measurement authority according to measurement standards (which are generic).
Each unit must also be calibrated and regularly re-calibrated by lab. Various sports also require that a setup for each competition (or daily if the competition takes more days) is verified by a specific procedure (eg. zero gun test).


Best wishes, Ivan Zilic.
Running out of GPIO pins and/or need to read analog values?
Solution: http://www.flyfish-tech.com/FF32

fuffkin
Posts: 92
Joined: Thu Mar 07, 2013 10:50 pm
Location: United Kingdom
Contact: Website

Re: RPi timing system

Tue May 20, 2014 11:57 am

The only real limitation I need from the RTOS is to reliably start the camera recording when the gun fires (GPIO). the rest of the timing can be assured from the elapsed time of the video.
Rather than start the recording when the gun fires and all the possible delays associated with that, why not start the recording before the gun fires and then relate it back via the video to the point of starting?

Just a thought.
Sleepy Pi - Extend RPi battery life with a plugin Power Management & Arduino I/O board
http://www.spellfoundry.com

mfa298
Posts: 1387
Joined: Tue Apr 22, 2014 11:18 am

Re: RPi timing system

Tue May 20, 2014 1:48 pm

jakwnd wrote: Section 12 is timing, and it seems that It could possibly pass a certificate procedure if any exists. This is mainly for High School meets. Most High schools don't have a budget for a 2-3 thousand dollar FAT system, so even if this can only qualify for AT (automatic timing - 1/60 of a second) it could still be a good alternative.
If the aim is to determine the timing from a captured video I wonder if you could even achieve 1/60 second resolution in the timing. With the recent 60/90 fps modes (but more limited resolution) you might be close enough. However you may need to take into account the rolling shutter as part of that. You'd also want to be sure that it's actually capturing at the requested rate rather than say requesting 60fps and actually getting 59fps. This probably wouldn't be visible just by watching the captured video (Film distributors get away with speeding up 24fps Cinematic films to 25fps for the European market - which makes a feature length film a couple of minutes shorter when watched at home!)

Return to “Advanced users”