Azure Kinect: how to find the windows device id - azurekinect

I have been developing a Win application that uses 3 Azure Kinects. Since there is no C# wrapper available yet, I made a C++ app that does what I need and the C# app just grabs its output files.
I now need to figure out which camera is which. In the C# app I can get the windows device id in a form similar to
\\.\USB#VID_045E&PID_097C#001007692912#{A5DCBF10-6530-11D2-901F-00C04FB951ED}
However the C API for the Kinect only provides ways to get the serial number of the device.
I tried to dig into the API, since I'm sure it must be somewhere in the code but, due to my limited C skills, I got lost pretty quickly.
Anybody with the same issue or can help?
Thanks,
Guido

The SDK is designed to use serial number specifically to determine which device or devices you are connected to. If you are just trying to use 2 Kinects with 2 instances of your C# then you will need to open devices until you find the serial number you are looking for. If you are trying to use multiple devices in a master/subordinate configuration then you can query for jack state to determine if you have connected to one or the other.
Also please be aware that we just released our own C# wrapper for the SDK. Checkout https://github.com/microsoft/Azure-Kinect-Sensor-SDK/issues/608 and https://microsoft.github.io/Azure-Kinect-Sensor-SDK/master/namespace_microsoft_1_1_azure_1_1_kinect_1_1_sensor.html for more details.

Related

Proprietary USB device access via browser... possible? Silverlight maybe? (Java is excluded for now)

Probably there are a lot of similar questions around, but since I know only few solutions to this which I am not sure will work for us, I am looking for something else, maybe new technologies...
What we have is this USB device which is not so fancy (of course, it requires a driver to be loaded), and it has couple of C++ dlls to help getting certain output from it. On top, we made a C# desktop application which makes use of the device in a more attractive way (plenty of interop inside).
So far so good, but to have the application lifted up to the web in order to gain more flexibility... What options are there?
Known solutions are:
1) ActiveX - kinda old technology and not cross-browser;
2) .Net 'applet' - not so common (is this even a solution?)
3) Java applet - well known, but JVM needed (since we went for C++ C#
maybe is out of scope);
4) Web service on the usb device itself - our device is very
light, we cannot have it there.
Are there other ways? Is Silverlight 4, 5 (maybe "out of browser") a feasable solution? What about these new technologies nowadays? Html 5 or something?
EDIT1: In particular I am interested in Silverlight. Is there a way using Silverlight?
EDIT2: I found this question: Can Silverlight access a .Net library that accesses a USB port? . What shall I understand from that? Is really Silverlight not a feasable solution for my scenario?
EDIT 3: VERY IMPORTANT!
These devices need to be used on customer side! People browsing must use them locally on their PCs!
Thanks in advance.
to have the application lifted up to the web [...]
Simple solution: Let the webserver (http server) run on the PC connected to the USB device, and use one of the webserver's interfaces like CGI to talk to your USB device. This way you need to code only a USB-to-CGI wrapper program, which can be C++ or C#.
Another way is to write a browser plugin.
The issue that you're going to face is that content in a browser is often run in a sandbox, in such a way that the web app does not have access to the computer. There are good reasons for this - security, primarily. One way to have some code running in the context of the computer is to have a browser plugin that can access the computer's hardware resources, but that can interact with browser content. Unfortunately, you may end up writing a different plugin for different browsers.
There do exist frameworks out there that make writing browser plugins more manageable. A simple search should turn up some of those candidates.
You can use Silverlight 5, it can give you access to your file system and USB storage device. If you want to get control for other USB device (printer, scanner, etc), you should give a device type. I know, Silverlight 5 works fine with a file system and web-cams...)

Detect type of Display Device (Monitor/Projector) through Silverlight Client

I know that we can find the screen resolution of the client's monitor.
Is it possible to find out whether the type of device is Monitor or Projector?
If I want my web-based silverlight client to work only in Monitors and not on Projectors or vice versa, is it possible to enforce that?
The following SO question deals a similar matter in the case of java applets.
Detect Display Type (Projector) from within the browser
So whats the case with silverlight?
I don't think even Windows knows that. Most of the time it's the display driver and only on laptops. So, I don't know of any easy way of doing that. You could use encrypted DRM to enforce HDCP but even then...no go more than likely. Silverlight is basically VB .net or C# so perhaps try to find an example in those languages.
EDIT: I did some more looking around and found no real API that provided a way to detect an outputs type (Monitor or Projector)

Bluetooth connection with Nokia e63 in java?

I want to connect with my nokia e63 mobile using bluetooth or usb with pc but that using java application.
I want to know about how to do that ? And
my question are like :
Can I connect with using java application and if yes then how ?
I mainly want to get the calling information. I want to save the calling information like whose called on which time in database but for that i need the number whose calling ? Is this possible with using java application ?
And any references will very much helpful.
Thank You...
I developed an Bluetooth Java Applicaton 1 year ago and I 've used the Java Docs pretty much which are really helpful !
http://developers.sun.com/mobility/midp/articles/bluetooth2/ , http://developers.sun.com/mobility/apis/articles/bluetoothcore/
I don't know how to access call informations but connecting is not that difficult.

Can silverlight queue a list of files and post, when connection available, to a web service / url?

I need to provide a way of users uploading multiple files (can be 10MB each) over Mac, PC and a mobile device (something with an SD slot).
The connection from the mobile device can be poor so I need to enable queuing of the files so they can be delivered when connection becomes available.
I am looking at Silverlight as a potential option using something like this example uses and sending over the files when a connection is available.
http://www.microsoft.com/silverlight/out-of-browser/demo/
I have tried searching for silverlight articles but not found anything appropriate. What I am trying to avoid is writing multiple versions of the software for Mac+PC (browser) and mobile device.
Can silverlight provide this kind of functionality or is something I would have to approach differently?
Silverlight can be used to do that.
You don't need to use the out-of-browser functionality, silverlight gives you low-level control over sockets and threads.
For devices it's a different scenario, as AnthonyWJones points out.
There is a silverlight version for the nokia, but I've know idea if it is actively developed. The is also a c++ version for linux/meego, there is a mono version.
But all those are different versions.

How to set specific IMEI in Nokia S60 SDK emulator

I'm also interested in other Symbian SDKs that allow to set their emulator's IMEI.
Emulator has hardcoded IMEI of '000000000000000'. Replace what with whatever you want to use and continue running your code.
Symbian C++:
TPlpVariantMachineId imei;
PlpVariant::GetMachineIdL(imei);
imei.Copy(_L("123456789012345"));
Python for S60 (PyS60):
import sysinfo
my_imei = sysinfo.imei()
my_imei = u"123456789012345"
My general approach to these kinds of things is do it in software.
Put the IMEI fetching code into one globally-accessible function, and only use this function for IMEI fetching.
#ifdef __WINS__ can be used in C++ code to selectively compile in the hard-coded IMEI you want to return in the emulator. In Java, you can probably tell you are in the emulator by other means (eg if the IMEI returned is a fixed weird value in the emulator), and act accordingly.
You can go one step further and have a dynamic IMEI. Once you do that, you will find that testing your code with different IMEIs becomes much easier.
I have never actually tried that but here's my best guess:
The emulator doesn't have a proper telephony implementation unless:
you link it to an actual phone over infrared/usb/serial. In which case the emulator telephony component will need configuration to use AT commands to pilot the phone (even if the phone isn't a Symbian phone). This allows you to make phone calls, send and receive SMS/MMS but certainly not change the IMEI.
you use the SIMTSY module. This is a component that uses configuration files to simulate telephony events. It can pretend to send SMS/MMS, pretend you are receiving a phone call...none of that actually creates any kind of network traffic, you understand. I assume the IMEI is in the configuration file but I don't expect you can properly change it without restarting the emulator. I have never seen SIMTSY used outside of Symbian itself so I don't know whether it is available to third-party developer. It should be open-sourced with the rest of the operating system within the next 2 years, though.
There is also the possibility that the way the SDK itself was built disabled most of the telephony framework for the emulator, using build-time macro. You should check http://forum.nokia.com

Resources