Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Categories > Micro Controllers


Micro Controllers Discuss all aspects of micro controllers - building them, coding them, etc. All controllers are welcome - PIC, BASIC, Z8 Encore!, etc.

Reply
 
Tools
Old 12th October 2005, 05:01 PM   #1
Default Optical Encoder

Hello. I intend to buy an optical encoder in order to use it to calculate the speed of a rotating wheel. However, it says in the datasheets of the encoder that the operating current is around 80 mA but that "an inrush current of 9 Amps flows for about 0.3 ms when it is switched on". The power supply I am using at the bench provides a maximum current of 5 Amps. Will this be a problem? Will the encoder fail to operate if the initial current of 9 Amps is not fully received and could this damage my power supply? Thanks a lot.
__________________
World.......behold........YAN is coming
YAN-1 is offline  
Old 12th October 2005, 06:20 PM   #2
Default

Don't worry about it, it's only 300uS, and the capacitors in the PSU will provide that.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 14th October 2005, 11:59 AM   #3
Default

Thanks. I have actually bought the encoder and it worked fine and nothing was burnt .

But now a new problem arises. The output phases of this incremental encoder are npn open-collector transistors. In order to input the pulses to my PIC so that it can count them, I used an opto-coupler that passes 5 volts to the PIC each time a pule occurs. But it seems that the opto-coupler I got has a very low frequency response becasue unless the encoder is turned very slowly, most of the pulses are missed. Is there another way of interfacing my encoder to my PIC (a fast MOSFET perhaps) and how? Or maybe there are faster types of opto-couplers available? I've never used an electronic device with an npn output before.
Thanks a lot.
__________________
World.......behold........YAN is coming
YAN-1 is offline  
Old 14th October 2005, 12:51 PM   #4
Default

Quote:
Originally Posted by YAN-1
Thanks. I have actually bought the encoder and it worked fine and nothing was burnt .

But now a new problem arises. The output phases of this incremental encoder are npn open-collector transistors. In order to input the pulses to my PIC so that it can count them, I used an opto-coupler that passes 5 volts to the PIC each time a pule occurs. But it seems that the opto-coupler I got has a very low frequency response becasue unless the encoder is turned very slowly, most of the pulses are missed. Is there another way of interfacing my encoder to my PIC (a fast MOSFET perhaps) and how? Or maybe there are faster types of opto-couplers available? I've never used an electronic device with an npn output before.
Thanks a lot.
Just use a pull-up resistor to 5V, and feed the collector directly in to the PIC pin - it couldn't be much simpler?.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 14th October 2005, 01:06 PM   #5
Default

Quote:
Originally Posted by YAN-1
I've never used an electronic device with an npn output before.
You are using microcontrollers port pins
And so use the pull up. You need not take care of logic high on the port pin (Major advantage of open collector output)
sarang1_in is offline  
Reply

Tags
encoder, optical

Thread Tools
Display Modes




All times are GMT. The time now is 03:20 AM.


Electronic Circuits  |  Learning Electronics
eXTReMe Tracker