全天相机 · 使用说明AllSky Camera · User Manual

版本与功能以设备当前固件为准 · 返回相机页面Features follow the device's current firmware · Back to the camera

1 快速上手

  1. 设备上电, 等约 1 分钟(热点启动需要时间)。
  2. 手机或电脑连 WiFi 热点 AllSky-Pico, 密码 allsky123。
  3. 浏览器打开 http://192.168.5.1 —— 看到大图与状态栏即成功。

相机默认每 60 秒拍一张, 第一张图要等一个拍摄间隔才出现。

2 界面总览

两种访问方式

访问方式看到的界面权限
连热点 AllSky-Pico管理面: 全部功能 + 设备管理区免口令, 可改一切设置
局域网 / 公网同一个页面, 少"参数区""设备管理"建任务/删除/拍摄记录要管理口令; 参数区不开放

管理口令

3 日常使用

实时预览

大图约 0.8 帧/秒, 是省资源设计, 不影响正式拍摄; 正式帧是全尺寸高质量, 按"拍摄间隔"出图。

状态字段

字段含义
当前曝光正在用的曝光时间(µs)
存储滚动存储用量
上传队列待上传到服务器的帧数

两种模式

模式行为何时用
全天相机按间隔定时拍摄, 自动曝光, 自动流星检测日常观测
拍摄模式手动曝光/增益, 全幅 964×545 预览约 1.5–2 秒刷新; 设备端与公网页都可进入对焦、单张、间隔与长曝光; 调完点"返回全天"

参数区逐项

参数约束说明
站点名≤60 字烧录在图像左上角
拍摄间隔(秒)≥10默认 60。两张正式帧之间的时间
检测灵敏度(kσ)≥2, 默认 5.0调小更灵敏(误报增多), 调大更保守
固定曝光(µs)空 = 自动填了就不再自动曝光
固定增益(dB)空 = 自动填了就不再自动增益
开启上传开关把帧与事件推送到服务器(第 5 章)
开启检测开关流星检测总开关

拍摄任务

任务 = 在指定时间段按固定参数拍指定张数(如流星雨观测), 创建后列表里可见进度。

字段约束默认
任务名≤40 字—
开始 / 结束可留空: 空开始 = 立即; 空结束 = 拍完为止现在 ~ 1 小时后
间隔(秒)≥1, 且 ≥ 曝光(秒)+110
曝光(µs)1000 ~ 300000005000000(5 秒)
增益(dB)0 ~ 3020
张数1 ~ 2000100

事件列表

事件由连续帧比对产生(流星等线状亮斑), 按时间倒序展示, 每条带置信度; 大图与分级(显著/标准/微弱)在"历史图库 → 事件"。白天(曝光短于 100ms)不检测。

4 拍摄模式

页面顶部的"拍摄模式"按钮在设备本地面(热点/局域网直连)与公网页都可用 (公网页经服务器控制通道透传, 需选中具体设备并输入管理口令)。进入后全天定时拍摄、 流星检测与上传暂停, 相机交给手动拍摄; 退出即恢复。

它与"日常使用 → 拍摄任务"是两回事: 拍摄任务仍属于全天相机(按任务参数拍, 存独立目录); 拍摄模式则完全接管相机, 走全天 CIF RAW + 软件解码(raw12_tool), 不启动 ISP, 适合接望远镜/镜头做对焦、单张与长曝光。

能做什么

功能说明
实时预览软件解码全幅预览 964×545(3856×2180 的 skip-4 采样, 视场与全天一致); 约 1.5 秒一帧, 无撕裂
拍照964×545 JPEG(与预览同尺寸, 全幅); 在历史图库的「拍摄」视图按日管理(也可在「全部」视图看到, 但不参与帧的批量删除)
曝光 / 增益 / HCG滑块调节, 预览与拍照的曝光上限 2 秒(更长请用长曝光 RAW); 读回值下一帧才生效, 状态栏每 2 秒刷新
间隔拍摄"开始到开始"间隔连拍; 张数 0 = 不限, 随时可停
长曝光 RAW3 ~ 900 秒, 可选 HCG; 存为 r_*.raw, 在历史图库「拍摄」视图下载
拍摄记录已并入历史图库「拍摄」视图: 按日折叠; 点缩略图看大图(RAW 大图现编 964×545); 可单条或按日删除; 设备端可下载

注意

6 公网接入

开了"公网接入", 任何地方打开服务器地址就能看到这台相机——同一个页面: 大图是最新上传帧, 历史图像与事件按日期浏览。设备离线时显示最后一张存档帧, 图库不受影响。

开通条件

留存策略(我的图去哪了)

位置策略
设备 · 全天帧滚动区 3.5GB, 满了删最旧 —— 大约只留最近 2 天(启用 SD 时这块配额在 SD 上)
设备 · 事件1GB(约 14 天), 满了删最旧(启用 SD 时在 SD 上)
设备 · 拍摄照片/RAW不自动回收(用户资产); 在历史图库「拍摄」视图手动单条/按日删除; 启用 SD 时存 SD
设备 · 内部旧库/var/allsky_internal, 首次启用 SD 时搬入; 只读保留、不自动删, 占用内部 rootfs
服务器 · 全天帧默认保留 7 天(可配, 见第 6 章)
服务器 · 事件永久保留

设备端滚动删除不是数据丢失: 长期留存在服务器, 事件永久保存。

7 自建服务器

服务器集中存档设备推上来的帧/事件/任务, 并 serve 同一个页面——任何地方打开服务器地址就能看; 多台设备接一台服务器, 页头有筛选条。没有服务器设备照常工作, 只是不能远程看、没有长期留存。

需要什么

安装(4 步)

源码仓库的获取方式见产品随附说明(或向供应商索取)。

  1. 建一个安装目录, 放入 4 个文件: server.py、dev_channel.py、 admin.py(取自 server/allsky_server/)、 gallery_render.py(取自 project/app/allsky_webui/backend/)。
  2. 把页面目录 project/app/allsky_webui/www/ 整个拷到安装目录下 (即 <安装目录>/www)。
  3. 装依赖: pip install aiohttp pillow
  4. 启动: cd <安装目录> && ALLSKY_WWW=<安装目录>/www python3 server.py —— 浏览器开 http://<服务器>:8084 能看到页面即成功。

长期运行(systemd)

把下面内容存为 /etc/systemd/system/allsky-server.service(崩溃自动拉起):

[Unit]
Description=AllSky server
After=network-online.target

[Service]
User=<运行用户>
WorkingDirectory=<安装目录>
Environment=ALLSKY_WWW=<安装目录>/www
# 公网部署必须取消下一行注释(只许 nginx 反代进来):
#Environment=ALLSKY_SRV_HOST=127.0.0.1
ExecStart=/usr/bin/python3 server.py
Restart=always
RestartSec=3

[Install]
WantedBy=multi-user.target

启用: sudo systemctl daemon-reload && sudo systemctl enable --now allsky-server; 日志: journalctl -u allsky-server。

环境变量(按需)

变量默认说明
ALLSKY_SRV_PORT8084监听端口
ALLSKY_SRV_DATA<安装目录>/data数据目录
ALLSKY_WWW仓库内 www 目录独立部署时指向你的 www/
ALLSKY_SRV_KEEP_DAYS7帧保留天数; 事件永久保留
ALLSKY_SRV_HOST0.0.0.0公网必须 127.0.0.1 并用 nginx 反代

公网反代(nginx + HTTPS)

nginx 在 443 终结 TLS → 反代到 127.0.0.1:8084。页面按根路径写死, 要用子域名 (如 allsky.example.com)直接指过来, 挂子路径会白屏:

server {
    listen 443 ssl;
    server_name allsky.example.com;
    ssl_certificate     /etc/letsencrypt/live/allsky.example.com/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/allsky.example.com/privkey.pem;

    client_max_body_size 50m;

    location / {
        proxy_pass http://127.0.0.1:8084;
        proxy_http_version 1.1;
        proxy_set_header Host $host;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
        # 设备长轮询一次挂 25 秒, 必须大于它
        proxy_read_timeout 40s;
    }
}

配对设备(3 步)

  1. 服务器上发密钥: cd <安装目录> && python3 admin.py new-device <设备ID> (设备 ID 在管理面「公网接入」区显示, 自动生成)。密钥只显示这一次; 丢了重跑换发。
  2. 连设备热点开 http://192.168.5.1, 在「设备管理 → 公网接入」填: 服务器地址 = https://<你的服务器>, 设备密钥 = 刚打印的那把, 勾选启用, 保存。
  3. 等 1~2 个拍摄间隔后开服务器地址: 设备在线、大图到来即成功(仍离线见第 9 章)。

多台设备: 各自 new-device 各自的 ID(每台一把密钥), 页头自动出现筛选条(上限 256 台)。

日常维护

安全三点

① 上传端点无鉴权(谁都能传帧, 只污染数据不给权限)——公网必须 nginx + HTTPS, 服务只监听 127.0.0.1。
② 设备密钥明文出现在服务日志与 nginx 日志里 —— 日志当机密对待。
③ 管理口令 ≠ 设备密钥: 口令在设备上设(管写操作), 密钥由服务器发(管上传/控制通道)。

8 现场管理

本章操作都在管理面: 连热点 AllSky-Pico → 开 http://192.168.5.1 → 页面底部"设备管理"区。

管理口令

公网/局域网写操作的钥匙, 至少 6 位; 初始 12345678(就显示在该区), 正式站点建议改掉。留空保存 = 关闭外网写控制。

热点(设备 AP)

改热点名称(≤32 字)与密码(≥8 位); 保存后热点立即重启, 用新名称/密码重连。

改完先确认新名称/密码能连上, 再离开现场。热点进不去就只能串口/重刷救回。

上行 WiFi(场地网络)

让设备接入场地 WiFi(密码 ≥8 位), 用于上传与公网访问; 保存后设备重连上行, 热点不受影响。 下方列出已记录的网络, 可逐条删除(删光 = 回到纯热点模式)。

公网接入(远程查看)

填服务器地址(自建见第 6 章; 公网须 HTTPS)、勾选启用、保存; 设备 ID 自动生成。 想切断公网: 取消启用并保存。详见第 5 章。

设备操作

"重启 webui 服务"只重启相机程序(页面短暂不可用); "重启设备"整机重启(约 1 分钟恢复)。 设备开机满 48 小时会在白天(10~15 时)自动重启一次防缓慢劣化; 想关掉可改配置文件 auto_reboot_hours(0 = 关闭)。

何时动哪里

9 自动升级(OTA)

设备每 6 小时自动检查升级: 有新版本自动下载、校验并切换, 失败自动回滚, 无需人工干预。

查看当前版本: 浏览器开 http://<设备地址>/api/ota/status(只读, 公网也可查)。 手动触发一次检查: POST /api/ota/run-now(热点直连免口令, 否则要管理口令)。

10 常见问题

白天为什么没有事件?

设计如此: 曝光短于 100ms 即判白天, 自动暂停检测(白天只会有误报), 天黑自动恢复。

夜间预览偏灰或偏亮?

预览只是参考图, 会做拉伸显示; 以正式帧(全尺寸高质量)为准。

连不上设备热点?

上电后等约 1 分钟再搜; 确认找的是 AllSky-Pico(改过名就找新名); 靠近设备再试。

忘记管理口令?

连热点开管理面(免口令), 在"设备管理 → 管理口令"直接重置。

升级后页面没变?

浏览器缓存了旧页面, 强制刷新: Ctrl+F5(Mac: Cmd+Shift+R)。

服务器页头显示设备"离线"?

先等 1~2 分钟(约一个拍摄间隔)再看。仍离线: 查上行 WiFi 是否断连("设备管理 → 上行 WiFi" 重连), 以及"公网接入"是否启用、地址是否填对。

1 Quick start

  1. Power on and wait about a minute (the hotspot takes time to come up).
  2. Join the WiFi hotspot AllSky-Pico, password allsky123.
  3. Open http://192.168.5.1 — seeing the live image and status bar means success.

The camera captures one frame every 60s by default; the first image arrives after one capture interval.

2 The interface

Two ways in

AccessWhat you seeRights
On hotspot AllSky-PicoAdmin plane: everything + Device ManagementNo token; all settings editable
LAN / publicThe same page, minus "Parameters" and "Device Management"Task create/delete and capture-record operations need the admin token; the parameter area is not offered

The admin token

3 Daily use

Live preview

The big image runs at ~0.8 fps by design (saves resources); real captures are full-size high quality at the capture interval.

Status fields

FieldMeaning
ExposureExposure time currently in use (µs)
StorageRolling storage usage
Upload queueFrames waiting to be uploaded to the server

The two modes

ModeBehaviorWhen
All-skyTimed captures, auto exposure, automatic meteor detectionDaily observing
Photo modeManual exposure/gain, full-frame 964×545 preview at ~1.5–2 s; device and public pageFocusing, single shots, interval and long exposures; tap "Exit photo mode" when done

Parameters, one by one

ParameterConstraintNotes
Site name≤60 charsBurned into the image top-left
Capture interval (s)≥10Default 60. Time between two stored frames
Detect sensitivity (kσ)≥2, default 5.0Lower = more sensitive (more false positives); higher = more conservative
Fixed exposure (µs)empty = autoOnce set, auto exposure is off
Fixed gain (dB)empty = autoOnce set, auto gain is off
Enable uploadtogglePush frames and events to the server (chapter 5)
Enable detectiontoggleMaster switch for meteor detection

Capture tasks

A task = shoot N frames with fixed parameters inside a time window (e.g. meteor-shower watch). Progress shows in the list right after creation.

FieldConstraintDefault
Task name≤40 chars—
Start / Endmay be empty: empty start = now; empty end = until donenow ~ +1h
Interval (s)≥1, and ≥ exposure(s)+110
Exposure (µs)1000 ~ 300000005000000 (5 s)
Gain (dB)0 ~ 3020
Frames1 ~ 2000100

Event list

Events come from comparing consecutive frames (linear bright streaks such as meteors), newest first, each with a confidence; images and grading (strong/standard/faint) are under "Gallery → Events". No detection in daytime (frames exposed under 100ms).

4 Photo mode

The "Photo mode" button appears on the device page (hotspot/direct LAN) and on the public page (proxied through the server control channel; select a concrete device and enter the admin token). Entering it pauses scheduled all-sky capture, meteor detection and uploads, and hands the camera to manual shooting; exit restores them.

This is different from "Daily use → Capture tasks": tasks still belong to the all-sky camera (they shoot with task parameters into their own folder). Photo mode takes the camera over completely and uses the all-sky CIF RAW + software decode (raw12_tool) path — no ISP — suited to a telescope/lens for focusing, single shots and long exposures.

What it does

FeatureDetails
Live previewSoftware-decoded full-frame preview 964×545 (skip-4 of 3856×2180; same field of view as all-sky), about 1.5 s per frame, tear-free
Capture964×545 JPEG (same as preview, full frame); managed in the Gallery's Captures view by day (also visible under "All", but excluded from frame batch delete)
Exposure / gain / HCGSliders; read-back takes effect on the next frame; the status line refreshes every 2 s
Interval shootingStart-to-start interval; count 0 = unlimited; stop any time
Long-exposure RAW3–900 s, optional HCG; saved as r_*.raw, downloadable from the Gallery's Captures view
CapturesMoved to the Gallery's Captures view: collapsed by day; click a thumbnail for a large view (RAW rendered at 964×545 on demand); delete a single item or a whole day; downloads on the device page

Caveats

6 Public access

With "public access" on, opening the server address from anywhere shows this camera — the same page: latest uploaded frame, history and events by date. Device offline: the last archived frame shows and the gallery is unaffected.

Requirements

Retention policy (where did my images go)

WherePolicy
Device · all-sky framesRolling area 3.5GB, oldest deleted first — about the last 2 days only (on the SD card when enabled)
Device · events1GB (~14 days), oldest first (on the SD card when enabled)
Device · captured photos/RAWNever auto-pruned (user assets); delete by item/day in the Gallery's Captures view; on the SD card when enabled
Device · internal legacy/var/allsky_internal, created on first SD enable; read-only, never auto-pruned, uses internal rootfs
Server · all-sky framesKept 7 days by default (configurable, chapter 6)
Server · eventsKept forever

Rolling deletion on the device is not data loss: long-term retention lives on the server, and events are kept forever.

7 Host your own server

The server archives what devices push up (frames/events/tasks) and serves the same page — open its address from anywhere; several devices on one server get a header selector. No server = the device works the same, just no remote viewing and no long-term retention.

What you need

Install (4 steps)

How to get the source repo: see the note shipped with the product (or ask your supplier).

  1. Create an install directory and put in 4 files: server.py, dev_channel.py, admin.py (from server/allsky_server/) and gallery_render.py (from project/app/allsky_webui/backend/).
  2. Copy the page directory project/app/allsky_webui/www/ into the install directory (as <install-dir>/www).
  3. Install dependencies: pip install aiohttp pillow
  4. Run: cd <install-dir> && ALLSKY_WWW=<install-dir>/www python3 server.py — open http://<server>:8084; seeing the page means success.

Long-term running (systemd)

Save this as /etc/systemd/system/allsky-server.service (restarts on crash):

[Unit]
Description=AllSky server
After=network-online.target

[Service]
User=<user>
WorkingDirectory=<install-dir>
Environment=ALLSKY_WWW=<install-dir>/www
# Public deployment: uncomment the next line (only nginx may proxy in):
#Environment=ALLSKY_SRV_HOST=127.0.0.1
ExecStart=/usr/bin/python3 server.py
Restart=always
RestartSec=3

[Install]
WantedBy=multi-user.target

Enable: sudo systemctl daemon-reload && sudo systemctl enable --now allsky-server; logs: journalctl -u allsky-server.

Environment variables (as needed)

VariableDefaultMeaning
ALLSKY_SRV_PORT8084Listening port
ALLSKY_SRV_DATA<install-dir>/dataData directory
ALLSKY_WWWthe repo's www directoryIn a standalone deployment, point it at your www/
ALLSKY_SRV_KEEP_DAYS7Frame retention; events kept forever
ALLSKY_SRV_HOST0.0.0.0Must be 127.0.0.1 on the public internet, behind nginx

Public reverse proxy (nginx + HTTPS)

nginx terminates TLS on 443 → proxies to 127.0.0.1:8084. The page hard-codes root paths, so point a subdomain (e.g. allsky.example.com) straight at it — mounting under a sub-path renders a blank page:

server {
    listen 443 ssl;
    server_name allsky.example.com;
    ssl_certificate     /etc/letsencrypt/live/allsky.example.com/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/allsky.example.com/privkey.pem;

    client_max_body_size 50m;

    location / {
        proxy_pass http://127.0.0.1:8084;
        proxy_http_version 1.1;
        proxy_set_header Host $host;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
        # the device long-poll hangs for 25s; must exceed it
        proxy_read_timeout 40s;
    }
}

Pairing a device (3 steps)

  1. Issue a key on the server: cd <install-dir> && python3 admin.py new-device <device-id> (the device ID is shown in the admin plane's "Public access" area, generated automatically). The key is printed only once; rerun the command to re-issue.
  2. Join the device hotspot, open http://192.168.5.1, and under "Device Management → Public access" fill: server address = https://<your-server>, device key = the key just printed; tick enable, save.
  3. After 1–2 capture intervals, open the server address: the device online with images arriving means success (still offline? chapter 9).

More devices: run new-device with each device's own ID (one key per device); the header grows a selector automatically (up to 256 devices).

Day-to-day maintenance

Security, three points

① Upload endpoints are unauthenticated (anyone can push frames; it pollutes data but grants no access) — public deployment must be nginx + HTTPS with the service on 127.0.0.1 only.
② The device key appears in plaintext in the service log and nginx logs — treat logs as confidential.
③ Admin token ≠ device key: the token is set on the device (governs writes); the key is issued by the server (governs the upload/control channel).

8 Field management

Everything here happens on the admin plane: join the hotspot AllSky-Pico → open http://192.168.5.1 → "Device Management" at the bottom.

Admin token

The key for public/LAN writes, 6+ chars; initial 12345678 (shown right there) — change it for a real site. Save empty = remote writes off.

Hotspot (device AP)

Change the hotspot SSID (≤32 chars) and password (≥8 chars); the hotspot restarts on save, reconnect with the new credentials.

Verify the new SSID/password connects before leaving the site. If you can't get into the hotspot, recovery means serial console or reflashing.

Uplink WiFi (site network)

Joins the device to the site WiFi (password ≥8 chars) for uploading and public access; the device rejoins on save, the hotspot is unaffected. Recorded networks are listed below and can be deleted one by one (delete all = hotspot-only mode).

Public access (remote viewing)

Fill in the server address (self-hosted: chapter 6; HTTPS mandatory on the public internet), tick enable, save; the device ID is generated automatically. To cut off public access: untick and save. See chapter 5.

Device actions

"Restart webui service" restarts just the camera program (page briefly down); "Reboot device" reboots everything (back in ~1 minute). The device also auto-reboots once in daytime (10:00–15:00) after 48 hours of uptime; set auto_reboot_hours to 0 in the config file to disable.

When to touch what

9 OTA updates

The device checks for updates every 6 hours: new versions are downloaded, verified and switched to automatically; a failed upgrade rolls back by itself — no human needed.

Current version: open http://<device>/api/ota/status (read-only, also via the public server). Trigger a check manually: POST /api/ota/run-now (free on the hotspot, admin token otherwise).

10 FAQ

Why no events in daytime?

By design: exposure under 100ms counts as daytime and detection pauses (daytime would only produce false positives). It resumes at dusk.

Night preview looks gray or too bright?

The preview is only a stretched reference image; trust the stored frames (full-size high quality).

Can't find the device hotspot?

Wait about a minute after power-on; make sure you're looking for AllSky-Pico (or its new name); move closer and retry.

Forgot the admin token?

Join the hotspot and open the admin plane (no token needed), then reset it under "Device Management → Admin token".

The page looks unchanged after an upgrade?

The browser cached the old page. Hard-refresh: Ctrl+F5 (Mac: Cmd+Shift+R).

The server page shows the device "offline"?

Wait 1–2 minutes (about one capture interval) and look again. Still offline: check the uplink WiFi ("Device Management → Uplink WiFi") and that "Public access" is enabled with the right address.