A year ago, I wrote an UWP application that can generate QR Code. However, at that time, the QR Code library I used was ZXing.Net, the last update for this package was in 2014. Now, time has changed, the author of ZXing.Net seems not to update the package any more. However, we have to move on, so I found a fantastic new library to generate QR Code in .NET applications: QRCoder To use that package, …
There used to be a {x:Static Fonts.SystemFontFamilies} in WPF that can bind to system font list very easy. However, this is gong in UWP! How stupid it is!
These days I wrote a character map UWP application, that would use system fonts, so I did some research.
In order to get system font in UWP, we must use DirectX.
Install these 3 NuGet pacakges into your project:
"SharpDX": "3.0.1",
" …
A lot of people including me has encounter a problem where on UWP apps, if a ListView control is being data binded, it will get a default selected item like this: It not only will display as selected item, it also fires SelectionChanged event. However, if we want to make ListView clickable, a popular way is to write the SelectionChanged event handler like this: private void StationsList_ …
Starting from Windows 8, one big feature for Windows Store Apps is to share data using Charm Bar across Apps. Although the Charm Bar is removed in Windows 10, but the API for sharing is still in the fight. For example, in my "Image Portray" App, I can share ink to OneNote or Outlook. Today, I added same capability for my "Shanghai Metro" App. Here's how to do it. First, to share data across …
In many buildings, there are sound controlled light in use. When you clap your hands, the light turns on. Now, with Raspberry Pi 3 and Windows 10 IoT, we can make a sound controlled light ourselves.
The sound sensor I use is FC-04. As other sensors, the first step is calibration.
1. Calibration for FC-04 Sound Sensor
In quiet environment. Connect VCC to DC 3.3V,GND to Ground. At that time, the …
I bought a moisture sensor like this recently.
After some research, there seem no articles to indicate how to use it in Windows 10. So I figured out myself.
This sensor has 4 Pins, which are:
PIN
Usage
AO
Analog Out
DO
Digital Out
GND
Ground
VCC
Power
So, let's connect VCC to DC3.3v on RPi, I use PIN 01. Connect GND to any ground header, which I use …
I purchased a GY-30 light sensor recently, this model is also known as "BH1550FVI". There seems no sample for this sensor on Windows 10 yet, so I tried to make one.
The light sensor looks like this:
My board is a Raspberry Pi 3, the GPIO layout is shown in this table:
Because GY-30 is an I2C device, so we can not use GPIO to drive it directly, we must use the I2C ports. In addition, …