Vishay UV Sensor I2C library

Dependents:   test_VEML6075 quattro_vishay_6075_171018 testSensor

Files at this revision

API Documentation at this revision

Comitter:
Rhyme
Date:
Fri Oct 27 04:56:45 2017 +0000
Parent:
3:d0d23d5abf34
Commit message:
coefficients updated to reflect the values in the AN

Changed in this revision

VEML6075.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r d0d23d5abf34 -r 9518befb9fd3 VEML6075.cpp
--- a/VEML6075.cpp	Fri May 19 05:20:22 2017 +0000
+++ b/VEML6075.cpp	Fri Oct 27 04:56:45 2017 +0000
@@ -21,16 +21,17 @@
 // Following magic numbers are from 
 // VISHAY veml6075 Application Note 84339
 // Page 6 
-#define UVA_A_COEF  (2.5)
-#define UVA_B_COEF  (2.5)
-#define UVB_C_COEF  (2.75)
-#define UVB_D_COEF  (2.75)
+#define UVA_A_COEF  (2.22)
+#define UVA_B_COEF  (1.33)
+#define UVB_C_COEF  (2.95)
+#define UVB_D_COEF  (1.74)
 #define UVA_sensitivity (0.93)
 #define UVA_CIE_sensitivity (0.093)
 #define UVB_sensitivity (2.1)
 #define UVB_CIE_sensitivity (0.21)
-#define UVA_RESPONSIVITY (0.0011)
-#define UVB_RESPONSIVITY (0.00125)
+// from page 15
+#define UVA_RESPONSIVITY (0.001461)
+#define UVB_RESPONSIVITY (0.002591)
 
 VEML6075::VEML6075(PinName sda, PinName scl, int addr) : m_i2c(sda, scl), m_addr(addr<<1) {
     // activate the peripheral