Driver for the laserscanner R2000 of Pepperl+Fuchs. More...
#include <r2000_driver.h>
Public Member Functions | |
bool | checkConnection () |
bool | connect (const std::string hostname, int port=80) |
void | disconnect () |
Disconnect from the laserscanner and reset internal state. More... | |
void | feedWatchdog (bool feed_always=false) |
Feed the watchdog with the current handle ID, to keep the data connection alive. More... | |
ScanData | getFullScan () |
std::size_t | getFullScansAvailable () const |
Get the total number of fully received laserscans available. More... | |
const std::map< std::string, std::string > & | getParameters () |
const std::map< std::string, std::string > & | getParametersCached () const |
const ProtocolInfo & | getProtocolInfo () |
ScanData | getScan () |
std::size_t | getScansAvailable () const |
Get the total number of laserscans available (even scans which are not fully reveived yet) More... | |
bool | isCapturing () |
bool | isConnected () |
Return connection status. More... | |
R2000Driver () | |
Initialize driver. More... | |
bool | rebootDevice () |
bool | resetParameters (const std::vector< std::string > &names) |
bool | setParameter (const std::string &name, const std::string &value) |
bool | setSamplesPerScan (unsigned int samples) |
bool | setScanFrequency (unsigned int frequency) |
bool | startCapturingTCP () |
bool | startCapturingUDP () |
bool | stopCapturing () |
~R2000Driver () | |
Cleanly disconnect in case of destruction. More... |
- Solenoid drivers from Pepperl+Fuchs are part of our K-System isolated barriers product family. Solenoid drivers provide power to a load in a hazardous area and can be switched on/off by a signal from a logic circuit.
- The ROS package pepperlfuchsr2000 consists of the driver library and a node named r2000node, which is linked to the library. This is the actual driver node. This is the actual driver node. The dummyslambroadcaster is only needed if you want to display the sensors data using the QuickStart method mentioned below.
- Pepperl+Fuchs Current Drivers Asia Science&Technology Company Limited We are a customer-oriented distributor for electronic components and industrial control parts.
Pepperl+Fuchs R2000 Driver This is the documentation of a driver for the Pepperl+Fuchs OMD10M-R2000-B23 laser range finder. The driver is based upon the widespread boost asio library (http://www.boost.org).
Private Attributes | |
HttpCommandInterface * | command_interface_ |
HTTP/JSON interface of the scanner. More... | |
ScanDataReceiver * | data_receiver_ |
Asynchronous data receiver. More... | |
double | food_timeout_ |
Feeding interval (in seconds) More... | |
boost::optional< HandleInfo > | handle_info_ |
Handle information about data connection. More... | |
bool | is_capturing_ |
Internal capturing state. More... | |
bool | is_connected_ |
Internal connection state. More... | |
std::map< std::string, std::string > | parameters_ |
Cached version of all parameter values. More... | |
ProtocolInfo | protocol_info_ |
Cached version of the protocol info. More... | |
double | watchdog_feed_time_ |
Last time the watchdog was fed. More... |
Detailed Description
Driver for the laserscanner R2000 of Pepperl+Fuchs.
Definition at line 47 of file r2000_driver.h.
Constructor & Destructor Documentation
Initialize driver.
Definition at line 39 of file r2000_driver.cpp.
Cleanly disconnect in case of destruction.
Definition at line 72 of file r2000_driver.cpp.
Member Function Documentation
bool pepperl_fuchs::R2000Driver::checkConnection | ( | ) |
Actively check connection to laserscanner
- Returns
- True if connection is alive, false otherwise
Definition at line 136 of file r2000_driver.cpp.
bool pepperl_fuchs::R2000Driver::connect | ( | const std::string | hostname, |
int | port = 80 | ||
) |
Connects to a given laserscanner, gets and checks protocol info of scanner, retrieves values of all parameters
ip | IP or hostname of laserscanner |
port | Port to use for HTTP-Interface (defaults to 80) |
Definition at line 49 of file r2000_driver.cpp.
Disconnect from the laserscanner and reset internal state.
Definition at line 197 of file r2000_driver.cpp.
void pepperl_fuchs::R2000Driver::feedWatchdog | ( | bool | feed_always = false | ) |
Feed the watchdog with the current handle ID, to keep the data connection alive.
Definition at line 270 of file r2000_driver.cpp.
ScanData pepperl_fuchs::R2000Driver::getFullScan | ( | ) |
Pop a single full scan out of the driver's internal FIFO queue if there is any If no full scan is available yet, blocks until a full scan is available
- Returns
- A ScanData struct with distance and amplitude data as well as the packet headers belonging to the data
Definition at line 160 of file r2000_driver.cpp.
std::size_t pepperl_fuchs::R2000Driver::getFullScansAvailable | ( | ) | const |
Get the total number of fully received laserscans available.
Definition at line 185 of file r2000_driver.cpp.
const std::map< std::string, std::string > & pepperl_fuchs::R2000Driver::getParameters | ( | ) |
Read all parameter values from the scanner
- Returns
- A key->value map with parametername->value
Definition at line 222 of file r2000_driver.cpp.
| inline |
Get cached parameter values of the scanner
- Returns
- A key->value map with parametername->value
Definition at line 97 of file r2000_driver.h.
| inline |
Retrieve Protocol information of the scanner
- Returns
- A struct containing name, version and available commands of the protocol
Definition at line 89 of file r2000_driver.h.
Pop a single scan out of the driver's interal FIFO queue CAUTION: Returns also unfinished scans for which a full rotation is not received yet Call getFullScansAvailable() first to see how many full scans are available
- Returns
- A ScanData struct with distance and amplitude data as well as the packet headers belonging to the data
Definition at line 147 of file r2000_driver.cpp.
std::size_t pepperl_fuchs::R2000Driver::getScansAvailable | ( | ) | const |
Get the total number of laserscans available (even scans which are not fully reveived yet)
Definition at line 173 of file r2000_driver.cpp.
Return capture status
- Returns
- True if a capture is running, False otherwise
Definition at line 216 of file r2000_driver.cpp.
| inline |
Return connection status.
Definition at line 65 of file r2000_driver.h.
Reboot Laserscanner (Takes ~60s)
- Returns
- True if command was successfully received, False otherwise
Definition at line 246 of file r2000_driver.cpp.
bool pepperl_fuchs::R2000Driver::resetParameters | ( | const std::vector< std::string > & | names | ) |
Reset certain parameters to factory default
names | Names of parameters to reset |
- Returns
- True if successfull, False otherwise
Definition at line 254 of file r2000_driver.cpp.
bool pepperl_fuchs::R2000Driver::setParameter | ( | const std::string & | name, |
const std::string & | value | ||
) |
Set a parameter by name and value
- Returns
- True if successfull, False otherwise
Definition at line 262 of file r2000_driver.cpp.
bool pepperl_fuchs::R2000Driver::setSamplesPerScan | ( | unsigned int | samples | ) |
Set number of samples per scan/rotation
samples | Only certain values are allowed (see Manual). Examples are 72, 360, 720, 1440, 1800, 3600, 7200, 10080, 25200 |
- Returns
- True on success, False otherwise
Drivers Pepperl Fuchs Proximity
Definition at line 238 of file r2000_driver.cpp.
bool pepperl_fuchs::R2000Driver::setScanFrequency | ( | unsigned int | frequency | ) |
Set scan frequency (rotation speed of scanner head)
frequency | Frequency in Hz |
Definition at line 230 of file r2000_driver.cpp.
bool pepperl_fuchs::R2000Driver::startCapturingTCP | ( | ) |
Start capturing laserdata: Requests a handle and begin retrieving data from the scanner
- Returns
- True in case of success, False otherwise
Definition at line 78 of file r2000_driver.cpp.
bool pepperl_fuchs::R2000Driver::startCapturingUDP | ( | ) |
Start capturing laserdata: Requests a handle and begin retrieving data from the scanner
- Returns
- True in case of success, False otherwise
Definition at line 97 of file r2000_driver.cpp.
Stop capturing laserdata: Release handle and stop retrieving data from the scanner
- Returns
- True in case of success, False otherwise
Definition at line 117 of file r2000_driver.cpp.
Member Data Documentation
| private |
HTTP/JSON interface of the scanner.
Definition at line 143 of file r2000_driver.h.
| private |
Asynchronous data receiver.
Definition at line 146 of file r2000_driver.h.
| private |
Feeding interval (in seconds)
Definition at line 158 of file r2000_driver.h.
| private |
Handle information about data connection.
Definition at line 161 of file r2000_driver.h.
| private |
Internal capturing state.
Definition at line 152 of file r2000_driver.h.
| private |
Internal connection state.
Pepperl+fuchs Distributors
Definition at line 149 of file r2000_driver.h.
| private |
Cached version of all parameter values.
Definition at line 167 of file r2000_driver.h.
| private |
Cached version of the protocol info.
Definition at line 164 of file r2000_driver.h.
| private |
Last time the watchdog was fed.
Definition at line 155 of file r2000_driver.h.
The documentation for this class was generated from the following files:Datasheet excerpt: Technical data of KFD0-SD2-Ex2.1245
Product Description | ||
---|---|---|
current limit 45 mA |
General specifications | ||
---|---|---|
Signal type | Digital Output | |
Functional safety related parameters | ||
Safety Integrity Level (SIL) | SIL 3 | |
Supply | ||
Rated voltage | loop powered | |
Power dissipation | < 1 W (≤ 30 V) per channel | |
Input | ||
Connection side | control side | |
Connection | terminals 7, 8; 8, 9 | |
Rated voltage | 20 ... 35 V DC | |
Current | 72 mA at 20 V input voltage, load = 265 Ω 50 mA at 35 V input voltage, load = 265 Ω | |
Inrush current | ≤ 200 mA after 100 µs | |
Output | ||
Connection side | field side | |
Connection | terminals 1+, 2-; 4+, 5- | |
Internal resistor | max. 238 Ω | |
Current | ≤ 45 mA | |
Voltage | ≥ 12 V | |
Open loop voltage | min. 22.7 V | |
Output rated operating current | 45 mA | |
Output signal | These values are valid for the rated operating voltage 20 ... 35 V DC. | |
Energized/De-energized delay | single operation: typ. 1.7 ms/50 µs; periodical: typ. 5 µs/50 µs | |
Indicators/settings | ||
Display elements | LEDs | |
Labeling | space for labeling at the front | |
Directive conformity | ||
Electromagnetic compatibility | ||
Directive 2014/30/EU | EN 61326-1:2013 (industrial locations) | |
Conformity | ||
Electromagnetic compatibility | NE 21:2006 | |
Degree of protection | IEC 60529:2001 | |
Protection against electrical shock | UL 61010-1:2004 | |
Ambient conditions | ||
Ambient temperature | -20 ... 60 °C (-4 ... 140 °F) | |
Mechanical specifications | ||
Degree of protection | IP20 | |
Connection | screw terminals | |
Mass | approx. 100 g | |
Dimensions | 20 x 107 x 115 mm (0.8 x 4.2 x 4.5 inch) , housing type B1 | |
Mounting | on 35 mm DIN mounting rail acc. to EN 60715:2001 | |
Data for application in connection with hazardous areas | ||
EU-type examination certificate | BASEEFA 06 ATEX 0252 | |
Marking | II (1)G [Ex ia Ga] IIC, II (1)D [Ex ia Da] IIIC, I (M1) [Ex ia Ma] I (-20 °C ≤ Tamb ≤ 60 °C) | |
Voltage | 25.2 V | |
Current | 110 mA | |
Power | 693 mW | |
Input | ||
Maximum safe voltage | 250 V (Attention! The rated voltage can be lower.) | |
Certificate | TÜV 99 ATEX 1499 X | |
Marking | II 3G Ex nA II T4 [device in zone 2] | |
Galvanic isolation | ||
Input/Output | safe electrical isolation acc. to IEC/EN 60079-11, voltage peak value 375 V | |
Directive conformity | ||
Directive 2014/34/EU | EN 60079-0:2012+A11:2013 , EN 60079-11:2012 , EN 60079-15:2010 | |
International approvals | ||
FM approval | ||
Control drawing | 116-0309 | |
UL approval | ||
Control drawing | 116-0316 (cULus) | |
IECEx approval | ||
IECEx certificate | IECEx BAS 06.0058 IECEx CML 19.0093X | |
IECEx marking | [Ex ia Ga] IIC , [Ex ia Da] IIIC , [Ex ia Ma] I Ex ec IIC T4 Gc | |
General information | ||
Supplementary information | Observe the certificates, declarations of conformity, instruction manuals, and manuals where applicable. For information see www.pepperl-fuchs.com. |
Comments are closed.