EmbDev.net

Forum: µC & Digital Electronics Shift-In PCB to buy (e.g. using CD4021 or 74HC597) with Arduino Mega


Author: Walter H. (prefect62)
Posted on:

Rate this post
0 useful
not useful
Hi @ll,

I got an old railroad switchbox controlboard which originally was 
connected to a heap of relays. I need to revive it using todays 
electronics. At the moment I favor an Arduino ATmega for control.

The switchbox control has around 100 push-buttons that I have to read 
in. No more than two push-buttons should be pressed simultaneously.

Question 1 - how would you do that?

I was thinking to use two or three chains of shift registers (the 4021 
or 597 mentioned in the subject). I am not so much into soldering so I'd 
prefer to use some well-designed prefabricated boards for the task 
(instead of learning how to design PCBs myself, which might or might not 
work out in time). But my search parameters did not find me anything 
useful.

Question 2 - Do you know of such a PCB? Ideally it would be supplemented 
by a library to adress it easily, but that is not a must.

Thanks in advance, Walter

Author: Thomas W. (Company: privat) (diddl)
Posted on:
Attached files:

Rate this post
1 useful
not useful
I suggest a I2C IO board.

It is simple to build a chain of IO boards and it is simple to use with 
an Arduino or a normal AVR board.


https://de.aliexpress.com/item/PCF8574-IO-Expansio...


It costs 1€ per board

: Edited by User
Author: Thomas W. (Company: privat) (diddl)
Posted on:
Attached files:

Rate this post
1 useful
not useful
But if it should be a 74595 shift Register, it also is very cheap:

https://de.aliexpress.com/item/74HC595-Shift-Regis...

Author: Walter H. (prefect62)
Posted on:

Rate this post
0 useful
not useful
Hi Thomas,

thank you so much for your answers! I will consider those boards that 
you mentioned, the I2C looks tempting.

The only downside on those options is that they just provide 8 
connections. The I2C board allows for 8 different adresses, so I would 
need at least two separate buses to add up to my approximately 100 input 
pins (2x8x8).

Therefore, if anyone can point me to an input board with even more pins 
provided, I would be grateful!

Cheers, Walter

Author: Thomas W. (Company: privat) (diddl)
Posted on:

Rate this post
0 useful
not useful
Hi Walter

Walter H. wrote:
> The only downside on those options is that they just provide 8
> connections.

Yes, this I2C boards are limited.

I've found two other boards with 16 x IO, but this is also insufficient

https://de.aliexpress.com/item/OPRN-SMART-PCF8575-...

https://de.aliexpress.com/item/-/32859752451.html

====

So it would be the best choice this 595 board as suggested bevore:

https://de.aliexpress.com/item/74HC595-Shift-Regis...

Author: Thomas W. (Company: privat) (diddl)
Posted on:

Rate this post
0 useful
not useful
This one seems to have 3 address Pins so you can use 8 boards.

Each board has 16 IO.

And each IO can work as Input or Output (real GPIO).


And it costs only 80 Cent!


https://de.aliexpress.com/store/product/MCP23017-S...

Reply

Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]




Bild automatisch verkleinern, falls nötig