CoreS3 and ENV Pro (BME688)
-
Hi
I am trying to get an S3Core to read from an ENV Pro (BME688) but without success, I am suspecting either incompatibility or a dead sensor, it seems to be behaving like it is dead, it works the same when plugged in as not plugged in. Or is there something I need to switch on?
Method1
Firstly using Arduino I have used the code from https://github.com/m5stack/M5Unit-ENV/blob/master/examples/ENV_PRO/ENV_PRO.ino but am unable to get past line 57if (!envSensor.begin(BME68X_I2C_ADDR_HIGH, Wire)) { checkBsecStatus(envSensor); }
I have put some debug in and it just hits this and hangs on the serial output, if I take out this code then it carries on but obviously errors. I tried changing '_HIGH' to '_LOW' but it made no difference.
Method2
I loaded https://github.com/adafruit/Adafruit_BME680/blob/master/examples/bme680test/bme680test.inoI can't get it to go past line 39
if (!bme.begin()) { Serial.println("Could not find a valid BME680 sensor, check wiring!"); while (1); }
It just displays the error message and hangs.
Thanks
Jon
-
-
Hello @felmue
Many thanks, yes I did have the wrong settings for SDA and SCL, I have now corrected them and am getting more output as below, but am getting error code -2, and then its rebooting.
Am investigating further.......
'''
BME68X error code : -2
Guru Meditation Error: Core 1 panic'ed (LoadProhibited). Exception was unhandled.Core 1 register dump:
PC : 0x40056f5c PS : 0x00060630 A0 : 0x82016254 A1 : 0x3fceb8e0
A2 : 0x3fceb8f0 A3 : 0x000009b0 A4 : 0x0000002e A5 : 0x3fceb8f0
A6 : 0x00060023 A7 : 0x00000002 A8 : 0x00000000 A9 : 0x00060023
A10 : 0x00060023 A11 : 0x00000001 A12 : 0x8037dbfd A13 : 0x3fc93bf0
A14 : 0x00060023 A15 : 0x00000003 SAR : 0x0000001e EXCCAUSE: 0x0000001c
EXCVADDR: 0x000009b0 LBEG : 0x40056f5c LEND : 0x40056f72 LCOUNT : 0x00000001Backtrace: 0x40056f59:0x3fceb8e0 |<-CORRUPTED
ELF file SHA256: a0a73cde460324f4
'''Thanks for the link to the scanner I will try that as well.
-
-
Hello @aitech
have you double-checked that port A actually has power? You'll need a multimeter for that and measure between black (GND) and red (5 V) wires.
Thanks
Felix -
-
@aitech Dont' throw that sensor away yet.
There is an error in the ENV_Pro demo code:
Line 51 should read Wire.begin();
After changing that it worked fine for me.
The interface address for the sensor is actually defined on line 57.
Pretty impressive sensor.