BrickPi + Java in 2019 - is ev3dev my best bet?

I was very excited to get my brickpi running! So I installed Raspbian for Robots based off this chart with the hopes of then installing via the ev3dev-java installer script.

But that didn’t work at all. And now I’m bouncing over to ev3dev-stretch-rpi2-generic-2019-03-03.img. Am I missing out on cool things that Raspbian for Robots gives me? Can I install the RforR features on top of the ev3dev base layer? Are these two alternate and orthogonal systems, or am I misunderstanding the relationship?

I’m seeing if I bought the right kit. I have a BrickPi3, and a Raspberry PI 3B+ - “the latest of everything.”

I’d like to code in Java. (Well, Kotlin, but if it runs Java it can run Kotlin)
I’ve been trying to get ev3dev installed, because it provides nice sysfs files for all the sensors and motors, and supports Java. However, I’m not sure this is the correct path - it won’t even boot.

What is the easiest way to for a rpi3b+ to

  1. run Java
  2. have some sort of easy access to standard EV3 Sensors and Motors
  3. enable what the rpi provides (like WiFi and bluetooth)

Is it the BrickPi3? (hopefully yes because I already own it!)
And if yes, which OS? Thanks!

Not sure if you’re still wanting to do this a few months on, but for what it’s worth, I recently bought a used BrickPi+ and below is what I did to get it running on a RPi3B. You mention easy access to motors and sensors in Java; I’m a fan of LeJOS which provides that and more. Although I’m not sure if/how that works with Kotlin.

  1. Download ev3-stretch for RPi 2/3 from the downloads section on the ev3dev website (I would have linked to it but am restricted to including max two links per post as a new user here)- I ended up with version 2019-03-03

  2. Unzipped and burned image file to SD Card (i’m on Win10 and use Win32diskimager)

  3. Use a text editor on the PC to edit config.txt. In my case for the BrickPi+. The instructions are commented within to do the same for the BrickPi3

  4. Eject the SD card and insert in the Pi (with the BrickPi hardware already installed of course)

  5. Fire up the Pi with a fixed ethernet connection, SSH to it with Putty to confirm you now have a working Pi.

  6. Optional but recommended, use connmanctl to give it a fixed IP address, I use, (don’t forget to set a nameserver) I also turned off IPV6 because of some name resolution problems

  7. On my PC I then installed a fresh version of Eclipse for Java Developers Version: 2019-06 (4.12.0)

  8. Download the ev3dev-lang-java template project gradle - to the PC, unzip it

  9. Import the gradle project into Eclipse

  10. Edit config.gradle with the ip address of the Pi

  11. If you’re on a windows PC also make these changes (For background, I logged an issue for this, no. 671 on the ev3dev-lang-java/ev3dev-lang-java GitHub page, again constrained to only two links sorry.)

  12. Now run some gradle tasks to test we can talk to the Pi, I did


here is my output

Image file:         ev3dev-stretch-rpi2-generic-2019-03-03
Kernel version:     4.14.94-ev3dev-2.3.2-rpi2
Brickman:           0.10.0
BogoMIPS:           38.40
Board:              board0
BOARD_INFO_MODEL=Raspberry Pi 3 Model B Rev 1.2
Board:              board1
BOARD_INFO_MODEL=Dexter Industries BrickPi
  1. Now install Java etc. to the brick using gradle tasks, I ran
	uploadGradleLibraries (if you want to use LeJOS)
  1. Verified the install with gradle task javaVersion, output as follows:
openjdk version "11.0.4" 2019-07-16
OpenJDK Runtime Environment (build 11.0.4+11-post-Debian-1bpo91)
OpenJDK Server VM (build 11.0.4+11-post-Debian-1bpo91, mixed mode, sharing)

BrickPi should now be in a state to be programmed with Java and LeJOS

  1. Attach a large motor to port MA

  2. Overwrite mainclass parameter in config.gradle with

mainClass = "example.robotics.ev3.actuator.motor.BasicMotorOperationExample"

  1. Execute gradletask deployRun
    and that should get your motor running.
    Good luck and have fun.
1 Like

I got it working with a BrickPi3 and a Rpi3B (not-plus) - and everything worked great! The not-plus was the problem, I had to downgrade my rpi by swapping with a friend.
No idea re: the rpi4.

1 Like