Jump to content

Recommended Posts

Posted

I was unable to use the IR tower on Windows 7 64 bit, so I need to know if there is a driver for the tower for Ubuntu. I do not want to use NQC to program the brick, I would like to use the Lego-made RIS 2.0, which I have running using Wine. Anybody out there who can help?

Thanks in advance,

Coby

Posted (edited)

Not sure about Ubuntu (last time I used Unix was in grad school ... 20 years ago!) but I recall I able to get it to work under Windows 7-64Bit, a while back. The other option is to try and run RoboLab (there should be a free version out there) and you can write programs for the RCX brick with it as well. Try the two links below. Good luck.

http://www.eurobrick...showtopic=70888

http://www.sevenforu...-usb-tower.html

Edited by DrJB
Posted

Do you have the USB or the COM (RS232) version?

Linux kernel has native support for the USB version, it's seen as a COM port. The COM version is just that, something connected to your COM port so no drivers needed (of course, your system needs to support the COM port itself but that's pretty standard, even most USB-COM adapters work).

So you just need to redirect your COM port to Wine. I know that it's possible but never done that.

I've both versions but I'll be out for some days so cannot help you although I'm interested in how managed to get Wine working, has been some years since i've tried [without sucess].

And you can always try VirtualBox, create a Virtual Machine with XP and redirect your COM or USB to the VM, I've done that with USB bluetooth dongle and my NXT 2.0 some years ago.

Posted

Not sure about Ubuntu (last time I used Unix was in grad school ... 20 years ago!) but I recall I able to get it to work under Windows 7-64Bit, a while back. The other option is to try and run RoboLab (there should be a free version out there) and you can write programs for the RCX brick with it as well. Try the two links below. Good luck.

http://www.eurobrick...showtopic=70888

http://www.sevenforu...-usb-tower.html

Do you have the USB or the COM (RS232) version?

Linux kernel has native support for the USB version, it's seen as a COM port. The COM version is just that, something connected to your COM port so no drivers needed (of course, your system needs to support the COM port itself but that's pretty standard, even most USB-COM adapters work).

So you just need to redirect your COM port to Wine. I know that it's possible but never done that.

I've both versions but I'll be out for some days so cannot help you although I'm interested in how managed to get Wine working, has been some years since i've tried [without sucess].

And you can always try VirtualBox, create a Virtual Machine with XP and redirect your COM or USB to the VM, I've done that with USB bluetooth dongle and my NXT 2.0 some years ago.

Thank you for the help. I have the USB version of the tower, and couldn't get the built in driver to work (i will keep trying). I did not have any probems with Wine, do you need some help with that? I tried a VirtualBox, but it wanted me to install the OS.

Posted

Thank you for the help. I have the USB version of the tower, and couldn't get the built in driver to work (i will keep trying). I did not have any probems with Wine, do you need some help with that? I tried a VirtualBox, but it wanted me to install the OS.

I have Ubuntu 14.10 (64 bit). I bought the USB Tower two months ago from Bricklink and remember that it was recognized immediately after plugging it. Never tried to used with a Mindstorms, my goal at the time was using it with lirc for remote control of Power Functions (failed). Could you run "dmesg" and "lsusb" before and after you plug it and post here just the difference?

The lsusb should show a device with USB id "ID 0694:0001 Lego Group Mindstorms Tower" and at the end of dmesg is expected something like this:

...

usbcore: registered new interface driver legousbtower

Posted (edited)

I have Ubuntu 14.10 (64 bit). I bought the USB Tower two months ago from Bricklink and remember that it was recognized immediately after plugging it. Never tried to used with a Mindstorms, my goal at the time was using it with lirc for remote control of Power Functions (failed). Could you run "dmesg" and "lsusb" before and after you plug it and post here just the difference?

The lsusb should show a device with USB id "ID 0694:0001 Lego Group Mindstorms Tower" and at the end of dmesg is expected something like this:

...

usbcore: registered new interface driver legousbtower

Here are the results. I tried to include what was different, and just linked it in documents so my post wouldn't be unsanely long. Is this what you wanted? It seems to be working? Does this mean I just need to get Wine to detect it? Also, is the green light supposed to be on when it is plugged in? When I plug it in, the light flashes for ~1 second and then turns off.

Oops, files wont upload (I blame libreoffice, should have saved it as .docx)

Not plugged in:

[ 55.068877] init: plymouth-upstart-bridge main process ended, respawning

[ 55.101795] init: plymouth-upstart-bridge main process ended, respawning

[ 107.978575] init: plymouth-stop pre-start process (2711) terminated with status 1

[ 140.317894] usb 5-1: new low-speed USB device number 2 using xhci_hcd

[ 140.356403] usb 5-1: New USB device found, idVendor=0694, idProduct=0001

[ 140.356415] usb 5-1: New USB device strings: Mfr=4, Product=26, SerialNumber=0

[ 140.356419] usb 5-1: Product: LEGO USB Tower

[ 140.356423] usb 5-1: Manufacturer: LEGO Group

[ 140.359505] legousbtower 5-1:1.0: LEGO USB Tower #-160 now attached to major 180 minor 0

[ 140.361478] legousbtower 5-1:1.0: LEGO USB Tower firmware version is 1.0 build 134

[ 448.169566] systemd-hostnamed[3203]: Warning: nss-myhostname is not installed. Changing the local hostname might make it unresolveable. Please install nss-myhostname!

[ 751.492381] usb 5-1: USB disconnect, device number 2

[ 751.493097] legousbtower 5-1:1.0: LEGO USB Tower #-160 now disconnected

[ 767.077256] usb 3-1: new low-speed USB device number 3 using ohci-pci

[ 767.266854] usb 3-1: New USB device found, idVendor=0694, idProduct=0001

[ 767.266873] usb 3-1: New USB device strings: Mfr=4, Product=26, SerialNumber=0

[ 767.266882] usb 3-1: Product: LEGO USB Tower

[ 767.266890] usb 3-1: Manufacturer: LEGO Group

[ 767.270422] legousbtower 3-1:1.0: LEGO USB Tower #-160 now attached to major 180 minor 0

[ 767.272672] legousbtower 3-1:1.0: LEGO USB Tower firmware version is 1.0 build 134

[ 895.026384] usb 3-1: USB disconnect, device number 3

[ 895.027486] legousbtower 3-1:1.0: LEGO USB Tower #-160 now disconnected

Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 002 Device 002: ID 13d3:5702 IMC Networks UVC VGA Webcam

Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 003 Device 002: ID 192f:0716 Avago Technologies, Pte.

Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

PLugged in:

[ 55.068877] init: plymouth-upstart-bridge main process ended, respawning

[ 55.101795] init: plymouth-upstart-bridge main process ended, respawning

[ 107.978575] init: plymouth-stop pre-start process (2711) terminated with status 1

[ 140.317894] usb 5-1: new low-speed USB device number 2 using xhci_hcd

[ 140.356403] usb 5-1: New USB device found, idVendor=0694, idProduct=0001

[ 140.356415] usb 5-1: New USB device strings: Mfr=4, Product=26, SerialNumber=0

[ 140.356419] usb 5-1: Product: LEGO USB Tower

[ 140.356423] usb 5-1: Manufacturer: LEGO Group

[ 140.359505] legousbtower 5-1:1.0: LEGO USB Tower #-160 now attached to major 180 minor 0

[ 140.361478] legousbtower 5-1:1.0: LEGO USB Tower firmware version is 1.0 build 134

[ 448.169566] systemd-hostnamed[3203]: Warning: nss-myhostname is not installed. Changing the local hostname might make it unresolveable. Please install nss-myhostname!

[ 751.492381] usb 5-1: USB disconnect, device number 2

[ 751.493097] legousbtower 5-1:1.0: LEGO USB Tower #-160 now disconnected

[ 767.077256] usb 3-1: new low-speed USB device number 3 using ohci-pci

[ 767.266854] usb 3-1: New USB device found, idVendor=0694, idProduct=0001

[ 767.266873] usb 3-1: New USB device strings: Mfr=4, Product=26, SerialNumber=0

[ 767.266882] usb 3-1: Product: LEGO USB Tower

[ 767.266890] usb 3-1: Manufacturer: LEGO Group

[ 767.270422] legousbtower 3-1:1.0: LEGO USB Tower #-160 now attached to major 180 minor 0

[ 767.272672] legousbtower 3-1:1.0: LEGO USB Tower firmware version is 1.0 build 134

[ 895.026384] usb 3-1: USB disconnect, device number 3

[ 895.027486] legousbtower 3-1:1.0: LEGO USB Tower #-160 now disconnected

[ 1158.538138] usb 3-1: new low-speed USB device number 4 using ohci-pci

[ 1158.730181] usb 3-1: New USB device found, idVendor=0694, idProduct=0001

[ 1158.730199] usb 3-1: New USB device strings: Mfr=4, Product=26, SerialNumber=0

[ 1158.730208] usb 3-1: Product: LEGO USB Tower

[ 1158.730216] usb 3-1: Manufacturer: LEGO Group

[ 1158.734173] legousbtower 3-1:1.0: LEGO USB Tower #-160 now attached to major 180 minor 0

[ 1158.736064] legousbtower 3-1:1.0: LEGO USB Tower firmware version is 1.0 build 134

Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 002 Device 002: ID 13d3:5702 IMC Networks UVC VGA Webcam

Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 003 Device 002: ID 192f:0716 Avago Technologies, Pte.

Bus 003 Device 004: ID 0694:0001 Lego Group Mindstorms Tower

Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

EDIT: What is nss-myhostname? Does this need installed? If so , how?

Wow, aren't I demanding!

Edited by CobyCobie
Posted

Your USB IR Tower is working and the driver loaded :)

Please type

ls /dev/usb/lego*

you should have /dev/usb/legousbtower0 or /dev/usb/legousbtower1 like I had, the number isn't important.

If you do have it, that's your device, try to use it with wine as COM1, i believe this is the way:

go to your home folder, there is a hidden .wine folder, that's were wine is, go to this folder:

~/.wine/dosdevices

and create a link so that wine thinks com1 is your USB IR Tower:

ln -s /dev/usb/legousbtower0 com1

(you can use another COM port). If the linux legousbtower talks exposes the USB IR tower as a serial device, wine will let your Mindstorms software to talk with it. If not, we'll have to investigate a bit further, next year ;)

nss-myhostname is a service not related to LEGO. I have same the same messages, don't worry :)

Posted

Your USB IR Tower is working and the driver loaded :)

Please type

ls /dev/usb/lego*

you should have /dev/usb/legousbtower0 or /dev/usb/legousbtower1 like I had, the number isn't important.

If you do have it, that's your device, try to use it with wine as COM1, i believe this is the way:

go to your home folder, there is a hidden .wine folder, that's were wine is, go to this folder:

~/.wine/dosdevices

and create a link so that wine thinks com1 is your USB IR Tower:

ln -s /dev/usb/legousbtower0 com1

(you can use another COM port). If the linux legousbtower talks exposes the USB IR tower as a serial device, wine will let your Mindstorms software to talk with it. If not, we'll have to investigate a bit further, next year ;)

nss-myhostname is a service not related to LEGO. I have same the same messages, don't worry :)

So I typed all of that in in order, is that what I was supposed to do? Or was there something I had to add (I am very new to Ubuntu). It doesn't work. I tried to do it in both USB and serial modes (in RIS) but was unable to connect to the RCX.

Thank you for all of the help, I am excited to get this thing working.

Posted

OK, excuse for assuming you were familiar with Ubuntu.

First: when you have the USB IR Tower connected, what is the output of the following command:

ls /dev/usb/lego*

it should show legousbtower0 or something simillar (I think mine was legousbtower1, the number at the end doesn't real matter). This his the file handler for your device, you could send it something with 'cp' command like

cp "Test" > /dev/usb/legousbtower0

and read from it with 'cat' command, although none of these has practical use, it's just for testing that you have acess to the device.

Posted (edited)

OK, excuse for assuming you were familiar with Ubuntu.

First: when you have the USB IR Tower connected, what is the output of the following command:

ls /dev/usb/lego*

it should show legousbtower0 or something simillar (I think mine was legousbtower1, the number at the end doesn't real matter). This his the file handler for your device, you could send it something with 'cp' command like

cp "Test" > /dev/usb/legousbtower0

and read from it with 'cat' command, although none of these has practical use, it's just for testing that you have acess to the device.

First one was /dev/usb/legousbtower0

I don't know if I ran the second one right (just copied and pasted, removed "test" and got the same result, because I assumed it was a comment), but here: bash: /dev/usb/legousbtower0: Permission denied

I'm guessing the "Permission denied" is not good. I am just running in the only account I set up, which is the admin account.

Happy New Year!

Edited by CobyCobie
Posted

The permission denied is not unusual. Ubuntu and other Debian systems like to play safe so unless you create a special rule for your device it will create the handler for it with permissions just for root.

You can try

sudo chmod 777 /dev/usb/legousbtower0

this will give everyone permissions to the device until your next reboot (or maybe just next unplug/replug). 'sudo' is a command that allows you to run other commands as root. Since you are using Ubuntu, your user as permissions to use 'sudo' but it will ask you first for your password (not root password; yours). It will remember that password for some minutes so you don't have to insert it always.

Then try this command:

echo "something" > /dev/usb/legousbtower0

'echo' is a command to send "something" to a handler. You can use this command as is or write whatever you want instead of something (but keep the commas if you use spaces), it's just for testing that you can write to the device. I'm not sure but I think that if the command works you will see some blinking on the USB IR Tower.

Posted

'echo' is a command to send "something" to a handler. You can use this command as is or write whatever you want instead of something (but keep the commas if you use spaces), it's just for testing that you can write to the device. I'm not sure but I think that if the command works you will see some blinking on the USB IR Tower.

There was blinking! Went into RIS 2.0 and still nothing, though.

Posted

Good!

You have your USB IR Tower working, you can already use some open source tools to program your RCX.

But for RIS to work with Wine it is necessary to match your USB IR Tower linux handle to something that Wine can pass to RIS. If it was a COM IR Tower, the method at post #8 would work but I'm not sure if the linux driver for USB IR Tower emulates a COM port or not. Now please excuse me but I really can't help much more until I return home and also install RIS 2.0 with Wine.

Since you said you don't want to use NQC, if you are in a big hurry you can try to get a COM IR Tower but you also need a COM port - my laptop doesn't so I used a USB<->COM cable adapter, Ubuntu has support for most of these type of adapters.

Posted

Good!

You have your USB IR Tower working, you can already use some open source tools to program your RCX.

But for RIS to work with Wine it is necessary to match your USB IR Tower linux handle to something that Wine can pass to RIS. If it was a COM IR Tower, the method at post #8 would work but I'm not sure if the linux driver for USB IR Tower emulates a COM port or not. Now please excuse me but I really can't help much more until I return home and also install RIS 2.0 with Wine.

Since you said you don't want to use NQC, if you are in a big hurry you can try to get a COM IR Tower but you also need a COM port - my laptop doesn't so I used a USB<->COM cable adapter, Ubuntu has support for most of these type of adapters.

Since the method in post 8 doesn't work, i'm guessing it does not emulate a com port. I am in no hurry, and I didn't want to use NQC mainly because I thought it would be nice to use the extremely simple Lego interface. Thank you for all of the help once again, I will try to Google a solution now that I know more about what I am doing.

Posted (edited)

Well, I bring good news and bad news...

The good news:

1. I got RIS 2.0 working with Wine (installs fine but when run I got a problem with it demanding 16 bpp, not quite sure how I solved it).

2. I got RIS 2.0 working with Wine AND LEGO IR Tower COM version with a USB-COM adapter

The bad news:

3. I can't find a way to use RIS 2.0 with Wine and LEGO IR Tower USB version. Sorry.

For others that might get here, here's how to use the COM version IR Tower with a USB COM adapter in Ubuntu:

My adapter is recognized by Ubuntu as a "pl2303 converter" with handler /dev/ttyUSB0

I give it full access:

sudo chmod 777 /dev/ttyUSB0

Then create the symbolic link for Wine to see it as COM1:

cd ~/.wine/dosdevices

ln -s /dev/ttyUSB0 com1

Then run RIS 2.0 with RCX already on.

At 'Settings' RIS finds the tower at COM1, but I couldn't run or download programs so I choose "Download Firmware", it suceeded (but from RIS side never ended, had to restart it some minutes AFTER the RCX beeped).

After that everything fine, RIS recognize RCX with firmware 2.0 and even shows battery level, and I can now run my own programs and download to RCX:

irtowercom.png

Edited by MajorAlvega
Posted (edited)

To get the com tower working, did you need the cord that comes with it, or just an adapter, because the towers are like 5 bucks.

I am still determined to see if this is possible. So far, none of the fixes have worked.

Does anybody think it is possible to run this on my Win7 64 bit/Ubuntu 14.04 machine with the usb IR tower? I am unable to run a virtual machine as I don't have a copy of any operating systems, and I do not want to spend money.

EDIT: I am now installing Wine 1.5.3 in an attempt to then install the usb compatibility patch Wine made for it. Worth a try, considering this is the only reason I have Ubuntu.

Edited by CobyCobie
Posted

To get the com tower working, did you need the cord that comes with it, or just an adapter, because the towers are like 5 bucks.

You need something with the typical 9-pin plug that fits in the IT Tower plug. I've used the original cord, both ends are female and don't have those fasteners at both sides that wouldn't allow to insert it.

You can get one from less than $2 at bricklink,

http://www.bricklink.com/search.asp?itemID=8860&colorID=9

Does anybody think it is possible to run this on my Win7 64 bit/Ubuntu 14.04 machine with the usb IR tower? I am unable to run a virtual machine as I don't have a copy of any operating systems, and I do not want to spend money.

Everybody say that is not possible because there are no x64 version of the drivers. The workaround is the same: get a serial version of the tower, eventually also a USB adapter.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...