17 lines
535 B
C
17 lines
535 B
C
#pragma once
|
|
|
|
#include <stdbool.h>
|
|
#include <stdint.h>
|
|
#ifdef AUTOFILM_HOST
|
|
#include "esp_host_compat.h"
|
|
#else
|
|
#include "esp_err.h"
|
|
#endif
|
|
|
|
void hal_motor_init(void);
|
|
void hal_motor_enable(bool on); /* on=false → EN disabled (HIGH on wroom) */
|
|
void hal_motor_request_stop(void); /* must be safe to call anytime; sets flag + enable false */
|
|
esp_err_t hal_motor_agitate_start(float cw_revs, float ccw_revs, uint32_t rpm);
|
|
void hal_motor_agitate_stop(void); /* leave disabled */
|
|
bool hal_motor_is_enabled(void);
|