{"id":2228,"date":"2020-04-17T07:49:51","date_gmt":"2020-04-17T14:49:51","guid":{"rendered":"http:\/\/www.donluc.com\/?p=2228"},"modified":"2020-04-17T07:49:51","modified_gmt":"2020-04-17T14:49:51","slug":"project-15-environment-adafruit-adalogger-featherwing-rtc-sd-mk03","status":"publish","type":"post","link":"https:\/\/www.donluc.com\/?p=2228","title":{"rendered":"Project #15: Environment &#8211; Adafruit Adalogger FeatherWing &#8211; RTC + SD &#8211; Mk03"},"content":{"rendered":"<div style=\"width: 720px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-2228-1\" width=\"720\" height=\"406\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/dl2004mk09.mp4?_=1\" \/><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/dl2004mk09.mp4\">https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/dl2004mk09.mp4<\/a><\/video><\/div>\n<p>&#8212;&#8212;<\/p>\n<p>#DonLuc #Environment #Microcontrollers #ESP32 #Adalogger #SparkFun #Fritzing #Programming #Adafruit #Arduino #Electronics #Consultant #Vlog #Aphasia<\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09a.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09a.png\" alt=\"Environment\" width=\"720\" height=\"457\" class=\"alignnone size-full wp-image-2230\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09a.png 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09a-300x190.png 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09b.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09b.png\" alt=\"Environment\" width=\"720\" height=\"480\" class=\"alignnone size-full wp-image-2231\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09b.png 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09b-300x200.png 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09c.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09c.png\" alt=\"Environment\" width=\"720\" height=\"480\" class=\"alignnone size-full wp-image-2232\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09c.png 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09c-300x200.png 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09d.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09d.png\" alt=\"Environment\" width=\"720\" height=\"480\" class=\"alignnone size-full wp-image-2233\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09d.png 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09d-300x200.png 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09e.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09e.png\" alt=\"Environment\" width=\"720\" height=\"480\" class=\"alignnone size-full wp-image-2234\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09e.png 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2020\/04\/DL2004Mk09e-300x200.png 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><strong>DL2004Mk09<\/strong><\/p>\n<p>1 x SparkFun Thing Plus &#8211; ESP32 WROOM<br \/>\n1 x Adafruit SHARP Memory Display<br \/>\n1 x SparkFun Environmental Combo Breakout &#8211; CCS811\/BME280<br \/>\n1 x Adafruit Adalogger FeatherWing &#8211; RTC + SD<br \/>\n1 x CR1220 12mm Lithium Battery<br \/>\n1 x 32Gb microSD Card<br \/>\n1 x Mountable Slide Switch<br \/>\n1 x Qwiic Cable &#8211; 100mm<br \/>\n1 x LED Green<br \/>\n1 x 10K Ohm<br \/>\n2 x Jumper Wires 3in M\/M<br \/>\n5 x Jumper Wires 6in M\/M<br \/>\n10 x Wire Solid Core &#8211; 22 AWG<br \/>\n1 x Full-Size Breadboard<br \/>\n1 x SparkFun Cerberus USB Cable<\/p>\n<p><strong>SparkFun Thing Plus &#8211; ESP32 WROOM<\/strong><\/p>\n<p>LEG &#8211; Digital 21<br \/>\nSCK &#8211; Digital 13<br \/>\nMOS &#8211; Digital 12<br \/>\nSSD &#8211; Digital 27<br \/>\nSDA &#8211; Digital 23<br \/>\nSCL &#8211; Digital 22<br \/>\nSD1 &#8211; Digital 33<br \/>\nSC2 &#8211; Digital 5<br \/>\nMO2 &#8211; Digital 18<br \/>\nMI2 &#8211; Digital 19<br \/>\nSS1 &#8211; Digital 16<br \/>\nVIN &#8211; +3.3V<br \/>\nGND &#8211; GND<\/p>\n<p><strong>DL2004Mk09p.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"default\" data-enlighter-title=\"DL2004Mk09p.ino\">\r\n\/\/ ***** Don Luc Electronics \u00a9 *****\r\n\/\/ Software Version Information\r\n\/\/ Project #15: Environment - Adafruit Adalogger FeatherWing - RTC + SD - Mk03\r\n\/\/ 04-09\r\n\/\/ DL2004Mk09p.ino 15-03\r\n\/\/ EEPROM with Unique ID\r\n\/\/ 1 x SparkFun Thing Plus - ESP32 WROOM\r\n\/\/ 1 x Adafruit SHARP Memory Display\r\n\/\/ 1 x SparkFun Environmental Combo Breakout - CCS811\/BME280\r\n\/\/ 1 x Adafruit Adalogger FeatherWing - RTC + SD\r\n\/\/ 1 x CR1220 12mm Lithium Battery\r\n\/\/ 1 x 32Gb microSD Card\r\n\/\/ 1 x Mountable Slide Switch\r\n\/\/ 1 x Qwiic Cable - 100mm\r\n\/\/ 1 x LED Green\r\n\/\/ 1 x 10K Ohm\r\n\/\/ 2 x Jumper Wires 3in M\/M\r\n\/\/ 5 x Jumper Wires 6in M\/M\r\n\/\/ 10 x Wire Solid Core - 22 AWG\r\n\/\/ 1 x Full-Size Breadboard\r\n\/\/ 1 x SparkFun Cerberus USB Cable\r\n\r\n\/\/ Include the Library Code\r\n\/\/ EEPROM Library to Read and Write EEPROM with Unique ID for Unit\r\n#include &quot;EEPROM.h&quot;\r\n\/\/ Wire\r\n#include &lt;Wire.h&gt;\r\n\/\/ SHARP Memory Display\r\n#include &lt;Adafruit_SharpMem.h&gt;\r\n#include &lt;Adafruit_GFX.h&gt;\r\n\/\/ SparkFun CCS811 - eCO2 &amp; tVOC\r\n#include &lt;SparkFunCCS811.h&gt;\r\n\/\/ SparkFun BME280 - Humidity, Temperature, Altitude and Barometric Pressure\r\n#include &lt;SparkFunBME280.h&gt;\r\n\/\/ Date and Time\r\n#include &quot;RTClib.h&quot;\r\n\/\/ SD Card\r\n#include &quot;FS.h&quot;\r\n#include &quot;SD.h&quot;\r\n#include &quot;SPI.h&quot;\r\n\r\n\/\/ LED Green\r\nint iLEDGreen = 21;\r\n\r\n\/\/ SHARP Memory Display\r\n\/\/ any pins can be used\r\n#define SHARP_SCK  13\r\n#define SHARP_MOSI 12\r\n#define SHARP_SS   27\r\n\/\/ Set the size of the display here - 144x168\r\nAdafruit_SharpMem display(SHARP_SCK, SHARP_MOSI, SHARP_SS, 144, 168);\r\n\/\/ The currently-available SHARP Memory Display (144x168 pixels)\r\n\/\/ requires &gt; 4K of microcontroller RAM; it WILL NOT WORK on Arduino Uno\r\n\/\/ or other &lt;4K &quot;classic&quot; devices!\r\n#define BLACK 0\r\n#define WHITE 1\r\n\/\/ 1\/2 of lesser of display width or height\r\nint minorHalfSize; \r\n\r\n\/\/ SparkFun CCS811 - eCO2 &amp; tVOC\r\n\/\/ Default I2C Address\r\n#define CCS811_ADDR 0x5B \r\nCCS811 myCCS811(CCS811_ADDR);\r\nfloat CCS811CO2 = 0;\r\nfloat CCS811TVOC = 0;\r\n\r\n\/\/ SparkFun BME280 - Humidity, Temperature, Altitude and Barometric Pressure\r\nBME280 myBME280;\r\nfloat BMEtempC = 0;\r\nfloat BMEhumid = 0;\r\nfloat BMEaltitudeM = 0;\r\nfloat BMEpressure = 0;\r\n\r\n\/\/ Date and Time\r\n\/\/ PCF8523 Precision RTC \r\nRTC_PCF8523 rtc;\r\nString dateRTC = &quot;&quot;;\r\nString timeRTC = &quot;&quot;;\r\n\r\n\/\/ microSD Card\r\nconst int chipSelect = 33;\r\nString zzzzzz = &quot;&quot;;\r\n\r\n\/\/ Mountable Slide Switch\r\nint iSS1 = 16;\r\n\/\/ State\r\nint iSS1State = 0;\r\n\r\n\/\/ Software Version Information\r\nString sver = &quot;15-03&quot;;\r\n\/\/ EEPROM Unique ID Information\r\n#define EEPROM_SIZE 64\r\nString uid = &quot;&quot;;\r\n\r\nvoid loop() {\r\n\r\n  \/\/ Date and Time \r\n  isRTC();\r\n  \r\n  \/\/ SparkFun BME280 - Humidity, Temperature, Altitude and Barometric Pressure\r\n  isBME280();\r\n\r\n  \/\/ SparkFun CCS811 - eCO2 &amp; tVOC\r\n  isCCS811();\r\n\r\n  \/\/ Display Environmental\r\n  isDisplayEnvironmental();\r\n\r\n  \/\/ Slide Switch\r\n  \/\/ Read the state of the iSS1 value\r\n  iSS1State = digitalRead(iSS1);\r\n  \r\n  \/\/ If it is the Slide Switch State is HIGH\r\n  if (iSS1State == HIGH) {\r\n\r\n    \/\/ iLEDGreen\r\n    digitalWrite(iLEDGreen,  HIGH );\r\n    \r\n    \/\/ microSD Card\r\n    isSD();\r\n\r\n  } else {\r\n\r\n    \/\/ iLEDGreen\r\n    digitalWrite(iLEDGreen,  LOW );\r\n  \r\n  }\r\n\r\n  delay( 1000 );\r\n  \r\n}\r\n<\/pre>\n<p><strong>getBME280.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"default\" data-enlighter-title=\"getBME280.ino\">\r\n\/\/ SparkFun BME280 - Humidity, Temperature, Altitude and Barometric Pressure\r\n\/\/ isBME280 - Humidity, Temperature, Altitude and Barometric Pressure\r\nvoid isBME280(){\r\n\r\n  \/\/ Temperature Celsius\r\n  BMEtempC = myBME280.readTempC();\r\n  \/\/ Humidity\r\n  BMEhumid = myBME280.readFloatHumidity();\r\n  \/\/ Altitude Meters\r\n  BMEaltitudeM = (myBME280.readFloatAltitudeMeters(), 2);\r\n  \/\/ Barometric Pressure\r\n  BMEpressure = myBME280.readFloatPressure();\r\n  \r\n}\r\n<\/pre>\n<p><strong>getCCS811.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"default\" data-enlighter-title=\"getCCS811.ino\">\r\n\/\/ CCS811 - eCO2 &amp; tVOC\r\n\/\/ isCCS811 - eCO2 &amp; tVOC\r\nvoid isCCS811(){\r\n\r\n  \/\/ This sends the temperature &amp; humidity data to the CCS811\r\n  myCCS811.setEnvironmentalData(BMEhumid, BMEtempC);\r\n\r\n  \/\/ Calling this function updates the global tVOC and eCO2 variables\r\n  myCCS811.readAlgorithmResults();\r\n\r\n  \/\/ eCO2 Concentration\r\n  CCS811CO2 = myCCS811.getCO2();\r\n  \r\n  \/\/ tVOC Concentration\r\n  CCS811TVOC = myCCS811.getTVOC();\r\n  \r\n}\r\n<\/pre>\n<p><strong>getDisplay.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"default\" data-enlighter-title=\"getDisplay.ino\">\r\n\/\/ Display\r\n\/\/ SHARP Memory Display - UID\r\nvoid isDisplayUID() {\r\n\r\n    \/\/ Text Display \r\n    display.setRotation(4);\r\n    display.setTextSize(3);\r\n    display.setTextColor(BLACK);\r\n    \/\/ Don Luc Electronics\r\n    display.setCursor(0,10);\r\n    display.println( &quot;Don Luc&quot; );\r\n    display.setTextSize(2);\r\n    display.setCursor(0,40);\r\n    display.println( &quot;Electronics&quot; );\r\n    \/\/ Version\r\n    display.setTextSize(3);\r\n    display.setCursor(0,70);\r\n    display.println( &quot;Version&quot; );\r\n    display.setTextSize(2);\r\n    display.setCursor(0,100);   \r\n    display.println( sver );\r\n    \/\/ EEPROM Unique ID\r\n    display.setTextSize(1);\r\n    display.setCursor(0,130);\r\n    display.println( &quot;EEPROM Unique ID&quot; );\r\n    display.setTextSize(2);\r\n    display.setCursor(0,145);\r\n    display.println( uid );\r\n    \/\/ Refresh\r\n    display.refresh();\r\n    delay( 100 );\r\n    \r\n}\r\n\/\/ Display Environmental\r\nvoid isDisplayEnvironmental(){\r\n\r\n    \/\/ Text Display Environmental\r\n    \/\/ Clear Display\r\n    display.clearDisplay();\r\n    display.setRotation(4);\r\n    display.setTextSize(1);\r\n    display.setTextColor(BLACK);\r\n    \/\/ Temperature Celsius\r\n    display.setCursor(0,0);\r\n    display.println( &quot;Temperature Celsius&quot; );\r\n    display.setCursor(0,10);\r\n    display.print( BMEtempC );\r\n    display.println( &quot; C&quot; );\r\n    \/\/ Humidity\r\n    display.setCursor(0,20);\r\n    display.println( &quot;Humidity&quot; );\r\n    display.setCursor(0,30);\r\n    display.print( BMEhumid );\r\n    display.println( &quot;%&quot; );\r\n    \/\/ Altitude Meters\r\n    display.setCursor(0,40);\r\n    display.println( &quot;Altitude Meters&quot; );\r\n    display.setCursor(0,50);\r\n    display.print( BMEaltitudeM );\r\n    display.println( &quot; m&quot; );\r\n    \/\/ Pressure\r\n    display.setCursor(0,60);    \r\n    display.println( &quot;Barometric Pressure&quot; );\r\n    display.setCursor(0,70);\r\n    display.print( BMEpressure );\r\n    display.println( &quot; Pa&quot; );\r\n    \/\/ eCO2 Concentration\r\n    display.setCursor(0,80);\r\n    display.println( &quot;eCO2 Concentration&quot; );\r\n    display.setCursor(0,90);\r\n    display.print( CCS811CO2 );\r\n    display.println( &quot; ppm&quot; );\r\n    \/\/ tVOC Concentration\r\n    display.setCursor(0,100);\r\n    display.println( &quot;tVOC Concentration&quot; );\r\n    display.setCursor(0,110);\r\n    display.print( CCS811TVOC );\r\n    display.println( &quot; ppb&quot; );\r\n    \/\/ Date\r\n    display.setCursor(0,120);\r\n    display.println( dateRTC );\r\n    \/\/ Time\r\n    display.setCursor(0,130);\r\n    display.println( timeRTC );\r\n    \/\/ Refresh\r\n    display.refresh();\r\n    delay( 100 );\r\n\r\n}\r\n<\/pre>\n<p><strong>getEEPROM.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"default\" data-enlighter-title=\"getEEPROM.ino\">\r\n\/\/ EEPROM\r\n\/\/ isUID EEPROM Unique ID\r\nvoid isUID()\r\n{\r\n  \r\n  \/\/ Is Unit ID\r\n  uid = &quot;&quot;;\r\n  for (int x = 0; x &lt; 5; x++)\r\n  {\r\n    uid = uid + char(EEPROM.read(x));\r\n  }\r\n  \r\n}\r\n<\/pre>\n<p><strong>getRTC.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"default\" data-enlighter-title=\"getRTC.ino\">\r\n\/\/ Date &amp; Time\r\n\/\/ PCF8523 Precision RTC \r\nvoid setupRTC() {\r\n\r\n  \/\/ Date &amp; Time\r\n  \/\/ pcf8523 Precision RTC   \r\n  if (! rtc.begin()) {\r\n    while (1);\r\n  }  \r\n  \r\n  if (! rtc.initialized()) {\r\n    \/\/ Following line sets the RTC to the date &amp; time this sketch was compiled\r\n    rtc.adjust(DateTime(F(__DATE__), F(__TIME__)));\r\n    \/\/ This line sets the RTC with an explicit date &amp; time, for example to set\r\n    \/\/ January 21, 2014 at 3am you would call:\r\n    \/\/ rtc.adjust(DateTime(2018, 9, 29, 12, 17, 0));\r\n  }\r\n  \r\n}\r\n\/\/ Date and Time RTC\r\nvoid isRTC () {\r\n\r\n  \/\/ Date and Time\r\n  dateRTC = &quot;&quot;;\r\n  timeRTC = &quot;&quot;;\r\n  DateTime now = rtc.now();\r\n  \r\n  \/\/ Date\r\n  dateRTC = now.year(), DEC; \r\n  dateRTC = dateRTC + &quot;\/&quot;;\r\n  dateRTC = dateRTC + now.month(), DEC;\r\n  dateRTC = dateRTC + &quot;\/&quot;;\r\n  dateRTC = dateRTC + now.day(), DEC;\r\n  \r\n  \/\/ Time\r\n  timeRTC = now.hour(), DEC;\r\n  timeRTC = timeRTC + &quot;:&quot;;\r\n  timeRTC = timeRTC + now.minute(), DEC;\r\n  timeRTC = timeRTC + &quot;:&quot;;\r\n  timeRTC = timeRTC + now.second(), DEC;\r\n  \r\n}\r\n<\/pre>\n<p><strong>getSD.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"default\" data-enlighter-title=\"getSD.ino\">\r\n\/\/ microSD Card\r\n\/\/ microSD Setup\r\nvoid setupSD() {\r\n\r\n    \/\/ microSD Card\r\n    pinMode( chipSelect , OUTPUT );\r\n    if(!SD.begin( chipSelect )){\r\n        ;  \r\n        return;\r\n    }\r\n    \r\n    uint8_t cardType = SD.cardType();\r\n\r\n    if(cardType == CARD_NONE){\r\n        ; \r\n        return;\r\n    }\r\n\r\n    \/\/Serial.print(&quot;SD Card Type: &quot;);\r\n    if(cardType == CARD_MMC){\r\n        ; \r\n    } else if(cardType == CARD_SD){\r\n        ; \r\n    } else if(cardType == CARD_SDHC){\r\n        ; \r\n    } else {\r\n        ; \r\n    } \r\n\r\n    uint64_t cardSize = SD.cardSize() \/ (1024 * 1024);\r\n  \r\n}\r\n\/\/ microSD Card\r\nvoid isSD() {\r\n\r\n  zzzzzz = &quot;&quot;;\r\n\r\n  \/\/ EEPROM Unique ID|Version|Date|Time|Temperature Celsius|Humidity|Altitude Meters|Barometric Pressure|eCO2 Concentration|tVOC Concentration\r\n  zzzzzz = uid + &quot;|&quot; + sver + &quot;|&quot; + dateRTC + &quot;|&quot; + timeRTC + &quot;|&quot; + BMEtempC + &quot;|&quot; + BMEhumid + &quot;|&quot; + BMEaltitudeM + &quot;|&quot; + BMEpressure + &quot;|&quot; + CCS811CO2 + &quot;|&quot; + CCS811TVOC + &quot;|\\r&quot;;\r\n\r\n  char msg[zzzzzz.length() + 1];\r\n\r\n  zzzzzz.toCharArray(msg, zzzzzz.length() + 1);\r\n\r\n  appendFile(SD, &quot;\/espdata.txt&quot;, msg );\r\n  \r\n}\r\n\/\/ List Dir\r\nvoid listDir(fs::FS &amp;fs, const char * dirname, uint8_t levels){\r\n    \r\n    dirname;\r\n    \r\n    File root = fs.open(dirname);\r\n    \r\n    if(!root){\r\n        return;\r\n    }\r\n    \r\n    if(!root.isDirectory()){\r\n        return;\r\n    }\r\n\r\n    File file = root.openNextFile();\r\n    \r\n    while(file){\r\n        if(file.isDirectory()){\r\n            file.name();\r\n            if(levels){\r\n                listDir(fs, file.name(), levels -1);\r\n            }\r\n        } else {\r\n            file.name();\r\n            file.size();\r\n        }\r\n        file = root.openNextFile();\r\n    }\r\n    \r\n}\r\n\/\/ Write File\r\nvoid writeFile(fs::FS &amp;fs, const char * path, const char * message){\r\n    \r\n    path;\r\n    \r\n    File file = fs.open(path, FILE_WRITE);\r\n    \r\n    if(!file){\r\n        return;\r\n    }\r\n    \r\n    if(file.print(message)){\r\n        ;  \r\n    } else {\r\n        ;  \r\n    }\r\n    \r\n    file.close();\r\n    \r\n}\r\n\/\/ Append File\r\nvoid appendFile(fs::FS &amp;fs, const char * path, const char * message){\r\n    \r\n    path;\r\n    \r\n    File file = fs.open(path, FILE_APPEND);\r\n    \r\n    if(!file){\r\n        return;\r\n    }\r\n    \r\n    if(file.print(message)){\r\n        ;  \r\n    } else {\r\n        ;  \r\n    }\r\n    \r\n    file.close();\r\n    \r\n}\r\n<\/pre>\n<p><strong>setup.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"default\" data-enlighter-title=\"setup.ino\">\r\n\/\/ Setup\r\nvoid setup() {\r\n\r\n  \/\/ EEPROM Size\r\n  EEPROM.begin(EEPROM_SIZE);\r\n  \r\n  \/\/ EEPROM Unique ID\r\n  isUID();\r\n  \r\n  \/\/ SHARP Display Start &amp; Clear the Display\r\n  display.begin();\r\n  \/\/ Clear Display\r\n  display.clearDisplay();\r\n  \r\n  \/\/ Display UID\r\n  isDisplayUID();\r\n\r\n  \/\/ Wire - Inialize I2C Hardware\r\n  Wire.begin();\r\n\r\n  \/\/ SparkFun BME280 - Humidity, Temperature, Altitude and Barometric Pressure\r\n  myBME280.begin();\r\n  \r\n  \/\/ CCS811 - eCO2 &amp; tVOC\r\n  myCCS811.begin();\r\n\r\n  \/\/ Initialize the LED Green\r\n  pinMode(iLEDGreen, OUTPUT);\r\n\r\n  \/\/ Date &amp; Time RTC\r\n  \/\/ PCF8523 Precision RTC \r\n  setupRTC();\r\n  \r\n  \/\/ Date &amp; Time\r\n  isRTC();\r\n  \r\n  \/\/ microSD Card\r\n  setupSD();\r\n\r\n  \/\/ Slide Switch\r\n  pinMode(iSS1, INPUT);\r\n  \r\n  delay( 10000 );\r\n\r\n}\r\n<\/pre>\n<p><strong>Technology Experience<\/strong><\/p>\n<ul>\n<li>Research &#038; Development (R &#038; D)<\/li>\n<li>Desktop Applications (Windows, OSX, Linux, Multi-OS, Multi-Tier, etc&#8230;)<\/li>\n<li>Mobile Applications (Android, iOS, Blackberry, Windows Mobile, Windows CE, etc&#8230;)<\/li>\n<li>Web Applications (LAMP, Scripting, Java, ASP, ASP.NET, RoR, Wakanda, etc&#8230;)<\/li>\n<li>Social Media Programming &#038; Integration (Facebook, Twitter, YouTube, Pinterest, etc&#8230;)<\/li>\n<li>Content Management Systems (WordPress, Drupal, Joomla, Moodle, etc&#8230;)<\/li>\n<li>Bulletin Boards (phpBB, SMF, Vanilla, jobberBase, etc&#8230;)<\/li>\n<li>eCommerce (WooCommerce, OSCommerce, ZenCart, PayPal Shopping Cart, etc&#8230;)<\/li>\n<\/ul>\n<p><strong>Instructor<\/strong><\/p>\n<ul>\n<li>DOS, Windows, OSX, Linux, iOS, Android, Multi-OS<\/li>\n<li>Linux-Apache-PHP-MySQL<\/li>\n<li>Robotics<\/li>\n<li>Arduino<\/li>\n<li>Raspberry Pi<\/li>\n<li>Espressif<\/li>\n<\/ul>\n<p><strong>Follow Us<\/strong><\/p>\n<p><strong>The Alpha Geek<\/strong><\/p>\n<blockquote class=\"wp-embedded-content\" data-secret=\"2KFTsKyO2L\"><p><a href=\"https:\/\/www.donluc.com\/?page_id=6\">Why &#8220;The Alpha Geek&#8221;?<\/a><\/p><\/blockquote>\n<p><iframe loading=\"lazy\" title=\"&#8220;Why &#8220;The Alpha Geek&#8221;?&#8221; &#8212; Don Luc Electronics\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" src=\"https:\/\/www.donluc.com\/?page_id=6&#038;embed=true#?secret=2KFTsKyO2L\" data-secret=\"2KFTsKyO2L\" width=\"600\" height=\"338\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe><\/p>\n<p><strong>Aphasia<\/strong><\/p>\n<blockquote class=\"wp-embedded-content\" data-secret=\"XFx3Yxh5s6\"><p><a href=\"https:\/\/www.donluc.com\/?page_id=2149\">Don Luc Aphasia<\/a><\/p><\/blockquote>\n<p><iframe loading=\"lazy\" title=\"&#8220;Don Luc Aphasia&#8221; &#8212; Don Luc Electronics\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" src=\"https:\/\/www.donluc.com\/?page_id=2149&#038;embed=true#?secret=XFx3Yxh5s6\" data-secret=\"XFx3Yxh5s6\" width=\"600\" height=\"338\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe><\/p>\n<p><strong>J. Luc Paquin \u2013 Curriculum Vitae<\/strong><br \/>\nhttps:\/\/www.donluc.com\/DLHackster\/LucPaquinCVEngMk2020a.pdf<\/p>\n<p><strong>Web:<\/strong> https:\/\/www.donluc.com\/<br \/>\n<strong>Web:<\/strong> http:\/\/www.jlpconsultants.com\/<br \/>\n<strong>Web:<\/strong> https:\/\/www.donluc.com\/DLHackster\/<br \/>\n<strong>Web:<\/strong> https:\/\/www.hackster.io\/neosteam-labs<br \/>\n<strong>Facebook:<\/strong> https:\/\/www.facebook.com\/neosteam.labs.9\/<br \/>\n<strong>YouTube:<\/strong> https:\/\/www.youtube.com\/channel\/UC5eRjrGn1CqkkGfZy0jxEdA<br \/>\n<strong>Twitter:<\/strong> https:\/\/twitter.com\/labs_steam<br \/>\n<strong>Pinterest:<\/strong> https:\/\/www.pinterest.com\/NeoSteamLabs\/<\/p>\n<p><strong>Don Luc<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8212;&#8212; #DonLuc #Environment #Microcontrollers #ESP32 #Adalogger #SparkFun #Fritzing #Programming #Adafruit #Arduino #Electronics #Consultant #Vlog #Aphasia &#8212;&#8212; &#8212;&#8212; &#8212;&#8212; &#8212;&#8212; &#8212;&#8212; &#8212;&#8212; DL2004Mk09 1 x SparkFun Thing Plus &#8211; ESP32 WROOM 1 x Adafruit SHARP Memory Display 1 x SparkFun Environmental Combo Breakout &#8211; CCS811\/BME280 1 x Adafruit Adalogger FeatherWing &#8211; RTC + SD 1 x &#8230; <a title=\"Project #15: Environment &#8211; Adafruit Adalogger FeatherWing &#8211; RTC + SD &#8211; Mk03\" class=\"read-more\" href=\"https:\/\/www.donluc.com\/?p=2228\" aria-label=\"Read more about Project #15: Environment &#8211; Adafruit Adalogger FeatherWing &#8211; RTC + SD &#8211; Mk03\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[106,47,38,80,59,5,82,10,43],"tags":[86,105,6,4,87,19,83,85,24,84,27,34,108],"class_list":["post-2228","post","type-post","status-publish","format-standard","hentry","category-environment","category-adafruit","category-digitalelectronics","category-esp32","category-fritzing","category-microcontrollers","category-program-esp32","category-projects","category-sparkfun","tag-adafruit","tag-aphasia","tag-arduino","tag-consultant","tag-display","tag-electronics","tag-esp32","tag-fritzing","tag-microcontroller","tag-programming-esp32","tag-projects-2","tag-video-blog","tag-vlog"],"_links":{"self":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/2228","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2228"}],"version-history":[{"count":1,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/2228\/revisions"}],"predecessor-version":[{"id":2235,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/2228\/revisions\/2235"}],"wp:attachment":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2228"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2228"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2228"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}