bitsim
Model, simulate, estimate and control robots in C++
Loading...
Searching...
No Matches
sim_rc_link.h
Go to the documentation of this file.
1#ifndef BITSIM_BOARDS_SIM_RC_LINK_H
2#define BITSIM_BOARDS_SIM_RC_LINK_H
3
7
8#include <string>
9
10namespace bitsim
11{
12namespace boards
13{
14
24class SIM_RCLink final : public RCTransmitterBase
25{
26 public:
30 explicit SIM_RCLink(real_t timeout = 0.5);
31
32 void send(const control::RCCommand &command, real_t time) override;
33
34 std::string backend_type_str() const override { return "SIMULATION"; }
35
41
45 bool in_failsafe(real_t time) const noexcept;
46
47 real_t timeout() const noexcept { return timeout_; }
48
49 private:
50 real_t timeout_;
51 control::RCCommand last_{};
52 real_t last_time_{0.0};
53 bool heard_{false};
54};
55
56} // namespace boards
57} // namespace bitsim
58
59#endif // BITSIM_BOARDS_SIM_RC_LINK_H
The basic types of bitsim. Code outside this file names Eigen's matrix and vector types only through ...
Sends the commands of a radio transmitter to a quadrotor: the laptop takes the place of the hand-held...
Definition rc_transmitter_base.h:25
Definition arduino_connector_base.h:15
Definition dc_motor_backend_base.h:9
double real_t
real_t
Definition bitsim_types.h:20
What the sticks of a radio transmitter for a quadrotor say, as a toy drone's transmitter sends them: ...
Definition rc_command.h:20