Accelerometer doesn't work in robot project

When I first tried to use the kit accelerometer with the example it didn’t work (with SPI).
Then I connected it with I2C and it worked (With the example).
But when I took the example to the robot project it started acting wierd,
The wiring is the same so it has nothing to do with it…

The problem is that on the begin the open vi of the accelerometer goes into infinite loop, I added a photo of it and the loop itself deep within the vi.

what else is in your begin?

Just to verify, you ran the example on your robot and everything was fine, it was only when you integrated it with the rest of your code that it failed.

Exactly, the example worked just fine.

And in the begin I have gyro, two joysticks, camera and drive motors.

A couple things to check:

  1. In LabVIEW go to Help>>About FIRST Robotics Competition Software… and make sure you have Software Update 5.1.0. I think we may have made an I2C fix.
  2. Open and check that the CompatibilityMode switch on the front panel is ON (I think this is the fix we made). If it is not, turn it on, and then right-click on the switch and choose Data Operations>>Make Current Value Default and then save the VI.