MPU_6000 with Arduino UNO using SPI

Hello all,

I am quite new to this field. I am trying to interface one MPU_6000 sensor with an Arduino UNO board. I am using SPI protocol for this. I have a piece of code. But the problem is that the output from the sensor is shown as -1 for all the accelerometer and Gyroscope values. I have spent several hours on this, but not able to get proper output in the serial monitor ! Can anyone help me with this?

[code / .ino file attached]

sketch_mar03a.ino (8.83 KB)