Develop a Windows Location Sensor in C# - c#

Hello fellow developpers,
I need to develop an application that would get geographical coordinates from different sources and then update the Windows system location with these. (These sources could be NMEA streams, web service, or even manual inputs).
If I understood correctly, based on what I read on the Microsoft website (here and here) and over the Internet, I would need to develop my own Windows sensor driver to update this location of the system.
The goal is then to use the very simple System.Device.Location.GeoCoordinateWatcher to obtain the system's position from any other application.
The documentation seems quite complete but does not contain any example. Because it is my first Windows sensor driver, I'm completely lost on how and where I should begin.
Any clues on this that could help me getting started ?
C# would be great but C/C++ would obviously do it perfectly

Related

How to forward output of a directshow app(C++) to a C# app?

I am making a C# app to capture graphic from an avermedia pcie capture card.
But it seems that there are no out of box tools to do so.
So I made a C++ directshow app to do the capture, which is a console app and opens a capture window when running.
How can I redirect the output to a C# app? for example, to a CaptureElement?
So you want to have XAML CaptureElement connected to AverMedia PCIe capture card. This sounds like a well-understood challenge overall, however every other piece of technology you mentioned is eventually a bad choice: DirectShow, multiple apps with piping, redirection and fitting of cutsom code to XAML CaptureElement control.
Microsoft has intentionally been limited ways you can integrate different APIs and so there are not so many ways to get everything together.
Let us go over the supposed integration path. The capture card is supposed to be shipped with a compatible driver:
Video capture devices are supported through the UVC class driver and must be compatible with UVC 1.1
When this is the case, such devices are visible to Media Foundation API handling video capture among tasks. XAML CaptureElement would be able to see a video capture device through this API and this way everything is supposed to work without need to fit anything from your end.
If this is not happening, it suggests you are dealing with an unsupported device coming without suitable or compatible driver.
Previous media API in Windows was DirectShow but its days are gone. It remains perfectly working as a legacy framework, a lot of applications out there are still relying on it. Specifically it will not integrate with new technology like XAML and UWP. More to that, even Media Foundation itself, the current media API, in its public offering is lagging behind when it comes to fitting with most recent technology. Having said that it is a good idea to stay well clear of DirectShow here if this is at all possible.
I see no need for cross-process design with video travelling between process through piping. There is no good reason for such design and even though this can work efficiently (Windows itself proves it can work great in terms of performance by having so called Frame Server service in it), this is not to be built on piping. In your case it is unlikely to be have to be built on multiple processes either. Instead you can develop a native code DLL project that takes care of video acquisition and connects to managed code via suitable glue layer: C++/CLI, COM, C++/WinRT and such.
Then next thing is fitting to XAML CaptureElement. The control is designed to work with Windows.Media.Capture.MediaCapture class that talks to hardware and you don't have suitable hardware as you plan to implement your own acquisition layer. Long story short you are not supposed to forward external data to CaptureElement and you would have hard time doing this. Your best strategy is to upload externally obtained data to Windows.Graphics.Imaging.SoftwareBitmap or alike and take involved performance impact as acceptable. That is, you will be dealing with video frames as images.
An alternative way is to upload acquired video frames into Direct 3D 11 textures and it would open you a more performant way of integration with video related controls, such as Windows.UI.Xaml.Controls.SwapChainPanel however it would also require that you put much more development effort in there.

How to access camera on a windows tablet or attached web cams using Windows Form Application (Not WPF)?

I am trying to develop a Windows Form Application (not WPF) where I would require to preview numbers of cameras available on a tablet or PC, take pictures and then save the pictures in the device.
I am very new to this kind of application development and recently came accross Media Capture but I can not find a good lead to start with.
Can anyone let me know how to approach or how can I build the application with the aforementioned features or provide a good lead??
P.S. Found a good example on https://code.msdn.microsoft.com/windowsapps/media-capture-sample-adf87622/ but it uses XML not the Win Form Application type.....
What kind of cameras do you have? If the cameras support onvif, then there is a good onvif camera software you could try. You can handle many cameras with it, you can take snapshots so I guess it could work for you.

Does Windows 8 Has The Ability To Read/Write NFC Tags?

I've tried downloading and deployed the Proximity Sample Code link. But i'm unable to do anything with regards to NFC.
Then i did a search on YouTube and found this. Is this even NFC? From what i know, NFC stands for Near Field Communication and typically, they can only receive/transmit data when the tag/device is of close proximity (1-2 cm away).
I'm using an SCL3711 hardware. I've tried using running the Sample Code provided by the hardware maker - IDENTIVE. It works alright if i'm creating a WPF project. Some classes don't exist on WindowsRT (In particular, System.Windows.Form.Message).
All i need is an application that can develop a Windows 8 (Windows Store) application that is able to read and write data to an NFC tag. Any help is appreciated.

Suggestion on geoloaction and application type

I'm trying to make a program using c# that will allow me to determine where a computer of mine is located using geolocation services. I was wondering what you would suggest as far as geolocatio APis go and whether you think i should just make a background process or a windows service or if it is even possible to make it a service. I've heard of one by w3c, google, windows, and skyhook. I'm hoping to be able to determine an address from it and I was also hoping that the service would be free (even if its only for a few look-ups a day.
Thanks for the help!
I'm not really clear why you're asking about background process or Windows service. You application will not be able to get the location of the computer from services like google.
I suggest you install the Geosense driver for Windows 7 to add a Location driver (see http://geosenseforwindows.com/ ) I would then use something like the Location and Sensor interop library to query that sensor to find the rough location of the computer. (see http://archive.msdn.microsoft.com/SensorsAndLocation/Release/ProjectReleases.aspx?ReleaseId=2359)
If that's not what you we wanting to do; please provide more information.

how i use WP7 mobile in wireless-based indoors positioning system?

can I use WP7 mobile in wireless-based indoors positioning system (i.e WIFI-based positioning system inside a building) ?
and if i can .. what about the type of map (for example vector map )
all of this in WP7 ..can I ?
It is likely to be very difficult to do this accurately with the current API.
There is only very little network information available to your application (see http://msdn.microsoft.com/en-us/library/k056bfdz(v=VS.95).aspx)
One of the aims of the WP7 SDK/API was to make working with location simpler. This is why location information has been abstracted away behind the GeoCoordinateWatcher. This is not designed for providing location based purely on (private) WiFi network information.
If you are trying to develop an application that must be able to interact closely with wireless networks then WP7 is currently not an appropriate platform for doing this.

Categories

Resources