modus
Menu
On this page

The entry serial_terminal

Serial ANSI 24-bit TrueColor terminal renderer for modus:terminal .

Reads typed terminal records from console on the shared terminal ring through the renderer intake of modus:terminal, renders 24-bit TrueColor ANSI escape sequences (including Lex syntax highlighting and interactive completion popups) over the second serial port, COM2, and decodes VT100/UTF-8 input bytes back into typed terminal_records.Input keys through the UART driver and key decoder of modus:terminal. COM1 stays the log of the kernel: the text of the terminal never mixes with its lines. Requires no compositor, no drawing module, no TrueType font, and no framebuffer.

See: Desktop-free console renderers: Variant A: serial_terminal in the repository

serial_terminal module with an entry

Hash
84bcfd973c74bea8be6f836a8bceee339804af00b33f4e6fd75cb9acc39605a7
Size
49152 bytes
Exports
0
Imports
0
Imported by
0
License
MIT

Serial ANSI 24-bit TrueColor terminal renderer for modus:terminal

FactValue
KindModules with an entry
Sourcesrc/modules/system/serial_terminal
Boot imageyes: in the boot image, 49152 bytes in this build
Build settingsnone: the defaults of the source
Importsnone
Imported bynone

Neighbours

It imports no module, and no module imports it. The module graph shows it with the other modules that have no edge.

Exports

ExportWhat it does
entry()

entry

entry()
Form
The entry of the module: one parameter, an address, fixed by the contract.
Source
src/modules/system/serial_terminal/main.odin:39

Read from the source of the module, as the build reads it to describe the exports (tools/modustool/build/describe.odin).

What the root service gives it

WhatValueAs the root service says
GrantsThe terminal of a console image with no compositor: the ports of the second serial port, COM2, where it writes ANSI text and reads keys (renderer_terminal_start). COM1 stays the log of the kernel.
Other terms of its start grant setnone
Budget that it asks for
  • working memory pages 32
  • pages of its threads 72
  • pages of the pictures of its window 0
  • pages of the module and its imports from the files of the build
  • processes the least
  • threads 1
Working memory for the terminal ring mapping, text region, ANSI staging buffer and the intake with its completion list, and one service thread.

The start grant set is read from start_grant_sets in src/modules/system/root/start_grant_sets.odin. The stated budget is read from the constant MODULE_BUDGET of the source of the module (its line); the build adds the counted parts and writes the sum in the module (tools/modustool/build/budget_count.odin); the root service accepts it up to the largest budget of a process, and adds the limits of processor time and of log records (src/modules/system/root/budgets.odin).