View Single Post
  #1   Spotlight this post!  
Unread 04-02-2017, 16:23
DIyer5465 DIyer5465 is offline
Registered User
FRC #5465
 
Join Date: Feb 2017
Location: Chandler
Posts: 4
DIyer5465 is on a distinguished road
E4T Encoder Help

We are having issues getting values from our am-3132 (E4T) encoder, connected to our ToughBox Mini with Dual CIM input.

We currently have it wired as follows:
Orange Wire --> DIO 5 / 5V
Brown Wire --> DIO 5 / GND
Yellow Wire (Channel B) --> DIO 5 / S
Blue Wire (Channel A) --> DIO 6* / S

*Nothing is wired to GND or 5V

Code (Java):

Encoder enc = new Encoder(5,6); //robotInit()
enc.reset() //robotInit()

enc.getDistance(); //teleopPeriodic()

So far we have tried:
  1. Switching the DIO ports used
  2. Swapping Channel A and B wires
  3. Reading DIO ports using get() --> We found DIO 5 oscillates between true/false when the wheels are turning, DIO 6 stays constant false

Is there something we're overlooking?
Reply With Quote