I2C_Drivers (ARM) 1.1
SMFSW collection of HAL I2C Drivers for ARM
Loading...
Searching...
No Matches
AMG88.h File Reference

AMG88 Driver. More...

#include "sarmfsw.h"
#include "I2C_component.h"
#include "I2C_peripheral.h"
#include "AMG88_proc.h"
#include "AMG88_ex.h"
Include dependency graph for AMG88.h:
This graph shows which files directly or indirectly include this file:

Data Structures

union  uAMG88_REG__FRAME_RATE
 Union for frame rate register of AMG88. More...
 
union  uAMG88_REG__INT_CONTROL
 Union for interrupt control register of AMG88. More...
 
union  uAMG88_REG__STATUS
 Union for status register of AMG88. More...
 
union  uAMG88_REG__STATUS_CLEAR
 Union for status clear register of AMG88. More...
 
union  uAMG88_REG__AVERAGE
 Union for average register of AMG88. More...
 
union  uAMG88_REG__TEMP
 Union for any temperature register of AMG88. More...
 
union  uAMG88_REG__INT
 

Macros

#define I2C_AMG88_NB   1U
 Number of AMG88 peripherals.
 
#define AMG88_ADDR   0x68U
 AMG88 address.
 
#define AMG88_BASE_ADDR   AMG88_ADDR
 AMG88 Base address.
 

Enumerations

enum  AMG88_reg {
  AMG88__PCTL = 0U , AMG88__RST , AMG88__FPSC , AMG88__INTC ,
  AMG88__STAT , AMG88__SCLR , AMG88__AVE = 0x07U , AMG88__INTHL ,
  AMG88__INTHH , AMG88__INTLL , AMG88__INTLH , AMG88__IHYSL ,
  AMG88__IHYSH , AMG88__TTHL , AMG88__TTHH , AMG88__INT0 ,
  AMG88__INT1 , AMG88__INT2 , AMG88__INT3 , AMG88__INT4 ,
  AMG88__INT5 , AMG88__INT6 , AMG88__INT7 , AMG88__T01L = 0x80U ,
  AMG88__T01H , AMG88__T02L , AMG88__T02H , AMG88__T03L ,
  AMG88__T03H , AMG88__T04L , AMG88__T04H , AMG88__T05L ,
  AMG88__T05H , AMG88__T06L , AMG88__T06H , AMG88__T07L ,
  AMG88__T07H , AMG88__T08L , AMG88__T08H , AMG88__T09L ,
  AMG88__T09H , AMG88__T10L , AMG88__T10H , AMG88__T11L ,
  AMG88__T11H , AMG88__T12L , AMG88__T12H , AMG88__T13L ,
  AMG88__T13H , AMG88__T14L , AMG88__T14H , AMG88__T15L ,
  AMG88__T15H , AMG88__T16L , AMG88__T16H , AMG88__T17L ,
  AMG88__T17H , AMG88__T18L , AMG88__T18H , AMG88__T19L ,
  AMG88__T19H , AMG88__T20L , AMG88__T20H , AMG88__T21L ,
  AMG88__T21H , AMG88__T22L , AMG88__T22H , AMG88__T23L ,
  AMG88__T23H , AMG88__T24L , AMG88__T24H , AMG88__T25L ,
  AMG88__T25H , AMG88__T26L , AMG88__T26H , AMG88__T27L ,
  AMG88__T27H , AMG88__T28L , AMG88__T28H , AMG88__T29L ,
  AMG88__T29H , AMG88__T30L , AMG88__T30H , AMG88__T31L ,
  AMG88__T31H , AMG88__T32L , AMG88__T32H , AMG88__T33L ,
  AMG88__T33H , AMG88__T34L , AMG88__T34H , AMG88__T35L ,
  AMG88__T35H , AMG88__T36L , AMG88__T36H , AMG88__T37L ,
  AMG88__T37H , AMG88__T38L , AMG88__T38H , AMG88__T39L ,
  AMG88__T39H , AMG88__T40L , AMG88__T40H , AMG88__T41L ,
  AMG88__T41H , AMG88__T42L , AMG88__T42H , AMG88__T43L ,
  AMG88__T43H , AMG88__T44L , AMG88__T44H , AMG88__T45L ,
  AMG88__T45H , AMG88__T46L , AMG88__T46H , AMG88__T47L ,
  AMG88__T47H , AMG88__T48L , AMG88__T48H , AMG88__T49L ,
  AMG88__T49H , AMG88__T50L , AMG88__T50H , AMG88__T51L ,
  AMG88__T51H , AMG88__T52L , AMG88__T52H , AMG88__T53L ,
  AMG88__T53H , AMG88__T54L , AMG88__T54H , AMG88__T55L ,
  AMG88__T55H , AMG88__T56L , AMG88__T56H , AMG88__T57L ,
  AMG88__T57H , AMG88__T58L , AMG88__T58H , AMG88__T59L ,
  AMG88__T59H , AMG88__T60L , AMG88__T60H , AMG88__T61L ,
  AMG88__T61H , AMG88__T62L , AMG88__T62H , AMG88__T63L ,
  AMG88__T63H , AMG88__T64L , AMG88__T64H
}
 Register map enum of AMG88. More...
 
enum  AMG88_reset { AMG88__FLAG_RESET = 0x30U , AMG88__INITIAL_RESET = 0x3FU }
 Reset types for AMG88. More...
 
enum  AMG88_mode { AMG88__NORMAL = 0U , AMG88__SLEEP = 0x10U , AMG88__STANBY_60 = 0x20U , AMG88__STANBY_10 = 0x21U }
 Operating modes for AMG88. More...
 

Functions

FctERR AMG88_Init (const uint8_t idx, I2C_HandleTypeDef *const hi2c, const uint16_t devAddress)
 Initialization for AMG88 peripheral.
 
FctERR AMG88_Init_Single (void)
 Initialization for AMG88 peripheral.
 
FctERR AMG88_Write (I2C_slave_t *const pSlave, const uint8_t *data, const uint16_t addr, const uint16_t nb)
 I2C Write function for AMG88.
 
FctERR AMG88_Read (I2C_slave_t *const pSlave, uint8_t *data, const uint16_t addr, const uint16_t nb)
 I2C Read function for AMG88.
 
FctERR AMG88_Write_Word (I2C_slave_t *const pSlave, const uint16_t *data, const uint16_t addr)
 I2C Word Write (little endian) function for AMG88.
 
FctERR AMG88_Read_Word (I2C_slave_t *const pSlave, uint16_t *data, const uint16_t addr)
 I2C Word Read (little endian) function for AMG88.
 

Detailed Description

AMG88 Driver.

Author
SMFSW

AMG88: Infrared Array Sensor (Grid-EYE)

Macro Definition Documentation

◆ AMG88_ADDR

#define AMG88_ADDR   0x68U

AMG88 address.

◆ AMG88_BASE_ADDR

#define AMG88_BASE_ADDR   AMG88_ADDR

AMG88 Base address.

Note
Define AMG88_BASE_ADDR to change default device base address

◆ I2C_AMG88_NB

#define I2C_AMG88_NB   1U

Number of AMG88 peripherals.

Note
Define I2C_AMG88_NB to enable multiple peripherals of this type

Enumeration Type Documentation

◆ AMG88_mode

enum AMG88_mode

Operating modes for AMG88.

Enumerator
AMG88__NORMAL 

Normal mode.

AMG88__SLEEP 

Sleep mode.

AMG88__STANBY_60 

Stand-by mode (60s intermittence)

AMG88__STANBY_10 

Stand-by mode (10s intermittence)

◆ AMG88_reg

enum AMG88_reg

Register map enum of AMG88.

Enumerator
AMG88__PCTL 

Set operating mode(Normal, Sleep etc.)

AMG88__RST 

Software Reset.

AMG88__FPSC 

Frame rate.

AMG88__INTC 

Interrupt Function.

AMG88__STAT 

Interrupt Flag, low voltage Flag.

AMG88__SCLR 

Interrupt Flag Clear.

AMG88__AVE 

Moving Average Output Mode.

AMG88__INTHL 

Interrupt upper value(Lower level)

AMG88__INTHH 

Interrupt upper value(Upper level)

AMG88__INTLL 

Interrupt lower value(Lower level)

AMG88__INTLH 

Interrupt lower value(Upper level)

AMG88__IHYSL 

Interrupt hysteresis value(Lower level)

AMG88__IHYSH 

Interrupt hysteresis value(Upper level)

AMG88__TTHL 

Thermistor Output Value(Lower level)

AMG88__TTHH 

Thermistor Output Value(Upper level)

AMG88__INT0 

Pixel 1~8 Interrupt Result.

AMG88__INT1 

Pixel 9~16 Interrupt Result.

AMG88__INT2 

Pixel 17~24 Interrupt Result.

AMG88__INT3 

Pixel 25~32 Interrupt Result.

AMG88__INT4 

Pixel 33~40 Interrupt Result.

AMG88__INT5 

Pixel 41~48 Interrupt Result.

AMG88__INT6 

Pixel 49~56 Interrupt Result.

AMG88__INT7 

Pixel 57~64 Interrupt Result.

AMG88__T01L 

Pixel 01 Output Value (Lower Level)

AMG88__T01H 

Pixel 01 Output Value (Upper Level)

AMG88__T02L 

Pixel 02 Output Value (Lower Level)

AMG88__T02H 

Pixel 02 Output Value (Upper Level)

AMG88__T03L 

Pixel 03 Output Value (Lower Level)

AMG88__T03H 

Pixel 03 Output Value (Upper Level)

AMG88__T04L 

Pixel 04 Output Value (Lower Level)

AMG88__T04H 

Pixel 04 Output Value (Upper Level)

AMG88__T05L 

Pixel 05 Output Value (Lower Level)

AMG88__T05H 

Pixel 05 Output Value (Upper Level)

AMG88__T06L 

Pixel 06 Output Value (Lower Level)

AMG88__T06H 

Pixel 06 Output Value (Upper Level)

AMG88__T07L 

Pixel 07 Output Value (Lower Level)

AMG88__T07H 

Pixel 07 Output Value (Upper Level)

AMG88__T08L 

Pixel 08 Output Value (Lower Level)

AMG88__T08H 

Pixel 08 Output Value (Upper Level)

AMG88__T09L 

Pixel 09 Output Value (Lower Level)

AMG88__T09H 

Pixel 09 Output Value (Upper Level)

AMG88__T10L 

Pixel 10 Output Value (Lower Level)

AMG88__T10H 

Pixel 10 Output Value (Upper Level)

AMG88__T11L 

Pixel 11 Output Value (Lower Level)

AMG88__T11H 

Pixel 11 Output Value (Upper Level)

AMG88__T12L 

Pixel 12 Output Value (Lower Level)

AMG88__T12H 

Pixel 12 Output Value (Upper Level)

AMG88__T13L 

Pixel 13 Output Value (Lower Level)

AMG88__T13H 

Pixel 13 Output Value (Upper Level)

AMG88__T14L 

Pixel 14 Output Value (Lower Level)

AMG88__T14H 

Pixel 14 Output Value (Upper Level)

AMG88__T15L 

Pixel 15 Output Value (Lower Level)

AMG88__T15H 

Pixel 15 Output Value (Upper Level)

AMG88__T16L 

Pixel 16 Output Value (Lower Level)

AMG88__T16H 

Pixel 16 Output Value (Upper Level)

AMG88__T17L 

Pixel 17 Output Value (Lower Level)

AMG88__T17H 

Pixel 17 Output Value (Upper Level)

AMG88__T18L 

Pixel 18 Output Value (Lower Level)

AMG88__T18H 

Pixel 18 Output Value (Upper Level)

AMG88__T19L 

Pixel 19 Output Value (Lower Level)

AMG88__T19H 

Pixel 19 Output Value (Upper Level)

AMG88__T20L 

Pixel 20 Output Value (Lower Level)

AMG88__T20H 

Pixel 20 Output Value (Upper Level)

AMG88__T21L 

Pixel 21 Output Value (Lower Level)

AMG88__T21H 

Pixel 21 Output Value (Upper Level)

AMG88__T22L 

Pixel 22 Output Value (Lower Level)

AMG88__T22H 

Pixel 22 Output Value (Upper Level)

AMG88__T23L 

Pixel 23 Output Value (Lower Level)

AMG88__T23H 

Pixel 23 Output Value (Upper Level)

AMG88__T24L 

Pixel 24 Output Value (Lower Level)

AMG88__T24H 

Pixel 24 Output Value (Upper Level)

AMG88__T25L 

Pixel 25 Output Value (Lower Level)

AMG88__T25H 

Pixel 25 Output Value (Upper Level)

AMG88__T26L 

Pixel 26 Output Value (Lower Level)

AMG88__T26H 

Pixel 26 Output Value (Upper Level)

AMG88__T27L 

Pixel 27 Output Value (Lower Level)

AMG88__T27H 

Pixel 27 Output Value (Upper Level)

AMG88__T28L 

Pixel 28 Output Value (Lower Level)

AMG88__T28H 

Pixel 28 Output Value (Upper Level)

AMG88__T29L 

Pixel 29 Output Value (Lower Level)

AMG88__T29H 

Pixel 29 Output Value (Upper Level)

AMG88__T30L 

Pixel 30 Output Value (Lower Level)

AMG88__T30H 

Pixel 30 Output Value (Upper Level)

AMG88__T31L 

Pixel 31 Output Value (Lower Level)

AMG88__T31H 

Pixel 31 Output Value (Upper Level)

AMG88__T32L 

Pixel 32 Output Value (Lower Level)

AMG88__T32H 

Pixel 32 Output Value (Upper Level)

AMG88__T33L 

Pixel 33 Output Value (Lower Level)

AMG88__T33H 

Pixel 33 Output Value (Upper Level)

AMG88__T34L 

Pixel 34 Output Value (Lower Level)

AMG88__T34H 

Pixel 34 Output Value (Upper Level)

AMG88__T35L 

Pixel 35 Output Value (Lower Level)

AMG88__T35H 

Pixel 35 Output Value (Upper Level)

AMG88__T36L 

Pixel 36 Output Value (Lower Level)

AMG88__T36H 

Pixel 36 Output Value (Upper Level)

AMG88__T37L 

Pixel 37 Output Value (Lower Level)

AMG88__T37H 

Pixel 37 Output Value (Upper Level)

AMG88__T38L 

Pixel 38 Output Value (Lower Level)

AMG88__T38H 

Pixel 38 Output Value (Upper Level)

AMG88__T39L 

Pixel 39 Output Value (Lower Level)

AMG88__T39H 

Pixel 39 Output Value (Upper Level)

AMG88__T40L 

Pixel 40 Output Value (Lower Level)

AMG88__T40H 

Pixel 40 Output Value (Upper Level)

AMG88__T41L 

Pixel 41 Output Value (Lower Level)

AMG88__T41H 

Pixel 41 Output Value (Upper Level)

AMG88__T42L 

Pixel 42 Output Value (Lower Level)

AMG88__T42H 

Pixel 42 Output Value (Upper Level)

AMG88__T43L 

Pixel 43 Output Value (Lower Level)

AMG88__T43H 

Pixel 43 Output Value (Upper Level)

AMG88__T44L 

Pixel 44 Output Value (Lower Level)

AMG88__T44H 

Pixel 44 Output Value (Upper Level)

AMG88__T45L 

Pixel 45 Output Value (Lower Level)

AMG88__T45H 

Pixel 45 Output Value (Upper Level)

AMG88__T46L 

Pixel 46 Output Value (Lower Level)

AMG88__T46H 

Pixel 46 Output Value (Upper Level)

AMG88__T47L 

Pixel 47 Output Value (Lower Level)

AMG88__T47H 

Pixel 47 Output Value (Upper Level)

AMG88__T48L 

Pixel 48 Output Value (Lower Level)

AMG88__T48H 

Pixel 48 Output Value (Upper Level)

AMG88__T49L 

Pixel 49 Output Value (Lower Level)

AMG88__T49H 

Pixel 49 Output Value (Upper Level)

AMG88__T50L 

Pixel 50 Output Value (Lower Level)

AMG88__T50H 

Pixel 50 Output Value (Upper Level)

AMG88__T51L 

Pixel 51 Output Value (Lower Level)

AMG88__T51H 

Pixel 51 Output Value (Upper Level)

AMG88__T52L 

Pixel 52 Output Value (Lower Level)

AMG88__T52H 

Pixel 52 Output Value (Upper Level)

AMG88__T53L 

Pixel 53 Output Value (Lower Level)

AMG88__T53H 

Pixel 53 Output Value (Upper Level)

AMG88__T54L 

Pixel 54 Output Value (Lower Level)

AMG88__T54H 

Pixel 54 Output Value (Upper Level)

AMG88__T55L 

Pixel 55 Output Value (Lower Level)

AMG88__T55H 

Pixel 55 Output Value (Upper Level)

AMG88__T56L 

Pixel 56 Output Value (Lower Level)

AMG88__T56H 

Pixel 56 Output Value (Upper Level)

AMG88__T57L 

Pixel 57 Output Value (Lower Level)

AMG88__T57H 

Pixel 57 Output Value (Upper Level)

AMG88__T58L 

Pixel 58 Output Value (Lower Level)

AMG88__T58H 

Pixel 58 Output Value (Upper Level)

AMG88__T59L 

Pixel 59 Output Value (Lower Level)

AMG88__T59H 

Pixel 59 Output Value (Upper Level)

AMG88__T60L 

Pixel 60 Output Value (Lower Level)

AMG88__T60H 

Pixel 60 Output Value (Upper Level)

AMG88__T61L 

Pixel 61 Output Value (Lower Level)

AMG88__T61H 

Pixel 61 Output Value (Upper Level)

AMG88__T62L 

Pixel 62 Output Value (Lower Level)

AMG88__T62H 

Pixel 62 Output Value (Upper Level)

AMG88__T63L 

Pixel 63 Output Value (Lower Level)

AMG88__T63H 

Pixel 63 Output Value (Upper Level)

AMG88__T64L 

Pixel 64 Output Value (Lower Level)

AMG88__T64H 

Pixel 64 Output Value (Upper Level)

◆ AMG88_reset

Reset types for AMG88.

Enumerator
AMG88__FLAG_RESET 

Flag Reset can all clear the Status Register(0x04),Interrupt Flag, and Interrupt Table(0x10~0x17).

AMG88__INITIAL_RESET 

Initial Reset brings Flag reset and returns to initial setting.

Function Documentation

◆ AMG88_Init()

FctERR AMG88_Init ( const uint8_t idx,
I2C_HandleTypeDef *const hi2c,
const uint16_t devAddress )

Initialization for AMG88 peripheral.

Parameters
[in]idx- AMG88 index
[in]hi2c- pointer to AMG88 I2C instance
[in]devAddress- AMG88 device address
Returns
FctERR - error code
Here is the call graph for this function:
Here is the caller graph for this function:

◆ AMG88_Init_Single()

FctERR AMG88_Init_Single ( void )

Initialization for AMG88 peripheral.

Warning
In case multiple devices (defined by I2C_AMG88_NB > 1), you shall use AMG88_Init instead
Returns
FctERR - error code
Here is the call graph for this function:

◆ AMG88_Read()

FctERR AMG88_Read ( I2C_slave_t *const pSlave,
uint8_t * data,
const uint16_t addr,
const uint16_t nb )

I2C Read function for AMG88.

Parameters
[in]pSlave- Pointer to I2C slave instance
[in,out]data- pointer to read to
[in]addr- Address to read from
[in]nb- Number of bytes to read
Returns
FctERR - error code
Here is the call graph for this function:
Here is the caller graph for this function:

◆ AMG88_Read_Word()

FctERR AMG88_Read_Word ( I2C_slave_t *const pSlave,
uint16_t * data,
const uint16_t addr )

I2C Word Read (little endian) function for AMG88.

Parameters
[in,out]pSlave- Pointer to I2C slave instance
[in,out]data- pointer to read to
[in]addr- Address to read from
Returns
FctERR - error code
Here is the call graph for this function:
Here is the caller graph for this function:

◆ AMG88_Write()

FctERR AMG88_Write ( I2C_slave_t *const pSlave,
const uint8_t * data,
const uint16_t addr,
const uint16_t nb )

I2C Write function for AMG88.

Parameters
[in]pSlave- Pointer to I2C slave instance
[in]data- pointer to write from
[in]addr- Address to write to
[in]nb- Number of bytes to write
Returns
FctERR - error code
Here is the call graph for this function:
Here is the caller graph for this function:

◆ AMG88_Write_Word()

FctERR AMG88_Write_Word ( I2C_slave_t *const pSlave,
const uint16_t * data,
const uint16_t addr )

I2C Word Write (little endian) function for AMG88.

Parameters
[in,out]pSlave- Pointer to I2C slave instance
[in]data- pointer to write from
[in]addr- Address to write to
Returns
FctERR - error code
Here is the call graph for this function: