To: Luchini, Kristi Subject: RE: real-time response of CA on coldfire - CORRECTED TIMES -----Original Message----- From: Luchini, Kristi Sent: Friday, March 03, 2006 8:43 AM To: Luchini, Kristi Subject: RE: real-time response of CA on coldfire - CORRECTED TIMES Sorry - my board's clock was somewhat off (and it's late...) The corrected times are maximum 2400us average 1800us T. -----Original Message----- From: owner-lcls-controls@lists1.slac.stanford.edu [mailto:owner-lcls-controls@lists1.slac.stanford.edu] On Behalf Of Till Straumann Sent: Thursday, March 02, 2006 11:49 PM To: lcls-controls; Akre, Ronald A.; Smith, Steve; Johnson, Ronald G.; Medvedko, Evgeny A. Subject: real-time response of CA on coldfire I did a quick and dirty test to get an estimate of latencies that we have to expect if we try to ship real-time data over TCP/IP/EPICS/Channel Access: I let the coldfire write a 'synchronization byte' to its RS232 port when it fires a CA monitor (i.e., when it has generated 'new' data) A MVME6100 monitors a waveform on the coldfire measuring the time difference between the 'sync byte' and 'data' arrival. Below, a block diagram is shown. Both CPUs are otherwise completely idle. The coldfire is connected to the MVME6100 by a dedicated, fast point-to-point ethernet connection. No other network traffic is present. The measured latencies are: Avg: 2300 us Max: 3200 us No fine tuning has been done but I'd say this backs the reservations I have. It's not surprising - the added complexity of TCP/IP, a few copy operations on a slow CPU... -- Till PS: BTW: with 100baseT, a 1000 byte ethernet packet (more or less what we need to read 1 BPM) spends 100us on the wire alone. I believe the readout from the device takes about another 100us. So the fastest possible w/o any other overhead is > 200us (although, in my approach I'd try to let the ethernet chip DMA directly out of the FIFO). Test diagram: COLDFIRE-IOC ============ -- scanned at 0.5s | V [ waveform: 1000 shorts ] process ---> devsup writes char to RS232 (115kb/s) /\ ^ || | || | || dedicated | RS232 || 100baseT | || Ethernet link | || (TCP/IP/CA) | \/ v MVME6100 IOC ============ [ waveform: 1000 shorts; ] INP: coldfire:wf CP 'slave' waveform helper task monitors coldfire, resets clock reads clock when when char arrives data arrives LATENCY = data arrival time - sync char arrival time