Go to the documentation of this file.
57 #ifndef SICK_TIM3XX_COMMON_TCP_H
58 #define SICK_TIM3XX_COMMON_TCP_H
64 #undef NOMINMAX // to get rid off warning C4005: "NOMINMAX": Makro-Neudefinition
83 virtual std::vector<unsigned char> &
data(
void) {
return datagram; }
97 char cola_dialect_id);
113 bool stopScanData(
bool force_immediate_shutdown =
false);
145 virtual int sendSOPASCommand(
const char *request, std::vector<unsigned char> *reply,
int cmdLen,
bool wait_for_reply =
true);
158 bool isBinaryProtocol,
int *numberOfRemainingFifoEntries,
const std::vector<std::string>& datagram_keywords);
161 virtual int readWithTimeout(
size_t timeout_ms,
char *buffer,
int buffer_size,
int *bytes_read,
const std::vector<std::string>& datagram_keywords);
DatagramWithTimeStamp(rosTime timeStamp_, std::vector< unsigned char > datagram_)
virtual int readWithTimeout(size_t timeout_ms, char *buffer, int buffer_size, int *bytes_read, const std::vector< std::string > &datagram_keywords)
int reinit(rosNodePtr nh, int delay_millisec)
void disconnectFunction()
static void disconnectFunctionS(void *obj)
UINT8 m_receiveBuffer[480000]
Low-Level receive buffer for all data.
Mutex m_receiveDataMutex
Access mutex for buffer.
void setEmulSensor(bool _emulFlag)
Set emulation flag (using emulation instead of "real" scanner - currently implemented for radar.
SopasEventMessage findFrameInReceiveBuffer()
UINT8 m_packetBuffer[480000]
void readCallbackFunctionOld(UINT8 *buffer, UINT32 &numOfBytes)
virtual int init_device()
UINT32 m_numberOfBytesInResponseBuffer
Number of bytes in buffer.
Queue< DatagramWithTimeStamp > recvQueue
void processFrame(rosTime timeStamp, SopasEventMessage &frame)
virtual ~SickScanCommonTcp()
virtual int sendSOPASCommand(const char *request, std::vector< unsigned char > *reply, int cmdLen, bool wait_for_reply=true)
Send a SOPAS command to the device and print out the response to the console.
bool getEmulSensor()
get emulation flag (using emulation instead of "real" scanner - currently implemented for radar
void setReplyMode(int _mode)
bool stopScanData(bool force_immediate_shutdown=false)
SickScanCommonTcp(const std::string &hostname, const std::string &port, int &timelimit, rosNodePtr nh, SickGenericParser *parser, char cola_dialect_id)
UINT8 m_responseBuffer[1024]
Receive buffer for everything except scan data and eval case data.
virtual int get_datagram(rosNodePtr nh, rosTime &recvTimeStamp, unsigned char *receiveBuffer, int bufferSize, int *actual_length, bool isBinaryProtocol, int *numberOfRemainingFifoEntries, const std::vector< std::string > &datagram_keywords)
Read a datagram from the device.
static void readCallbackFunctionS(void *obj, UINT8 *buffer, UINT32 &numOfBytes)
void readCallbackFunction(UINT8 *buffer, UINT32 &numOfBytes)
bool isConnected()
Returns true if the tcp connection is established.
virtual int close_device()
virtual std::vector< unsigned char > & data(void)
ros::Time * timeStamp(M &m)
returns TimeStamp<M>::pointer(m);
int numberOfDatagramInInputFifo()
std::vector< unsigned char > datagram
Class that represents a message that was sent by a sensor. (Event message)
UINT32 m_alreadyReceivedBytes
UINT32 m_numberOfBytesInReceiveBuffer
Number of bytes in buffer.
sick_scan_xd
Author(s): Michael Lehning
, Jochen Sprickerhof , Martin Günther
autogenerated on Fri Oct 25 2024 02:47:11