diff --git a/src/ezbot_command_module/config/.gitignore b/src/ezbot_command_module/config/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/src/ezbot_command_module/launch/.gitignore b/src/ezbot_command_module/launch/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/src/ezbot_command_module/src/tirette_node.cpp b/src/ezbot_command_module/src/tirette_node.cpp index b654317..5caa8c6 100644 --- a/src/ezbot_command_module/src/tirette_node.cpp +++ b/src/ezbot_command_module/src/tirette_node.cpp @@ -11,22 +11,24 @@ void TiretteNode::readGPIO() int value; chip = gpiod_chip_open("/dev/gpiochip0"); + printf("chip : %p\n", chip); + if (!chip) { - // handle error + printf("unable to open GPIO\n") } line = gpiod_chip_get_line(chip, 11); if (!line) { - // handle error + printf("unable to get line\n") } if (gpiod_line_request_input(line, "tirette_node") < 0) { - // handle error + printf("unable to request line\n") } value = gpiod_line_get_value(line); if (value < 0) { - // handle error + printf("unable to get value\n") } message.data = value ? true : false;