Paparazzi UAS  v5.15_devel-230-gc96ce27
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
ir_mlx.c File Reference

Melexis MLX90614 I2C. More...

#include "modules/meteo/ir_mlx.h"
#include "mcu_periph/sys_time.h"
#include "mcu_periph/i2c.h"
#include "led.h"
#include "mcu_periph/uart.h"
#include "pprzlink/messages.h"
#include "subsystems/datalink/downlink.h"
+ Include dependency graph for ir_mlx.c:

Go to the source code of this file.

Macros

#define MLX_I2C_DEV   i2c0
 
#define MLX90614_ADDR   0x06
 
#define MLX90614_GENERAL_ADDR   0
 

Functions

void ir_mlx_crc (unsigned char addr, volatile unsigned char *data)
 
void ir_mlx_init (void)
 
void ir_mlx_periodic (void)
 
void ir_mlx_event (void)
 

Variables

struct i2c_transaction mlx_trans
 
uint8_t ir_mlx_status
 
uint16_t ir_mlx_itemp_case
 
float ir_mlx_temp_case
 
uint16_t ir_mlx_itemp_obj
 
float ir_mlx_temp_obj
 
uint32_t ir_mlx_id_01
 
uint32_t ir_mlx_id_23
 

Detailed Description

Melexis MLX90614 I2C.

This reads the values for temperatures from the Melexis MLX90614 IR sensor through I2C.

Definition in file ir_mlx.c.

Macro Definition Documentation

#define MLX90614_ADDR   0x06

Definition at line 56 of file ir_mlx.c.

Referenced by ir_mlx_event(), and ir_mlx_periodic().

#define MLX90614_GENERAL_ADDR   0

Definition at line 59 of file ir_mlx.c.

Referenced by ir_mlx_periodic().

#define MLX_I2C_DEV   i2c0

Definition at line 41 of file ir_mlx.c.

Referenced by ir_mlx_event(), and ir_mlx_periodic().

Function Documentation

void ir_mlx_crc ( unsigned char  addr,
volatile unsigned char *  data 
)

Definition at line 63 of file ir_mlx.c.

References crc.

Referenced by ir_mlx_periodic().

+ Here is the caller graph for this function:

void ir_mlx_init ( void  )

Definition at line 83 of file ir_mlx.c.

References IR_MLX_ADDR_CHANGE, ir_mlx_status, and IR_MLX_UNINIT.

Variable Documentation

uint32_t ir_mlx_id_01

Definition at line 51 of file ir_mlx.c.

Referenced by ir_mlx_event(), and ir_mlx_periodic().

uint32_t ir_mlx_id_23

Definition at line 52 of file ir_mlx.c.

Referenced by ir_mlx_event(), and ir_mlx_periodic().

uint16_t ir_mlx_itemp_case

Definition at line 47 of file ir_mlx.c.

Referenced by ir_mlx_event().

uint16_t ir_mlx_itemp_obj

Definition at line 49 of file ir_mlx.c.

Referenced by ir_mlx_event().

uint8_t ir_mlx_status

Definition at line 46 of file ir_mlx.c.

Referenced by ir_mlx_event(), ir_mlx_init(), and ir_mlx_periodic().

float ir_mlx_temp_case

Definition at line 48 of file ir_mlx.c.

Referenced by ir_mlx_event().

float ir_mlx_temp_obj

Definition at line 50 of file ir_mlx.c.

Referenced by ir_mlx_event().

struct i2c_transaction mlx_trans

Definition at line 44 of file ir_mlx.c.

Referenced by ir_mlx_event(), and ir_mlx_periodic().