Grounding Issue With Sensors

I’m know very little about electric and how proper grounding works and should be setup. I have an issue while using the Arduino and some simple ultrasonic sensors. When hooked up at certain locations, the sensors do not get the correct readings and also the Arduino does not read the sensors correctly.

I know this is a power / grounding issue as when I switch the power source to a source that I know produces clean power and ground then everything works great. The wiring diagram is attached to this post. It looks a little complex, but it really is very simple. I’ll explain the diagram below.

Is there anything I am doing wrong, or is there any item I can use to further isolate / fix the grounding issue so everything works.

The power comes into a 24V power conditioner. This keeps power currently at 24V and cleans out any spikes or surges. The 24V ground and hot then go to connectors where they branch out to the other devices. There is a 9V regulator that brings the 24V down to 9V and powers the Arduino via the Vin pin. The Arduino is also connected to the ground from the 24V. There is also a 5V regulator that powers the sensors. This is connected to the 24V power, the ground from the 24V and also connected to the Arduino PWM Digital Pin 9. The Arduino triggers the 5V regulator by putting pin 9 high. This essentials turns on the 5V regulator so that 5V regulator can power the sensors. This is needed as the sensors need more power then the 5V output from the Arduino PWM pins.

Any help would be greatly appreciated!

Are you trying to use PWM to control the power to the sensors? Is that 5V supply one that actually expects PWM control? Most don't. If there's a "shutdown" or "enable" pin on the regulator, it's not usually possible to send PWM into that pin.

Most sensors need a "clean" power supply with little deviation from the nominal value. I don't know of any ultrasonic sensors that need a variable voltage input. Perhaps you can share with us the part number and internet address of these sensors you have?

Hi,

You should have a single "Common Ground Point". In your case that should be the negative connection on the 24V supply.

ALL devices should have their own ground wire going back to that single point.

...let us know...

So, you have an Arduino which runs at 5V and sensors which also need 5V. My advice is get rid of the 24V power supply and the 9V regulator. Get a 5V power supply and run everything of that. Your current setup is just wasting most of the power.

The Arduino digital pin 9 PWM is connected to a pin on the 5V regulator. Basically the regulator powers the sensors. The Arduino is hooked up to the regulators "on/off" pin.

Here is the regulator. http://www.digikey.com/product-search/en?WT.z_header=search_go&lang=en&site=us&keywords=Ka278r05ctu&x=-1468&y=-51

So the regulator is powering the sensors directly, no power runs through the Arduino.

All the equipment has the common ground, shown in the wiring diagram.

Here are the sensors we are using. Very basic ultrasonic sensor. http://maxbotix.com/Ultrasonic_Sensors/People_Sensors.htm

Some of the sites having issues had "floating grounds" according to an electrician. Also some sites seem to have some voltage between the ground and neutral, when measuring with a multimeter. I've been told all of these things are issues, basically things that need to be fixed with the main power connection.

Is there anything out there that can fix these issues without always having to relay on an electrician to come out and fix the issues with the main power? This is very time consuming and costs a lot. The sensors and Arduino seem to need a "cleaner" power connection than all the other equipment on site (lights, heaters, general devices used in a warehouse).

So the regulator is powering the sensors directly, no power runs through the Arduino.

Looking at figure 38 and 40 of your regulator, do you have (for example) a 100µF capacitor from Vo to GND and 10µF capacitor from Vin to GND?

Also some sites seem to have some voltage between the ground and neutral, when measuring with a multimeter. I've been told all of these things are issues, basically things that need to be fixed with the main power connection.

Huh? It's normal to measure low voltage between ground and neutral because neutral is a current carrying conductor for the AC load, AC Ground is used only for fault current. The point at which AC Ground is connected to the Neutral would only be at the main service panel and further away at the service transformer. Some voltage on AC neutral measured at some branch circuit would not be an issue unless your power supplies aren't isolated ... then that would be a safety issue.

Hi,

Can you please post a copy of your sketch, using code tags?
They are made with the </> icon in the reply Menu.
See section 7 http://forum.arduino.cc/index.php/topic,148850.0.html

Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?
Please go to the trouble of putting all your capacitors and power regulators in it, and name the connection pins.
DO NOT use Fritzy diagrams.
Please hand draw and photograph, that way you can create instantly symbols without having to go looking for them.

What are your sensors?
Why do you want to turn the supply to the sonic system, ON and OFF?

Tom… :slight_smile:

Hi,

The sensor gnds should be connected to the gnd on the arduino, as this is the sensor gnd reference which should be at arduino gnd. Are you sensors analog outputs? Do you have bypass capacitors fitted to the sensors and their outputs?

A picture of your project would help to, so we can see your layout.

Thanks... Tom... :)

I’ve posted the diagram in the original post. I have attached it here again. I do not have any capacitors in my circuit anywhere. I’m very much a novice when it comes to circuits and electricity, I’m a programmer who needed to build something.

I need to power the sensors on and off as they are powered only when readings are needed. My Arduino runs 24/7, but only takes measurements from the sensors every few hours. This is why the 5V regulator with the on/off pin is used.

The 24V power supply is used because I have a few other things that run off of the 24V unit. These things have nothing to do with the Arduino or the sensors, so I left them off the diagram.

I have over 100 of these setups installed and running on different sites. I experience issues with around 10% of the power on certain sites. After an electrician looks at the power on the sites, usually the issues are cleared and everything works. I’m just looking for any possible solution that would avoid having an electrician look at the main power at the facility, as all other equipment seems to work fine except this setup.

Hi, Sorry a FULL diagram, how you have connected signal lines and power supply.

A copy of your circuit, in CAD or [u]a picture of a hand drawn circuit in jpg, png[/u]?

You should by now have a circuit diagram.

Tom... :)

Tom, I'm sorry but I have no idea how to give you any more than the wiring diagrams I have already attached. I'm far from anyone that has experience with reading diagrams let alone creating them.

All the things used in the wiring diagram are listed, parts are also listed for the regulators. Not sure what else is needed as there are no other parts.

24ebd3c69e4eda178cc4aaefb0e9638896d1efcd.jpg

Hi,
Hmm, okay can you post a picture of your project please, if possible a faulty one and a properly working one?

Thanks… Tom… :slight_smile:
Also google bypass capacitors

Check this link.
http://www.seattlerobotics.org/encoder/jun97/basics.html

Here is the 24V power supply.

http://deltapsu.com/products/download/Datasheet/DRP024V060W1AZ

Shouldn't that unit really be giving out clean DC power?

The only difference from the unit working and not working is changing the power source that feeds the 24V unit. I can use a simple power inverter from my truck to test the units if something is suspected wrong with the power on site. When powering the 24V unit from the power inverter the sensors and Arduino work great. When switching the input power back to the line supplied from on site is when the sensors start failing.

If the site has a faulty ground, that needs to be fixed by an electrician. You should not even consider avoiding that. There are things that can be done to isolate your unit from the faults but I wouldn't consider them as an alternative. As for your ground paths, consider any current flow through the wire as being a signal. Where things may be sensitive to add filter capacitor. These should be located before any regulators and also before any branching of the power. Think of filter capacitors as something that the ground and voltage pass by, not something that they have to go out of there way to get to. Ground issues are often the reason why many remote analog sensor use current loops rather than voltage level signals. In cases where the remote sensors might be subject to sudden surges, like high power motors starting, optical idolators might be a better option than direct wiring. Dwight

Dwight,

So would you suggest that I add a filter capacitor to each of the positive and negative wires coming out of the 24V converter before anything branches out? If so, what type of capacitor should I use in my circuit? Are there any restrictions based on the voltage and or amp draw? The regulators are rated to handle 2amps, but the equipment doesn’t even pull 1amp.

The 24V supply it self probably has enough filters at its output leads. The various down regulators you have following don't seem to have any filters on their inputs and output. Try to think about the paths that the filter current flows. The wire coming to the filter cap from the source, is what you are trying to isolate from the regulator input. If the ground side of the capacitor is past the ground of the output filter capacitor it would be wrong. This is the thinking of the common rule of thumb of using a star connection for grounds. Not all application are correct with a star ground. One still has to think about the paths of the current flow, both DC and AC. One has to look at the practicality of the wire lengths as well. Dwight

Hi,

I know this is a power / grounding issue as when I switch the power source to a source that I know produces clean power and ground then everything works great.

The 24V power supply is used because I have a few other things that run off of the 24V unit. These things have nothing to do with the Arduino or the sensors, so I left them off the diagram.

The source that produces “clean” power, what is its output current rated at.
When you use the “clean” power, is all the other equipment connected as well?
Is the “clean” power connected to gnd when you try it?

With the normal PSU, what is the load current, have you measured it?

What is the other equipment using the 24V PSU.

Did you design, install this system?
The fact that no code has been posted makes me think, no.

Please a picture of the installation,

If you have 100 of these installations, why don’t you have a circuit diagram?

Tom… :slight_smile:
PS.

WHY so many questions??

You have the project infront of you, we don’t.

You know how it is wired, we don’t.