Arduino Manager Development for All

My comments on Arduino relate to the early days when it was first getting popular.

Existing micro controller hobbyists of the time didn’t see Arduino as a big deal. It was just a $4-5 Atmel micro with a pre-programmed bootloader and a Serial/USB support chip. The 8-bit atmel chips of the time were cheap and high voltage programmers for raw micro’s were ~$20. Maybe the chips and programmers were ~$100 at some point years prior but costs were way down by the time Arduino came around.

Hobbyists already had one (or six) programmers and could build one themselves anyhow. “PIC” micro controllers were easier still and plenty cheap. What they missed was the value of the ecosystem that evolved around Arduino (not unlike what happened with r-pi), the “hats” and the huge expansion in interest that Arduino catalyzed.

These days the focus has moved to 32 bit microcontrollers for sure. The more modern 32 bit chips integrate some of the functionality and easy programming that made Arduino dev boards easy and popular. The extra features also let you skip an arduino “hat” in many cases too. I’d grab a NodeMCU (ESP32) or other simple hobby board before an Arduino in a huge number of cases.

1 Like

Here is an interface I developed to use with automotive cube relays. Why this does not already exist in this form is beyond me. I am not a fan of the relay interfaces they offer with relays soldered into the boards. If one relay goes bad the whole board is junk and they are pretty weak to begin with.

So here is just took an Arduino Nano screw terminal shield kit and modified so I could plug in mosfets to energize the relay coils. If a mosfet goes bad I simply un plug it and replace it

https://youtu.be/GytKRfJGVe8

2 Likes

Arduino has a “Relay Hat” but it feels like a bit of a toy for any mission critical use case like a gasifier.

Relays are really tough on digital circuits. The coil has high inductance leading to big voltage under and over shoots with each cycle unless snubbed properly. The mechanical relay connection itself can arc causing huge amounts of electrical noise, potentially disrupting control circuitry. It would be good to have a harness for the relays so the “brains” can be separated from the switches and so relays can be swapped out as needed. They are mechanical parts and wear out.

MOSFETs that can handle similar current as a relay will not be cheap. And the driving circuitry won’t be either. Beefy MOSFETs need a good amount of current into their gates to switch.

If you make the investment however… MOSFETs should last almost forever and that’s worth a lot. They don’t arc and they don’t have any direct physical wear. I’d buy a couple spares just in case though. If you are going for longevity, pay attention to your capacitors, especially any electrolytics. Polypropylene caps cost a good bit more but they last…

Edit: Matt - sounds like you are using mosfets to drive relays. That makes sense. Relays will be much cheaper than MOSFETs big enough to switch equivalent current. But the current to switch the relays is much more than a micro can produce. The Arduino micro switches the MOSFET. The MOSFET switches the relay.

1 Like

Thats why I Im sinking the mosfet to eliminate noise and also back feeding high voltage to the controller. The mosfet controls the ground of the relay coil. The only signal is the 5 volts from logic.

These here are what Im using.

2 Likes

yeah I have a few of the genuine Arduino relay hats. The issue for me is I needed more than just the four; plus they are expensive and I would still need to interface them into automotive relays. so Im protecting those delicate 10 amp max toy relays. Mechanical things always break! lol.

This little interface only cost a few bucks to make and is a far better solution and is very compact. I love using the Nano with the screw shield. They offer more inputs over the standard Arduino, you have a nice screw terminal to hard wire into and if the board goes bad you just pop it out and put a new one in its place. Then there is the size nice and compact with the same power as the big ones. I love them!!!

3 Likes

How come you aren’t just using a optocoupler or logic level shifter?

Then you are isolating the 3.3v or 5v from the microcontroller and the 12v circuit completely. Then you can ditch the relay or the mosfet. And you don’t have to worry as much about leakage from the mosfet and back current from the relay.

Then if you want to clean it up and make it more reliable you can draw up a board and do that whole thing. There is a place in the US that does it and caters to makers.

You probably need a soldering rework station though. I got the best cheapest one I could find. It was 10 less on aliexpress, and they all come from the same warehouse, and are all shipped usps despite what the advertise.

Because you can adjust the temperature down, I use mine to weld and shape plastic as well. You just need extra tips. :stuck_out_tongue:

2 Likes

To cumbersome and take up too much room, too much work mounting them. Teach a kid off the street to wire this and you will have a big mess. been there done that too. They are too expensive I have those in stock as well. I had to use three of these 4 channel boards to make my system work. Put three of them together and then you start taking up a lot of board space on something you dont have a lot of room with to begin with.

This Mosfet board is stupid simple. It works and you cant back feed its working from ground. It takes up half the space as just one of those four channels. It is very unlikely the mosfet will fail and short to ground. If it does Im not worried about replacing a two dollar Nano.

1 Like

How are you going back feed power from the ground?

These guys are in my backyard. Ive had lots of talks with them if these are the guys your talking about. 24V Industrial I/O Shield PLC Replacement — Rugged CircuitsRugged Arduino

But yeah that is the idea I will outsource these boards to a company that is close by in Allendale Mich.

1 Like

I was actually talking about service that you send the files and sends you back the boards. More like:
https://oshpark.com/

The chinese version is https://jlcpcb.com/

Typically the relay boards are isolated, now that I think about it. Or least the 16 channel ones are. But I am a bit confused, you have a mosfet and you can drive the motor directly with that. but you seem to able be using a relay in your circuit… If you are still using the relay you can probably use a npn transistor depending on the relay current draw, and those are like 40 cents.

If you want to stick with relays you would need:
https://www.amazon.com/SainSmart-101-70-103-16-Channel-Relay-Module/dp/B0057OC66U/ref=asc_df_B0057OC66U/?

Then typically you would use an i2c pwm controller to drive it like:
https://www.amazon.com/HiLetgo-PCA9685-Channel-12-Bit-Arduino/dp/B01D1D0CX2/ref=asc_df_B01D1D0CX2/?

You can drive mosfets with the pca9685 board as well. then you only have the i2c wires to the arduino or whatever controller you use. If you are going to do a custom board then I would probably add the pca9685 and the mosfets or relays on the same board. And in all honestly since you have the 4 channel boards if you just want to test it, just unsolder the relays, and put the mosfet in. You may need heatsinks for the mosfets.

Mosfets don’t do the backcurrent thing like relays do. relays have the solenoid type of coil, and it generates electric when it turns off like a motor does. The Mosfets do tend to leak current. so even if it is ‘off’ it still might be leaking some current through.

2 Likes

Those relay boards are what Im trying to get away from. No offence but all those boards are junk, and not capable enough. I want cube relays that can be replaced and capable of 30 to 40 amps.

I dont want any thing on my controls that can not be replaced easily by anyone on the planet. Automotive stuff is very standardized and those cube relays are everywhere worldwide. Plus they are automotive so they are much more robust. I figured the mosfet board would be a good solution as its just strip and wire and its tiny. I dont trust running that much current through those mosfets. These controllers must not fail and in the case they do; then I need it to where there is no special ordering.to replace those parts. I want parts that can be obtained by clients more locally regardless where they reside.

2 Likes

The thing you have to understand I am not an electronic engineer. So when I design this stuff I have to use things I know will work not fail. Like these mosfets I know they are 100 times more capable of what Im using them for. When you run a relay I triple its capability of what its running. Besides this is a ton of development with a lot of things already designed around it that complex and its been working fine. If it not broke and is simple why fix it?

2 Likes

Just trying to help you out. With what I was describing, you would end up with something like this:

It is the first one I found probably not the cheapest. They definitely have a mark up.

2 Likes

Right on that thing is what Im looking for. But again it is soldered in fets and $178 bucks!! Let the smoke out of one of those fets and its broken. :frowning:

A major Part of my criteria is everything must be replaceable as close to local means as possible any where in the world I ship too. If that board had removable fets that would be perfect but 178 bucks is a little hard to swallow.

1 Like

But that thing right there might be a big deal for me to over look those solid mounted fets. Because I already use the I2C for the Arduino and RPI to interface.

1 Like

Oh. I didn’t expect you to buy a 178 dollar board. i thought the price was a bit steep too. but it is 16 instead of the 12 you need so technically you could just program around the first 4 blown ones and switch wires… lol

What you need is the eagle file or kicad file for the board that can be edited a bit.

The cheap way to connect the mosfets is to use a 3 position screw terminal block like you would for 3 wires. Then just put the mosfet legs in.

You could probably get the connectors for the auto relays, then put the socket on the board, and then solder the mosfet to the plug that goes in it, and just wire it the same as a relay, and in a pinch they could use a relay. I don’t know what they call those connectors to look them up.

Usually they are soldered on because they don’t go bad that often, and corrosion and loosening from vibration are more likely to build up resistance and kill it.

1 Like

Here is the repo for the adafruit pca9685 board. I can’t get it imported into kicad though. I think it was done in an old version of fritzing and exported as xml but there are a bunch of errors in it.

It looks like this is a design for a 4 channel relay board, which basically you just quadruple it for 16channels. What I don’t know is how you figure out the width and thickness of the copper channels you need to supply power…


Ironically, my latest gifts from Xi Jinping have arrived. The Uno clones were $3 preOrangeman, now it’s doubled. The price went up enough that the ESP series of microprocessor is actually cheaper.
As an added bonus, these ESP8266 boards have a removable antenna. So if you combine these with this…

The little board can punch out quite a ways…10km line of sight (as seen on the internet).
The other board is an UNO clone with an ESP12f processor. It has wifi too.

4 Likes

The ESPs went up in price. and unfortunately, Ukraine is where half of the world’s neon comes from, and they shut down both factories. It is used in the production of microchips…

1 Like

Whoever wants to use arduino but is not fan of coding (like me), I discovered a nice software. It’s called Visuino.

Visuino - Visual Development for Arduino

There are plenty instructional videos in their website and many in youtube.

Visuino - Beginner Series - Part 1 of 7 - YouTube

9 Likes