I'm trying to grab lap data from InSim, to display in LRA, my replay analyser.
For this I need LFS to send MCI packets, at a fairly high rate (every 100 ms or less). These should give me the car's position and speed. Together with a timestamp, these will enable a basic analysis of the lap.
The problem I have encountered is that the packets arrive at irregular times, sometimes in bursts of 5 or more within the same millisecond. This is in single player, so there's only 1 car per packet.
That means they are useless for my purpose -- there is no timestamp in the packet, so I have to use the time of arrival as the sample time. It looks like LFS is buffering the packets, and sends them only when it has some "spare time". (My PC is very old.)
My question is: would using UDP help for this problem? Until now, I used only TCP.
For this I need LFS to send MCI packets, at a fairly high rate (every 100 ms or less). These should give me the car's position and speed. Together with a timestamp, these will enable a basic analysis of the lap.
The problem I have encountered is that the packets arrive at irregular times, sometimes in bursts of 5 or more within the same millisecond. This is in single player, so there's only 1 car per packet.
That means they are useless for my purpose -- there is no timestamp in the packet, so I have to use the time of arrival as the sample time. It looks like LFS is buffering the packets, and sends them only when it has some "spare time". (My PC is very old.)
My question is: would using UDP help for this problem? Until now, I used only TCP.