Marvelmind python does not get location data on raspberry pi 3

Frequent questions asked online, offline, in forums are answered here
victory
Posts: 1
Joined: Thu Mar 29, 2018 12:34 am

Marvelmind python does not get location data on raspberry pi 3

Postby victory » Thu Mar 29, 2018 12:44 am

I'm trying to run this code: https://bitbucket.org/marvelmind_robotics/marvelmind.py on the the raspberry pi 3. I don't get location data from it.
Here is the output:
pi@roomba:~/marvelmind_robotics-marvelmind.py-76cbfffbe3e6/src $ python example.py
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00
Hedge 0: X: 0 m, Y: 0 m, Z: 0 m at time T: 0.00

The Windows GUI connects to the network and we are able to see the locations of the beacons and the hedgehog. When we move the modem to the raspberry pi and run the above script, we get zeroes for everything.

What we have tried to do:
1. Freeze the sub-map in the windows GUI and then plugging the modem in the pi and then running the python script
2. Adding permissions to the raspberry pi ports
3. We have tried python2 and python3
4. We have the Linux version of the GUI, but we can't run it because we can't find the driver.

How do you suggest I proceed?

Thank you,
Victory

smoker77
Posts: 262
Joined: Sat Feb 06, 2016 4:03 pm

Re: Marvelmind python does not get location data on raspberry pi 3

Postby smoker77 » Thu Mar 29, 2018 11:34 pm

Hello,
1. Make sure you connect to correct serial port.
Check list of ports before and after connecting the modem: ls /dev/ttyACM*
Python script connects to /dev/ttyACM0 by default, so after connecting modem /dev/ttyACM0 should appear.
2. After connecting modem, the mobile beacon should start sounding after several seconds. Stationary beacons should not sound, but they should blink by LEDs. If modem is too close to mobile beacon, radio signal may be too strong, communication (and consenquently positioning) will not work.
3. Try to check coming data from modem by any software, for example simply: cat /dev/ttyACM0
The data will not be readable, but you will check their presence.

mmcclan3
Posts: 2
Joined: Sun Nov 18, 2018 7:20 pm

Re: Marvelmind python does not get location data on raspberry pi 3

Postby mmcclan3 » Mon Nov 19, 2018 3:07 am

I am currently having the exact same issue. Did you ever find a solution?

zlite
Posts: 16
Joined: Fri Feb 16, 2018 8:04 am

Re: Marvelmind python does not get location data on raspberry pi 3

Postby zlite » Mon Nov 19, 2018 9:54 pm

I'm seeing the same problem since the most recent firmware update, and I think it has something to do with the USB interface in the Marvelmind beacons.

When you plug them into the RaspberryPi, they should show up in /dev as ttyACM0, like other devices, but they don't. I've asked the Marvelmind team to diagnose.

See these examples.

The first is another USB device (in this case and Arduino), which does cause ttyACM0 to be created in /dev.

The second is a Marvelmind, which does not properly instatiate and no ttyACM0 is created.

zlite
Posts: 16
Joined: Fri Feb 16, 2018 8:04 am

Re: Marvelmind python does not get location data on raspberry pi 3

Postby zlite » Mon Nov 19, 2018 11:29 pm

BTW, as a work-around until they fix this, you can use the Marvemind UART pins and an Adafruit serial-to-USB adapter, which will show up at ttyUSB0 and works fine.

https://www.adafruit.com/product/954
Attachments
Screenshot 2018-11-19 at 12.29.19 PM.png

zlite
Posts: 16
Joined: Fri Feb 16, 2018 8:04 am

Re: Marvelmind python does not get location data on raspberry pi 3

Postby zlite » Thu Nov 22, 2018 8:21 pm

Update. I finally got it working (at least for now), with some help from the Marvelmind team. It turns out that if you have the "power save function" enabled in the modem, it can disable the USB in the hedgehog.

So disable it and see if that fixes the problem
Attachments
Annotation 2018-11-22 092226.jpg


Return to “FAQ”

Who is online

Users browsing this forum: No registered users and 5 guests