Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
main.cpp
00001 #include "mbed.h" 00002 #include "MSS.h" 00003 #include "VEML7700.h" 00004 00005 #ifndef MSU_VEML7700_I2C_ADDRESS 00006 #define MSU_VEML7700_I2C_ADDRESS 0x10 00007 #endif 00008 00009 VEML7700 *veml7700 = 0 ; 00010 00011 int main(void) 00012 { 00013 uint16_t als, white ; 00014 00015 veml7700 = new VEML7700(PIN_SDA, PIN_SCL, MSU_VEML7700_I2C_ADDRESS) ; 00016 veml7700->setALSConf(0x0000) ; 00017 veml7700->setPowerSaving(0x0000) ; 00018 00019 printf("=== VEML7700 test for %s (%s) ===\n",BOARD_NAME, __DATE__) ; 00020 printf(" ALS, White\n") ; 00021 00022 while(1) { 00023 als = veml7700->getALS() ; 00024 white = veml7700->getWHITE() ; 00025 printf("%6d, %6d\n", als, white) ; 00026 wait(2) ; 00027 } 00028 }
Generated on Sun Jul 17 2022 19:25:11 by
1.7.2