driver mma7660fc basic header file
uint8_t mma7660fc_set_auto_wake_up(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable auto wake up
uint8_t mma7660fc_init(mma7660fc_handle_t *handle)
initialize the chip
uint8_t mma7660fc_set_shake_x_interrupt(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable shake x interrupt
uint8_t mma7660fc_set_sleep_counter_prescaler(mma7660fc_handle_t *handle, mma7660fc_sleep_counter_prescaler_t prescaler)
set sleep counter prescaler
uint8_t mma7660fc_set_interrupt_pin_type(mma7660fc_handle_t *handle, mma7660fc_interrupt_pin_type_t type)
set interrupt pin type
uint8_t mma7660fc_read(mma7660fc_handle_t *handle, int8_t raw[3], float g[3])
read the data
uint8_t mma7660fc_set_tap_detection_threshold(mma7660fc_handle_t *handle, uint8_t threshold)
set tap detection threshold
uint8_t mma7660fc_deinit(mma7660fc_handle_t *handle)
close the chip
uint8_t mma7660fc_set_shake_z_interrupt(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable shake z interrupt
uint8_t mma7660fc_set_tilt_debounce_filter(mma7660fc_handle_t *handle, mma7660fc_tilt_debounce_filter_t filter)
set tilt debounce filter
uint8_t mma7660fc_set_auto_wake_rate(mma7660fc_handle_t *handle, mma7660fc_auto_wake_rate_t rate)
set auto wake rate
uint8_t mma7660fc_set_mode(mma7660fc_handle_t *handle, mma7660fc_mode_t mode)
set mode
uint8_t mma7660fc_set_auto_sleep_interrupt(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable auto sleep interrupt
struct mma7660fc_handle_s mma7660fc_handle_t
mma7660fc handle structure definition
uint8_t mma7660fc_set_update_interrupt(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable update interrupt status
uint8_t mma7660fc_set_front_back_interrupt(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable front back interrupt
uint8_t mma7660fc_set_tap_interrupt(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable tap interrupt
uint8_t mma7660fc_set_tap_x_detection(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable tap x detection
uint8_t mma7660fc_set_tap_y_detection(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable tap y detection
uint8_t mma7660fc_set_auto_sleep(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable auto sleep
uint8_t mma7660fc_set_interrupt_active_level(mma7660fc_handle_t *handle, mma7660fc_interrupt_active_level_t level)
set interrupt active level
uint8_t mma7660fc_set_tap_pulse_debounce_count(mma7660fc_handle_t *handle, uint8_t count)
set tap pulse debounce count
uint8_t mma7660fc_set_tap_detection_rate(mma7660fc_handle_t *handle, mma7660fc_auto_sleep_rate_t rate)
set tap detection rate
uint8_t mma7660fc_set_shake_y_interrupt(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable shake y interrupt
uint8_t mma7660fc_set_sleep_count(mma7660fc_handle_t *handle, uint8_t count)
set sleep count
uint8_t mma7660fc_set_tap_z_detection(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable tap z detection
uint8_t mma7660fc_set_up_down_right_left_interrupt(mma7660fc_handle_t *handle, mma7660fc_bool_t enable)
enable or disable up down right left interrupt
@ MMA7660FC_INTERRUPT_PIN_TYPE_PUSH_PULL
@ MMA7660FC_INTERRUPT_ACTIVE_LEVEL_LOW
@ MMA7660FC_SLEEP_COUNTER_PRESCALER_1
@ MMA7660FC_AUTO_SLEEP_RATE_8
@ MMA7660FC_TILT_DEBOUNCE_FILTER_2
@ MMA7660FC_AUTO_WAKE_RATE_16
uint8_t mma7660fc_basic_deinit(void)
basic example deinit
uint8_t mma7660fc_basic_init(void)
basic example init
uint8_t mma7660fc_basic_read(float g[3])
basic example read
void mma7660fc_interface_receive_callback(uint8_t type)
interface receive callback
uint8_t mma7660fc_interface_iic_read(uint8_t addr, uint8_t reg, uint8_t *buf, uint16_t len)
interface iic bus read
void mma7660fc_interface_delay_ms(uint32_t ms)
interface delay ms
uint8_t mma7660fc_interface_iic_write(uint8_t addr, uint8_t reg, uint8_t *buf, uint16_t len)
interface iic bus write
uint8_t mma7660fc_interface_iic_init(void)
interface iic bus init
void mma7660fc_interface_debug_print(const char *const fmt,...)
interface print format data
uint8_t mma7660fc_interface_iic_deinit(void)
interface iic bus deinit
#define DRIVER_MMA7660FC_LINK_RECEIVE_CALLBACK(HANDLE, FUC)
link receive_callback function
#define DRIVER_MMA7660FC_LINK_IIC_READ(HANDLE, FUC)
link iic_read function
#define DRIVER_MMA7660FC_LINK_DEBUG_PRINT(HANDLE, FUC)
link debug_print function
#define DRIVER_MMA7660FC_LINK_IIC_INIT(HANDLE, FUC)
link iic_init function
#define DRIVER_MMA7660FC_LINK_INIT(HANDLE, STRUCTURE)
initialize mma7660fc_handle_t structure
#define DRIVER_MMA7660FC_LINK_DELAY_MS(HANDLE, FUC)
link delay_ms function
#define DRIVER_MMA7660FC_LINK_IIC_WRITE(HANDLE, FUC)
link iic_write function
#define DRIVER_MMA7660FC_LINK_IIC_DEINIT(HANDLE, FUC)
link iic_deinit function