39#ifdef PREINIT_SUPPORTED
43#ifdef MikroCCoreVersion
44 #if MikroCCoreVersion >= 1
49#include "drv_digital_out.h"
50#include "drv_digital_in.h"
73#define BRUSHLESS15_DEF_FREQ 1000
79#define BRUSHLESS15_DIR_CW 0
80#define BRUSHLESS15_DIR_CCW 1
98#define BRUSHLESS15_MAP_MIKROBUS( cfg, mikrobus ) \
99 cfg.pwm = MIKROBUS( mikrobus, MIKROBUS_PWM ); \
100 cfg.dir = MIKROBUS( mikrobus, MIKROBUS_RST ); \
101 cfg.en = MIKROBUS( mikrobus, MIKROBUS_CS ); \
102 cfg.int_pin = MIKROBUS( mikrobus, MIKROBUS_INT );
brushless15_return_value_t
Brushless 15 Click return value data.
Definition brushless15.h:157
@ BRUSHLESS15_OK
Definition brushless15.h:158
@ BRUSHLESS15_ERROR
Definition brushless15.h:159
void brushless15_set_direction(brushless15_t *ctx, uint8_t direction)
Brushless 15 set direction function.
void brushless15_disable_device(brushless15_t *ctx)
Brushless 15 disable device function.
void brushless15_cfg_setup(brushless15_cfg_t *cfg)
Brushless 15 configuration object setup function.
err_t brushless15_init(brushless15_t *ctx, brushless15_cfg_t *cfg)
Brushless 15 initialization function.
err_t brushless15_set_duty_cycle(brushless15_t *ctx, float duty_cycle)
Brushless 15 sets PWM duty cycle.
void brushless15_switch_direction(brushless15_t *ctx)
Brushless 15 switch direction function.
void brushless15_enable_device(brushless15_t *ctx)
Brushless 15 enable device function.
err_t brushless15_pwm_start(brushless15_t *ctx)
Brushless 15 start PWM module.
uint8_t brushless15_get_int_pin(brushless15_t *ctx)
Brushless 15 get int pin function.
err_t brushless15_default_cfg(brushless15_t *ctx)
Brushless 15 default configuration function.
err_t brushless15_pwm_stop(brushless15_t *ctx)
Brushless 15 stop PWM module.
Brushless 15 Click configuration object.
Definition brushless15.h:138
uint32_t dev_pwm_freq
Definition brushless15.h:148
pin_name_t dir
Definition brushless15.h:143
pin_name_t en
Definition brushless15.h:144
pin_name_t int_pin
Definition brushless15.h:145
pin_name_t pwm
Definition brushless15.h:140
Brushless 15 Click driver selector.
Definition brushless15.h:117
uint32_t pwm_freq
Definition brushless15.h:129
digital_in_t int_pin
Definition brushless15.h:123
digital_out_t en
Definition brushless15.h:120
pwm_t pwm
Definition brushless15.h:126
digital_out_t dir
Definition brushless15.h:119