miércoles, 18 de agosto de 2010

Testing the Sick Laser

1) First I created a directory called:

~/Player_Stage/Laser_Test

Then I created there a file named sick.cfg (This idea was taked from Laura's Blogg).

The content of that file must be:

driver
(
name "sicklms200"
provides ["laser:0"]
port "/dev/ttyUSB1")

Then, after saving it you must execute these commands:
$ robot-player sick.cfg
$ robot-playerv

Then you are supposed to see the scan when you subscribe to the laser sick lms 200.
...
But following these steps I couldn't get the lecture of the laser, instead I got this error:

oscar@oscar-laptop:~/Player_Stage/Laser_Test$ robot-playerv
PlayerViewer 2.0.4
Connecting to [localhost:6665]
calling connect
done
Available devices: localhost:6665
laser:0 sicklms200 ready
playerc error : timed out waiting for server reply to request 6:0:3:1
playerv : error in dev_laser.c
libplayerc error: timed out waiting for server reply to request 6:0:3:1


Then reading about the ports I accessed the /dev directory and looked up for the ttyUSB0 port, but I could not fin it. The ports I found that I think may be the usb ports are these:

usbmon0
usbmon1
usbmon2



...

Reading about usbmon on the web I got these info:

"3 The name "usbmon" in lowercase refers to a facility in kernel which is
4 used to collect traces of I/O on the USB bus. This function is analogous
5 to a packet socket used by network monitoring tools such as tcpdump(1)
6 or Ethereal. Similarly, it is expected that a tool such as usbdump or
7 USBMon (with uppercase letters) is used to examine raw traces produced
8 by usbmon.
9
10 The usbmon reports requests made by peripheral-specific drivers to Host
11 Controller Drivers (HCD). So, if HCD is buggy, the traces reported by
12 usbmon may not correspond to bus transactions precisely. This is the same
13 situation as with tcpdump.


So I need the ports ttyUSB0 and ttyUSB1.

Reading on Linux Forums I found this post, and it maybe the main reason of why I don't see the port on /dev:


"I don't know what exactly your device is. But my Palm use ttyUSB0 to sync with Ubuntu. The /dev directory is managed by udev, so every device file is created dynamically. What I see on my system is: when I connect my Palm to the usb port and push the sync button on Palm, the /dev/ttyUSB0 will be created on the fly. And after the sync is over, the /dev/ttyUSB0 gone too. So you might not see the /dev/ttyUSB0 device file if your device is not activated."


The next step is to try again the teleoperation of the Pioneer and see if the ttyUSB0 port is created at that instant.

...

It doesn't work, I get the next error:

ROSARIA/bin$ ./RosAria
[ INFO] [1282178888.412720880]: using serial port: [/dev/ttyUSB0]
ArLog::init: Could not open file aria.log for logging.
Could not connect to simulator, connecting to robot through serial port /dev/ttyUSB0.
ArSerialConnection::open: Could not open serial port '/dev/ttyUSB0'
Could not connect, because open on the device connection failed.
Failed to connect to robot.
rotate: Could not connect to robot! Exiting.
setup failed...

I don't have any idea of why ttyUSB0 doesn't appear. I will continue tomorrow.
------------------------------------------------------------------------------------

Testing the Laser With Aria.

First change the port from COM3 to ttyUSB0 (It depends in where you want to listen the Laser) in line 110 of p3dx.p in .../Aria/Aria/params

No hay comentarios:

Publicar un comentario