Wait for keypress Assembly NASM, Linux -
i'm working on hello world in assembly x86-64. i have managed create 1 finishes when enter key pressed, have finish when key pressed. this code waiting enter key: mov rax, 0 mov rdi, 0 mov rdx, 1 syscall i can't use int xh or that. syscalls. thanks! i've answered a similar question before , , gave c code work directly system calls wanted. here's translation of code nasm, slight changes reflect you're checking key pressed, not specific key: fwait: ; fetch current terminal settings mov rax, 16 ; __nr_ioctl mov rdi, 0 ; fd: stdin mov rsi, 21505 ; cmd: tcgets mov rdx, orig ; arg: buffer, orig syscall ; again, time 'new' buffer mov rax, 16 mov rdi, 0 mov rsi, 21505 mov rdx, new syscall ; change settings , dword [new+0], -1516 ; ~(ignbrk | brkint | parmrk | istrip | inlcr | igncr | icrnl | ixon) , dword [new+4], -2 ; ~opost , dword [new+12], -32844 ; ~(ec...