[Documentation] [TitleIndex] [WordIndex

Package: psen_scan_v2

The psen_scan_v2 package is a ROS integration driver for the PSENscan safety laser scanner product. It lets you integrate the laser scanner data into your ROS Environment easily. Using the standard sensor_msgs/LaserScan message format ensures compatibility with other laserscan-post-processing nodes such as gmapping.

PILZ safety laser scanner

Common features:

Light versions Additional features:

Supported Devices

PSENscan firmware >= 3.1.0 is supported on the following models:



Order number

PSEN sc L 3.0 08-12

3.0 m safety zone, 8 or 12-pin exchangeable memory module


PSEN sc L 5.5 08-12

5.5 m safety zone, 8 or 12-pin exchangeable memory module


*Master versions* Additional features: Muting, EDM, Override, restart in accordance with EN ISO 61496-3, vertical applications

PSEN sc M 3.0 08-12

3.0 m safety zone, 8 or 12-pin exchangeable memory module


PSEN sc M 5.5 08-12

5.5 m safety zone, 8 or 12-pin exchangeable memory module


PSEN sc ME 5.5 08-17

Master Encoder, 5.5 m safety zone, 8/17-pin exchangeable memory



To start reading data from the safety laser scanner and publishing scans execute roslaunch psen_scan_v2 psen_scan_v2.launch in a command line. This will launch the ROS Node with the default configuration.

If you wish to set parameters from the command line, add them to the end of the command as parameter:=value, separated by spaces.

roslaunch psen_scan_v2 psen_scan_v2.launch sensor_ip:=

This example configures the safety laser scanner at to send it´s frames to the ROS node at localhost.

In order to create an application with your own launch file, you can include the bringup.launch, where you can easily adjust the configuration parameters. A more detailed explanation can be found in the tutorials.









IP-Address of safety laser scanner.

Optional Parameters








Name of this scanner that can be changed to differentiate between multiple devices. By convention this is used as tf prefix.



-2.398 (= -137.4 deg))

Start angle of measurement. (Radian)



2.398 (= 137.4 deg))

End angle of measurement. It is included in the measurements. (Radian)




Publish intensities. If this is enabled, the resolution needs to be increased (at least 0.2 deg).



0.0017 (= 0.1 deg))

Scan angle resolution. (Radian) The value is rounded to a multiple of 0.1 deg and has to be in the range [0.1, 10] degrees.




Full path to a scanner config file. If a file is provided the configured zonesets and active zone markers are published, see here for more information.

Expert Parameters (optional)








IP-Address of host machine. The IP of the local machine is used by default.




UDP Port on which monitoring frames (scans) should be received.




UDP Port used to send commands (start/stop) and receive the corresponding replies.




Publish scan data as soon as a UDP packet is ready, do not wait for a full scan.




Start a preconfigured rviz visualizing the scan data.

Published Topics

/<name>/scan (sensor_msgs/LaserScan)

Hint: 1: Scan rounds and fragments that contain no measurement data are not published. This can happen with smaller scan ranges.

Hint: 2: Frequency of the laser scan messages is about 33hz for the combined and 200hz for the fragmented scans.

/<name>/zoneconfiguration (psen_scan_v2/ZoneSetConfiguration)

Hint: 1: Will not be advertised if no config_file is provided.

/<name>/active_zoneset (std_msgs/UInt8)

Hint: 1: If no zonesets are configured the driver will publish "0" as default.

/<name>/active_zoneset_markers (visualization_msgs/MarkerArray)

Hint: 1: Uses the topics /<name>/zoneconfiguration and /<name>/active_zoneset to calculate the vizualization and updates in the same frequency as those topics.

Hint: 2: Will not be advertised if no config_file is provided.

/<name>/io_states (psen_scan_v2/IOState)

Hint: 1: With every scan data of a monitoring frame the IO states are transferred from the PSENscan safety laser scanner. They are processed in the same way as the scan data.

Hint: 2: By using <fragmented_scans=true> the driver will publish 1 IOStates while with <fragmented_scans=false> it will publish 6 IOStates per single publish of scan data.

Hint: 3: The timesamps of all IO states are the same as the one of their corresponding LaserScan msg.

TF Frames

The location of the TF frames is shown in the image below. These names are defined by the aforementioned launchfile parameter name. Changing them is necessary for instance when running multiple scanners.

PILZ safety laser scanner frames

Defining the scan range

You can adjust the scan field to your needs by changing angle_start and angle_end. The published sensor_msgs/LaserScan will only contain data within the given angle limits. Both limits are defined within the laser_1frame as shown in the image below.

Limit visualization

Timestamp details

The timestamps of the scan data published are computed to be close to reality and processing speed of incoming data was optimized to reduce the time for the scan data to be published. This should suffice for localization and slam algorithms. If you application benefits from getting the scan data any sooner there are two possibilities:

Transferred IOs

The state of inputs and outputs of the PSENscan safety laser scanner are published as psen_scan_v2/IOState. The topic at /<name>/io_states is latched and always gives the most recent pin state. On changes at the physical IOs, the changes are logged to the console and the new state is published to the topic.

The input pin state contains information about

The output pin state consists of

Please see the message descriptions for full lists of bits.

Importing the zoneset configuration

Once you setup the scanner and created a configuration according to our tutorial you can use an exported xml configuration file within ROS. The configured zonesets will be published.

The zonesets you created in the Pilz configurator:


will be exactly the same in ROS:


You can try this out with:

roslaunch psen_scan_v2 psen_scan_v2.lauch config_file:='full_path_to/example_config.xml'

If you want to use the configuration node in your launchfile add a section such as:

   1 <node ns="$(arg laser_ns)" name="config_server_node_$(arg laser_ns)" type="config_server_node" pkg="psen_scan_v2">
   2   <param name="config_file" value="$(arg config_file)" />
   3   <param name="frame_id" value="$(arg frame_id)" />
   4 </node>

Visualizing the active zoneset

For visualizing the active zoneset in RViz you can run the active_zoneset_node. It will publish markers on the <name>/active_zoneset_markers topic like shown in the RViz screenshot above.

Report a Bug

Use GitHub to report bugs or submit feature requests. [View active issues]

Further information

You need further information? Our international hotline staff will support you individually about our ROS packages at ros@pilz.de or visit us at https://pilz.com.

Pilz is an international-scale, innovative automation technology company. Pilz uses its solutions to create safety for man, machine and the environment. In addition to the head office in Ostfildern near Stuttgart, the family business is represented by over 2,400 employees at 42 subsidiaries and branches on all continents.

The company's products include sensor technology, electronic monitoring relays, safety relays, configurable and programmable control systems, automation solutions with motion control, systems for industrial communication as well as visualization solutions and operator terminals.

Pilz solutions can be used in all areas of mechanical engineering, including the packaging and automotive sector, plus the railway technology, press and wind energy sectors. These solutions ensure that baggage handling systems run safely at airports and funiculars or roller coasters travel safely; they guarantee fire protection an energy supply in buildings.


2024-07-20 13:25