-
Notifications
You must be signed in to change notification settings - Fork 646
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tx_timed_samples.cpp with float timespec creates LATE errors #592
Comments
As a quick follow-up, this might help to debug:
which shows that in the conversion something happens. And this little difference makes UHD misinterpret time_spec in some way which I cannot debug. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Issue Description
I found a weird behaviour in setting the time_spec for a burst transmission in the future. I modified the tx_timed_samples.cpp example, where i changed the type of
seconds_in_future
fromdouble
tofloat
. Moreover, I added some more debug output. I attach the source code below.Setup
If I compile this the program on the USRP X410 with UHD v4.2.0.0 freshly installed with
Expected Behaviour
and run as such:
Everything is as expected.
Erroneous behaviour
However, If I run with a nsecs value which is not exactly representable in floating point (like 0.3), The output becomes erronous (there are many L in the console, and I get many async error code 8 (which is LATE):
if I change back the type of
seconds_in_future
todouble
and also in the options parser line, the error is gone and evreything works as expected.I know that 0.3seconds cannot be fully represented in both double adn float. However, I expect that the casting into double would not create any problems as long as the time is clearly in the future. I do not expect to see these "LATE" messages in the console, even though I supply a float (also, the compiler does not throw a warning regardign a lossy conversion).
Source code
The text was updated successfully, but these errors were encountered: