Maxim I2C temperature sensor library for MAX31725. Choose I2C address per data sheet based on pin connections.
MAX31725.h
- Committer:
- laserdad
- Date:
- 2017-08-16
- Revision:
- 0:8ba1cde7adb6
File content as of revision 0:8ba1cde7adb6:
#ifndef __MAX31725_H__ #define __MAX31725_H__ #include "mbed.h" #define MAX31725_ADDR 0x92 //this is the 8-bit address #define MAX31725_CONVERSION_TIME_MS 44 class MAX31725 { public: void writeRegister(uint8_t, uint8_t, uint8_t); void writeBlock(uint8_t, uint8_t, uint8_t *, uint8_t); void readRegisters(uint8_t, uint8_t, char *, int); uint16_t LSB_MSB_2uint16(char *); uint16_t MSB_LSB_2uint16(char *); void regDump(uint8_t, uint8_t, uint8_t); bool bitRead(uint16_t, uint8_t); float getTemp(void); }; #endif