Skip to content

Commit

Permalink
AP_SerialManager: RegisteredPort, add bytes_per_second/baudrate methods
Browse files Browse the repository at this point in the history
  • Loading branch information
olliw42 committed Oct 5, 2024
1 parent be1c87f commit e2279ea
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions libraries/AP_SerialManager/AP_SerialManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,8 @@ class AP_SerialManager {
*/
class RegisteredPort : public AP_HAL::UARTDriver {
public:
uint32_t bw_in_bytes_per_second() const override { return state.baudrate()/10; }
uint32_t get_baud_rate() const override { return state.baudrate(); }
RegisteredPort *next;
UARTState state;
};
Expand Down

0 comments on commit e2279ea

Please sign in to comment.