http://img13.imageshack.us/img13/7916/iuc.gif
R2 is to protect pic if current is over 20mA.
Also you can use 220 Ohm resistor for R1, so you can detect over current...
http://img13.imageshack.us/img13/7916/iuc.gif
R2 is to protect pic if current is over 20mA.
Also you can use 220 Ohm resistor for R1, so you can detect over current...
Thanks.
Just curious to know why there are so many circuits involving Op-Amps when this can be done so simply with 2 resistors?
Because when input is on 4mA output voltage is 1V. So you get output 1-5V for input 4-20mA. Some pic have differential input, so you still can get all 8,10 or 12 bit. Or you can in software subtract value to get 0 reading when input is 4mA, but then resolution is lower.
Also you can use OAmp with offset to get 0 on output when input is 4mA...
Thanks Pedja. One more question has popped up in my mind. I measured the voltage on the output of the sensor. It measures out at 8V, the sensor is working on 12V. So is it safe to connect the connections from the sensor to the PIC with just one resistor in between?
Mesure voltage on R1, that voltage goes to pic. U=R*I, R=250 Ohm, I=20mA, U=5V. So check your circuit and current...
Bookmarks