CHDK task repeat interval timing precision (USB Remote Pulse Accuracy) - General Discussion and Assistance - CHDK Forum supplierdeeply

CHDK task repeat interval timing precision (USB Remote Pulse Accuracy)

  • 0 Replies
There have been a number of posts reporting issues with pulse width timing using the USB remote code. All my tests have indicated that the timing is quite accurate but people like msl have posted that they have timing issues.   So I wrote a little script to compare task timing vs the camera's tick timer - which should give a pretty good idea about USB remote pulse width timing accuracy.

Code: [Select]
@title Timing Test
 @param t Task Loop Time (mSec)
 @default t 10
 @range   t 5 50
set_console_layout(1 ,1, 45, 14 )
camera_time = get_tick_count()
script_time = camera_time
delay = 0
count = 1
    sleep(5)  -- short sleep for one task iteration only
    script_time = script_time + t
    error = script_time - get_tick_count()
    if( delay == 0 ) then
     print(count,"error = "..error)
     delay = 50
     count = count + 1
     delay = delay -1
until false

When I run the script on my A1200 in playback mode,  the script reports zero timing errors !  As I had expected.

But when I run it in shooting modes,  I get vastly different answers depending on what mode I use (P , Auto, Scene,  Favorite, etc).   And I never see the zero error that I got in playback mode.

At least that mystery is now solved.    Fortunatley,  we now have high precision timer capability in 1.3.0 for applications that need it.
« Last Edit: 01 / June / 2014, 21:22:35 by waterwingz »
Ported :   A1200    SD940   G10    Powershot N    G16


Related Topics