I'm trying to provide an ADC output to two different microcontrollers. Wondering if this is at all possible. If yes, then how could I be able to achieve it?
Electrical Engineering Stack Exchange is a question and answer site for electronics and electrical engineering professionals, students, and enthusiasts. It only takes a minute to sign up.Sign up to join this community
The ADC probably uses SPI or I2C. In both cases, there's one master MCU that generates the clock signal. The secondary MCU would in practice "snoop" the digital lines to pick up the traffic, without contributing to or disturbing the synchronizing clock signal.
You can in theory do this, but the non-standard programming involved means you're spending a lot of work for little benefit as your MCU HAL library won't help you. The better way is to let one MCU handle all communication with the ADC, and in turn use some other channel to forward the result to the secondary MCU.
ADC --> primary MCU --> secondary MCU
If the ADC uses SPI, you can use the same SPI bus but with a separate enable pin between the two MCUs, and configure the secondary MCU as a SPI slave.
If the ADC uses I2C, you can use the same I2C bus without extra pins. Just configure the secondary MCU as I2C slave with a unique address, listening for the forwarded data from the master MCU.
There will be a slight delay for the secondary MCU to receive the data, but this model is easier to implement.