39#ifdef PREINIT_SUPPORTED
43#ifdef MikroCCoreVersion
44 #if MikroCCoreVersion >= 1
49#include "drv_digital_out.h"
66#define DSP_SET_EFFECT_MEDIUM 0x00
67#define DSP_SET_EFFECT_CHAMBR7B 0x01
68#define DSP_SET_EFFECT_ROOM3B 0x02
69#define DSP_SET_EFFECT_CHAMBER2 0x03
70#define DSP_SET_EFFECT_REVERS3B 0x04
71#define DSP_SET_EFFECT_GATED4B 0x05
72#define DSP_SET_EFFECT_ROOM2A 0x06
73#define DSP_SET_EFFECT_SPRING3B 0x07
74#define DSP_SET_EFFECT_PHASER1 0x08
75#define DSP_SET_EFFECT_FLANGER2 0x09
76#define DSP_SET_EFFECT_DELAY7 0x0A
77#define DSP_SET_EFFECT_CHORUS4 0x0B
78#define DSP_SET_EFFECT_EARLREF4 0x0C
79#define DSP_SET_EFFECT_AMB4 0x0D
80#define DSP_SET_EFFECT_DELAY3 0x0E
81#define DSP_SET_EFFECT_DELAY1 0x0F
94#define DSP_SET_PIN_STATE_LOW 0x00
95#define DSP_SET_PIN_STATE_HIGH 0x01
108#define dsp_retval_t uint8_t
111#define DSP_ERROR 0xFF
130#define DSP_MAP_MIKROBUS( cfg, mikrobus ) \
131 cfg.p0 = MIKROBUS( mikrobus, MIKROBUS_AN ); \
132 cfg.rst = MIKROBUS( mikrobus, MIKROBUS_RST ); \
133 cfg.p1 = MIKROBUS( mikrobus, MIKROBUS_CS ); \
134 cfg.p3 = MIKROBUS( mikrobus, MIKROBUS_PWM ); \
135 cfg.p2 = MIKROBUS( mikrobus, MIKROBUS_INT )
#define dsp_retval_t
DSP error code settings.
Definition dsp.h:108
err_t dsp_init(dsp_t *ctx, dsp_cfg_t *cfg)
DSP initialization function.
void dsp_power_on(dsp_t *ctx)
DSP power on the device function.
void dsp_pin_set_p0(dsp_t *ctx, uint8_t pin_state)
DSP P0 pin setting function.
void dsp_reset(dsp_t *ctx)
DSP reset the device function.
void dsp_pin_set_p3(dsp_t *ctx, uint8_t pin_state)
DSP P3 pin setting function.
dsp_retval_t dsp_set_effect(dsp_t *ctx, uint8_t effects)
DSP reverb and multi-effects setting function.
void dsp_cfg_setup(dsp_cfg_t *cfg)
DSP configuration object setup function.
void dsp_pin_set_p2(dsp_t *ctx, uint8_t pin_state)
DSP P2 pin setting function.
void dsp_default_cfg(dsp_t *ctx)
DSP default configuration function.
void dsp_pin_set_p1(dsp_t *ctx, uint8_t pin_state)
DSP P1 pin setting function.
DSP Click configuration object.
Definition dsp.h:159
pin_name_t p3
Definition dsp.h:163
pin_name_t p1
Definition dsp.h:162
pin_name_t p0
Definition dsp.h:160
pin_name_t p2
Definition dsp.h:164
pin_name_t rst
Definition dsp.h:161
DSP Click context object.
Definition dsp.h:145
digital_out_t p1
Definition dsp.h:148
digital_out_t p0
Definition dsp.h:146
digital_out_t p2
Definition dsp.h:150
digital_out_t rst
Definition dsp.h:147
digital_out_t p3
Definition dsp.h:149