Servo troubleshoot


 

SPDecoste

New member
Hey guys,

I just made a Heatermeter 4.3! Everything is working except the servo.. :confused: I was hoping some of you could give me a hand troubleshooting my issue.

Raspberry Pi 3 B
Power Supply (Same brand as suggested) 2A
Servo MG90D
Blower 15cfm (works properly)

I know the MG90D is working because when I touched the yellow cable with my multimeter it was moving randomly.

I read a few threads and saw that the Q5 BS170 could be the issue so I replaced it. No dice. Also someone had a bent pin on the ATMEGA. Mine looks fine.

What other component could be affecting the servo? I guess I could replace the 1k resistor next to the CAT5 jack, but I tested it with a multimeter and it seems to be working fine.

I don't really know how to test the circuit with a Multimeter, how do I check the servo signal and 5v? I guess ground is working fine because the blower use it.

also, I had a few problems connecting the BS170 so I replaced them all with new ones I bought from a store near my place. I guess all BS170 are the same, but they didn't have the same things written on them... They didn't have the "F"... not sure if this makes any difference.

What other pieces I could test/replace/resolder that could help my situation?

Thanks
 
Last edited:

SPDecoste

New member
I tried with a MG90s, not working. I tried changing the 1k resistor... nothing

My board might be damaged from my poor soldering skills... When I changed the BS170 I might have damaged the circuit around the joints. I'll keep on looking.
 

Bryan Mayland

TVWBB Hall of Fame
What's it doing, is it going to weird positions and jittering all around, or is it just totally dead and not moving at all (even if you move it to a different position before powering on)? The first is usually solved by the capacitor. Have you tried measuring the voltage between "Servo" and "GND" at the output jack? It's a 5V PWM signal so depending on your multimeter it might display differently, but on mine it shows ~0.38V at 0% output and ~0.70V at 100% output.
 

SPDecoste

New member
What's it doing, is it going to weird positions and jittering all around, or is it just totally dead and not moving at all (even if you move it to a different position before powering on)? The first is usually solved by the capacitor. Have you tried measuring the voltage between "Servo" and "GND" at the output jack? It's a 5V PWM signal so depending on your multimeter it might display differently, but on mine it shows ~0.38V at 0% output and ~0.70V at 100% output.

Not moving at all.

I get ~4.96V on the HM board from GND to Servo.

I changed the Q5 bs170 twice...

I get ~4.86V from GND to Servo on the cat5 jack at the end of the servo. Is that correct?
 

Bryan Mayland

TVWBB Hall of Fame
That does not sound right, unless your multimeter is only reading the peak voltage and not the average voltage. You can check that by measuring the servo output from the microcontroller on the pin labeled SVO (or on the gate pin of Q5, closest to the microcontroller). If it reads 3.3V I suppose your multimeter is reading only peak voltage so those numbers seem right. If it reads a low voltage, like 0.45V at 100% then that's right and something is feeding 5V into your servo output. If that is the case then maybe check between the +5V and SERVO pin on the output with no power connected and you should see a resistance of about 1Mohm (no servo connected).
 

SPDecoste

New member
That does not sound right, unless your multimeter is only reading the peak voltage and not the average voltage. You can check that by measuring the servo output from the microcontroller on the pin labeled SVO (or on the gate pin of Q5, closest to the microcontroller). If it reads 3.3V I suppose your multimeter is reading only peak voltage so those numbers seem right. If it reads a low voltage, like 0.45V at 100% then that's right and something is feeding 5V into your servo output. If that is the case then maybe check between the +5V and SERVO pin on the output with no power connected and you should see a resistance of about 1Mohm (no servo connected).

Thanks for taking the time to help me out!

GND and Gate Pin of Q5 gives me 5.16V @ 0% and 5.20V @ 100%.

I went through all the installation over and I have no idea where to look at now.

The only thing I could think of is that I had to buy new bs170 because I messed up the first time installing them and the one I bought are not labeled exactly the same as the one that came with the kit.

The one I bought says:

CAL
B$170
M9705

I don't know much so I asked the guy if there was different type of BS170, he said no and gave me this... https://abra-electronics.com/ics-se...ets/bs170-mosfet-n-channel-05a-60v-bs170.html

I'll try to find the exact same one as you.
 
Last edited:

SPDecoste

New member
What are your Servo Pulse Duration settings in the HM config? Maybe the issue is there?

Everything is default. Should I change something?

3Fer5NG.png
 

RalphTrimble

TVWBB Diamond Member
Are you sure you are connecting the servo to the proper wires? I would unplug the HM power and use continuity mode on your meter to see if the red servo wire goes to +5v on the HM board cat5 jack (pins are marked on the board on the solder side), Orange goes to SERVO and brown goes to ground.
 

SPDecoste

New member
Are you sure you are connecting the servo to the proper wires? I would unplug the HM power and use continuity mode on your meter to see if the red servo wire goes to +5v on the HM board cat5 jack (pins are marked on the board on the solder side), Orange goes to SERVO and brown goes to ground.

Alright I'll try this it out tomorrow!

Is it normal I get 5.16V on the bs170 pin and servo pin though?
 

RalphTrimble

TVWBB Diamond Member
No, not normal... mine measures just about .385VC on the Servo pin, .385V on one side of R21 and 5v on the other, on Q5 I see .385V - 3.3V - .287
The only place you should see 5V is on the high side of R21, the transistor should have only 3.3v on the center pin, low voltages on the other two. Seems like something may be shorting 5V somewhere on the servo line. Try unplugging the CAT5 cable and check for a short between the SERVO and BLOW pin and also 5v pin, maybe you over soldered there and bridged. If no short, plug in your CAT5 cable and see if they are bridged, maybe you have a short in your cat5 wiring somewhere? It's just that resistor (R21) and that transistor (Q5) you are concerned with... Check the traces for continuity from point to point and bridges to other components or traces...
 
Last edited:

SPDecoste

New member
No, not normal... mine measures just about .385VC on the Servo pin, .385V on one side of R21 and 5v on the other, on Q5 I see .385V - 3.3V - .287
The only place you should see 5V is on the high side of R21, the transistor should have only 3.3v on the center pin, low voltages on the other two. Seems like something may be shorting 5V somewhere on the servo line. Try unplugging the CAT5 cable and check for a short between the SERVO and BLOW pin and also 5v pin, maybe you over soldered there and bridged. If no short, plug in your CAT5 cable and see if they are bridged, maybe you have a short in your cat5 wiring somewhere? It's just that resistor (R21) and that transistor (Q5) you are concerned with... Check the traces for continuity from point to point and bridges to other components or traces...

Thanks for answering so quickly!

Is the R21 the 1k Resistor next to the cat5 jack? Both ends read 5.20V on it. On the Q5 I get from left to right: 5.39V - 3.58V - 2.07V

I guess that's the problem. Now I have no idea how to solve this...

The power is first going through the Q5 and then going to R21, right?
 
Last edited:

Bryan Mayland

TVWBB Hall of Fame
No, the issue is that your Q5 has 5V, which is definitely wrong. I think you might be honing in on the issue now though. Check the resistance between the SERVO pin on the output and the SVO pin on the microcontroller (no power plugged in) to see if there's a short there. This may be difficult to test though because the BS170 will probably start conducting solely from probing it with the multimeter so you might have to remove Q5 again.

Q5 when active should have voltages like Ralph mentioned, a low voltage on the right pin, 3.3V on the center pin, and a slightly higher voltage on the left pin than was on the right (~1.5x right). The right pin should never have more than 3.3V on it so the most likely scenario is that the left and right pins are bridged somehow. You can also check the resistance of that 1k resistor by the output hack to make sure it reads about 1k and not like 5 ohms.

Note that I mistakenly called the right pin of Q5 the gate in my previous post but the gate pin is actually the center one. I did mean the right pin, but that's actually the source pin that's connected to SVO on the microcontroller. However, neither the gate nor source should have more than 3.3V at any time.
 
Last edited:

SPDecoste

New member
No, the issue is that your Q5 has 5V, which is definitely wrong. I think you might be honing in on the issue now though. Check the resistance between the SERVO pin on the output and the SVO pin on the microcontroller (no power plugged in) to see if there's a short there. This may be difficult to test though because the BS170 will probably start conducting solely from probing it with the multimeter so you might have to remove Q5 again.

Q5 when active should have voltages like Ralph mentioned, a low voltage on the right pin, 3.3V on the center pin, and a slightly higher voltage on the left pin than was on the right (~1.5x right). The right pin should never have more than 3.3V on it so the most likely scenario is that the left and right pins are bridged somehow. You can also check the resistance of that 1k resistor by the output hack to make sure it reads about 1k and not like 5 ohms.

Note that I mistakenly called the right pin of Q5 the gate in my previous post but the gate pin is actually the center one. I did mean the right pin, but that's actually the source pin that's connected to SVO on the microcontroller. However, neither the gate nor source should have more than 3.3V at any time.

Ok, I just realized what you were refering to on your 2nd post when you said the SVO on the microcontroller.

You can check that by measuring the servo output from the microcontroller on the pin labeled SVO (or on the gate pin of Q5, closest to the microcontroller). If it reads 3.3V I suppose your multimeter is reading only peak voltage so those numbers seem right. If it reads a low voltage, like 0.45V at 100% then that's right and something is feeding 5V into your servo output

The SVO pin on the microcontroller @ 100% reads 0.37V.

The right pin from the Q5 @ 100% reads 2.12V
Middle @ 100% reads 3.70V
Left @ 100% reads 5.60V

I get 989 ohm when measuring the SERVO and 5V+ on the output (No power, No Ethernet connected) (Is that a good thing?)

I get 1589 ohm when measuring Servo (from Output) to Q5 right pin.

I get 001 ohm from Servo to Q5 left pin

I get nothing from Servo to Q5 middle pin

I get nothing measuring Servo (output) to SVO (microcontroller) Did not remove the bs170 though
 
Last edited:

RalphTrimble

TVWBB Diamond Member
Sounds like you have a short somewhere from a solder bridge or something, perhaps you should post some close up pictures of the board and someone may spot the bridge for you.

If you have proper de-soldering equipment the easiest way to troubleshoot may be to remove the resistor and transistor and measure voltages on those same points again. If you still have 5V on the servo pin at the CAT5 jack then you have a short somewhere that you need to find and correct.

You mentioned that you replaced the BS170 with an equivalent, are you sure the pin out is the same as the original?
 

Bryan Mayland

TVWBB Hall of Fame
The SVO pin on the microcontroller @ 100% reads 0.37V. - Seems about right
The right pin from the Q5 @ 100% reads 2.12V - This seems wrong since SVO and the right pin of Q5 are directly connected so they should have the same voltage
Middle @ 100% reads 3.70V - I'm not sure how this is 3.7V considering it is directly connected to the 3.3V rail so you should not be seeing more than 3.3V
Left @ 100% reads 5.60V - And this one is connected to 5V (through the 1k resistor) so it should never be above 5V
I get 989 ohm when measuring the SERVO and 5V+ on the output (No power, No Ethernet connected) - That's the 1k resistor you're seeing there so that's perfect
I get 1589 ohm when measuring Servo (from Output) to Q5 right pin. - This seems low, are you measuring it with power applied? It might also be somewhat conducting so that might be ok. It is hard to say.
I get 001 ohm from Servo to Q5 left pin - perfect
I get nothing from Servo to Q5 middle pin - sounds rightish
I get nothing measuring Servo (output) to SVO (microcontroller) Did not remove the bs170 though - Well that would be OK if Q5 isn't "on", but the 1589ohm reading says it is mostly on so you should read the same thing there as you did between SERVO and Q5 right pin. It could also be that the gate charge on Q5 has dissipated so it isn't conducting any more

My next course of action would be to remove Q5 and do the measurements again and make sure the left and right Q5 pins (now holes) don't show as connected, and with power and 100% output, you get 5V at the left pin/hole, 3.3V at the center pin/hole, and 0.2-0.4V on the right pin/hole, all within +/-3%.
 

SPDecoste

New member
Sounds like you have a short somewhere from a solder bridge or something, perhaps you should post some close up pictures of the board and someone may spot the bridge for you.

If you have proper de-soldering equipment the easiest way to troubleshoot may be to remove the resistor and transistor and measure voltages on those same points again. If you still have 5V on the servo pin at the CAT5 jack then you have a short somewhere that you need to find and correct.

You mentioned that you replaced the BS170 with an equivalent, are you sure the pin out is the same as the original?

The bs170 seems to be the same, but with some different stuff written on it. I guess the pin out is the same. Not sure how I could test it out.

I think we're onto something with my next post. Sounds like it could be from SVO to the right pin of bs170

The SVO pin on the microcontroller @ 100% reads 0.37V. - Seems about right
The right pin from the Q5 @ 100% reads 2.12V - This seems wrong since SVO and the right pin of Q5 are directly connected so they should have the same voltage
Middle @ 100% reads 3.70V - I'm not sure how this is 3.7V considering it is directly connected to the 3.3V rail so you should not be seeing more than 3.3V
Left @ 100% reads 5.60V - And this one is connected to 5V (through the 1k resistor) so it should never be above 5V
I get 989 ohm when measuring the SERVO and 5V+ on the output (No power, No Ethernet connected) - That's the 1k resistor you're seeing there so that's perfect
I get 1589 ohm when measuring Servo (from Output) to Q5 right pin. - This seems low, are you measuring it with power applied? It might also be somewhat conducting so that might be ok. It is hard to say.
I get 001 ohm from Servo to Q5 left pin - perfect
I get nothing from Servo to Q5 middle pin - sounds rightish
I get nothing measuring Servo (output) to SVO (microcontroller) Did not remove the bs170 though - Well that would be OK if Q5 isn't "on", but the 1589ohm reading says it is mostly on so you should read the same thing there as you did between SERVO and Q5 right pin. It could also be that the gate charge on Q5 has dissipated so it isn't conducting any more

My next course of action would be to remove Q5 and do the measurements again and make sure the left and right Q5 pins (now holes) don't show as connected, and with power and 100% output, you get 5V at the left pin/hole, 3.3V at the center pin/hole, and 0.2-0.4V on the right pin/hole, all within +/-3%.

Here's what I got:

Left hole: 4.95V
middle hole: 3.28V
right hole: 0.00V (sometimes 0.01V...)

SVO on microcontroller: 0.33V

So the problem is the right hole I guess... There's no continuity between SVO and right hole.

As usually I don't know what my next move should be :confused: so I'll be waiting for your reply!

Thanks again
 
Last edited:
Top