![](/media/cache/group/default_image.jpg.50x50_q85.jpg)
A working demo code, to show the CD74HC4067 16 channel digital/analogue Multiplexer IC working. It takes 16 ADC readings and displays the value from each pin to a PC serial terminal.
Dependencies: mbed
Fork of MUX_test by
With the limited numbers of ADC pins, it often helps to use multiplexing to access, in this case 16 inputs using just one ADC pin and 4 I/O pins.
This code replicates some examples currently published for Arduino. It provides a function to access whichever channel you like, just pass the function the pin you wish to access and it will pass back the ADC reading from it. - Simple Really!
Any Questions, please do let me know.