Skip to content

Commit

Permalink
book.toml / corrections
Browse files Browse the repository at this point in the history
  • Loading branch information
kaplan2539 committed Feb 11, 2024
1 parent 2718649 commit e327b5d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
6 changes: 6 additions & 0 deletions book/book.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ authors = ["Alexander Kaplan"]
language = "en"
multilingual = false
src = "src"
default-theme = "dark"
preferred-dark-theme = "Ayu"
git-repository-url = "https://github.com/kaplan2539/cindy"
edit-url-template = "https://github.com/kaplan2539/cindy/edit/<branch>/{path}"
side-url = "https://d.eadc0.de/cindy"
cname = "d.eadc0.de"

[build]
build-dir = "output"
18 changes: 13 additions & 5 deletions book/src/warmup.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Warmup: Boot the latest Linux LTS

In this warmup exercise were going to show that C.H.I.P is not dead: We are
booting into the latest Linux LTS release (6.1.63 at the time of writing).
In this warm-up exercise were going to show that C.H.I.P is not dead: We are
booting into the latest Linux LTS release (6.1.62 at the time of writing).

## Hardware

Expand Down Expand Up @@ -80,7 +80,11 @@ Some explanation: We're calling `make` and set the target architecture to `arm`
and select the `arm-linux-gnueabihf-` toolchain we installed before.

That wasn't too bad, so now let's try to boot CHIP.
First open a new terminal window in which we're going to run `cu`:
First, connect the `TX` wire of your USB serial adapter to CHIP's `RX` pin and
the `RX` wir of your USB serial adapter to CHIP's `TX` pin.
Also connect a `GND` pin of your USB serial adapter to one of CHIP's `GND`
pins.
Then, open a new terminal window in which we're going to run `cu`:
```shell
cu -l /dev/ttyUSB0 -s 115200
```
Expand Down Expand Up @@ -225,6 +229,9 @@ Exciting times! We've just ran the latest Linux LTS (for one second or so)!

## Busybox Rootfs

The above attempt to boot into Linux failed because we did not have a root
filesystem (rootfs). Let's build one using Busybox!

Download Busybox
```
wget -c -P downlad https://busybox.net/downloads/busybox-1.36.1.tar.bz2
Expand All @@ -241,7 +248,7 @@ mkdir ../rootfs
ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make CONFIG_PREFIX=./../rootfs install
```

Finalize initramfs
Finalize initramfs:
```
cat > rootfs/init << EOF
#!/bin/sh
Expand All @@ -263,7 +270,8 @@ fakeroot -- /bin/bash -c '\
u-boot-v2023.10/tools/mkimage -A arm -O linux -T ramdisk -C gzip -d rootfs.cpio.gz rootfs.cpio.gz.uboot
```

Now that we have rootfs we can download it to CHIP's RAM and boot into it:
Now that we have a root file system we can download it to CHIP's RAM and boot
into it:

```shell
sunxi-fel -v uboot u-boot-v2023.10/u-boot-sunxi-with-spl.bin \
Expand Down

0 comments on commit e327b5d

Please sign in to comment.