Just an update on this project...
I have abandoned (for now) the idea of using a serial port due to the latency issues but that does not mean I might not go back to it in the future! Using the serial port has the advantage that no hardware DCC controller was required and would have connected directly to the commercial DCC "Power Stations".
I have also abandoned the use of Ubuntu having got a good flea in my ear from the supplier of the new computer that failed to restore itself after a Ubuntu installation went wrong side up, but that is another thing I might come back to.
Meanwhile, I am dusting off the work/play I did some months ago to use the audio for output of the digital data stream. This has the disadvantage that hardware is required to shape the wave form but it is a very simple op amp circuit. It seems to work too..
https://farm4.staticflickr.com/3768/10033122854_ce1e171971.jpg... the audio trace and the square wave digital data derived from it.
The idea is to write the train control packets into buffers using the .WAV format and play those via the audio port.
Latency will still be an issue but if I can get to feed the sound card every 100ms or so most of the time that might be acceptable.
Fortunately gaps in the data stream are acceptable as the trains will continue according to the last received packet but too much delay will be frustrating to the user.
I am posting this information as others may be interesting in this scheme of getting digital data via an audio port.
John