clock problem
Quoted 11 lines
Would it be possible for you to send mails formatted correctly?
Then the bug is somewhere in between the serial line and the test application, including possibly in the driver.
In order to know where it is, you should compute the latency at each point on this path: when receiving the interrupt, when waking up the task, etc...
Signature · 1 line
Gilles.
Hi Gilles,
Sorry for the formatting, I am new to mailing lists.
I have looked at the latency in the 16550A driver. The first thing the driver does in its ISR is to call rtdm_clock_read and store the resulting timestamp in a "struct rtser_event". The code I posted grabs this structure. If I use this as my timestamp I get the exact same timing results.
It seems like the clock used by rtdm_clock_read is fast. I don't see how I could get a delay according to rtdm_clock_read of 1000000us between interrupts that I know are being triggered by an event coming in at 1000000 us.
Do you have any suggestions on what I can test?
Thanks for all your help.
Philip Ha
Quoted 11 lines · Philip Ha
Quoted 8 lines
Would it be possible for you to send mails formatted correctly?
Then the bug is somewhere in between the serial line and the test application, including possibly in the driver.
In order to know where it is, you should compute the latency at each point on this path: when receiving the interrupt, when waking up the task, etc...
Hi Gilles,
Quoted 7 lines
Sorry for the formatting, I am new to mailing lists.
I have looked at the latency in the 16550A driver. The first thing the driver does in its ISR is to call
rtdm_clock_readand store the resulting timestamp in a "structrtser_event". The code I posted grabs this structure. If I use this as my timestamp I get the exact same timing results.
are you sure that the interrupt triggers as soon as you receive a character, and not upon timeout when not receiving characters for some time? After all, 100us is approximately the time to transmit one character at 115200 bauds on the serial line.
Signature · 1 line
Gilles.
Quoted 17 lines
Hi Gilles,
Sorry for the formatting, I am new to mailing lists.
I have looked at the latency in the 16550A driver. The first thing the driver does in its ISR is to call
rtdm_clock_readand store the resulting timestamp in a "structrtser_event". The code I posted grabs this structure. If I use this as my timestamp I get the exact same timing results.Quoted 7 lines
are you sure that the interrupt triggers as soon as you receive a character, and not upon timeout when not receiving characters for some time? After all, 100us is approximately the time to transmit one character at 115200 bauds on the serial line.
Signature · 1 line
Gilles.
Hi Gilles,
I am not sending characters, I am sending a pulse from a function generator into the DSR pin and looking for the rising edge event ( RTSER_EVENT_MODEMHI ). Any latency in the system should be similar for every pulse it receives, therefore the time between pulses should still be 1000000us.
Thanks,
Philip Ha
Quoted 18 lines · Philip Ha
Quoted 17 lines
Hi Gilles,
Sorry for the formatting, I am new to mailing lists.
I have looked at the latency in the 16550A driver. The first thing the driver does in its ISR is to call
rtdm_clock_readand store the resulting timestamp in a "structrtser_event". The code I posted grabs this structure. If I use this as my timestamp I get the exact same timing results.Quoted 7 lines
are you sure that the interrupt triggers as soon as you receive a character, and not upon timeout when not receiving characters for some time? After all, 100us is approximately the time to transmit one character at 115200 bauds on the serial line.
Signature · 1 line
Gilles.
Quoted 7 lines
Hi Gilles,
I am not sending characters, I am sending a pulse from a function generator into the DSR pin and looking for the rising edge event (
RTSER_EVENT_MODEMHI). Any latency in the system should be similar for every pulse it receives, therefore the time between pulses should still be 1000000us.
The question remains: are you sure the UART does not introduce the delay, have you checked the datasheet?
Signature · 1 line
Gilles.