View Single Post
  #4   Spotlight this post!  
Unread 09-02-2010, 15:14
stevethetinker stevethetinker is offline
Registered User
FRC #1288 (RAVEN)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 2004
Location: St. Charles, MO
Posts: 35
stevethetinker is an unknown quantity at this point
Re: C++ V4.1 Update and DriverStationLCD

Another question for Brad: is source available for the new update? I am having some nasty problems and need the source for a few classes.

My problems in case you might be able to help:

The gyro class won't initialize correctly. The constructor seems to run but calling GetAngle gives a memory access error. The debugger in Gyro.cpp shows that m_analog is NULL. BUT: I have Gyro.cpp from a previous version of the source.

Encoders don't work. I get no counts. A logic probe on the wires from the encoders shows there is a signal there. BTW, the encoders are powered from the DIO +5 pin. Is that OK?

Adding some bits of code cause obscure errors. I can add some loops to bring the return angle from the gyro (when I compute it myself rather than use the Gyro class) into the interval [-pi, pi) causes the joystick input not to go through to the wheels. I haven't isolated where the input goes away, but when I remove the angle loops the problem goes away.

All these suggest there may be a memory overwrite somewhere. I am in a panic this late for this problem. These things can take weeks to find.
Reply With Quote