2 multiplexers 1 for inputs 1 for output

Is possible to use 2 74hc4067db multiplexers on Arduino uno, 1 for inputs and the other one for outputs? I want to connect 1 74hc595 Wich is a shift registrer on the input multiplexer for scan a button matrix, and 4 7 segments displays on the output mux and I don't know if it's possible, can someone give me some idea please?

yes - but why? There are other IC's which are more suitable for that job.

to control LEDs there are several options:

  • MAX7219 / MAX7221
  • HT16K33
  • SX1509

The MAX7219 has a SPI like interface. It is able to control a matrix of 8x8 = 64 LEDs individually or 8 seven segment digits. You can daisy chain this IC, meaning, with one chip select pin you can control several ICs. The MA7219 is often used for 7 Segment Displays, modules for 8x8 Matrixes are available also.

The HT16K33 has an I2C interface. You can chose from 8 addresses. Each IC can drive 8 x 16 LEDs. There are modules available with 7 Segment LED displays and several Alphanumeric Displays. The HT16K33 can be used to read a key matrix also. See the datasheet if you can make it work in your setup.

The SX1509 has an I2C interface also. You can chose from 16 addresses. The SX1509 controls 16 LEDs. Each LED can have PWM. The SX can "blink" or "pulse" the outputs also. It has an build in keypad controller to read from button matrix.

In my opinion all 3 variants a better usable as LED driver than shift registers. Especially the HT16K33 might fit well to your requirements.

2 Likes

Using a 74HC4067 for outputs is a very bad idea. This is because the output only follows the input when that output is being addressed. When it is not being addressed then the output is floating. It will not retain its value. What you probably need to retain its value is what is known as an "addressable latch"

1 Like

Again, the "XY problem" here. :astonished:

Multiplexers are not the answer in either case. So, start again, and let's see how best to solve the problem. What is this "button matrix" and do you have a specific 7-segment, 4 digit display already? If not, we will suggest the more suitable and inexpensive options.

noiasca likes these though his link is "Derzeit nicht verfügbar". I like the MAX7219s, mostly because I code them without using a library. There are also the really cheap TM1637 modules of which I have accumulated more than the others.

1 Like

Thank you for your answers!
I asked that because I have only those components, and I already have a code that works with the shift register but I plan to add a few buttons and displays, and I thought I could do it without buying more but I see that if it is a better option to use the display than you recommend, thank you very much!

Sorry for the XY problem I don't notice hehe

I want to make a keytar midi controller using the code of my other answer, first I thought use the same keys of the keyboard to do the functions of transpose and chance instrument but I cannot solve that problem so I thought yesterday, I have those multiplexers, maybe adding more buttons to do the functions but to do that I need a display to show me the values of that functions

I hope you understand me I do my best on English cause I speak Spanish.

Thanks a lot!

I did a MIDI keytar project only recently a few months back. It uses two Trill Touch sensors. The MagPi magazine they are in are available as a free PDF download.

Trill Guitar Part 1
Trill Guitar Part 2

It uses the new Pico controller (only about £4.50) and is written in Micro Python, which is easy to use on this platform.

1 Like

The touch strumming is a great idea!

However we presently have no idea of just what components you are presently using, how they are wired or what the code is, so failing those details, cannot really help much! :worried:

Suggesting you are using a 74HC595 for reading inputs is quite bizarre!

Hell yeah! Hi and thx for sharing! Funny stuff. Do you have more videos dedicated to it? I faced many keytars from Yamaha and Roland(useful review). But here is a pure fun
Cheers!

Not that specific keytar.

But I have made two other keytar projects.
Cattle Caster
and
Arduinocaster