Can anyone here explain to me is there any significant differennce between these two ways of switching columns in button/LED matrix with shared columns:
scan all columns, wait couple of ms, repeat
activate one column, wait couple of ms, activate next, repeat
So far I've been using method 2, but I'm interested in difference, if there is any (and if is I'm guessing it can only affect LEDs).
Well, you need buffer transistors or ICs to multiplex the matrix, the Arduino does not have the drive capacity. Six or eight buffer transistors and resistors take as much space - if not more - as a MAX7219 and the latter is pretty cheap.
The MAX7219 does all the multiplexing for you.
You need three wires to drive the MAX7219, but you are probably scanning that many fewer columns on the keyboard. You can then scan the whole keyboard fast - no waiting at all. Don't forget the debounce though.
Well, you need buffer transistors or ICs to multiplex the matrix, the Arduino does not have the drive capacity. Six or eight buffer transistors and resistors take as much space - if not more - as a MAX7219 and the latter is pretty cheap.
The MAX7219 does all the multiplexing for you.
You need three wires to drive the MAX7219, but you are probably scanning that many fewer columns on the keyboard. You can then scan the whole keyboard fast - no waiting at all. Don't forget the debounce though.
{Seems I rather like MAX7219s, doesn't it?. :D}
I agree that it is a good chip, however I'm using only 4 LEDs with single row (so I need only one resistor and no IC at all). It would be overkill. However, thanks for advice!