Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/heeplr/linuxcncpi
bake linuxcnc raspberry pi image
https://github.com/heeplr/linuxcncpi
linuxcnc raspberry-pi raspberry-pi-4
Last synced: 20 days ago
JSON representation
bake linuxcnc raspberry pi image
- Host: GitHub
- URL: https://github.com/heeplr/linuxcncpi
- Owner: heeplr
- License: mit
- Created: 2023-09-01T13:09:17.000Z (about 1 year ago)
- Default Branch: rpi4
- Last Pushed: 2023-12-28T13:48:51.000Z (11 months ago)
- Last Synced: 2024-10-16T20:47:38.940Z (about 1 month ago)
- Topics: linuxcnc, raspberry-pi, raspberry-pi-4
- Language: Shell
- Homepage:
- Size: 103 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# LinuxCNC on raspberry pi 4
* raspbian lite
* RT_PREEMPT patches
* cross-compile raspberry kernel
* setup lightwm + xfce
* compile linuxcnc on first login of "pi" user## Prerequisites
* aarch64-unknown-linux-gnueabi-gcc cross compiler
* wget
* git
* POSIX system## Usage
```
$ git clone --recursive https://github.com/heeplr/linuxcncpi
$ cd linuxcncpi
$ ./bootstrap.sh
```
bootstrap.sh will ask for sudo password to mount loopback device & manipulating mounted root partition of image.
After image is generated, you will see a message like:```
Image creation successful. Copy "..." to an SD card.(e.g. dd if=.bootstrap-work/raspbian-lite.img of=/dev/sdcard bs=64M status=progress)
```
Replace /dev/sdcard with your sdcard device. Let's assume it's /dev/sdc. Run:```$ dd if=.bootstrap-work/raspbian-lite.img of=/dev/sdc bs=64M status=progress```
after image is written, safely eject the card. e.g.
```$ eject /dev/sdc``` or ```$ sync```
Boot raspberry pi from card and log in as "pi" user. After bootstrapping finished, reboot.
## Customize
### authorize your SSH pubkey for pi user
Add to ~/.bootstrap.cfg:
```
RPI_BOOTSTRAP_PLUGINS+=( "ssh" )
# authorized ssh pubkeys
RPI_SSH_AUTHORIZE=(
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAA... user1@host"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAA... user2@host"
)
RPI_SSH_KEYGEN="true"
```### set wifi config
Add to ~/.bootstrap.cfg:
```
RPI_BOOTSTRAP_PLUGINS+=( "wifi" )
RPI_WIFI_SSID="wifiname"
RPI_WIFI_PSK="wifipassword"
```### apt install/remove packages
Add to ~/.bootstrap.cfg:
```
RPI_BOOTSTRAP_PLUGINS+=( "apt" )
RPI_APT_CMDS+=(
"autoremove avahi-daemon bluez cryptsetup-run cryptsetup-initramfs cryptsetup-bin cryptsetup nfs-common ntfs-3g rfkill"
"install tmux"
)```
### copy files to image
To copy file "issue" to "/etc/issue" on the image, place "issue" into "~/.bootstrap-dist/etc/issue".
Add to ~/.bootstrap.cfg:```
RPI_BOOTSTRAP_PLUGINS+=( "dist" )
RPI_DIST_COPY_ON_BAKE+=(
"/etc/issue"
)
```