- Vue 56.6%
- TypeScript 21.7%
- JavaScript 17.9%
- CSS 1.5%
- Dockerfile 1.3%
- Other 1%
|
|
||
|---|---|---|
| data | ||
| public | ||
| server | ||
| src | ||
| .dockerignore | ||
| .gitignore | ||
| Dockerfile | ||
| index.html | ||
| lineups.html | ||
| package-lock.json | ||
| package.json | ||
| play.html | ||
| README.md | ||
| tsconfig.json | ||
| vite.config.ts | ||
Sega Channel
A web app modeled on the 1994–98 Sega Channel menu, for playing the Genesis / Mega Drive ROMs on a home server. Games run in EmulatorJS 4.2.3 with the genesis_plus_gx core, the same build RomM ships, served from the container itself (no CDN).
The menu follows the real Sega Channel adapter's software, as seen in 1995-96
prototype screenshots: a starfield boot screen, a seasonal Now Playing
screen with a two-column grid of beveled category buttons, and Game Guide-style
category screens (a header panel over a list with a yellow selection bar). It
runs at the Genesis's 320x224, scaled up by whole pixels, in Genesis colours
(9-bit, channels in 0x20 steps). Category names come from the channel's own
menus; the Lineup Vault and /lineups.html use the
archived 1997 sega.com/channel pages.
All art is original, drawn in code; no Sega images, fonts or music are shipped.
The lineup
Like the later channel, the lineup changes on the 1st and the 15th (server
time, TZ). About 50 games are on the air at once (LINEUP_SIZE), roughly
two thirds of them new each time, and every category gets at least three. Each
game's air dates come from its id and the date alone (server/rotation.mjs),
so every device agrees and adding a ROM doesn't reshuffle the rest. When the
calendar lines up with one of the eight archived 1996-97 lineups, the games
you have from that real lineup are on air too, marked 97.
My Faves and the Control Room can play any game, on air or not.
?at=2026-12-05 previews another date's lineup; ?theme=halloween (winter,
spring, summer, autumn, halloween, holiday) previews a season.
Runs on the OptiPlex at http://segachannel.local (port 3006), deployed by
cyberdeck/optiplex/segachannel/deploy.py.
How it works
- ROMs are read from one folder (
ROM_DIR, mounted read-only). On the Mac mini that's/mnt/aether/roms/genesis, the same folder RomM uses. Nothing is copied or moved. New files show up within 15 seconds. - Titles come from the No-Intro file name (
Lost World, The - Jurassic Park (USA).zip→ The Lost World: Jurassic Park). Each ROM is matched against the archived 1996–97 lineups indata/to pick its room and show when it ran on the channel. Games that never appeared there get a room fromDEFAULT_ROOMSinserver/library.mjs, or The Arcade. - Everything else is server-side (
DATA_DIR, a Docker volume): room and title edits from the Control Room, favorites, play counts, save states (one slot per game) and battery saves. Any device on the network sees the same channel, and a game saved on one device can be continued on another.
Pages
| Path | |
|---|---|
/ |
The channel: Now Playing with Test Drives (newest files), eight game categories, My Faves, Prize-O-Rama, Lineup Vault, News Link, Game Guide and Control Room |
/play.html?id=… |
The player. &resume loads the server save state on start (the menu adds it when one exists) |
/lineups.html |
Every game from the archived lineups, checked off when a matching ROM is on the server |
API
GET /api/library |
games with room, title, favorite, plays, save state flag, lineup info and onAir, plus the current lineup window (?at= for another date) |
GET /api/lineups |
the archive, with gameId set for games on the server |
PATCH /api/games/:id |
{ "room": "shooters", "title": "…", "fav": true } (empty title resets it) |
POST /api/games/:id/played |
bump the play count |
GET/PUT/DELETE /api/games/:id/state |
save state (raw bytes) |
GET/PUT/DELETE /api/games/:id/sram |
battery save (raw bytes) |
GET /roms/:id |
the ROM file (Range supported) |
Develop
npm install
# EmulatorJS for local runs: extract data/ from the 4.2.3 release into ./emulatorjs
ROM_DIR=/path/to/genesis npm run server # http://localhost:8080 (serves dist/)
npm run dev # http://localhost:3333, proxies the API to :8080
npm run build # typecheck + build to dist/
Or the whole thing: docker build -t sega-channel . then
docker run -p 8080:8080 -v /path/to/genesis:/roms:ro -v sega-channel-data:/data sega-channel.
Controls
| Menu | Keyboard | Gamepad |
|---|---|---|
| Move | Arrows | D-pad |
| Select | Z / Space / Enter | A / Start |
| Back | X / Esc | B |
| Star a game | F | Y |
On Now Playing the D-pad moves around the grid; A opens a category, B goes back. In the Control Room, ◀ ▶ moves the highlighted game to another category; double-click a title to rename it. In the Lineup Vault, ◀ ▶ switches between the eight archived lineups.
Structure
server/index.mjs: HTTP server, API, save storage (no dependencies)server/library.mjs: ROM scan, title cleanup, lineup matching, default roomsserver/rotation.mjs: the twice-monthly lineupsrc/App.vue: Now Playing and the category screenssrc/Lineups.vue: the lineup checklist pagesrc/play.ts: the EmulatorJS player and server save syncsrc/components/: the 320x224 screen, boot screen, seasonal scene, mascot, "now downloading", TV static, news tickersrc/lib/categories.ts: categories;src/lib/themes.ts: seasons;src/lib/pixelart.ts: sprites and palettedata/: the archived lineup (JSON + CSV)