Close

Library update required

A project log for Sunburn Monitor

A UV monitor which helps prevent UV-caused skin damage.

hackadayhackaday 05/09/2015 at 16:120 Comments

You need to modify the Adafruit_SI1145 library as follows (or just substitute tthe SI1145 for the SI1132):

edit Adafruit_SI1145.cpp

#include "Adafruit_SI1145.h"

Adafruit_SI1145::Adafruit_SI1145() {
  _addr = SI1145_ADDR;
}


boolean Adafruit_SI1145::begin(void) {
  Wire.begin();
 
  uint8_t id = read8(SI1145_REG_PARTID);
  // if (id != 0x45) return false; // look for SI1145
  if ((id != 0x32) && (id != 0x45)) return false; // look for SI1132 or SI1145

Discussions