what is adc_timer
In the rosserial_arduino oscilloscope example there is the following line: long adc_timer;
does anyone know what adc_timer is or how it's being used?
Thanks!
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A answers.ros.org |
In the rosserial_arduino oscilloscope example there is the following line: long adc_timer;
does anyone know what adc_timer is or how it's being used?
Thanks!
Hi,
I've done this tutorial as well, and I don't see any use for that line in the code. I am certain if you comment it out (go ahead and try) that it will compile just fine.
The best reason I could see for something like this is to put a timestamp on the message, but you don't need a separate variable to keep track of that value, since you can simply use the nodehandle timestamp call : nh.now();
If you're interesting in adding a time stamp, you want to modify your message with a header. I had written up a similar thing on my blog that outputs the oscilloscope/ADC values in volts instead of counts, and includes the time stamp. If you're interested you can check it out here : Custom ROS Messages with rosserial_arduino.
Regards,
Doug
Please start posting anonymously - your entry will be published after you log in or create a new account.
Asked: 2012-07-12 12:51:38 -0600
Seen: 184 times
Last updated: Jul 13 '12
Bluetooth communication problem with arduino over rosserial_arduino and rosserial_python
Rosserial_arduino use on an arduino uno with IMU (I2C/Wire library)
rosserial debs for rosserial_arduino
rosserial communication between bluetooth and arduino
rosserial_arduino compiling problems on OS X [closed]
Using arduino with ROS: Using ros library vs serial communication in external script
How can I increase the communication rate of rosserial arduino [closed]
Using rosserial for a ATmega168/Arduino based motorcontroller