2016-01-22 06:50:41 -04:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "RCInput.h"
|
|
|
|
|
2016-07-29 16:14:02 -03:00
|
|
|
|
|
|
|
namespace Linux {
|
|
|
|
|
|
|
|
class RCInput_Navio2 : public RCInput {
|
2016-01-22 06:50:41 -04:00
|
|
|
public:
|
|
|
|
void init() override;
|
|
|
|
void _timer_tick(void) override;
|
|
|
|
RCInput_Navio2();
|
|
|
|
~RCInput_Navio2();
|
|
|
|
|
|
|
|
private:
|
|
|
|
int open_channel(int ch);
|
|
|
|
|
|
|
|
uint64_t _last_timestamp = 0l;
|
2016-05-23 09:12:33 -03:00
|
|
|
static const size_t CHANNEL_COUNT = 16;
|
2016-01-22 06:50:41 -04:00
|
|
|
int channels[CHANNEL_COUNT];
|
|
|
|
uint16_t periods[ARRAY_SIZE(channels)] = {0};
|
|
|
|
};
|
2016-07-29 16:14:02 -03:00
|
|
|
|
|
|
|
}
|