c16x9 2.0.0.0
c16x9.h File Reference

This file contains API for 16x9 Click driver. More...

#include "drv_digital_out.h"
#include "drv_digital_in.h"
#include "drv_i2c_master.h"

Go to the source code of this file.

Data Structures

struct  c16x9_t
 Click ctx object definition. More...
 
struct  c16x9_cfg_t
 Click configuration structure definition. More...
 
struct  c16x9_point_t
 Point structure definition. More...
 
struct  c16x9_image_t
 Image structure definition. More...
 
struct  c16x9_char_t
 Character structure definition. More...
 
struct  c16x9_rectangle_t
 Rectangle structure definition. More...
 

Macros

#define C16X9_MAP_MIKROBUS(cfg, mikrobus)
 
#define C16X9_RETVAL   uint8_t
 
#define C16X9_OK   0x00
 
#define C16X9_INIT_ERROR   0xFF
 
#define C16X9_SLAVE_ADDRESS   0x74
 
#define C16X9_POINT_TO_PAGE_ONE   0x00
 
#define C16X9_POINT_TO_PAGE_TWO   0x01
 
#define C16X9_POINT_TO_PAGE_THREE   0x02
 
#define C16X9_POINT_TO_PAGE_FOUR   0x03
 
#define C16X9_POINT_TO_PAGE_FIVE   0x04
 
#define C16X9_POINT_TO_PAGE_SIX   0x05
 
#define C16X9_POINT_TO_PAGE_SEVEN   0x06
 
#define C16X9_POINT_TO_PAGE_EIGHT   0x07
 
#define C16X9_POINT_TO_PAGE_NINE   0x0B
 
#define C16X9_REG_CONFIG   0x00
 
#define C16X9_REG_PICTURE_DISPLAY   0x01
 
#define C16X9_REG_AUTO_PLAY_CTRL1   0x02
 
#define C16X9_REG_AUTO_PLAY_CTRL2   0x03
 
#define C16X9_REG_DISPLAY_OPTION   0x05
 
#define C16X9_REG_AUDIO_SYNC   0x06
 
#define C16X9_REG_FRAME_STATE   0x07
 
#define C16X9_REG_BREATH_CTRL1   0x08
 
#define C16X9_REG_BREATH_CTRL2   0x09
 
#define C16X9_REG_SHUTDOWN   0x0A
 
#define C16X9_REG_AGC_CTRL   0x0B
 
#define C16X9_REG_AUDIO_ADC_RATE   0x0C
 
#define C16X9_REG_COMMAND   0xFD
 
#define C16X9_CFG_PICTURE_MODE   0x00
 
#define C16X9_CFG_AUTO_FRAME_PLAY_MODE   0x08
 
#define C16X9_AP_CTRL1_PLAY_ENDLESS   0x00
 
#define C16X9_AP_CTRL1_LOOP_1   0x10
 
#define C16X9_AP_CTRL1_LOOP_2   0x20
 
#define C16X9_AP_CTRL1_LOOP_3   0x30
 
#define C16X9_AP_CTRL1_LOOP_4   0x40
 
#define C16X9_AP_CTRL1_LOOP_5   0x50
 
#define C16X9_AP_CTRL1_LOOP_6   0x60
 
#define C16X9_AP_CTRL1_LOOP_7   0x70
 
#define C16X9_AP_CTRL1_ALL_FRAME   0x00
 
#define C16X9_AP_CTRL1_FRAME_1   0x01
 
#define C16X9_AP_CTRL1_FRAME_2   0x02
 
#define C16X9_AP_CTRL1_FRAME_3   0x03
 
#define C16X9_AP_CTRL1_FRAME_4   0x04
 
#define C16X9_AP_CTRL1_FRAME_5   0x05
 
#define C16X9_AP_CTRL1_FRAME_6   0x06
 
#define C16X9_AP_CTRL1_FRAME_7   0x07
 
#define C16X9_SET_ONE_FRAME_INTENSITY   0x00
 
#define C16X9_SET_ALL_FRAME_INTENSITY   0x20
 
#define C16X9_BLINK_DISABLE   0x00
 
#define C16X9_BLINK_ENABLE   0x08
 
#define C16X9_AUDIO_SYNCHRONIZATION_DISABLE   0x00
 
#define C16X9_AUDIO_SYNCHRONIZATION_ENABLE   0x01
 
#define C16X9_SHUTDOWN_MODE   0x00
 
#define C16X9_NORMAL_OPERATION   0x01
 
#define C16X9_AGC_SLOW_MODE   0x00
 
#define C16X9_AGC_FAST_MODE   0x10
 
#define C16X9_AGC_DISABLE   0x00
 
#define C16X9_AGC_ENABLE   0x08
 
#define C16X9_AGC_GAIN_0dB   0x00
 
#define C16X9_AGC_GAIN_3dB   0x01
 
#define C16X9_AGC_GAIN_6dB   0x02
 
#define C16X9_AGC_GAIN_9dB   0x03
 
#define C16X9_AGC_GAIN_12dB   0x04
 
#define C16X9_AGC_GAIN_15dB   0x05
 
#define C16X9_AGC_GAIN_18dB   0x06
 
#define C16X9_AGC_GAIN_21dB   0x07
 
#define C16X9_FRAME_1   0x00
 
#define C16X9_FRAME_2   0x01
 
#define C16X9_FRAME_3   0x02
 
#define C16X9_FRAME_4   0x03
 
#define C16X9_FRAME_5   0x04
 
#define C16X9_FRAME_6   0x05
 
#define C16X9_FRAME_7   0x06
 
#define C16X9_FRAME_8   0x07
 
#define C16X9_CTRL_LED   0x01
 
#define C16X9_CTRL_LED_BLINK   0x02
 

Functions

void c16x9_cfg_setup (c16x9_cfg_t *cfg)
 Config Object Initialization function.
 
C16X9_RETVAL c16x9_init (c16x9_t *ctx, c16x9_cfg_t *cfg)
 Initialization function.
 
void c16x9_generic_write (c16x9_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
 Generic write function.
 
void c16x9_control_all (c16x9_t *ctx, uint8_t ctrl, uint8_t state)
 Functions for control all leds.
 
void c16x9_fill_screen (c16x9_t *ctx, uint8_t pwm)
 Functions for fill screen.
 
void c16x9_display_refresh (c16x9_t *ctx)
 Function for refresh display.
 
void c16x9_draw_point (c16x9_t *ctx, c16x9_point_t *point)
 Functions for draw point .
 
void c16x9_display_image (c16x9_t *ctx, c16x9_image_t *image)
 Image display function.
 
void c16x9_display_byte (c16x9_t *ctx, c16x9_char_t *data_char)
 Function for displaying one character.
 
void c16x9_draw_rectangle (c16x9_t *ctx, c16x9_rectangle_t *rectangle)
 Draw rectangle.
 
uint8_t c16x9_get_interrupt_state (c16x9_t *ctx)
 Interrupt pin state.
 

Detailed Description

This file contains API for 16x9 Click driver.