Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I have 2 keyboards and I want to know if it's possible to know which keyboard generated an input event in Windows (using WINAPI)?
Windows has a RAW Input API that can be used to monitor events from keyboards, mice, and HIDs (joysticks, etc) without using low-level hooks.
Use GetRawInputDeviceList() and GetRawInputDeviceInfo() to discover which keyboard devices are connected to the system.
Use RegisterRawInputDevices() to register for events from the desired keyboard devices.
You will receive a WM_INPUT message whenever an input event occurs on a registered device. It will tell you which device sent it.
There is also a WM_INPUT_DEVICE_CHANGE message to notify you when devices are added and removed.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I'm trying to find a proper way how to reuse existing implementations of wifi tools(iw) in own code(c\c++). I need to get information about available AccessPoints in range(signal strength, mac addr., etc). I found couple example codes(WEXT and others) that uses ioctl approach, but it makes passive scans(and i get new information only once in two minutes in my network)[UPDATE1: Thanks to #fluter, i know that WEXT can do active scanning, too.]. I found that iw makes an active scan and that is what i need. So my question:
Is there a way to use iw code in my own app without parsing its source code in chunks, or, maybe, there is an Wireless API for such purpose?
(UPDATE1: with basic code examples to start with.)
Similar question
UPDATE2: I have reviewed my task and found that AP information is not enough for me, i need to capture clients data, too. That leads me to wifi packet sniffing and the best tool i have found to do that is Horst. So, i'm trying to reuse its code in my app, now.
You might wish to start with cfg80211.
cfg80211 replaces Wireless-Extensions and it is suggested that :
All new Linux wireless drivers should be written targeting either cfg80211 for fullmac devices or mac80211 for softmac devices.
Also, it is written:
Instead of writing wext ioctls you now write cfg80211 operation
callbacks and fill in the wiphy struct to indicate to cfg80211 its
device capabilities.
To start with active scanning start here
You can use the wext api provided by kernel, basically, call ioctl with SIOCSIWSCAN, and get the scanned result with SIOCGIWSCAN.
You can set to scan all by using flag IW_SCAN_ALL_ESSID, and choose scan type with flag IW_SCAN_TYPE_ACTIVE or IW_SCAN_TYPE_PASSIVE.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
The community reviewed whether to reopen this question 6 months ago and left it closed:
Original close reason(s) were not resolved
Improve this question
Ok, my question is this:
How can I programmatically capture audio from a specific application and then send it to a specific audio device in Windows 7?
I know for a fact this can be done, since SoundLeech captures audio from individual programs, and theoretically once you have the sound you can do what you want with it (including play it to any sound output device).
I'm a C++ programmer but I know very little about Windows programming. I need some pointers to capturing sound from individual programs. I work with audio recording very frequently and I would be willing to put in a large amount of work to develop a way to better handle sound in Windows given how difficult to use it currently is.
So how can I capture audio streams directly from applications without first routing them through Virtual Audio Cables or the like?
You cannot do it using standard user mode APIs. You need to either hook APIs or create virtual devices to accept application streams/sessions.
Intercepting and postprocessing all audio streams on Windows
Recording Audio Output from a Specific Program on Windows
Is it possible to caputre the rendering audio session from another process?
Capture audio of a single application on Windows 7
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 8 years ago.
Improve this question
So I am hoping to use a Futaba remote controller (specifically the Futaba 7c 2.4ghz) for a c++ + OpenGL simulator that I wrote.
Are there Ubuntu packages available to assist with this? I am okay with buying the USB cable to connect the controller to the computer, but then I need a c/c++ SDK to allow the controller to communicate with my program.
Thanks
Futaba and all other controllers send/receive PPM signals. You need a device (USB device for example) which is capable of receiving PPM signals.
For example this device:
http://www.mftech.de/usb-interface_en.htm
Also you can go "hackish" way
Just like this:
http://wiki.neuronrobotics.com/PPM_Reader_Channel
and
http://diydrones.com/profiles/blogs/705844:BlogPost:38393
You can use an Arudino or ArduPilot board to receive signals from controller, then send it with Serial port to USB converter to PC for processing.
I remember I've done something similar to this with a basic Arduino. If I recall correctly, I had a signal cable connected from Futaba's RC receiver part to Arduino and I was able to receive PPM signals. Something like this: https://www.sparkfun.com/tutorials/348
Also you can simply use this http://www.rctoys.com/rc-products/GWS-GWFSM002A-ROUND.html
directly connected to RC transmitter and all buttons pressed on RC will be sent directly to USB port, you'll have a virtual COM port and you can read all signals
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I got stuck on my Glass unit with Launchy crashing (sideloaded the wrong version -_-) in XE11 every time I try to launch an application, including the built-in settings. The problem is for some reason I don't have ADB access anymore and because of Launchy, now can't even reenable Debug mode.
So I am now trying to boot into fastboot mode using the hardware method reference here: Having issues seeing GLASS in Fastboot
But when I keep the camera button pressed and press the power button briefly, the LED is solid for a few seconds and then goes on to blink at very low frequency. No matter how long I seem to keep the camera button pressed, the LED never goes solid.
I've also tried to plug in the unit to my computer and look for it show up in the System Information (the Apple Device Manager equivalent).
Does anyone know if the fastboot hardware method changed in XE11? Or what am I doing wrong?
Thanks in advance,
Charles.
The slow blink you're seeing is Glass in fastboot. Once in fastboot you can verify that it's connected by doing a device list:
$ fastboot devices
If you see output, you'll be able to run other fastboot commands.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking for code must demonstrate a minimal understanding of the problem being solved. Include attempted solutions, why they didn't work, and the expected results. See also: Stack Overflow question checklist
Closed 9 years ago.
Improve this question
I'm looking to create a mobile app on IOS devices before I started I just needed to check up on one thing. How can I detect other IOS mobile devices within local rage e.g same room, same train, etc..
I want to be able to do it while the phone is locked, so bluetooth wouldn't be a great example as most people have it turned off.
Thanks!
The application has to send its location to the server.
Then the server knows where every devices that shared its location are.
Then your application can ask "who is around?" to your server... and your server calculates (let's suppose within a radius of 2 miles) who is around... and sends back to you.
It doesn't have anything to do with bluetooth. It's done via regular internet.
For other users of your app who want to be discovered you could use Bluetooth LE and the new iBeacon support added in iOS 7. Each user would have to launch your app and give it permission to start "advertising" their presence. However, the range of Bluetooth LE is like 10-20 meters (I forget the exact figure) and that will go down in "RF hostile" environments.
If everybody's connected to the same WiFi network you could use Bonjour.
Another option, as suggested by Wagner, above, is to have the devices send their locations to a central server.