View Single Post
  #22   Spotlight this post!  
Unread 13-12-2013, 15:33
yash101 yash101 is offline
Curiosity | I have too much of it!
AKA: null
no team
 
Join Date: Oct 2012
Rookie Year: 2012
Location: devnull
Posts: 1,191
yash101 is an unknown quantity at this point
Re: MicroControllers at competitions

I was thinking of using this method because it seems simple, and easy to calculate. E=I/R; I=E/R
That means that the voltage reading you get will be equal to the amperage/the shunt resistance. I want a low vRef to help me get a much better resolution! This should give me the exact value.
Anyways, you can measure the voltage drop and you know the resistance, so I=E/R

If you are measuring a 1 volt drop, and your resistance is .25 ohms, you will have: 1/.4, or 4 amps going through the circuit. Say you have a .025 ohm resistor (much more likely in FIRST), and you have a 1.024 volt drop, you have 1.024/.025, or 40.96 amps going through the circuit.
Now, say:
R(shunt)=.025ohm
V(drop)=4v096 (4.096 volts)
4.096/.025=163.84 Amps running through the circuit.
If you see that constantly, you know that there is a fault, and you know to fix the fault. I'd say, have code ready to put on the cRIO that cycles through your robot's motors at 100%. You can write down each current value, and if it seems excessive, you know to change the motor AND the motor controller!

MAKE SURE YOU CHANGE BOTH THE MOTOR AND THE MOTOR CONTROLLER. IF YOUR MOTOR IS BY CHANCE BAD, YOU CONTROLLER MAY DIE. VICE VERSA! (I think that the caps were required