<feed xmlns='http://www.w3.org/2005/Atom'>
<title>gbos.git/src/font.asm, branch master</title>
<subtitle>gbos - a tiny Unix-flavored OS for the Game Boy Color (kernel, shell, coreutils in C, RAM filesystem)</subtitle>
<id>https://git.sl0p.foo/gbos.git/atom/src/font.asm?h=master</id>
<link rel='self' href='https://git.sl0p.foo/gbos.git/atom/src/font.asm?h=master'/>
<link rel='alternate' type='text/html' href='https://git.sl0p.foo/gbos.git/'/>
<updated>2026-07-16T12:53:25Z</updated>
<entry>
<title>font: full mixed-case + punctuation glyph set (not uppercase-only)</title>
<updated>2026-07-16T12:53:25Z</updated>
<author>
<name>user</name>
<email>user@clank</email>
</author>
<published>2026-07-16T12:53:25Z</published>
<link rel='alternate' type='text/html' href='https://git.sl0p.foo/gbos.git/commit/?id=db022ffc366c8e81cd1120aa0190661e43d5dc32'/>
<id>urn:sha1:db022ffc366c8e81cd1120aa0190661e43d5dc32</id>
<content type='text'>
Replace the small-caps placeholder font with a real baseline-aligned
4x8 set covering all 96 printable ASCII: distinct lowercase with true
ascenders (b d f h k l t) and descenders (g j p q y), digits, and
punctuation. Metrics: caps/ascenders rows 1-5, x-height rows 2-5,
baseline row 5, descenders into rows 6-7. Glyphs are ~3px wide in the
4px cell -- cramped but legible; the tile mechanism itself imposes no
character-set limit.

genfont.py now takes per-glyph (top, rows) so glyphs sit on the baseline.
Demo strings in term_test updated to show mixed case + punctuation.
Verified by screenshot: descenders visibly drop below the baseline.
</content>
</entry>
<entry>
<title>term: 40-column text terminal on the CGB LCD (4x8 dynamic tiles)</title>
<updated>2026-07-16T11:54:23Z</updated>
<author>
<name>user</name>
<email>user@clank</email>
</author>
<published>2026-07-16T11:54:23Z</published>
<link rel='alternate' type='text/html' href='https://git.sl0p.foo/gbos.git/commit/?id=4656a1003226709e9b3c804ec32b4913fca4c7f4'/>
<id>urn:sha1:4656a1003226709e9b3c804ec32b4913fca4c7f4</id>
<content type='text'>
Add a background-tile text terminal that packs TWO 4px-wide characters
into each 8x8 tile, giving a 40x18 grid instead of the 20x18 you'd get
from an 8x8 font. The tilemap is static (one dedicated VRAM tile per
screen position); we rebuild a tile's 16 bytes from two glyphs whenever
a character changes. 360 tiles exceed the 256 a single tilemap can
address, so positions 256-359 live in VRAM bank 1 via the CGB tilemap
attribute bank-bit -- hence CGB-only.

- Switch the ROM to CGB (rgbfix -C). Safe for the FS: every process has
  PROC_WRAMB=1, so SVBK stays on bank 1 and the WRAMX FS caches don't move.
- CGB BG palette 0 = white bg / black text via BCPS/BCPD.
- src/term.asm: term_init (palette + static tilemap + clear buffer),
  build_tile (combine two 4px glyphs -&gt; one 8x8 tile, correct VRAM bank),
  term_redraw (rebuild all tiles), term_puts, term_show, term_test.
- src/font.asm: 96-glyph 3x5-in-4x8 font, generated by tools/genfont.py.
- 40x18 text buffer at $D600 (WRAMX, above the FS caches).
- tools/ppmview.py: render a --shot PPM as ASCII so the LCD is inspectable
  from the shell during development.

Verified via emulator screenshot: "GBOS TERMINAL", the alphabet, and a
bank-1 row all render legibly at 40 columns. Serial shell + filesystem
still work unchanged.

Note: a full term_redraw builds 360 tiles and takes ~8 frames; fine for
incremental single-char updates, but scrolling needs a smarter path
(next milestone). Input (no keyboard) is also still TODO.
</content>
</entry>
</feed>
