Some handy Raspberry Pi stuff ;)
https://datasheets.raspberrypi.com/
Questionning the USB 'roles' & whre/how it connects:
- schematic for USB interface question: https://forums.raspberrypi.com/viewtopic.php?t=217858
- https://raspberrypi.stackexchange.com/questions/127415/are-schematics-available-for-the-newer-rpi-4-with-fixed-usb-c-power-circuit
| Model A and B (Original) | Model A+, B+ and B2 |
|---|---|
![]() |
![]() |
-
run
df -hto see the devices currently mounted
ex of output:Filesystem Size Used Avail Use% Mounted on # ( .. ) /dev/mmcblk0p1 32G 32K 32G 1% /media/stephaneag/F0E9-334E -
the device name 'll be the 'Filesystem' name minus the partition number
ex: for '/dev/mmcblk0p1' it'll be '/dev/mmcblk0', for '/dev/sdd1', '/dev/sdd' -
to only list the connected SD cards ( if they use the standard naming system ), run:
df -h | head -1; df -h | grep 'mmcblk\|sdd' | cat -
unmount any partition related to the SD card using
unmount /dev/<SC_card_filesys><partition>
ex, for the first partition of '/dev/mmcblk0p1':
'unmount /dev/mmcblk0p1' -
write the .img to the SD card using
dd bs=4M if=<img> of=/dev/<SC_card_filesys>
ex, for a Raspbian release:
dd bs=4M if=2015-09-24-raspbian-jessie.img of=/dev/mmcblk0 -
to see some progress about the operation, as
dddoesn't giv any, we can use the following:- to get an update on the progress:
sudo pkill -USR1 -n -x dd - to get updates on the progress:
watch -n5 'sudo kill -USR1 $(pgrep ^dd)' - other ways to do so (
pv,dcfldd): Ask Ubuntu - monitor the progress of dd
- to get an update on the progress:
Nb: this should also work for ANY linux system ;)
-
plug the SD card containing the RPi system on a laptop, & open the
/etc/shadowfile for editing -
in it, find the line that has the following syntax and correct username: '
<username>:<hashed_password>:::'
ex of what the line should look like:
'pi:$6$3YkhpIdG$y4C5gTMdnVnhMND9Pe.MFRi3Gi.. ..zTz52bnG1XOcXuhNOpk85xQJfQ.:15710:0:99999:7:::' -
replace it with either:
- another
<username>:<hashed_password>:::line - an empty password for the same user, using
<username>::::, ex:pi::::
- another
-
on the next boot of the RPi, no password 'll be asked ( if we set an empty password ) !
we could also set a new password if we left it empty, usingpasswd <username>as in the following:passwd pi <new_password> <new_password_again>


