iowarrior 24 irregular output rate

This is the English forum for all topics related to IO-Warrior. Please post in English only

Moderator: Guido Körber

Post Reply
slashj
Posts: 6
Joined: Fri Mar 03, 2006 7:10 am

iowarrior 24 irregular output rate

Post by slashj »

G'day,

I have a 64 led matrix using the iow24 development board and the support chips mentioned in the document. It works fine in terms of setting individual led on and off. However, for my experiment I need to be able to light up the LEDs at a fixed rate and this is proving to be problematic.

I am programming in C/C++ in Windows XP linking in with the Iowkit.dll and have set the base time sampling under XP to 1ms already using timeBeginPeriod(1). I have a function which uses timeGetTime() to set the LED to on and off for a specified time in ms. The rate is not too fast - 10ms on and 10ms off.

I am testing using a 40Mhz cro on the output of the LED lines and I find that the off rate slips, sometimes it's 10ms, sometimes its greater.

I understand the LED matrix cycles each row at 128Hz, is that the problem? is there a way to accurately (to a few ms accounting for USB latencies) set the lights on and off in time?

cheers.
Guido Körber
Site Admin
Posts: 2856
Joined: Tue Nov 25, 2003 10:25 pm
Location: Germany/Berlin
Contact:

Post by Guido Körber »

Depending on your USB host a transfer to the IO-Warrior takes 300µsec or 3msec. If you write the complete matrix you need eight such transfers.

The matrix multiplexing is not synchronised to the USB transfers, so latencies add up to 11msec worst case not counting Windows latencies.

Also the matrix multiplexing rate of 128Hz with 1:8 multiplexing means each individual LED will be on for 1msec every 8msec.
Post Reply