ToneAlarm.h 281 B

12345678910111213141516171819
  1. #pragma once
  2. #include <AP_HAL/AP_HAL.h>
  3. namespace Linux {
  4. class ToneAlarm {
  5. public:
  6. ToneAlarm();
  7. virtual bool init();
  8. virtual void set_buzzer_tone(float frequency, float volume, uint32_t duration_ms);
  9. private:
  10. int32_t period_fd;
  11. int32_t duty_fd;
  12. int32_t run_fd;
  13. };
  14. }