Noise on reading whenever 72v motor running

I try to build a controller to control VOTOL EM100 which control 80V BLDC Motor for electric motorcycle purpose.
My logic is quite simple, whenever I push a button (connected to D10, active LOW), it will trigger the parking signal (connected to A0, connected through cable above the pcb to the JST XH socket).
However, when I try to pull the gas through the throttle, the push button triggered randomly 1010101010. Can anybody tell me what is going wrong here?
Thanks in advance.

I used arduino nano, and the supply for it come from 12v dc dc converter. Below I attach my connection also pcb.


Yes, it is interference from the motor getting into the Arduino inputs.

You need robust pull up resistors on any input pin try with 1K to start with. Also you need to put a filter network in the motor to minimise the interference.

The actual schematic would help as well, and not the game of find the matching label you posted.

It looks like you are not driving the relays correctly as well.

1 Like

Hi, @Hehenryprbo

Can you please post a proper connected schematic with all the switches and hardware that you have connected.
A PCB schematic is not very helpful to troubleshoot what the external hardware is not shown.

An image of a hand drawn schematic will be fine, include ALL power supplies, component names and pin labels.

Thanks... Tom.. :smiley: :+1: :coffee: :australia:

so maybe my first step will be, put a pullup resistor with 1k value accross pin A0 and GND? Do I have to remove the INPUT_PULLUP declaration on my code?

Are you using it as an input or reading an Analog voltage? I'm assuming digital input but just want to make sure.

My connection is kinda like this

yup, I use it as a digital input.

Hi,
On your digital inputs and you have 12V and 80V in the system, then consider opto-couplers on ALL your digital inputs to help isolate any interference.

How long are your wires from the input devices?

A 0.1uF capacitor on every input and connected to gnd, as well as some capacitors spaced on your PCB between 5V and gnd to minimise noise would also help.

Can you please post some images of your project?
So we can see your component layout.

Thanks.. Tom.. :smiley: :+1: :coffee: :australia:

actually i have to use analog to measure the voltage of the battery.

wires maybe 1to 2 metres.

which capacitor? electrolytic or ceramic?

i dont have much documentations, as i already confused with this situation :sob:


Hi,
Thanks for the info.
You definitely need 0.1uF bypass capacitors.

What does A0 output got to?
A relay, transistor, lamp, LED?

0.1uF cap of any sort, except electrolytic.
Polyester or ceramic will do.

Wire of 1 to 2 metres, they are acting as antenna to any noise from your bike.

Tom... :smiley: :+1: :coffee: :australia:

A0 output control the parking signal of the votol em100 controller. active LOW.

I see, maybe another attempt beside strong pullup resistor will be putting 0.1uf capacitor on accross A0 and GND.

Thanks, will try tomorrow

And D10 to ground, this is possibly where the interference is coming from.

Tom... :smiley: :+1: :coffee: :australia:
PS. Goodnight, I'm off to bed. :sleeping: :sleeping: :sleeping: :sleeping: :sleeping:

nice, thanks, sleep tight bruh.
will be back tomorrow. LOL
aapreciate a lot.

I have tried this, I added 10uf capacitor electrolytic between D10 and GND, and it can remove the noise.

Thanks a lot, much appreciated.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.