-
Notifications
You must be signed in to change notification settings - Fork 13.7k
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
SBUS on Linux: replace termios with termios2 #14083
Conversation
Feel free to add it here if you'd like - https://github.com/PX4/Firmware/blob/9d2a37b35d3af1f8848565ee8eedd6aa94a19251/platforms/common/px4_work_queue/WorkQueueManager.cpp#L166-L202 |
Could you structure the ifdef so that the decoder initialise section is run in both cases? |
Is it OK to add something like EDIT: Mostly like to remove that error and create some place for unrecognized UART instead of hp_default? |
The point of it is to have a thread dedicated to each physical bus. At the moment it's all static, but it could be more flexible in the future (needs some thought and rework). I would either:
|
Describe problem solved by this pull request
Previous version of code could not set the serial device properly, which leads to incorrect read of
_rcs_buf
. This PR solves that problem.Describe your solution
Code comes from existing
drivers/linux_sbus
, which works well.A problem still exists that
rc_input
will reportERROR [px4_work_queue] unknown serial port: /dev/ttyAMA0
for that customised ttyAMA0 is not defined which is necessary for function
px4::serial_port_to_wq()
Test data / coverage