The official way in the XMOS Programming Guide (section 6.10) to synchronise multiple ports is to use a sync(p) call to create the largest timing window and then quickly stuff each of the transfer registers before next clock edge. However, I am clocking the shift registers at around 60MHz and the window is too small get everything written in time.
Instead I am using scheduled transfers with the "@ count+delta" form. For this I need to read the current timestamp from one of the ports by doing a dummy write. This is not too bad, because I can write 0xffffffff to a line that is parked high anyway, but it is hugely wasteful of time.
Is there a way that I can read the port timestamp without a dummy write? Anyone used GETTS directly?
(Yes, I know I could use a 4 bit port which would be in sync already, but I have run out of 4 bit ports)
Update:
Code: Select all
count = partout_timestamped(dac_sync_A, 1 ,1);