In this sample, we will create and deploy the proverbial 1st app, “Hello, world!” to any device running Windows 10 IoT Core.
Follow the instructions here to setup your device and PC.
Install Python for Windows (3.*) from http://www.python.org/downloads
Download and install PTVS (Python Tools for Visual Studio) VS 2015 latest release from here.
Download and install the latest Python UWP SDK (pyuwpsdk.vsix) release from here.
Template > Python > Windows 10 IoT Core > Background Application (IoT)
Modify StartupTask.py like this
Follow the instructions to setup remote debugging and deploy the app.
NOTE: For now, use device name in lieu of IP address. If the device name is not unique, use
setcomputername tool on the device to reset the device name and reboot. Documentation for this can be found here
The Python app will deploy and start on the device.
NOTE: Launching the debugger for Python can take a few minutes to connect and start debugging the remote Python. If it takes more than a few minutes, there may be a problem with msvsmon on the remote device. Please check the FAQ for any potential fixes/workarounds.
The ‘Hello, World from IoT!’ message will be displayed in the output window of Visual Studio. Open the output window by
Debug > Window > Output.
Right-click on the References node in the Python project
Click Add Reference…
Click on Browse tab
Download pywindevices content from here
Navigate to ARM for RPi2 or RPi3 or win32 for MBM
Select the PYD file for the device type and configuration you want to use (e.g. _wingpio_d.pyd if a Debug configuration and _wingpio.pyd for a Release configuration)
Add import _wingpio as gpio to your StartupTask.py
Start using gpio functions (similar steps for I2C or SPI)
WinDevices documentation can be found here
Please refer to the FAQ for issues.
Your session has expired. Please sign-in again to continue. Unfortunately any unsaved changes will be lost.