View Single Post
  #3   Spotlight this post!  
Unread 04-15-2015, 10:45 PM
Joe Ross's Avatar Unsung FIRST Hero
Joe Ross Joe Ross is offline
Registered User
FRC #0330 (Beachbots)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1997
Location: Los Angeles, CA
Posts: 8,547
Joe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond repute
Re: error with NavX MXP connected to the Serial Port

Quote:
Originally Posted by Sparkyshires View Post
Hey guys, title pretty much says it all. About two weeks ago, we installed the new NavX MXP and set it up. We downloaded their code from their github repo and we're using that. The only problem is that I'm not sure that I'm using it properly. I'm no expert in using the serial port on the roboRIO, and I have a feeling that something somewhere is going wrong. Does anybody know where this error might be coming from? our code is at https://github.com/Sparky384/Team384Year2015



Code:
Error on line 115 of SerialPort.cpp: HAL - VISA: Resource Locked
	at /home/lvuser/FRCUserProgram() [0x23b4c]
	at /home/lvuser/FRCUserProgram() [0x1194c]
	at startRoutine(void*)
Thanks for your time! If you have any questions about the code feel free to ask them. All the relevant gyro calls are in the drivetrain subsystem file.
Code:
sPort = new SerialPort(57600,SerialPort::kMXP);
navX = new AHRS(sPort, 60);
imu = new IMU(sPort, 60);
You should choose either AHRS or IMU, not both.

Quote:
Originally Posted by slibert View Post
Perhaps the latest code is not checked in - or I'm looking in the wrong place.
It's in the gyro branch.
Reply With Quote