EV3 sensors and BrickPi


#1

Hi,

I’m trying to get the Lego EV3 ultrasonic sensor to communicate with the Brickpi.
The EV3 firmware script gives the following output :

Trying to communicate with firmware.
PASS: Serial line setup.

Setup sensors returns: 0
Checking Firmware Version of BrickPi.
Firmware version is: 2
GREAT! Firmware is up to date!
You should be able to run EV3 sensors!

EV3 sensor return strange values, however.
I’m disappointed, since I find posts that suggest using EV3 sensors should be possible, next to posts that state that this is not possible.
This is all very confusing, and I would recommend that Dexter make this explicit in the store which sensor and motor types are supported for which Board.

For now, any help in getting the sensor to work is highly appreciated.

Richard.


#2

Hi Richard,

It looks like you have the latest version of the firmware, and it should be working fine. Have you used the EV3 sensor examples to test them? Which posts are stating that it’s not possible to use the EV3 sensors?

If you look at this repository: https://github.com/DexterInd/BrickPi_Python/tree/master/Sensor_Examples we have a ton of EV3 sensors supported (all of them).

Can you help me understand what’s not working better?

John


#3

Hi,

Well, the values coming back from the EV3 ultrasone sensor did not seem to make any sense. With an output in cm, you wo’nt expect values like 401 when your hand is approx 20 cm before the sensor.

But then things got worse. I ran the hardware test script (BrickPi_Hardware_Test.py) but I killed that process.
Then nothing worked at all, not even the test programs.
I rechecked the firmware :

pi@dex ~/Desktop/BrickPi_Python/Sensor_Examples $ python EV3-Firmware_Check.py
Trying to communicate with firmware.
PASS: Serial line setup.

Setup sensors returns: -1
Checking Firmware Version of BrickPi.
Firmware version is: None
DOH! Please update your firmware to run EV3 sensors!
You should be able to run NXT sensors, but not EV3 sensors.

Tutorials on how to flash firmware do not make sense to me.
How can I fix this ?

Richard.


#4

Never mind : I shutdown the RPi, removed all power sources for a while, and restarted the RPi + BrickPi.
Firmware check shows :

pi@dex ~/Desktop/BrickPi_Python/Sensor_Examples $ python EV3-Firmware_Check.py
Trying to communicate with firmware.
PASS: Serial line setup.

Setup sensors returns: 0
Checking Firmware Version of BrickPi.
Firmware version is: 2
GREAT! Firmware is up to date!
You should be able to run EV3 sensors!


#5

So now back to the EV3 sensor and motor test python scripts.

I rotate the motor for 90 degrees, yet occasionally the Bricpi misses a command and does not stop and consequently overrotates.
For EV3 ultrasonic sensor, see previous post. The EV3 sensor is working very accurately when plugged into an EV3 intelligent brick, though.

I suspect troubles in the communications, but this is hard to pinpoint.

Although I think the Brickpi is an interesting setup, it is hard for beginners like me (and my 11 year old son…)

Richard.