Тёмный

32 Channel Relay/Solenoid Driver - MCP23017 ULN2803 

Gadget Reboot
Подписаться 30 тыс.
Просмотров 3,1 тыс.
50% 1

PCBWay Supports High Precision Advanced PCBs: www.pcbway.com/
This is a 32 channel driver pcb intended to drive relays and solenoids, or other resistive or inductive loads.
It uses ULN2803 transistor drivers for the output control, and the logic is controlled by a pair of MCP23017 GPIO expanders over I2C.
Sketch/Schematic: github.com/GadgetReboot/Relay...
PCBs at PCBWay.com: www.pcbway.com/project/sharep...
MCP23017 Datasheet: ww1.microchip.com/downloads/e...
ULN2803 Datasheet: www.ti.com/lit/ds/symlink/uln...
If you'd like to support the channel, you can:
Support me on Patreon: / gadgetreboot
Become a channel member (click the Join button): / gadgetreboot
Shop through my affiliate links (I may earn a small commission, costs you nothing)!
Banggood www.banggood.com/custlink/3vK...
Aliexpress s.click.aliexpress.com/e/_AFeHwB
Amazon.com www.amazon.com/?&_encoding=UT...
Amazon.ca www.amazon.ca/?&_encoding=UTF...
Videos are mirrored at LBRY/Odysee: odysee.com/@GadgetReboot:4
#ElectronicsCreators

Наука

Опубликовано:

 

9 апр 2022

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 32   
@AnotherMaker
@AnotherMaker 2 года назад
Such a ridiculous project. I love it. Can't wait to see what you do with them.
@johnmarshall2660
@johnmarshall2660 2 года назад
This a great help as I was using a Mega to control part of my Model Railway and most of the Mega pins are used, so I think I can adapt my sketch to use the MCP23017 as OUtPUTS and use the Mega as INPUTS ... thanks for video was a great help ... but i have a long way to go ...
@kyleallred984
@kyleallred984 2 года назад
All the gpio, awesome board.
@TheEmbeddedHobbyist
@TheEmbeddedHobbyist 2 года назад
Have to thought about how much current will be flowing it the 0V as this is the common for all the relay outputs. You might want the output oV to be a star ground so the logic and output grounds only meet at the 0V (input pin) you don't want any output ground current flowing near you logic chips ground. as the voltage spikes on switching could corrupt your logic signals and this can be a bugger to fault find. Sometimes it's good to put a zero ohm link between the ground in put and the output ground so you can isolate them if there are any issues in testing. nice video.
@GadgetReboot
@GadgetReboot 2 года назад
if it ends up giving problems at least it will be something fun to debug and I could use a spare board populated only with digital to control isolation.
@electronic7979
@electronic7979 2 года назад
Nice
@HazeAnderson
@HazeAnderson 2 года назад
oh no are you building a robot drummer? 😅
@GadgetReboot
@GadgetReboot 2 года назад
That might be attempted in the future but not one of the near term objectives. I would need a lot more parts so with the supply chain maybe that would be half a year away at the earliest!
@pileofstuff
@pileofstuff 2 года назад
Adding MIDI to this board would be trivially eeasy...
@GadgetReboot
@GadgetReboot 2 года назад
There may just be some midi connectors coming up in a mailbag...
@jenniferw8963
@jenniferw8963 Год назад
How many microseconds does it take via I2C to do a digitalWrite/digitalRead of the expander PINS on the MCP23017? I can do direct port reads from arduino pins in like 3 microseconds. Just wondering how much longer it takes via I2C to the MCP23017. I know it takes 20 milliseconds to update 3 characters on an OLED screen in my program, which is ridiculously slow; I have to use itnerrupts to catch the all the detents on a rotary encoder knob turn, otherwise half or so are skipped due to the 20ms OLED update time.
@kevinhoublon8630
@kevinhoublon8630 Год назад
Hello, great video 😄. I'm a beginner and I have a question : Can you use the MCP23017 with the TCA9548A multiplexer? Thank you in advance for your precious support 😁. Cordially.
@GadgetReboot
@GadgetReboot Год назад
Yeah it should work because the multiplexer is just acting like a splitter cable, passing the I2C signals through when the channel is selected. Of course all other I2C devices on that same selected bus need to be operating at the same voltage, but that's the benefit of the multiplexer, I think you can use some channels at one voltage and other channels at a different voltage and then talk to the main controller at whatever other voltage it wants to see.
@kevinhoublon8630
@kevinhoublon8630 Год назад
@@GadgetReboot Hello Gadgrt7, thank you very much for your feedback 😁 😊. I'll try it then. Have a nice week and happy new year 😄
@spillagonner
@spillagonner 2 года назад
So, if I wanted to use one of the GPIO expander pins for input (e.g. a button) I would have to wire the button directly to a 23017 pin, not to a relay driver pin. Would this create a problem for the relay driver IC?
@GadgetReboot
@GadgetReboot 2 года назад
If the 23017 pin is configured as input and is connected to a button as well as a relay driver output control pin, the relay control may go on and off as the button is pressed but if there is no relay on that driver channel, that should be fine. The real problem, which I haven't tested, is the relay driver chips have some internal resistors from the control input to ground, so combined with the 23017's weak internal pull up of 100k (if enabled when it's an input) may not allow the 23017 to actually see a logic high input with the relay driver connected to it, so if there is a button to ground on the input and a pull up enabled, the input may only go from 0v (low) to 0.5v or so (high). So maybe it would be better to not use internal pull ups and then use an external pull up of 10K or 4.7K with a button to ground and it may allow the input to reach a valid logic high with the relay driver's resistors to ground being present. Or if the input logic can be reversed, use the input button straight to VCC and then a pull down resistor, so the 23017 sees a proper logic high and then the logic low is also unaffected because it's a pull down in parallel with the relay driver chip's built in pull downs. In fact maybe an extra pull down isn't needed because the relay driver pull downs will do the job.
@spillagonner
@spillagonner 2 года назад
@@GadgetReboot I am reading the voltage at the 23017 pin using one of the Arduino analog input pins, with a momentary switch connected between the pin and ground. With 23017 pin configured as INPUT_PULLUP I get ~1.1V when the switch is open, 0.0 with the switch closed. With the pin configured as INPUT, and no external pullup, I get 0.0V whether switch is open or closed. With the pin configured as INPUT, using an external pullup of 10K, I get ~2.4V with switch open, 0.0 closed. With 4.7K; 2.8V open, 0.0 closed. 3.3K; 3.18 open, 0.0 closed. Search for Arduino logic high/low voltage levels suggests minimum of 2.9V for logic high.
@spillagonner
@spillagonner 2 года назад
How did you know I needed one of these? (For my antenna tuner.)
@GadgetReboot
@GadgetReboot 2 года назад
I think everyone could use one of these. I hope it will be a while until I need to get a bunch of transistors diodes and resistors on a breadboard for quick experiments!
@gorillaau
@gorillaau Год назад
I suspect that there is a need for every enthusiast to have module boards, such as this one in their junk box. Something tested and documented that can be pulled out. "I need 32 output pins on my Arduino Nano project"
@joedoe6471
@joedoe6471 Год назад
Messaged you/commented on PCBway about this: I am VERY interested in using this design to drive 24VDC solenoids that are used as switch machines on a model railroad. I believe that this might work for such a task, however I would like to use an Arduino Nano to control/drive the board/solenoids, but need to figure a way to control the Arduino, and thus which outputs (switches) it is throwing, via discreet external switches (1 for each output). Thoughts? I can certainly elaborate on what I am trying to do.
@GadgetReboot
@GadgetReboot Год назад
if a lot of input switches are needed along with a lot of output controls for relays and this board is used for the outputs on I2C, an additional design using the same MCP 23017 GPIO expander could be used to read as many switch inputs as there are relay outputs on this board. The extra chips were just connect to the same I2C bus. in the first video I did using this chip I had some inputs as a demo. ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-74DgM2nAeLo.html
@joedoe6471
@joedoe6471 Год назад
@@GadgetReboot Hey! Thanks for responding to me. I understand what you are saying and I would be happy to maybe even the possibility of commissioning (paid of course) this project to you if that might be something you'd be interested in doing. Aside from the hardware boards themselves, I would definitely need help with any code needed. Please let me know as this is def something I would like to tackle sooner rather than later.
@GadgetReboot
@GadgetReboot Год назад
I currently can’t take on extra outside work but I do think it would probably be a good companion PCB project for me to do as a video project using that same chip to do switch inputs to pair with The existing board doing all relay outputs and of course then I would have sample code as a demo so if all goes well, I could have a video with a working project before the end of this month.
@joedoe6471
@joedoe6471 Год назад
@@GadgetReboot Hey! I understand and really appreciate your efforts. Would you be willing to allow me to give you a better idea of exactly what we would like to accomplish and be able to do so that way maybe you could address those specifics in your endeavor, or at the very least point me in the right direction or maybe even recommend a course of action for us to take? Lmk! Thanks again!
@GadgetReboot
@GadgetReboot Год назад
it wouldn’t hurt to hear a description and if certain things make sense to implement on what I will be doing, I can consider that or else give any feedback I may have
@spillagonner
@spillagonner 2 года назад
But I gotta say, using PCBWay is a serious pain in the butt!
@AnotherMaker
@AnotherMaker 2 года назад
What's hard about it? I think part of it is that there are a ton of options but literally the only 2 I use are the board quantity (I keep going up until my price does) and I check the little box that says they can use gold if they're already running it and I leave everything else alone.
@spillagonner
@spillagonner 2 года назад
@@AnotherMaker I was referring, rather, to their web site...took me 10 minutes to figure out how to enter my shipping address.
@AnotherMaker
@AnotherMaker 2 года назад
@@spillagonner ahhhh. That makes sense
@DrexProjects
@DrexProjects 2 года назад
@@spillagonner You didn't know yer address? Yer on yer own there Bud.
Далее
готовка с Даней🥹
00:59
Просмотров 448 тыс.
ULN2803 Low-Side Drivers and UDN2983 High-Side Drivers
20:34
MegaMUX - 32 Channel Multiplexer Board and Tutorial
9:54
ULN2003
6:52
Просмотров 29 тыс.
Nixie Tube Driver using HV5222
8:14
Просмотров 615
6 Horribly Common PCB Design Mistakes
10:40
Просмотров 179 тыс.
Using the ULN2003A Transistor Array with Arduino
9:01
Просмотров 216 тыс.
Wylsa Pro: опять блокировка YouTube?
17:49
Wylsa Pro: опять блокировка YouTube?
17:49
iPhone 15 Pro в реальной жизни
24:07
Просмотров 345 тыс.