Is it safe to use arduino boards? - Page 1
Forum section: electronics / projects

author: JohnNG2
author_rank: Newbie
timestamp: March 15, 2021, 12:53:47 am
content: Hi we have a case that need 2 sensors and want to use arduino boards. The computer we plan to conect the board with is very expensive and before we need to make sure that a arduino board is fine to connect using usb port. Sorry for the beginner question.

author: Dubbie
author_rank: Unknown
timestamp: March 15, 2021, 01:24:16 am
content: If you're really worried, it might be prudent to use a USB isolator like this:https://www.olimex.com/Products/USB-Modules/USB-ISO/There are plenty of other ones around if you search.

author: Mecanix
author_rank: Frequent Contributor
timestamp: March 15, 2021, 01:33:40 am
content: Nothing to do with beginner or advanced, very valid concern. Depending on what you consider expensive, and your belief in ESD lottery!For instance there are zero cut corner on the CAD workstations we use here (ZBooks, US$8.2k each). None of that hobby/thinker/gadget stuff gets connected in them unless the device complies with e.g. IEC 61000-4-2. We have two of those workstations that are interfaced to MCUs via USB2.0 and using ADC input pins for mechatronic dev, all that stuff needs to comply regardless whether the workstation has built-in protection, or not. Anyone caught hooking up a duino on those workstation can look for another job the following day too... for sure!Consider buying yourself a second-hand computer if really you are limited to already manufactured Arduino boards I'd say. Something like a 100~200 computer. Another option would be to customize an adapter board with let's say a USBLC6-2SC6http://www.st.com/st-web-ui/static/active/en/resource/technical/document/datasheet/CD00050750.pdf...

author: JohnNG2
author_rank: Newbie
timestamp: March 15, 2021, 02:04:25 am
content: Thank you for the recomendation and to confirm the hazard. We can not use another computer so I will need to look for usb adapter with esd protection?@mecanix can you explain how you connect the ADC pin to the usb in safe way?

author: Mecanix
author_rank: Frequent Contributor
timestamp: March 15, 2021, 02:24:25 am
content: Quote from: JohnNG2 on March 15, 2021, 02:04:25 amSafest way is to not connect anything at all (my guess mind you). If you are forced to use the over-priced PC for the job (like us) then look-up at what Dubbie posted for a quick and reasonably priced solution (I think). If you can do your own pcbs then lookup those rail to rail with zener clamp ESD protection ICs, bet there a tons of others too. The one we use for our applications is linked in my previous post.Our setup for clarification = MCD/CAD workstation > OPC ua client > MCU/ADC(logic) > Mechatronic PLC (OPC ua server). Both side Rx/Tx.I wouldn't know how to hook-up an ADC directly to USB, my bad for having you confused at the first place.

author: wizard69
author_rank: Super Contributor
timestamp: March 15, 2021, 04:02:52 am
content: Quote from: JohnNG2 on March 15, 2021, 12:53:47 amA little more info wouldn't hurt. The Arduino board is safe to hook up to a computer all on its own. It is what you intend to do with it that could be a problem. Also is this a bench development question or for a product or permanent installation? At the development bench the computer will be exposed to all the nasties that environment has when the Arduino is connected. Put the Arduino in a nice case with an optical sensor and your risks are greatly diminished. The point here is that there are lots of ifs.As others have pointed out one of your best bets is to consider port isolation. It might also pay to consider alternative communication methods like RS485 depending upon the sensors distance from the PC. RS485 is heavily used in industry and frankly that leaves me with a bit more confidence in isolation and working over distances. You can find all sorts of rugged and isolated adapter boxes that go from XYZ industrial interface to USB. It is really a question of how much isolation your usage requires.I don't freak out when connecting devices with USB. However I never do so with a desktop computer as I generally carry a laptop around. We do have a lot of installations with desktop computers and frankly have little trouble there. Having a laptop connected while on battery power, does give you resistance to one type of port failure, especially on RS232. The trick is to understand what you are connecting to.

author: JohnNG2
author_rank: Newbie
timestamp: March 15, 2021, 04:37:15 am
content: Hi I m not experienced enough in electronic to understand what you ask for. I just want to know from the experience people if the popular arduino boards come with esd protection already and safe when using in the computer usb. And the answer is already answer no protection at all on arduino and very dangerous if considering all the ifs and what can cause esd. I m very surprised to find out about this because arduino is popular, very deceiving. Maybe ok for hobby use only connected to a very cheap computer but not for our case. I m happy I ask the question before ordering some boards thank you for your answer all. I will find a solution to this problem with a safety adapter

author: Dubbie
author_rank: Unknown
timestamp: March 15, 2021, 07:56:33 am
content: It's very unlikely that you will damage a computer with an Arduino unless you do something very silly such as connect mains up to the Arduino, or have some severe ESD issues. However, if your computer is very expensive or difficult to replace, I think a $20 USB port isolator is worth the cost for peace of mind.

author: teksturi
author_rank: Regular Contributor
timestamp: March 15, 2021, 09:14:24 am
content: Another safe method will be to use Arduino no wifi. This way you do not need to plug it to computer. You can just use wifi.https://store.arduino.cc/arduino-uno-wifi-rev2

author: tunk
author_rank: Super Contributor
timestamp: March 15, 2021, 11:27:36 am
content: What kind of sensors?You could also use an usb hub to minimize the risk(i.e. hoping that the hub will blow up first and notdamage the PC).

author: Syntax Error
author_rank: Frequent Contributor
timestamp: March 15, 2021, 11:33:38 am
content: What do you mean by Arduino? Official Italian boards made to spec. Or China clones with dubious parts quality?If in doubt, use a Raspberry Pi.

author: Nominal Animal
author_rank: Super Contributor
timestamp: March 15, 2021, 12:05:48 pm
content: There are four safe ways I would consider when connecting an external microcontroller project to a computer:Use a wireless connection (Bluetooth, WiFi)Use Ethernet (as it is galvanically isolated)Use isolated USBUse a fiberoptic connection (TOSLINK or similar)I researched all of these when I participated in a group building a fusor, with a 100 kV voltage supply.Because of where the fusor was to be placed, wireless connection was out.Ethernet is particularly useful, if you have a microcontroller with an ethernet interface; those can be difficult to acquire. However, PJRC.com sellsTeensy 4.1withEthernet kitfor ~ $30 USD, with pretty darn good support in the Arduino environment (using Teensyduino addon). This ethernet kit uses the built-in PHY on the i.MX RT1060 microcontroller, and has a MagJack (galvanically isolated Ethernet connector) on it, despite the rather affordable price. The developer, Paul Stoffregen, also maintains several other Arduino libraries, and there is a livelyforumfor Teensy users and developers where one can participate and discuss Teensy-specific stuff; while the Teensy hardware and the bootloader are NOT open source, the support thus far has been really good. (I'm not affiliated, just a very long time satisfied customer.)For low-speed (LS, 1.5 Mbit/s) and full-speed (FS, 12 Mbit/s) USB 2.0, there are plenty of affordable USB isolators based on Analog Devices ADuM3160/ADuM4160 IC. TheOlimex USB-ISOonly works with full-speed (12 MBit/s) USB 2.0, but that is most common with microcontrollers with a native USB interface anyway, and the Olimex one has a standard barrel jack connector that takes 8VDC to 15VDC in (I suggest using a 9V or a 12V regulated isolated wall wart) and provides USB 5VDC at up to 750mA to the device. The Olimex, and the cheap ADuM-based USB isolators you can get off eBay, all also have an isolated DC-DC converter, which provides somewhere around 200-300mA (from the computer) at 5 VDC. All are based on the example circuit on theADuM3160 datasheet(because it is trivial; at most four resistors and a couple of bypass capacitors!), with only the additional DC-DC converter circuitry (and optional associated circuitry, like the Olimex one, that can supply power to the device isolated from the host computer) differing among them.As mentioned, I like Teensies, but I also use other microcontrollers with native USB interfaces (ATmega32u4 in particular; Pro Micro clones off eBay), and these do achieve about 1 Mbyte/s over full-speed USB in one direction. I have not had any problems with the cheap USB isolators off eBay with any of my microcontrollers; the only trick is that some of mine have a small DIP switch to select between low speed and full speed operation, and I always use full speed.You can use plastic TOSLINK optical cables for UART between two microcontrollers, if you invert the signal logic (so that the LEDs are OFF at idle). This provides complete electrical isolation, but in OP's case, would still require a microcontroller to be connected to the host computer, since computers do not have such TOSLINK UART interfaces. The trick, here, is to ensure that the actual baud rate used by the two microcontrollers is the same – not all microcontrollers can generate even the standard baud rates, but approximate them with a few percent error – and that the transmitted bit stream isn't all ones (LEDs ON) for too long.I do not recommend this unless you have voltage potentials that are outside what USB isolators and Ethernet galvanic isolation can handle.Personally, I would suggest Teensy 4.1 with the Ethernet kit, and an USB isolator (either Olimex or a popular one off eBay): decidelaterwhich one (Ethernet or isolated USB) you end up using. Having the option is always a plus. Teensy 4.1 has a beast of a microcontroller, i.MX RT1060 on it, with lots of RAM and processing power, without being too expensive, making it a relatively easy development target.

author: nigelwright7557
author_rank: Frequent Contributor
timestamp: March 15, 2021, 01:41:57 pm
content: I do horrible things to my USB ports with USB scopes I have designed.I have had power supply shorts, D+/D- shorts and the pc just says there is a problem with the port and shuts it down.In 5 years of abuse the USB port has always survived.But as others have said $20 for a protector is money well spent.

author: wizard69
author_rank: Super Contributor
timestamp: March 15, 2021, 09:09:07 pm
content: ESD is a problem separate from the Arduino. That is why we have ESD grounded workstations and are taught to ground ourselves before touching electronics. ESD is not something unique to Arduino it something that people often generate. I really don't see a connection here, either the USB port is protected properly or it isn't. You can have an ESD discharge plugging in a mouse or keyboard.Quote from: JohnNG2 on March 15, 2021, 04:37:15 amI doubt your case is any different from anybody elses. Follow good practice at the bench and you will not have a problem.Quote

author: Syntax Error
author_rank: Frequent Contributor
timestamp: March 15, 2021, 09:31:09 pm
content: Use one of the ESP32 series development boards. NodeMCU, Adafruit feather, Sparkfun Esp32 are just some of the many form factors. You can get these from Aliexpress from $10 - $20. Program them using your Arduino IDE and connect to your PC using the *WiFi network*.No wires = no ESD = Safe

author: Terry Bites
author_rank: Super Contributor
timestamp: March 16, 2021, 02:33:00 pm
content: Can you live with USB2?Seehttps://www.seeedstudio.com/USB-Isolator-p-4098.html

author: Mecanix
author_rank: Frequent Contributor
timestamp: March 16, 2021, 07:29:43 pm
content: Not an arduino user and even less an expert having been forced to learn onto a different architecture, and too lazy to check, but do these things come ootb with an oversized bright yellow WARNING sticker letting the enthusiast/hobbyist that there is a potential for damage? Although I'm pretty sure a few computer ports and mb got fried over the years, perhaps the newer arduino are compliant nowadays and we just don't know?

author: Dubbie
author_rank: Unknown
timestamp: March 17, 2021, 01:23:33 am
content: You have to mess up pretty bad to cause damage. USB already has a bit of protection built in, such as short circuit protection etc.The main danger is feeding high voltages back into the USB. If you're just using the 5V on the board, it's extremely unlikely that you'll cause any damage.

author: Mecanix
author_rank: Frequent Contributor
timestamp: March 17, 2021, 08:10:38 am
content: Quote from: Dubbie on March 17, 2021, 01:23:33 amThat does sound like what I anticipate when I buy dev/prototyping boards. Mind you though I still unintentionally leave floating what shouldn't-be-floating and annihilate 6.3V tant caps hooked on 24V high freq circuit, they blow up just the way I like (not)... among quite a few other breadboard unfun & booms. All that to say; these enthusiast boards are made to mess up with at the first place, some added protection from their designers wouldn't be bad imho (cost pennies really).I'm guessing if you toss out all the house/shop carpeting and spray anti-static cans all over regularly one should be (sorta) free of those xKv lightningsWrist's ESD band, mat and all...

author: ricard2k
author_rank: Unknown
timestamp: March 17, 2021, 08:37:09 am
content: I was using my 3k$ mac from the first day with arduino and other proto boards and never had a problem.If you plan to interface with power line voltages, then the problem is not the arduino itself. But a good design with optocouplers and good PSB isolation is a must.

author: Mecanix
author_rank: Frequent Contributor
timestamp: March 17, 2021, 10:06:21 am
content: Think those random 1~2kV lightnings aren't given to everyone! It's an Electron Gods' decision kinda thing... you need to be a very special kinda lucky guy to receive those (it's space science!)

author: cdev
author_rank: Super Contributor
timestamp: March 17, 2021, 02:04:32 pm
content: It depends on the application. If you're saying that you want the USB plug to be safe from external voltages, well,use common sense. Also consider the quality of the manufacturer. Arduino boards vary quite a bit in quality.If you are using formata just to use the board as an interface to hardware, yes, it will isolate the computer from the circuit substantially but use common sense. You could buy a USB isolator to isolate it more, I would. USB 1 isolators are fairly cheap. (and slow) If your application only uses USB1 I would definitely do that. USB 2 isolators exist but are much more expensive.The best quality Arduinos I have are my Seeduinos, I think. They work great with formata. I am using them right now to control an antenna switch. Its quite handy and easy to use this way.Quote from: JohnNG2 on March 15, 2021, 12:53:47 am

author: cdev
author_rank: Super Contributor
timestamp: March 17, 2021, 02:11:25 pm
content: Don't ever leave cables around that use USB plugs in non-standard ways, like some Chinese hardware does for chargers, and I also have a breadboard power supply that does. without labeling them with huge obvious labels.This is especially important if friends ever come over and use your stuff.

author: perdrix
author_rank: Frequent Contributor
timestamp: March 17, 2021, 02:13:27 pm
content: Quote from: Mecanix on March 15, 2021, 01:33:40 amI'll happily relieve you of the stress of worrying about possible damage to those - just ship 'em to me - I promise I'll look after them

author: TK
author_rank: Super Contributor
timestamp: March 17, 2021, 02:30:10 pm
content: If you need to read serial data from the sensors through the arduino board, connect it to a cheap PC or raspberry pi and get the data through ethernet or wifi

author: Mecanix
author_rank: Frequent Contributor
timestamp: March 17, 2021, 05:37:54 pm
content: Quote from: perdrix on March 17, 2021, 02:13:27 pmNo kidd. Tried to blackmail the devs for one also lol. Those Zbook will easily run a 500+ parts assembly without over heating and capable of fast 360/3dof real-time motion on those large assemblies. Nearly zero noise on the comm (4800Mbps error-free) too. All good fluid motions stuff. One of those "you get what you pay for" thing... buy with confidence!I've quit using them at the shop, when I get back home and on my PC it feels like a lada with a flat tire...