https://github.com/voidcontext/nixos-uconsole
Mirror of https://git.vdx.hu/voidcontext/nixos-uconsole
https://github.com/voidcontext/nixos-uconsole
cm4 nixos uconsole
Last synced: 4 months ago
JSON representation
Mirror of https://git.vdx.hu/voidcontext/nixos-uconsole
- Host: GitHub
- URL: https://github.com/voidcontext/nixos-uconsole
- Owner: voidcontext
- Created: 2024-04-03T21:20:58.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-04-13T10:49:55.000Z (about 2 years ago)
- Last Synced: 2024-04-14T00:45:59.125Z (about 2 years ago)
- Topics: cm4, nixos, uconsole
- Language: Nix
- Homepage:
- Size: 55.7 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# nixos-uconsole
NixOS module and base SD card image for clockworkPi uConsole.
## Status
For now, only devices using RaspberryPi Compute Module 4 are supported.
Many things just doesn't work at the moment, the sd image boots, but it can only be confirmed using
the HDMI output, and it's impossible to log in since the keyboard doesn't work.
| | Does it work? |
|------------------ | ------------- |
| boot | ✓ |
| built-in display | ✓ |
| backlight | ✓ |
| hdmi output | ✓ |
| built-in keyboard | ✓ |
| usb keyboard | ? |
| bluetooth | x |
| wifi | ✓ |
| audio | x |
| fast charging | ✓ |
## Usage
### NixOS module
```nix
```
### SD card image
Build one of the sd-image packages, e.g:
```
nix build .\#packages.aarch64-linux.\"sd-image-cm4-6.1-potatomania\" -L
```
Then flash the img file from `result/sd-image`. For more information see [Development](#development)
section.
## Development
The kernels are available in 2 versions:
as normal `aarch64-linux` build, e.g:
```bash
nix build .\#packages.aarch64-linux.\"sd-image-cm4-6.1-potatomania\" -L
```
and with a config where the kernel is cross built on `x86_64-linux`, e.g:
```bash
nix build .\#packages.aarch64-linux.\"sd-image-cm4-6.1-potatomania-cross-build\" -L
```
For cross building you'll need 2 machines: an `x86_64-linux` and an `aarch64-linux` build machine.
This is useful when you want to offload the kernel compilation to a potentially stronger computer
using cross compilation.
Once the image is flashed into an SD card the `/boot/config.txt` needs to be updated and copied over
from the relevant kernel's directory.
The available images, and NixOS modules are all discoverable using `nix flake show`.
## Sources
- Kernel patches from : https://github.com/PotatoMania/uconsole-cm3
- Kernel config changes: https://jhewitt.net/uconsole