pazi88 wrote: ↑Thu Nov 19, 2020 10:59 am
Do you have example of what is correct, tested and verified to lead noise free ADC inputs? I just linked my design on last page. For latest one I copied how rusefi does the decoupling but caps are closer to mcu than in those designs. Don't know yet how well that will work. Analog voltage reference now comes from 5v using same voltage divider resistors as are used with analog inputs to tie in the analog vref to 5v that all sensors use = differences in 5v voltage do not affect analog readings.
The resistor divider is a good idea but you have a lot of filtering so Vref may not follow the 5V line well. The problem with the Mega format is that the analog and digital returns follow the same path so you pick up noise on the 0V line. You are also subject to any noise that might occur from the shield. What else is your 5V driving? How much noise are you seeing?
If the anti-aliasing filters aren't well designed then you will get a lot of additional noise. I did a similar design with an SPC572 and added provision for the filter caps on the board to get them the 'right side' of the connector, it won't be much of an improvement though.
Noise is going to be a problem with a design like that and there isn't a simple solution, you only really need 8-bits so noise on the last two bits isn't really an issue and you can use the speed of the STM32 to oversample to reduce noise without reducing the bandwidth.
The idea of a seperate ADC could work well with a filtered 5V supply to the sensors and its reference it would decouple the inputs from the noise on the 3V3.