473,414 Members | 1,776 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,414 software developers and data experts.

Checking for the status of a device (before connection)... -- (JohnMcCormick)

Hello, ... I am John McCormick (Systems Programmer ) and I am currently
working on a python program which will connect (user) specified inputs
and connect them to (user) selected outputs (like screen or
video/audio-recording devices) and would like to know if there's a
technique to "test" or "sense" if the desired output device is busy
without interrupting the output device while checking to see if it's
busy... ?? If, perhaps, python does not have this type of feature, I
wonder if you could give me some type of direction (ie., manufacturer's
device response checking techniques that could be used in conjunction
with python) but the bottom line is not to "crash" or interrupt the
desired output device (if it's still busy)...

Thank You

John McCormick

##############################################
John W. McCormick, Systems Programmer / DBA
High Performance Computing & Scientific Visualization
Lockheed Martin Information Technology, Supporting the EPA
Research Triangle Park, NC
919-541-0890

Federal Infrastructure Contact - Ravi Nair
919-541-5467 - na*******@epa.gov
Federal Infrastructure Contact - Joe Retzer, Ph.D.
919-541-4190 - re***********@epa.gov

Jul 18 '05 #1
1 1474
Mc*************@epamail.epa.gov writes:
Hello, ... I am John McCormick (Systems Programmer ) and I am currently
working on a python program which will connect (user) specified inputs
and connect them to (user) selected outputs (like screen or
video/audio-recording devices) and would like to know if there's a
technique to "test" or "sense" if the desired output device is busy
without interrupting the output device while checking to see if it's
busy... ?? If, perhaps, python does not have this type of feature, I
wonder if you could give me some type of direction (ie., manufacturer's
device response checking techniques that could be used in conjunction
with python) but the bottom line is not to "crash" or interrupt the
desired output device (if it's still busy)...


That's a very device - and platform! - specific thing to want to
do. On Unix, you would typically open() the /dev/device file and
perform an ioctl on it to see if it was busy - assuming it supported
that kind of operation at all. The exact ioctl call would depend on
the device, as there really isn't a standard for them.

<mike
--
Mike Meyer <mw*@mired.org> http://www.mired.org/home/mwm/
Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information.
Jul 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

63
by: Martin Johansen | last post by:
Hey guys Since C is my language of choice for almost any kind of application, I'd like to know what the status of C is around the world today. And I am ofcourse not talking about C++ or C#. I...
0
by: Eddy_w | last post by:
Hello, I try to ping from my mobile device with a wireless connection to my pc. I found the class clsping on the internet and it works perfect with application from pc to pc but when i use it...
20
by: newbie | last post by:
Hi all, http://www.aswin.be/nictransfer.JPG How can I get these numbers with VB.NET ? I thought somewhere in WMI but I can't find them. Thank you, Aswin
66
by: Johan Tibell | last post by:
I've written a piece of code that uses sockets a lot (I know that sockets aren't portable C, this is not a question about sockets per se). Much of my code ended up looking like this: if...
2
by: beaker | last post by:
Hi, I'm looking for a way of checking whether a specific USB device (a webcam) is plugged in. I have the Vendor and Product ID numbers for the device. I found an article...
2
by: Mike | last post by:
Hello, Ok I have 2 classes in my project, one is the main form and one is a connection class, at a certain event on my main form a new instance is made of the connection class, and a reference...
8
by: John | last post by:
Hi I am creating a db connection using the below code. Is there a way to check if the connection is open? Thanks Regards
0
by: spira | last post by:
Hi, i'm writing a C code which would schedule some backup in linux. It takes in a device as one of its arguments. I want to check whether the device is valid for storing the backup(or if that...
46
by: John | last post by:
Hi How can I check for existence of a certain table by name in and access database and if the table exists find the number of records in it? I guess I can access this information by setting up...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.