retroforth/interface/ioctl.retro
crc f326a99caf start of the new ioctl device
FossilOrigin-Name: ff4557673a4ee251c20472267a4e6e8c7b364aaead7bc5c8c9065f043396bb44
2024-01-22 15:19:00 +00:00

12 lines
387 B
Forth

~~~
:ioctl:operation
DEVICE:IOCTL io:scan-for
dup n:negative? [ drop 'Error:_ioctl_device_not_found s:put nl ] if;
io:invoke ;
:ioctl:term-size (-nn) #0 ioctl:operation ;
:ioctl:set-cbreak (-) #1 ioctl:operation ;
:ioctl:set-lbreak (-) #2 ioctl:operation ;
:ioctl:save-state (-) #3 ioctl:operation ;
:ioctl:restore-state (-) #4 ioctl:operation ;
~~~