How to get started ? Share you development setup!
I decided to test developing for the PineTime using Microsoft Windows Subsystem for Linux (WSL).  This allows you to run Linux under Windows 10 without using a hypervisor or emulator like QEMU, VirtualBox or VMware, I ran my tests on a Microsoft Surface Pro 4.

Summary: Everything ran perfectly except for the most important part.  WSL could not access the STLink device to program the target device.  But there was a workaround.

The WSL feature is turned off by default so on Windows 10 you have to go into Settings - Apps - Programs and Features - Turn Windows Features On and Off. Click the checkbox for Windows Subsystem for Linux and OK.  After the restart I had WSL 1 installed.  Then you download and install the Linux version of your choice FROM THE MICROSOFT STORE.  I chose Debian ‘buster’.

Once Debian was installed I could open a special command prompt window and issue standard Linux commands. Linux graphics are not supported.

The Debian version supplied by Microsoft is quite lean.  A lot of the standard commands are not included.  In order to get an environment suitable for programming I had to use APT to install the following: git, make, unzip, bzip2, python, stlink-tools.  I also downloaded and installed the gcc-arm cross compiler and toolchain.

For testing I used a standard STLink V2 and an old STM32F103C8T6 ‘blue pill’ board I had available.  I downloaded FreeRTOS.  I built the standard ‘blink the LED’ program.  There were no problems building the bin file and performance was good. But then a serious problem appeared.

Debian could not see the STLink plugged into a USB port.  Windows could see it but Linux could not.  I found out that Linux under WSL can only access USB drives and similar devices but not other devices like the STLink.  A problem has been opened with Microsoft about this.

It is possible to get around this problem. Debian Linux provides a mount point /MNT/C which points to the Windows C: drive.  I copied the bin file created by the Linux build process to a Windows directory.  I then went into Windows and used the STM32 ST-LINK Utility from STMicroelectronics to program the bin file into the blue pill device.  Everything worked perfectly.

So, if you only have a Windows 10 system you can quite easily create a Linux environment to do developing for PineTime, with the only problem being you have to program the PineTime using Windows tools.

Messages In This Thread
RE: How to get started ? Share you development setup! - by VMMainFrame - 03-27-2020, 02:56 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Looking to sink my teeth in to development, but need a bit of direction. wilsonjholmes 4 50 08-12-2021, 07:52 AM
Last Post: wilsonjholmes

Forum Jump:

Users browsing this thread: 1 Guest(s)