11 #include <rosserial_mbed/Adc.h> 13 #if defined(TARGET_LPC1768) 20 #elif defined(TARGET_KL25Z) || defined(TARGET_NUCLEO_F401RE) 28 #error "You need to specify the pins for the adcs" 40 for (
int i=0;
i<4;
i++) v+= AnalogIn(pin).read_u16();
rosserial_mbed::Adc adc_msg
void publish(const boost::shared_ptr< M > &message) const
ros::Publisher p("adc",&adc_msg)
int averageAnalog(PinName pin)
Publisher advertise(const std::string &topic, uint32_t queue_size, bool latch=false)