-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Option for typewriter effect when typing within terminal? #18
Comments
Just realized, could pipe /dev/tty for input to beep, without having beep pull in additional libraries. $ beep -c -f 750 -D 30 -l 30 < /dev/tty However, beep is only activated on carriage return or '\n', end of line return, instead of after each key press. |
You could try this in $ while read -n1 -r; do beep -f 750 -D 30 -l 30; done or % while read -k; do beep -f 750 -D 30 -l 30; done |
Perhaps
and then reverse that before the beep program terminates in any way. |
Probably a better way to implement key press noises would be in the keystroke processing software stack: Either inside the kernel or as a user space evdev input device driver for keyboard type devices. A lot of care would need to be taken in that software, as that is also where you would implement a keylogger. |
I've seen quite a few extravagant typewriting sound emulators using ALSA/Pulse for output, but seemingly bloated in my opinion with high resource usage, rather than using simple PC speaker beep. (eg. bucklespring program, but useless for vision impaired as the sounds are emitted upon press and release, more of a cosmetic feature rather than useful feature.)
Is there any method of providing the beep command the option for emulating a typewriter while typing within terminals?
If I'm not mistaken, the process is relatively simple, detect a keyscan press, play beep. I'm pretty sure the code is almost there using "beep -c -f 750 -D 20 -l 5", just needs to detect a keyscan press.
The text was updated successfully, but these errors were encountered: