mirror of https://github.com/ArduPilot/ardupilot
21 lines
396 B
C++
21 lines
396 B
C++
#pragma once
|
|
|
|
#include "AP_HAL_Linux.h"
|
|
|
|
#include "ToneAlarm.h"
|
|
|
|
class Linux::ToneAlarm_Raspilot : public Linux::ToneAlarm {
|
|
public:
|
|
ToneAlarm_Raspilot();
|
|
bool init() override;
|
|
void stop() override;
|
|
bool play() override;
|
|
|
|
private:
|
|
void _set_pwm0_period(uint32_t time_us);
|
|
void _set_pwm0_duty(uint8_t percent);
|
|
|
|
volatile uint32_t *_pwm;
|
|
volatile uint32_t *_clk;
|
|
};
|