I’m trying to run an Environmental Combo CCS811/BME280 with an ESP8266. I’ve uploaded the code shown on the product page, and in the Arduino IDE library (Which appear identical). When I do that, I get the error messages below.
I can get the basic readings independantly from both the BME280 and the CCS811, they work flawlessly, but when I try to use the whole thing together, it gives me these messages. I’m really new to both of these products and programming in general, so I have no idea what to do next. I’ve searched both the Arduino forums ad the Sparkfun forums, and I don’t see anything with this problem specifically. Help?
Here’s the error messages:
Arduino: 1.8.19 (Mac OS X), Board: “LOLIN(WEMOS) D1 R2 & mini, 80 MHz, Flash, Disabled (new aborts on oom), Disabled, All SSL ciphers (most compatible), 32KB cache + 32KB IRAM (balanced), Use pgm_read macros for IRAM/PROGMEM, 4MB (FS:2MB OTA:~1019KB), v2 Lower Memory, Disabled, None, Only Sketch, 115200”
/Arduino/Environmental_Basic_Readings/Environmental_Basic_Readings.ino: In function ‘void setup()’:
Environmental_Basic_Readings:20:13: error: expected unqualified-id before ‘==’ token
20 | CCS811Core==status returnCode = myCCS811.begin();
| ^~
Environmental_Basic_Readings:21:7: error: ‘returnCode’ was not declared in this scope
21 | if (returnCode != CCS811Core::SENSOR_SUCCESS)
| ^~~~~~~~~~
Environmental_Basic_Readings:21:33: error: ‘SENSOR_SUCCESS’ is not a member of ‘CCS811Core’
21 | if (returnCode != CCS811Core::SENSOR_SUCCESS)
| ^~~~~~~~~~~~~~
Environmental_Basic_Readings:24:5: error: ‘printDriverError’ was not declared in this scope
24 | printDriverError(returnCode);
| ^~~~~~~~~~~~~~~~
/Arduino/Environmental_Basic_Readings/Environmental_Basic_Readings.ino: At global scope:
Environmental_Basic_Readings:101:11: error: expected initializer before ‘.’ token
101 | void print.DriverError( CCS811Core::status errorCode )
| ^
Environmental_Basic_Readings:124:6: error: redefinition of ‘void loop()’
124 | void loop()
| ^~~~
/Arduino/Environmental_Basic_Readings/Environmental_Basic_Readings.ino:56:6: note: ‘void loop()’ previously defined here
56 | void loop() {
| ^~~~
exit status 1
expected unqualified-id before ‘==’ token