Is it possible to create a socket connection to an open port on an end device.
If the connection drops print something?
I have seen a few examples but they require a server type script and a client, just looking for a client.
Thanks
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Perl has sockets built right into it. You just need to load the standard
Socket.pmmodule to get the constants you need.The perlipc manpage tells you all about this. There are many higher-level modules that get at this more easily than the builtins, however. Some are even standard.
Here’s a CLI example: