Close

Log 10

A project log for ESP32 EEG

Heavily inspired by OpenBCI, especially their ganglion board design, but with an ESP32 handling communication/control

pP 04/03/2021 at 03:380 Comments

Quick update on the artifacts I was seeing before - after lots of debugging I'm pretty sure it's due to some sort of transients in the analog power supply. I've reposted the image of the artifacts here:

They look a lot more noisy in this plot because they are being ran through the 60hz notch filter on the client software, but in actuality they are brief moments where the MCP3912 is transmitting zeros (and the noisiness is due to the filter ringing). The fact that the MCP is still transmitting during those periods is a clue that the digital side of things is fine. Additionally, going back to 200 hz sampling reduced (but didn't completely get rid of) the artifacts. Sampling from only a single channel completely got rid of the artifacts, and switching to 16 bit sampling (instead of 24 bits, so 1/3 less power spent on the ADC) allowed me to get back up to sampling 4 channels at 200 hz without any more of these artifacts. The last 8 bits are below the noise threshold anyway so saving power and reducing the data size without sacrificing any signal quality is a pretty solid win. Definitely not surprised I may have ended up overdrawing from the AVdd LDO (a TLV700), which is only rated to supply 200 mA, especially when really pushing the conversion frequency/oversampling ratio, dithering, and boost settings on the MCP.

I guess it may also be worth mentioning that I'm still powering everything from a USB battery pack, and my USB cable is 3' long, so it's probably inductive enough that even though the ESP32 has it's own LDO regulator, instantaneous power transients from it's transmissions may be dropping the supply voltage enough to cause issues on the other power supplies. Not sure what the best course of action is moving forward, whether/where I need more decoupling caps or inductive chokes, or LDOs with more output current. Taking a look at the power supply designs in the MCP3912 datasheet and eval board offers a couple potential changes. 

MCP3912 datasheet uses MCP1703 regulators which can supply a slightly larger 250 mA output current:

and the MCP3912 Eval board uses an MCP1825S for DVdd (500 mA output current) and MCP1754S for AVdd (only 150 mA output current), but with a ferrite choke on the AVdd supply (presumably for power supply noise reduction, but may make a difference in suppressing transients that would otherwise cause AVdd to momentarily drop out):

Discussions