Open droter opened 6 years ago
Found a couple problems. My user wasn't added to the gpio group. I had the wrong pin assignment BCM vs Wiring. To view the pin out this command is helpful : gpio readall
The error in ROS log: [ERROR] [1532822222.361818]: Error processing request: Pin 8 has not been exported. ['Traceback (most recent call last):\n', ' File "/opt/ros/kinetic/lib/python2.7/dist-packages/rospy/impl/tcpros_service.py", line 625, in _handle_request\n response = convert_return_to_response(self.handler(request), self.response_class)\n', ' File "/home/ubuntu/catkin_ws/src/rpi_gpio/rpi_gpio/nodes/rpi_gpio_node.py", line 136, in _set_pin_handler\n assert msg.pin in self.directions, \'Pin %s has not been exported.\' % msg.pin\n', 'AssertionError: Pin 8 has not been exported.\n']
Anyone see this before?
When starting the launch file and the example.yaml config file I get the following error: load_parameters: unable to set parameters (last param was [/rpi_gpio/states=[{8: 1}]]): dictionary key must be string Traceback (most recent call last): File "/usr/lib/python2.7/xmlrpclib.py", line 739, in dump_struct raise TypeError, "dictionary key must be string" TypeError: dictionary key must be string
example.yaml file: $ more example.yaml // Define the pins that are inputs or outputs. directions:
// Define default pin states. states:
shutdown_states:
Hi,
I am getting this error when calling rosservice call /rpi_gpio/set_pin 2 1
$ rosservice call /rpi_gpio/set_pin 2 1 ERROR: Unable to load type [rpi_gpio/DigitalWrite]. Have you typed 'make' in [rpi_gpio]?
The package built without errors. I did need to install wiringpi python.
Thanks for the help,
Matt