code wiki / _hdl_build / nx_assembly_gate.nx
nx_assembly_gate.nx
buildroot/runtime/_hdl_build/nx_assembly_gate.nx
about
nx_assembly_gate.nx -- GATE: a whole-PRODUCT digital twin -- a REFRIGERATOR, modeled as an assembly tree from the
real supply chain, with the nx_bom PCB control board composed in as a subsystem.
T1 EFF COUNTS -- the assembly multiplies correctly (2 doors -> effective count 2).
T2 ROLLED COST -- exact total bill of materials = 14005 cents ($140.05), summed over the whole tree.
T3 ROLLED MASS -- exact total mass = 46950 g (46.95 kg).
T4 PART COUNT -- 9 real parts.
T5 SOURCEABLE -- all parts in stock -> 0 shortfalls; dropping door stock to 1 (need 2) -> a real shortfall (liar-kill).
T6 COMPOSE PCB -- the control board cost = the nx_bom PCB twin (the PCB is a SUBSYSTEM of the fridge).
GREEN iff all. Sovereign nx_cc->nxasm. The same engine scales to a car (a bigger tree). expect_exit: 0 license_tier: ORIGINAL
dependencies 3 imports · 0 importers
imports: nx_assembly.nxnx_bom.nxnx_syscalls.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| none |
functions
| 14 | func w(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 } |
| 15 | func wn(v: i64) -> i64 { var m: i64=v; if m<0{w("-" as *u8);m=0-m} let t:*u8=sys_mmap(24); var k:i64=0; if m==0{t[0]=48 as u8;k=1} while m>0{t[k]=(48+(m%10)) as u8;m=m/10;k=k+1} var i:i64=0; let o:*u8=sys_mmap(24); while i<k{o[i]=t[k-1-i];i=i+1} sys_write(1,o,k); return 0 } |
| 17 | func main() -> i64 |