Windows 10 IoT Core UWP app proof-of-concept that works great with the Pimoroni Pan-Tilt HAT (PIC16F1503). The app is in a final state. No maintenance effort planned.
Service | Result |
---|---|
Continious integration | |
Static code analyse |
- Windows 10
- Visual Studio 2019
- Raspbbery Pi 3 (B) with Windows 10 IoT Core 17763 or higher
- Pimoroni Pan-Tilt HAT
- (optional) Webcam (Supported devices)
- (optional) Wired XBox 360 controller
- Pans
- Tilts
- Camera preview
- Take camera snaphots
- Follows detected faces
- Gamepad support
- Controls LEDs
Windows 10 IoT Core does not support the camera interface of a Raspberry Pi (CSI). I choose a Logitech CS270 HD Webcam (Amazon).
The casing had to be removed to make it light enough that the camera will be pan- and tilt-able by the servos.
The apps takes on button press snapshots of the current camera preview. The images will be stored in the Pictures library folder of the Windows 10 IoT Core system.
To access the images from another computer open the Device Portal Website and use the File explorer to download the images.
To detected faces, the app will use the built-in face detection feature of the Windows.Media.Core
package.
The media capture processing capabilities of a Raspberry Pi 3B seems to be not very performant. The detection is slow but works in good light condition.
According to the Microsoft Technet, Windows 10 IoT Core does not work well with the Bluetooth based XBox One gamepad.
The XBox 360 gamepad should work wired or using the Wireless receiver. The receiver lost the connection to the Pi after the app has been started. A USB-wired gamepad works as expected.
To assemble the LED strip I have to learn solidering first. I'll update the app after I earned this skill.
Connect all USB devices like the camera or the gamepad to the Pi. Check if all devices are listed at the dashboard "connected.
Start the app from the Device Portal's App Manager or via a Visual Studio debug deployed session.
This a is a learning project
This is a proof-of-concept app that's purely build for having fun! All features have room for improvements or could harm the hardware.
Auto. granted permissions and capabilities
The system will access your web camera, microphone and photo lib capabilities.
<Capabilities>
<Capability Name="internetClient" />
<uap:Capability Name="picturesLibrary"/>
<DeviceCapability Name="webcam"/>
<DeviceCapability Name="microphone"/>
</Capabilities>
Most of the HAT logic is based on the offical Python libraries.
- Reading of pan and tilt angles are (slightly) off the actual value.
- The servos sometimes start to buzz quite heavily.
- The webcam could flicker on the x, y middle.
- The gamepad could be interpreted as touch that selects buttons
- Connect to Azure IoT Hub
- Add Azure Blog Storage for uploading detected faces
Feel free to improve the quality of the code. It would be great to learn more from experienced C#, UWP and IoT developers.
Just me, Tobi.
- Pimoroni Discord Community
- Stackoverflow User michael-xu-msft
- Pimoroni Python source
This project is licensed under the MIT License - see the LICENSE file for details. Dependencies or assets maybe licensed differently.