Bouffalo SDK  1.0
Bouffalolab Software Development Kit
CORE
Collaboration diagram for CORE:

Data Structures

struct  bflb_device_s
 

Macros

#define ASSERT_PARAM(expr)   ((void)0U)
 
#define BFLB_DEVICE_TYPE_ADC   0
 
#define BFLB_DEVICE_TYPE_DAC   1
 
#define BFLB_DEVICE_TYPE_AUDIOADC   2
 
#define BFLB_DEVICE_TYPE_AUDIODAC   3
 
#define BFLB_DEVICE_TYPE_GPIO   4
 
#define BFLB_DEVICE_TYPE_UART   5
 
#define BFLB_DEVICE_TYPE_SPI   6
 
#define BFLB_DEVICE_TYPE_I2C   7
 
#define BFLB_DEVICE_TYPE_DMA   8
 
#define BFLB_DEVICE_TYPE_I2S   9
 
#define BFLB_DEVICE_TYPE_IR   10
 
#define BFLB_DEVICE_TYPE_TIMER   11
 
#define BFLB_DEVICE_TYPE_PWM   12
 
#define BFLB_DEVICE_TYPE_CAMERA   14
 
#define BFLB_DEVICE_TYPE_FLASH   15
 
#define BFLB_DEVICE_TYPE_QSPI   16
 
#define BFLB_DEVICE_TYPE_SDH   17
 
#define BFLB_DEVICE_TYPE_SDU   18
 
#define BFLB_DEVICE_TYPE_ETH   19
 
#define BFLB_DEVICE_TYPE_RTC   20
 
#define BFLB_DEVICE_TYPE_CRC   21
 
#define BFLB_DEVICE_TYPE_RNG   22
 
#define BFLB_DEVICE_TYPE_MIPI   23
 
#define BFLB_DEVICE_TYPE_DPI   24
 
#define BFLB_DEVICE_TYPE_DSI   25
 
#define BFLB_DEVICE_TYPE_CSI   26
 
#define BFLB_DEVICE_TYPE_USB   27
 
#define BFLB_DEVICE_TYPE_AES   28
 
#define BFLB_DEVICE_TYPE_SHA   29
 
#define BFLB_DEVICE_TYPE_MD5   30
 
#define BFLB_DEVICE_TYPE_TRNG   31
 
#define BFLB_DEVICE_TYPE_PKA   32
 
#define BFLB_DEVICE_TYPE_CKS   33
 
#define BFLB_DEVICE_TYPE_MJPEG   34
 
#define BFLB_DEVICE_TYPE_KYS   35
 
#define BFLB_DEVICE_TYPE_DBI   36
 
#define BFLB_DEVICE_TYPE_WDT   37
 
#define BFLB_DEVICE_TYPE_EF_CTRL   38
 
#define BFLB_DEVICE_TYPE_SDIO2   39
 
#define BFLB_DEVICE_TYPE_SDIO3   40
 
#define BFLB_DEVICE_TYPE_PLFMDMA   41
 
#define BFLB_DEVICE_TYPE_WO   42
 

Functions

struct bflb_device_sbflb_device_get_by_name (const char *name)
 Get device handle by name. More...
 
struct bflb_device_sbflb_device_get_by_id (uint8_t type, uint8_t idx)
 Get device handle by type and index. More...
 
void bflb_device_set_userdata (struct bflb_device_s *device, void *user_data)
 Set user data into device handle. More...
 

Detailed Description

Macro Definition Documentation

◆ ASSERT_PARAM

#define ASSERT_PARAM (   expr)    ((void)0U)

Definition at line 37 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_ADC

#define BFLB_DEVICE_TYPE_ADC   0

Definition at line 50 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_AES

#define BFLB_DEVICE_TYPE_AES   28

Definition at line 77 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_AUDIOADC

#define BFLB_DEVICE_TYPE_AUDIOADC   2

Definition at line 52 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_AUDIODAC

#define BFLB_DEVICE_TYPE_AUDIODAC   3

Definition at line 53 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_CAMERA

#define BFLB_DEVICE_TYPE_CAMERA   14

Definition at line 63 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_CKS

#define BFLB_DEVICE_TYPE_CKS   33

Definition at line 82 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_CRC

#define BFLB_DEVICE_TYPE_CRC   21

Definition at line 70 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_CSI

#define BFLB_DEVICE_TYPE_CSI   26

Definition at line 75 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_DAC

#define BFLB_DEVICE_TYPE_DAC   1

Definition at line 51 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_DBI

#define BFLB_DEVICE_TYPE_DBI   36

Definition at line 85 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_DMA

#define BFLB_DEVICE_TYPE_DMA   8

Definition at line 58 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_DPI

#define BFLB_DEVICE_TYPE_DPI   24

Definition at line 73 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_DSI

#define BFLB_DEVICE_TYPE_DSI   25

Definition at line 74 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_EF_CTRL

#define BFLB_DEVICE_TYPE_EF_CTRL   38

Definition at line 87 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_ETH

#define BFLB_DEVICE_TYPE_ETH   19

Definition at line 68 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_FLASH

#define BFLB_DEVICE_TYPE_FLASH   15

Definition at line 64 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_GPIO

#define BFLB_DEVICE_TYPE_GPIO   4

Definition at line 54 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_I2C

#define BFLB_DEVICE_TYPE_I2C   7

Definition at line 57 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_I2S

#define BFLB_DEVICE_TYPE_I2S   9

Definition at line 59 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_IR

#define BFLB_DEVICE_TYPE_IR   10

Definition at line 60 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_KYS

#define BFLB_DEVICE_TYPE_KYS   35

Definition at line 84 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_MD5

#define BFLB_DEVICE_TYPE_MD5   30

Definition at line 79 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_MIPI

#define BFLB_DEVICE_TYPE_MIPI   23

Definition at line 72 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_MJPEG

#define BFLB_DEVICE_TYPE_MJPEG   34

Definition at line 83 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_PKA

#define BFLB_DEVICE_TYPE_PKA   32

Definition at line 81 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_PLFMDMA

#define BFLB_DEVICE_TYPE_PLFMDMA   41

Definition at line 90 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_PWM

#define BFLB_DEVICE_TYPE_PWM   12

Definition at line 62 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_QSPI

#define BFLB_DEVICE_TYPE_QSPI   16

Definition at line 65 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_RNG

#define BFLB_DEVICE_TYPE_RNG   22

Definition at line 71 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_RTC

#define BFLB_DEVICE_TYPE_RTC   20

Definition at line 69 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_SDH

#define BFLB_DEVICE_TYPE_SDH   17

Definition at line 66 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_SDIO2

#define BFLB_DEVICE_TYPE_SDIO2   39

Definition at line 88 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_SDIO3

#define BFLB_DEVICE_TYPE_SDIO3   40

Definition at line 89 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_SDU

#define BFLB_DEVICE_TYPE_SDU   18

Definition at line 67 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_SHA

#define BFLB_DEVICE_TYPE_SHA   29

Definition at line 78 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_SPI

#define BFLB_DEVICE_TYPE_SPI   6

Definition at line 56 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_TIMER

#define BFLB_DEVICE_TYPE_TIMER   11

Definition at line 61 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_TRNG

#define BFLB_DEVICE_TYPE_TRNG   31

Definition at line 80 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_UART

#define BFLB_DEVICE_TYPE_UART   5

Definition at line 55 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_USB

#define BFLB_DEVICE_TYPE_USB   27

Definition at line 76 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_WDT

#define BFLB_DEVICE_TYPE_WDT   37

Definition at line 86 of file bflb_core.h.

◆ BFLB_DEVICE_TYPE_WO

#define BFLB_DEVICE_TYPE_WO   42

Definition at line 91 of file bflb_core.h.

Function Documentation

◆ bflb_device_get_by_id()

struct bflb_device_s* bflb_device_get_by_id ( uint8_t  type,
uint8_t  idx 
)

Get device handle by type and index.

Parameters
[in]typedevice type
[in]idxdevice index
Returns
device handle

◆ bflb_device_get_by_name()

struct bflb_device_s* bflb_device_get_by_name ( const char *  name)

Get device handle by name.

Parameters
[in]namedevice name
Returns
device handle

◆ bflb_device_set_userdata()

void bflb_device_set_userdata ( struct bflb_device_s device,
void *  user_data 
)

Set user data into device handle.

Parameters
[in]devicedevice handle
[in]user_datapointer to user data