Am trying to build a controller for this vj software. Problem is I require 136 digital input buttons and only 8 analog ones. Is there anyway to make use of the analog inputs to act as digital ones? Cause don’t think i want to build another core for another 8 buttons.
But the J5 examples only demonstrate how to use the complete analog port (8 pins) of the PIC as digital in- or outputs. In this configuration no pots or faders can be stuffed at the same time.
So, it’s better just to connect the buttons to the AINs. One contact of the button has to be connected to +5V, the other to the analog input. Additionally a 1k pulldown has to be added to the analog input for a defined signal if the button is not pressed.
If using J5 as a DIN instead of an AIN, can the inputs be multiplexed like with a DIN module?
This would allow up to 256 Digital Ins, but obviously no analog ins… I’d really like that!
by using a clever multiplex algorithm for the shift register chain, you could multiplex up to 1024 buttons - the scan matrix driver will make this clear. But there are also disadvantages of this method: each button needs an additional diode, higher latency or higher CPU load, higher RAM consumption, and the driver itself is very individual - it depends on your hardware and on the application, and therefore requires some technical as well as programming skills. Therefore this solution is not supported as “standard” by myself, because the guidance would cost a lot of my sparetime.