Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: Non blocking read from the console

by Anonymous Monk
on Oct 18, 2024 at 18:37 UTC ( [id://11162318]=note: print w/replies, xml ) Need Help??


in reply to Non blocking read from the console

I don't get where the non blocking part is ...

Replies are listed 'Best First'.
Re^2: Non blocking read from the console
by soonix (Chancellor) on Oct 18, 2024 at 20:39 UTC
    the ReadKey(-1) (and the underlying system call) is non-blocking. At least OP doesn't hog the CPU as in the SYNOPSIS of Term::ReadKey, but uses usleep during the active waiting…

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11162318]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (4)
As of 2025-01-24 17:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Which URL do you most often use to access this site?












    Results (68 votes). Check out past polls.