<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://rsewiki.electro.dtu.dk/index.php?action=history&amp;feed=atom&amp;title=RFLEX_plug-in</id>
	<title>RFLEX plug-in - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://rsewiki.electro.dtu.dk/index.php?action=history&amp;feed=atom&amp;title=RFLEX_plug-in"/>
	<link rel="alternate" type="text/html" href="https://rsewiki.electro.dtu.dk/index.php?title=RFLEX_plug-in&amp;action=history"/>
	<updated>2026-04-30T17:57:15Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.1</generator>
	<entry>
		<id>https://rsewiki.electro.dtu.dk/index.php?title=RFLEX_plug-in&amp;diff=443&amp;oldid=prev</id>
		<title>S021786: New page: As the Institute for Automation got a hand on an iRobot ATRV-Jr robot platform, we needed a plug-in to control the robot. The robot has a fully developed control framework built-in, the rF...</title>
		<link rel="alternate" type="text/html" href="https://rsewiki.electro.dtu.dk/index.php?title=RFLEX_plug-in&amp;diff=443&amp;oldid=prev"/>
		<updated>2009-07-27T11:56:51Z</updated>

		<summary type="html">&lt;p&gt;New page: As the Institute for Automation got a hand on an iRobot ATRV-Jr robot platform, we needed a plug-in to control the robot. The robot has a fully developed control framework built-in, the rF...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;As the Institute for Automation got a hand on an iRobot ATRV-Jr robot platform, we needed a plug-in to control the robot. The robot has a fully developed control framework built-in, the rFLEX, that provides odometry and sensors through a RS-232 connection.&lt;br /&gt;
&lt;br /&gt;
iRobot has moved focus towards developing consumer (vacuum) and military robots, so no documentation &amp;#039;&amp;#039;&amp;#039;at all&amp;#039;&amp;#039;&amp;#039; is available for the robot. Fortunately, Carnegie Mellon University (CMU) has drivers for the rFLEX in their Carnegie Mellon Robot Navigation Toolkit ([http://carmen.sourceforge.net, CARMEN]). This is actually also the base for the rFLEX drivers in Player/Stage framework. About half of the code is ported from [http://carmen.sourceforge.net, CARMEN] - Thank you guys!&lt;br /&gt;
&lt;br /&gt;
== The rFLEX system ==&lt;br /&gt;
&lt;br /&gt;
rFLEX provides a full interface to the robot sensors, and does somewhat of post-processing, such as odometry calculations and ultrasound processing. &lt;br /&gt;
&lt;br /&gt;
The intension of the interface is to create a flexible platform for all iRobot research robots. As we only had the ATRV-Jr robot for testing, the rFLEX plugin is kept as universal as possible, but bumpers and ultrasound sensors are mapped specifically for ATRV-Jr. &lt;br /&gt;
&lt;br /&gt;
Odometry is provided in a translation / rotation axis configuration. The system outputs position, velocity, acceleration and torque in both axes (i.e. forward speed and rotation speed)&lt;br /&gt;
&lt;br /&gt;
== XML Configuration ==&lt;br /&gt;
&lt;br /&gt;
Through the [[RHD]] XML configuration, it is possible to define parameters for the plug-in&lt;br /&gt;
&lt;br /&gt;
The default configuration is seen below:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;rflex enable=&amp;quot;true&amp;quot; lib=&amp;quot;librflex.so.1&amp;quot; critical=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;serial port=&amp;quot;/dev/ttyUSB0&amp;quot; baudrate=&amp;quot;115200&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;odometry period=&amp;quot;100000&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;translation accel=&amp;quot;100000&amp;quot; torque=&amp;quot;30000&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;rotation accel=&amp;quot;100000&amp;quot; torque=&amp;quot;35000&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;bumperbrake default=&amp;quot;true&amp;quot; /&amp;gt;&lt;br /&gt;
   &amp;lt;/rflex&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt; &lt;br /&gt;
&lt;br /&gt;
Configuration include serial port settings and default values for accelleration and torque in both translation and rotation axes. &lt;br /&gt;
&lt;br /&gt;
The odometry period sets, how often a odometry package is sampled to the serial bus. The value is in µs.&lt;br /&gt;
&lt;br /&gt;
The final parameter is the bumperbrake, that is described below.&lt;br /&gt;
&lt;br /&gt;
== Plug-in special features ==&lt;br /&gt;
&lt;br /&gt;
Normally, it is against [[RHD]] principles to assign too much robot functionality into the plug-ins. But as a safety feature, a brake feature is coupled to the bumpers of the robot.&lt;br /&gt;
&lt;br /&gt;
If the bumperbrake is enabled, the robot will enable it&amp;#039;s brake, when bumpers is touched. The default setting is assigned in the XML configuration, but a write-variable makes it possible to en/disable the feature at runtime.&lt;br /&gt;
This makes the response-time as short as possible for emergency stop.&lt;br /&gt;
&lt;br /&gt;
== Plug-in variables ==&lt;br /&gt;
&lt;br /&gt;
Most of the plug-in functionality is described by the plug-ins it creates&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+ rFLEX plugin variable table&lt;br /&gt;
|-&lt;br /&gt;
! Direction &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;  !! Variable name &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;    !! Array contents &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;   !! Description&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| transvel || [vel] || Velocity of translation&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| transaccl || [accl] || Acceleration of translation&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| transtorque || [torque] || Torque of translation&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| transpos || [pos] || Position of translation (distance)&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| rotvel || [vel] || Velocity of rotation&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| rotaccl || [accl] || Acceleration of rotation&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| rottorque || [torque] || Torque of rotation&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| rotpos || [pos] || Position of rotation (bering)&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| sonar || [s0]..[s16] || Measurements of sonars (mapped 0-16, as on ATRV-Jr)&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| bumper || [front][rear] || Status of ARTV-Jr bumpers&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| brake || [brake] || Status of robot brake (updated at 1Hz)&lt;br /&gt;
|-&lt;br /&gt;
! r&lt;br /&gt;
| battvoltage || [batt] || Raw mesurement of battery voltage (needs calibration and updated at 1Hz)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| cmdtransvel || [vel] || Desired velocity of translation (command)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| cmdtransaccl || [accl] || Max acceleration of translation (XML default used if = 0)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| cmdtranstorque || [torque] || Max torque of translation (XML default used if = 0)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| cmdrotvel || [vel] || Desired velocity of rotation (command)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| cmdrotaccl || [accl] || Max acceleration of rotation (XML default used if = 0)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| cmdrottorque || [torque] || Max torque of rotation (XML default used if = 0)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| usesonar || [enable] || Enable / disable ultrasound sonars (default off)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| cmdbrake || [brake] || Enable / disable robot brake (default off)&lt;br /&gt;
|-&lt;br /&gt;
! w&lt;br /&gt;
| bumperbrake || [enable] || Enable / disable bumperbrake (overrides default)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Using these variables, it is possible to control all functions on the ATRV-Jr robot... Enjoy&lt;/div&gt;</summary>
		<author><name>S021786</name></author>
	</entry>
</feed>