41 int main(
int argc,
char **argv)
43 ros::init(argc, argv,
"sick_tim551_2050001");
49 if(nhPriv.
getParam(
"hostname", hostname)) {
53 nhPriv.
param<std::string>(
"port", port,
"2112");
56 nhPriv.
param(
"timelimit", timelimit, 5);
58 bool subscribe_datagram;
60 nhPriv.
param(
"subscribe_datagram", subscribe_datagram,
false);
61 nhPriv.
param(
"device_number", device_number, 0);
66 if (nhPriv.
getParam(
"range_min", param))
70 if (nhPriv.
getParam(
"range_max", param))
74 if (nhPriv.
getParam(
"time_increment", param))
85 if (subscribe_datagram)
103 if (
ros::ok() && !subscribe_datagram && !useTCP)
bool param(const std::string ¶m_name, T ¶m_val, const T &default_val)
void set_time_increment(float time)
ROSCPP_DECL void init(int &argc, char **argv, const std::string &name, uint32_t options=0)
void set_range_max(float max)
bool param(const std::string ¶m_name, T ¶m_val, const T &default_val) const
int main(int argc, char **argv)
void set_range_min(float min)
bool getParam(const std::string &key, std::string &s) const
ROSCPP_DECL void spinOnce()