nx_print_response.nx
buildroot/runtime/nx_print_response.nx
about
nx_print_response.nx -- map runtime-monitor issue verdicts to
corrective actions on the printer.
When the runtime monitor fires an NX_RT_ISSUE_*, the operator
integration needs to actually DO something on the printer:
pause, hard-stop, notify-only. This brick:
1. Maps each issue kind to a recommended response class
(operator can override per-deployment).
2. Builds the HTTP wire bytes for the canonical
Moonraker `/printer/print/pause` request, ready for
nx_mr_post_ipv4 to send.
Substrate stays pure: this function produces bytes, doesn't
open sockets. Operator decides when/whether to actually
send the wire bytes.
license_tier: ORIGINAL
dependencies 3 imports · 3 importers
imports: nx_syscalls.nxnx_moonraker_client.nxnx_print_runtime_monitor.nx
imported by: nx_moonraker_loop_e2e_test.nxnx_print_loop_e2e_test.nxnx_print_response_test.nx
structs
| none |
consts
| 26 | const NX_PRINT_RESPONSE_NONE: i64 = 0 |
| 27 | const NX_PRINT_RESPONSE_NOTIFY: i64 = 1 // log/page, do not pause |
| 28 | const NX_PRINT_RESPONSE_PAUSE: i64 = 2 // PAUSE; operator inspects + resumes |
| 29 | const NX_PRINT_RESPONSE_HARD_STOP: i64 = 3 // emergency stop (cancel; not resumable) |
| 30 | const NX_PRINT_RESPONSE_N: i64 = 4 |
functions
| 36 | func nx_print_response_for_issue(kind: i64) -> i64 |
| 54 | func nx_print_build_pause_request( |
| 73 | func nx_print_build_cancel_request( |
| 94 | func nx_print_build_response_for_issue( |