![]() |
|
#1
|
|||
|
|||
Creating Virtual Hardware interruptsHello,
I have been looking for a way to mimic a hardware interrupt in software. For example, how would someone send a mouse click interrupt virtually to a different program without actually clicking the mouse? I have seen ways to handle interrupts, but never a way to generate the interrupt. Does the OS (linux for example) have a global interrupt array where I can set a hardware interrupt (even though it's probably dangerous to do that)? I'm sorry I have no code, as this is not for a class nor for any work project. I have been thinking of program automation techniques and this concerpt has been on my mind for quite some time now. Thanks, PPAN |
|
#2
|
|||
|
|||
Re: Creating Virtual Hardware interruptsI don't know about Linux, but Windows has concept called "hooks" where the OS calls your callback function when a certain event happens (the event depends on the type of hook -- it can be a mouse click, a keyboard press, a message send, etc).
|
|
#3
|
|||
|
|||
Re: Creating Virtual Hardware interruptsThanks. I read a little about hooks and they seem pretty neat. I read that they intercept events, so I wonder can I intercept a MOUSECLICK event and then intead call a KEYBOARD event callback function instead
|
|
#4
|
|||
|
|||
Re: Creating Virtual Hardware interruptsQuote:
Most modern operating systems are not going to give your userland applications (memory) access to interrupt vector tables. If, by some kernel method, you obtain a pointer to the memory locations, altering them would likely cause kernel faults that could be catastropic. As noted by UG, the windowing system is probably the preferred way to "send" mouse clicks and other "events" to an application(s). You can easily "hook" these events through your windowing subsystem on both Windows and Linux (X Window system). :davis: |
Recent GIDBlog
Toyota - 2008 September Promotion by Nihal
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Help in Virtual function | Janakiraman | MS Visual C++ / MFC Forum | 1 | 31-May-2006 00:15 |
| pure virtual function | vatsa_mitr | C++ Forum | 1 | 12-May-2006 00:41 |
| virtual memory | Hood | Computer Software Forum - Windows | 1 | 15-Jun-2005 13:17 |
| Online debit card - Virtual debit card - Cachecard | pinky123 | eCommerce / Merchant Account Forum | 0 | 20-Feb-2005 00:04 |
| Dealing with virtual functions | crystalattice | C++ Forum | 0 | 16-Nov-2004 22:34 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The