Main Site Documentation

Reading clock and data stream



I’m trying to read a clock and data stream with the EMX board. I have the clock and data pulses connected to two input pins. The clock pin is configured as an interrupt and the data pin will be read at every clock pulse.

What I’ve realised is that I am not able to read the state of the data pin fast enough and the data read is not alligned to the clock pulse.
Does anyone know of any other method to do this? Or are there any functions built into the NETMF to assist with this?



In managed code, interrupt processing occurs milliseconds after the edge change. You have an accurate time for the interrupt occurence, but it difficult to sync with another pin at anything but very very low clock rates.

You will have to RLP to do this at a high speed.


Maybe somethnig wrong and dumb but…

Is it really a clock that triggers your data acquisition? If yes does the latency between the trig and the acquisition is fixed? if still yes, why not delaying the acquisition of about Tclock-latency, in this case you catch the next sample in a pseudo synchronous way.