Arduino has a limited number of I/O pins. Especially you can run out when using Analog in or PWM channels. One solution would be to stick to Arduino Mega solution or simply add another arduino as second core. ExtraCore allows connecting another Arduino board only using two wires to communicate. SO you instantly get additional 6 analog channels and bunch of digital pins.
Obviously there is a client sketch running on second core which takes command from managing arduino and does what it asks. Bit it seems that second core is limited to work as port expander only – it doesn’t add additional processing power that would be really useful in some cases.