-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
Hello,
I wonder why we don't capture the timestamp immediately after setting the GPIO pin to HIGH?
sensor_trigger/src/sensor_trigger.cpp
Lines 154 to 161 in 60c9e5b
| bool to_high = gpio_handler_.set_gpio_pin_state(GPIO_HIGH); | |
| rclcpp::sleep_for(std::chrono::nanoseconds(pulse_width)); | |
| rclcpp::Time now = rclcpp::Clock{RCL_SYSTEM_TIME}.now(); | |
| int64_t now_sec = now.nanoseconds() / 1e9; | |
| trigger_time_msg.sec = (int32_t)now_sec; | |
| trigger_time_msg.nanosec = (uint32_t)now_nsec; | |
| trigger_time_publisher_->publish(trigger_time_msg); | |
| bool to_low = gpio_handler_.set_gpio_pin_state(GPIO_LOW); |
In the current implementation above, we are waiting until the falling edge. Why? Is the camera capturing the frame according to a falling edge?
Metadata
Metadata
Assignees
Labels
No labels