Rotary Encoder Issue
Helihead
Posts: 4
Hi All,
I have been away from circuits for a while so I'm probably just missing something obvious but I have a problem with a rotary encoder on a BS2 that has me stumped.
I have an Oak Grigsby 5V 64PPR encoder PN 78016 connected to P0 and P1 on a BS2 plugged into a super carrier board.· I rotate the encoder but get no inputs.·
I breadboarded the encoder before I hooked it to the uC and it works great with 1K pull-ups.· It clocks forward and backwards just fine and switches LEDs on/off and I have confirmed the outputs with my oscilloscope.· Everything looks great on the bread board.
I confirmed by BS2 and stamp code by switching those two inputs with plain old switches.· I can toggle them by hand and watch it count up and down just pefect.
When I hook·the encoder to the BS2, I go no input although I do see the inputs swing from .1V to about .21 and back as I rotate.· I thought it was likely my selecion of pull-up resistors but at this point I have tried everthing from 50 ohms up to 100K Ohms and I get basically the same thing.
In summary:
1) The encoder works perfect on a breadboard with 1K pull-ups.
2) The BS2 and code work perfectly when switched with push button switches.
3) The encoder connected to the BS2 only swings the inputs about .2V regardless of pull-up resistors selected and never trigger the input
Any·ideas?
Even with the problem it's good to be back doodlin' with circuits again.
Thanks
I have been away from circuits for a while so I'm probably just missing something obvious but I have a problem with a rotary encoder on a BS2 that has me stumped.
I have an Oak Grigsby 5V 64PPR encoder PN 78016 connected to P0 and P1 on a BS2 plugged into a super carrier board.· I rotate the encoder but get no inputs.·
I breadboarded the encoder before I hooked it to the uC and it works great with 1K pull-ups.· It clocks forward and backwards just fine and switches LEDs on/off and I have confirmed the outputs with my oscilloscope.· Everything looks great on the bread board.
I confirmed by BS2 and stamp code by switching those two inputs with plain old switches.· I can toggle them by hand and watch it count up and down just pefect.
When I hook·the encoder to the BS2, I go no input although I do see the inputs swing from .1V to about .21 and back as I rotate.· I thought it was likely my selecion of pull-up resistors but at this point I have tried everthing from 50 ohms up to 100K Ohms and I get basically the same thing.
In summary:
1) The encoder works perfect on a breadboard with 1K pull-ups.
2) The BS2 and code work perfectly when switched with push button switches.
3) The encoder connected to the BS2 only swings the inputs about .2V regardless of pull-up resistors selected and never trigger the input
Any·ideas?
Even with the problem it's good to be back doodlin' with circuits again.
Thanks
Comments
I disconnected the encoder inputs from Po and P1 and it clocks perfectly.· I get about .3V for the low and it switches to 4.8V for the high pulse from the encoder.· I hooked it up to P0 and I'm back to the original issue where it swings from about .2V to .45V as I clock the encoder.
I think you are right about the input being loaded but I'm not sure what else it would be as the 2 encoder inputs are currently the only connections on the board besides the built in super carrier stuff.
Like I said, I can jumper the input to Vdd or switch it with a switch and watch my code respond correctly.· Not sure why it is so different for these encoders.
·
Looks like it is hooked up right.
The hardware was right but·I'd set my inputs as outputs in my code and that had it latched up.· Not sure where my head was but I'm blaming it on this being the first stamp·code I've done·in probably·5 years and the fact that I wrote that·with a 5 year old and a·3 year old running around tearing the house apart.
Anyway, thanks for you help.
If anyone has trouble getting your inputs to read... MAKE SURE YOUR INPUTS ARE SET AS INPUTS·AND NOT OUTPUTS :-)
Glad you got it working.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Whit+
"We keep moving forward, opening new doors, and doing new things, because we're curious and curiosity keeps leading us down new paths." - Walt Disney