Is there a scratch library for the BrickPi3 and Mindstorms motors and sensors?
Yes there is. The BrickPi3 supports the EV3 and NXT sensors and motors, in Scratch 1.4
The easiest way to get it is to put Raspbian for Robots on the SD card. Scratch will be available to you on the desktop.
Thanks for your help!
I think I needed to ask if there was complete code examples for the different mindstorm sensors. line follower, gyro, ultrasonic and IR sensor. I am using the BrickPi3.
Well, I can tell you this:
The support for Scratch on the BrickPi3 can be found here:
Examples for the BrickPi3 in Python are here:
And some of the projects that have been done in Python sit right here:
I’m thinking this will give you a couple of ideas of what you can do.
I’m not sure about the MindStorm sensors though.
We are limited in the examples for Scratch+BrickPi3,
You can find about 3 of them in the Examples folder within Scratch.
This image should tell you what you need to access a sensor:
There has to be someone that has scratch code for the all the different EV3 mindstorm sensors. I really need help with the EV3 gyro. Can Dexter Industries take some time and help with the code for each of the EV3 sensors. They have lots of examples for python and only three for scratch. I have searched the web and looked at the examples on my Brickpi3 with no luck.
I will try to get something this week.
I’m not entirely sure why we don’t have a full series of examples. We usually do. I can’t recall what was going on when the BrickPi3 was released. Hmmm.
If you bought the brickpi3 and you are new to scratch like I am there is no documentation to make these ev3/nxt sensors to work. Its very frustrating. Yes I see the sample code in scratch for robots but there is no complete code ideas for scratch. For
example all it shows for the EV3 gyro is the broadcast block code but nothing more. I can get scratch to say the the gyro output but after that I have no clue how to make it function in the code.
We’re pondering the idea of writing a documentation for the BrickPi3’s Python library just as we did for the GoPiGo3, the GrovePi and the DI_Sensors.
As for Scratch, we’ll only add more examples very soon and probably make the README more descriptive.
I really need help with the mindstorms gyro. I can get scratch to “say” the reading of the gyro but the gyro will not work.
Yep. I’ll take this into consideration.
I have a small gyro demo working now. You can use the gyro to control the position of the sprite in Scratch.
I wonder if you needed help with a specific aspect of the gyro?
I need it to work with the Brickpi3. When it is put on our two wheel robot it does nothing to correct the robot.
Could you share your code? I’ll take a look and see if I can help
ETA: just to make sure I understand everything properly, by a two wheel robot, you do mean something akin to our BalanceBot: https://www.dexterindustries.com/projects/brickpi3-balancebot-raspberry-pi-balancing-robot/
I will send you the code and robot type tonight after work.