A PolyOculus node is one Jetson Nano (2019 dev kit, p3450 B01, 4 GB) driving one telescope: an iOptron CEM70 mount over USB-serial, a DMK 33UX273 guide camera over USB3, and a piezo fast steering mirror (FSM) controller over USB-serial. Everything on the Nano comes from this repo, and every Nano is configured the same way; only its name differs.
laptop SD card Nano, first boot
------ ------- ----------------
os/build-kernel.sh --------> /boot/Image-nano, dtb, modules
os/flash-card.sh --------> Arch Linux ARM rootfs
/boot/extlinux/extlinux.conf
/home/alarm/polyoculus-node (repo)
nano-firstboot.service -----------> wait for network + clock
polyoculus-identity.service pacman keys, full update
ansible-playbook site.yml
(local run), reboot
laptop, later
-------------
ansible-playbook site.yml ---- SSH to <name>.local -------------> same playbook, pushes repo
os/build-kernel.shdownloads the prebuilt Nano kernel from this repo's GitHub releases (or compiles it). See kernel.md for why Arch's stock kernel can't be used.os/flash-card.shreformats the card's first partition, unpacks Arch Linux ARM, installs the kernel, writes the boot config, copies this repo onto the card, and installs two services. See new-node.md.- First boot (
os/firstboot.sh, run once bynano-firstboot.service): waits for internet and NTP, initializes pacman, installs Ansible, and appliesansible/site.ymlto the Nano itself. It retries every minute until it succeeds, then disables itself and reboots. - From then on, changes go out from a laptop:
ansible-playbook site.ymlover SSH to every Nano at once. See operations.md.
- U-Boot in the Nano module's QSPI flash (installed by NVIDIA's JetPack; the board must have
run JetPack 4.5+ once) reads
/boot/extlinux/extlinux.conffrom the card's first partition. - It loads
/boot/Image-nano(mainline Linux 7.1, our build) and the device treetegra210-p3450-0000.dtb. There is no initramfs: everything needed to reach the SD card is built into the kernel. - systemd starts.
polyoculus-identity.serviceruns before networking and sets the hostname (below). Then networking (systemd-networkd, DHCP on Ethernet), name resolution and mDNS (systemd-resolved), time (chrony), SSH, and the node services.
| Service | What it does | Set up by |
|---|---|---|
polyoculus-identity |
names the Nano at every boot from ansible/nodes.txt |
flash-card.sh, base role |
nano-firstboot |
first boot only: applies site.yml locally, then disables itself | flash-card.sh |
systemd-networkd |
DHCP on Ethernet (en*/eth*), mDNS on |
Arch default + base role |
systemd-resolved |
DNS, and answers/resolves <name>.local (mDNS) |
Arch default + base role |
chronyd |
time from the internet pool and from the other Nanos | base role |
sshd |
key-only SSH as alarm |
Arch default + base role |
indiserver |
INDI server + iOptron driver on port 7624 | indi role |
| systemd watchdog | reboots a hung Nano (PMIC watchdog, 30 s) | hardware role |
| journald | logs in RAM only (volatile), to spare the card |
sd-wear role |
| zram | compressed swap in RAM, no card writes | base role |
The node software (camera/, mount/, guide/) lives in /home/alarm/polyoculus-node, with
its Python environments already built by the software role. Nothing runs it automatically yet:
observing is started by hand (see observing.md).
Cards are interchangeable, so a Nano's name comes from the hardware it's attached to, decided at
every boot by os/identity.sh from ansible/nodes.txt:
- the node listing this Nano's guide camera serial (the camera stays with its telescope),
- else the node listing one of this board's MAC addresses,
- else the name the card was flashed with (
flash-card.sh /dev/sdX nano-03), - else
nano-<last 4 hex digits of the MAC>.
The login screen shows the camera serial and MAC, so pinning a telescope to a name is: read the
screen, add the serial to that node's line in nodes.txt, commit, and run site.yml (which
pushes the new table to every Nano). nodes.txt is also Ansible's inventory (inventory.py).
- Finding Nanos: every Nano answers to
<name>.localover mDNS on the local network. No IP addresses are recorded anywhere. Tailscale support exists in the repo but is off (the group decided against it); see operations.md. - Time: the Nano has no clock battery and boots with a wrong clock. chrony steps it as soon as it reaches a server. Every Nano lists the internet pool and every other Nano; with no internet, chrony's orphan mode elects one Nano and the rest follow it, so the fleet still agrees with itself (what synchronized observing needs).
- Access: no passwords.
alarmlogs in at the console with an empty password; SSH accepts only the keys inansible/files/authorized_keys/(exactly those: deleting a key file revokes it); root is locked; sudo needs no password.
/dev/mount,/dev/fsm: udev symlinks for the two USB-serial adapters, chosen by which USB port they're plugged into (usb_portsinansible/group_vars/nanos.yml), the same on every Nano.guide.pyandfsm.pydefault to them when they exist.- Guide camera: found by its name (
DMK 33UX273) in any USB3 port; no rule needed.
SD cards are the weakest part. The setup limits writes (logs in RAM, noatime, zram swap) and
assumes any card can die: a Nano is rebuilt by flashing a new card (~2 min) and letting first
boot run (~15-20 min). So nothing may live only on a card: observation data and calibration
files have to be copied off (operations.md).