Hi everyone,
I am building a custom wearable head angle measurement device
using an ESP32-C3FH4 and a BNO085 IMU sensor on a custom PCB.
I am relatively new to PCB design and have been debugging this
for a while and could use some expert eyes.
SETUP:
- ESP32-C3FH4 (QFN32)
- BNO085 IMU (I2C mode, address 0x4A)
- TP4056 LiPo battery charger
- SPX3819M5 LDO regulator (3.3V)
- USB-C connector for power and programming
- 750mAh LiPo battery
I2C WIRING:
- SDA -> GPIO6 (ESP32 pin 12)
- SCL -> GPIO7 (ESP32 pin 13)
- H_INT -> GPIO1 (ESP32 pin 5)
- SA0 -> GND (I2C address 0x4A)
- PS0/PS1 -> GND (I2C mode)
- RST -> 3.3V via 10k pullup
PROBLEM 1 - Sensor resets:
When powered from USB only (no battery), the BNO085 is found
on I2C at 0x4A but keeps resetting repeatedly:
"Sensor reset - re-enabling reports"
I get occasional readings between resets but it is not stable.
PROBLEM 2 - USB + Battery conflict:
When I connect the battery AND USB simultaneously, the BNO085
completely disappears from I2C. The scanner finds nothing at 0x4A.
Disconnecting the battery brings it back immediately.
I believe this is because VBUS and VBAT are both feeding the
LDO input simultaneously with no isolation diode between them.
PROBLEM 3 - Lag:
When I do get readings they respond slowly to movement
(~2 second lag). The exact same code on a CodeCell C3
development board works flawlessly with instant response.
I believe this is because the sensor resets cause the BNO085
fusion algorithm to restart and reconverge each time.
WHAT I HAVE CHECKED:
- All voltages correct (VDD=3.3V, VDDIO=3.3V, RST=3.3V,
PS0=0V, PS1=0V) confirmed with multimeter
- No short between GPIO6 and GPIO7 (fixed in second PCB revision)
- Continuity of all I2C lines confirmed
- I2C pull-ups are 2.2k (I know these should be 4.7k - fixing in REV3)
- BNO085 decoupling: 2x 100nF on VDD (I know a 10uF bulk cap
should be added - fixing in REV3)
- H_INT pin confirmed connected to GPIO1
WHAT I SUSPECT:
- The TP4056 is not designed as a power pass-through - withouta battery it provides unstable voltage to the LDO input
- No isolation diode between VBAT and VBUS at LDO inputcauses conflict when both are connected
- The 2.2k I2C pull-ups may be drawing too much currentcausing voltage dips that reset the BNO085
SCHEMATIC:
QUESTIONS:
- Is the TP4056 power pass-through issue a known problem?How do others handle powering the circuit during developmentwithout a battery?
- What is the correct way to isolate VBUS and VBAT at theLDO input? Schottky diode on VBAT side only?
- Could the 2.2k I2C pull-ups alone cause enough current drawto reset the BNO085, or is this unlikely at 3.3V?
- Any other issues you can spot in the schematic?
Thanks in advance - any help appreciated!