dheera / ros-pwm-pca9685

ROS package for PCA9685 16-channel PWM driver, used in motor and LED applications

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Segmentation Fault

themultiplexer opened this issue · comments

Hi @dheera

I am pretty new to ROS and trying to build a RPi-Robot to learn it.
I have this PCA9685 based PWM board and I run ROS Melodic on Debian Buster and everything works fine (including a camera). The board has address 0x40 so the default parameters are probably correct.

libi2c-dev is installed and I try to start your node like this:

rosrun pwm_pca9685 pca9685_node

But it segfaults:

[ INFO] [1585099217.457893949]: initializing
[ INFO] [1585099217.477227357]: starting
Segmentation fault

(gdb) backtrace

#0  0x00016158 in pwm_pca9685::PCA9685Activity::set(unsigned char, unsigned short) ()
#1  0x00016ae0 in pwm_pca9685::PCA9685Activity::spinOnce() ()
#2  0x00015bd4 in main ()

Maybe you know why this happens or you can tell me how to properly debug it.

Oh wait, today after restarting the bot and the master it does not crash with a segmentation fault anymore 👍