Mini can app
Dependencies: mbed mbed-STM32F103C8T6
spl0601.h
00001 #ifndef SPL06_01_H 00002 #define SPL06_01_H 00003 00004 00005 #define SPL0601_ADR 0x76 00006 00007 #define PRS_REG 0x00 00008 #define TMP_REG 0x03 00009 00010 #define PRS_CFG 0x06 00011 #define TRS_CFG 0x07 00012 #define MEAS_CFG 0x08 00013 00014 #define CFG_REG 0x09 00015 00016 #define COEF_SRC 0x28 00017 00018 #define PRESS_RD_1_SEC 0x01 00019 #define PRESS_OVER_SMPL 0x00 // single 00020 #define TEMP_RD_RATE_1_SEC 0x83 // 1 per second, single oversmaple 00021 #define MEAS_RATE 0x07 00022 00023 #define CAL_C0 0x10 // 8 bytes of cal 00024 00025 #include "mbed.h" 00026 #include <stdint.h> 00027 #include "wiced_types.h" 00028 00029 PinName const SDA = PB_7; 00030 PinName const SCL = PB_6; 00031 00032 extern int16_t c0; 00033 extern int16_t c1; 00034 extern int32_t c00, c10; 00035 extern int16_t c01, c11, c20, c21, c30; 00036 00037 void Init_SPL0601(); 00038 void DeInit_SPL0601(); 00039 00040 int16_t getInt16(uint8_t *importval); 00041 int16_t getInt12IntoInt16(uint8_t* importval, wiced_bool_t leading4Bits); 00042 int32_t getInt20IntoInt32(uint8_t* importval, wiced_bool_t leading4Bits); 00043 int32_t getInt24IntoInt32(uint8_t* importval); 00044 wiced_bool_t getPressure(double* result); 00045 #endif
Generated on Fri Jul 15 2022 20:08:26 by
1.7.2