You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
396 B
21 lines
396 B
9 years ago
|
#pragma once
|
||
9 years ago
|
|
||
|
#include "AP_HAL_Linux.h"
|
||
|
|
||
9 years ago
|
#include "ToneAlarm.h"
|
||
9 years ago
|
|
||
|
class Linux::ToneAlarm_Raspilot : public Linux::ToneAlarm {
|
||
|
public:
|
||
9 years ago
|
ToneAlarm_Raspilot();
|
||
|
bool init() override;
|
||
|
void stop() override;
|
||
|
bool play() override;
|
||
9 years ago
|
|
||
|
private:
|
||
9 years ago
|
void _set_pwm0_period(uint32_t time_us);
|
||
|
void _set_pwm0_duty(uint8_t percent);
|
||
9 years ago
|
|
||
9 years ago
|
volatile uint32_t *_pwm;
|
||
|
volatile uint32_t *_clk;
|
||
9 years ago
|
};
|