Hello,im pretty new im just wondering if my theory is a viable solution.
So to free up gpio pins multiplexing is the main method but,couldnt i just hook up one micro controller to another via UART (rx/tx pins) and have one give serial commands and the other take them?
A little more coding for simplicity and not having to learn to much more,is this viable?
I2C is essentially a serial port optimized for such "Inter IC Communication" It uses the same wire count (2), but adds a protocol that allows multiple "client" chips to be addressed, so that you can add "many" I2C peripherals to a single main CPU. (and yeah, those peripherals COULD be another microcontroller running custom code.)
I2C also run a 100kHz or 400kHz or higher, making it faster than traditional UART links. (although more recently, UARTs have gone up in speed.)