Greetings. I just purchased a Brickpi. I have a rapsbery pi3+. I am used to linux, been using it since 98. I am building this so my son can learn to program lego nxt using scratch. While we have the old lego sotware, I want him to learn the computer part with python. I have read the githubs, I have tried compiling the updates on multiple legacy OS. For some reason the SD image from soureceforge is not booting into a desktop nor is it booting. I used multiple different ways to burn it, including DD, etcher, etc. Now its 2024, what is the best OS to use (given that there are issues with python wxgtk3.0 libraries that break things, etc. I just wanted to do something simple. Install the OS, have scratch, and program the motors and sensors. I know I can use regular python, I see some dependencies on python2.x here.
Any hints on modernizing this for use would be great.
Legacy Pi OS 32-bit. Is the recommended OS to use with the BrickPi install/update script.
That may be a problem. The install/update script does not install Scratch to my knowledge.
Raspbian For Robots, as recommended on the BrickPi page is now 5 years old. I have a Pi3B GoPiGo3 robot that is running R4Robots but I stopped updating it, because too many things were breaking. I don’t know why it is not installing.
Here are my install notes - don’t know if that will result in a working system or not. I would not run the update/upgrade step until you have a working system and a backup of the working system.
*** Download Raspian For Robots (2020_10_17 version is not available any more)
https://sourceforge.net/projects/dexter-raspbian-for-robots/files/2019_12_12_Raspbian_For_Robots_Buster_experimental_by_Dexter_Industries.zip/download
*** Current Instructions
https://www.dexterindustries.com/howto/install-raspbian-for-robots-image-on-an-sd-card/
*** Flash SD card with Raspberry Pi Imager / Etcher
Select the Raspian For Robots zip file
Select the 16GB SD Card
Flash
=== Mount the card to allow headless configuration
- Pull card out, reinsert for next steps
=== Enable SSH
- create a file called "ssh" (or ssh.txt) in the Boot partition
(touch /boot/ssh)
=== Setup WiFi Headless
- create the file /boot/wpa_supplicant.conf
(quote chars must be straight up/down, traditional, not slanted/matched Unicode chars
use ssid="XXXX"
country=US
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
ssid="XXXX"
psk="XXXX"
key_mgmt=WPA-PSK
}
=== disable ipv6
Browse the disk (boot)
Rt Click on System Volume Information->Open Terminal Here
cd ..
cp /boot/cmdline.txt /boot/cmdline.txt.bak
nano cmdline.txt
add to end of line/file:
ipv6.disable=1
save, exit editor
- eject disk
==== Raspbian First Boot
-insert micro SD card
-power on
- on mac: arp -a to check IP
=== First Login
ssh pi@10.0.0.XX
The default login for Raspbian For Robots is username pi with the password robots1234
=== is see SSH HOST KEY verification failed
on mac: ssh-keygen -R 10.0.0.XX
Login: username: pi password: robots1234
=== Configure for locale, timezone, and expand filesystem to fill card
$ sudo raspi-config
(You can exit menus by using Tab key, move to Finish, enter key)
change password to XXXXX
Network Options: change hostname to XXXX
change Localisation:Locale -> remove en_GB, add en_US.UTF8
default local: en_US.UTF-8
change Localisation:Timezone-> US->Eastern
change Localisation:WiFi Country->US
Interfacing:PiCamera enable
reboot now yes
=== LOG IN Again
pi:XXXXXX
=== Change TightVNC password ====
at a terminal:
vncpasswd
<new password>
<new password>
n (do not set up a view only "no password" login)
=== update now
sudo apt-get update
sudo apt-get full-upgrade
==== Check TEMPERATURE
To view the Pi's temperature
vcgencmd measure_temp
It's generally a good idea to keep the core temperature below 70 degrees
=== info about processor, memory, disk partitions ===
cat /proc/cpuinfo
cat /proc/meminfo
cat /proc/partitions
cat /proc/version
Stretch kernal: Linux version 4.9.41-v7+
free -h displays memory usage
total used free shared buff/cache available
Mem: 875M 69M 540M 11M 266M 745M
Swap: 99M 0B 99M
=== check memory usage program
htop
q to exit
Record the ipV4 addresses:
wired:
wifi:
GoPiGo3 : 10.0.0.XXX
=====GETTING WIFI NETWORK DETAILS
To scan for WiFi networks, use the command
iwlist scan | less
=== check time zone
$ date to check if correct time
========= SSH from mac to Pi =====
(SSH enabled in raspi-config)
ssh -l pi 10.0.0.xxx (wireless)
or
ssh pi@10.0.0.xxx
password: robots1234 (changed to XXXX)
===== rebooting ====
sudo shutdown -r now (or sudo reboot)
(if doesn’t come back up try
sudo shutdown -t9 -r now
or (sync;sync;sudo reboot -d -f -i)
==== check disk file systems =====
df -h
Filesystem Size Used Avail Use% Mounted on
/dev/root 15G 4.2G 9.9G 30% /
devtmpfs 434M 0 434M 0% /dev
tmpfs 438M 0 438M 0% /dev/shm
tmpfs 438M 12M 427M 3% /run
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 438M 0 438M 0% /sys/fs/cgroup
/dev/mmcblk0p1 42M 21M 21M 51% /boot
tmpfs 88M 0 88M 0% /run/user/1000
==== disk space of a directory:
$ du -hD
=== install disk monitor tool
sudo apt-get install dstat
dstat -cd --disk-util --disk-tps
sudo apt-get install iotop
sudo iotop -o
?? === install atop (may waste CPU cycles if not needed )
sudo apt-get install atop
atop 5 (every 5 seconds)
sudo apt-get install iostat ?? may be already installed ??
sudo iostat -d 5
glances --enable-process-extended
===== update and upgrade ===
$ sudo apt-get update
or
sudo apt-get sudo apt-get -o Acquire::ForceIPv4=true upgrade
$ sudo apt-get upgrade
===== Fix pip ?
$sudo pip install --upgrade requests
===== test internet speed ====
$ sudo pip install speedtest-cli
$ speedtest
Speedtest Result
2018Aug22: 81.1 Mbps Download, 10.5Mbps Up 36ms ping
2016Apr29: 29.5 Mbps Download, 11.0Mbps Up 38ms ping
2015Jan25: 19.3 Mbps Download, 5.5 Mbps Up 40ms ping
===== describe hardware =====
sudo apt-get install lshw
sudo lshw
=== check memory ===
sudo lshw
...
*-memory
description: System memory
physical id: 4
size: 862MiB
or
$ free -h
total used free shared buffers cached
Mem: 862M 232M 630M 5.9M 14M 177M
Swap: 99M 0B 99M
====== Testing Disk speed =====
sudo hdparm -t /dev/mmcblk0 (sudo apt-get install hdparm)
reports
Pi3: 62 MB in 3.06s = 20.27 MB/sec
pi B+: 54 MB in 3s = 17.7 MB/s
======= check OS version ======
cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
==== check Pi firmware version
vcgencmd version
uname -a
==== SHUTTING DOWN Pi ======
sudo poweroff ( or shutdown -h now )
Safe to remove power when green light blinks a bunch (12 times) and then stops blinking
Then, if you want, download legacy Buster, 32 bit, and try installing the Brick Pi libraries and the sensor libraries if you’re going to use Dexter sensors with it.
A “just out of curiosity” question:
What do you plan to do with the Brick Pi?
The recommended version of Raspbian For Robots that I suggested is based on RaspbianStretch, and as a consequence it is NOT compatible with the Pi-4.
If you ever decide to migrate your Brick Pi to a Pi-4, you will need to download Raspberry Pi O/S Buster and install the libraries manually or install them over the Buster version of Raspbian For Robots.
Note that:
The Buster version of Raspbian For Robots was specifically designed for the GoPiGo-3 robot and specifically excluded support for other Dexter Industries devices.
I strongly suspect that you can manually install the Brick Pi libraries on that version and I also suspect that it will work. However, nobody here has a Brick Pi, and that configuration hasn’t been tested as far as I know.
If you DO install the Brick Pi libraries on that version, and it works, please let us know!
Also note:
None of this has ever been tried with Raspberry Pi O/S Bullseye or Bookworm.
Bullseye might, just might, maybe, work with the Brick Pi libraries. (Assuming a lot of both prayer and luck.) You are welcome to try if you wish, but you will be in uncharted territory if you do.
It is very unlikely, (make that read "99.9999999% unlikely), to work with Bookworm absent significant amounts of effort and significant changes to the Brick Pi libraries.
Let us know what happens with your Brick.
P.S.
You are more than welcome to join us and provide your expertise with the Brick Pi, which is sadly lacking here.
You can use R4R Buster if you have a Brick Pi-3 instead of an earlier version. Since we don’t know what version of the Brick Pi you have and since you’re using a Pi-3, I recommended the most generic version, (Stretch).
All versions of R4R include Scratch because it is pre-installed with the base Raspberry Pi software. As I remember Scratch doesn’t support the robot, (or it is implemented so clumsily due to the way Scratch is designed), as to be essentially useless. (I could be mistaken as I haven’t used R4R in years, but that’s what I remember.)
If you want to use a Scratch-like programming environment, Dexter has a special version of Google’s Blockly language called “Bloxter” that is specifically designed for the robots. (Though you can do other things too.) This is only available for the Brick Pi if you use the Dexter OS.
Dexter OS is specifically designed for a classroom environment and is “locked down” so that students cannot inadvertently damage the operating system and is specifically designed to be used with a web browser set to 10.10.10.10. (It broadcasts it’s own access point that you connect to before you use it.)
If, (somehow or other), the system goes all pear-shaped, all you have to do is reboot and everything is working normally again.
My own personal recommendation, unless you have a particular and special reason for using the Brick Pi, (wanting to use the Lego Mindstorms world of accessories, for example), is that you get a GoPiGo robot, as it is the most flexible and accessable device in the Dexter family, and your son won’t outgrow it.
Your son can use a simple block-based language to start with, and then migrate to more advanced languages and projects as his skills improve.
Likewise the GoPiGo can be easily extended with additional accessories, (like a pan-and-tilt for a camera or distance sensor). Literally the possible configurations are only limited by your imagination, (and wallet!)