pcdangio / ros-driver_mpu9250

ROS driver for the InvenSense MPU9250 9DoF IMU.
MIT License
34 stars 14 forks source link

[FATAL] [1683809441.745647705]: initialize: Set mode for interrupt pin not permitted. #16

Closed jessihub closed 2 weeks ago

jessihub commented 1 year ago

Hi,

I keep getting the error: [FATAL] [1683809441.745647705]: initialize: Set mode for interrupt pin not permitted.

I use the default GPIO number 0 and physically connected it to the MPU9250's interrupt pin. Moreover my user already has permission to access the GPIO.

Do you have any idea why I still get this error?

Thanks in advance!

pcdangio commented 1 year ago

This exception is thrown when pigpio indicates a PI_NOT_PERMITTED error, which seems like its only thrown when the user running the process is either not root or not in thegpio group.

Since this library uses pigpiod, the first place I'd look is making sure that whatever user starts the pigpiod daemon has access to the gpio group. Don't forget that group changes don't go into effect until after a login/logout.

Let me know what you find.

syedjameel commented 9 months ago

I think the error @jessihub is facing because of not setting the interrupt pin number in the ROS parameter server, properly. Just in case if others face this issue, They need to set the parameters as follows: For example: i2c bus number 1, address 0x68, and interrupt gpio pin 4 (on raspberry pi) [for mpu9250] rosparam set driver_mpu9250/i2c_bus 1 rosparam set driver_mpu9250/i2c_address 104 rosparam set driver_mpu9250/interrupt_gpio_pin 4

and also they need to set the other parameters listed in the README.md file, properly.