Releases: lupyuen/stm32bluepill-mynewt-sensor
Apache Mynewt Sensor App for STM32 Blue Pill with Quectel NB-IoT BC95-G (Windows Build)
Refer to the instructions here...
https://medium.com/@ly.lee/install-apache-mynewt-on-windows-7f5fea9a02dd
newt\newt.exe
was built for Windows from
Prerelease: Apache Mynewt Sensor App for STM32 Blue Pill with Quectel NB-IoT BC95-G (Windows Build)
-
Download the
.7z
file attached below -
Expand the
.7z
file with 7zip:
https://www.7-zip.org/download.html -
Install Arm Cross-Compiler and Linker for Windows from Arm Developer Website:
https://developer.arm.com/-/media/Files/downloads/gnu-rm/8-2019q3/RC1.1/gcc-arm-none-eabi-8-2019-q3-update-win32-sha1.exe?revision=fcadabed-d946-49dc-8f78-0732d2f43773?product=GNU%20Arm%20Embedded%20Toolchain,32-bit,,Windows,8-2019-q3-update -
Download the ST-Link USB driver from ST-Link Driver Website (email registration required):
https://www.st.com/en/development-tools/stsw-link009.html -
Click
Get Software
Unzip the downloaded file. Double-click the driver installer:
dpinst_amd64.exe
-
Install Windows Studio Code:
https://code.visualstudio.com/ -
Launch Visual Studio Code
-
Install the extension "Cortex-Debug":
https://marketplace.visualstudio.com/items?itemName=marus25.cortex-debug -
Click
File → Open Folder
. Select the downloaded folderstm32bluepill-mynewt-sensor
. When prompted to open the workspace, clickOpen Workspace
-
Click
Terminal → Run Task → [1] Build bluepill_boot
-
Click
Terminal → Run Task → [2] Build bluepill_my_sensor
-
Click
Terminal → Run Task → [3] Image bluepill_my_sensor
-
Click
Terminal → Run Task → [4] Load bluepill_boot
-
Click
Terminal → Run Task → [5] Load bluepill_my_sensor
newt\newt.exe
was built for Windows from
https://github.com/lupyuen/mynewt-newt
mynewt-jetson: microSD Card image for Nvidia Jetson Nano
Complete source code and tools for building Mynewt for STM32 Blue Pill, packaged as a bootable microSD card for Nvidia Jetson Nano. The code is described in the third article of the series...
Build Your IoT Sensor Network — STM32 Blue Pill + nRF24L01 + ESP8266 + Apache Mynewt + thethings.io
-
Download the 6-part (5.5 GB) 7zip archive:
*7z.001
,*7z.002
, ... -
Run
7zip
orKeka
to expand the archive into a 30 GB microSD image filemynewt-jetson.img
-
Launch SD Memory Card Formatter for Windows or Etcher (for macOS) to write the image file
mynewt-jetson.img
into a 32 GB UHS-1 microSD card (or larger) -
Insert the microSD card into Jetson Nano and power on. Wait for the desktop to appear.
-
Source code is located in
/opt/mynewt
, based on Mynewt 1.6.0 -
Run
code-oss
(or click the icon at top left with the horizontal lines) to launch Visual Studio Code. Open the folder/opt/mynewt
-
To build, look for the Task Runner at the lower left corner. Click
Clean
, thenBuild bluepill_boot
, thenBuild bluepill_my_sensor
-
Visual Studio Remote SSH is NOT supported on Arm64
-
Excludes Rust support
-
SSH is enabled for hostname
jetson.local
...
User:user
Password:password
For example:ssh user@jetson.local
-
Operating system is Ubuntu 19.04, instead of the default 18.04 bundled with Jetson Nano
-
The installed image only uses 32 GB of the microSD card. Run a partitioning tool like
gparted
to expand the partition to fill up the entire microSD card -
Script used to generate this image:
Disable screensaver, screen timeout
# Install open-source build of Visual Studio Code
wget -qO - https://packagecloud.io/headmelted/codebuilds/gpgkey | sudo apt-key add -
sudo -s
. <( wget -O - https://code.headmelted.com/installers/apt.sh )
exit
sudo apt autoremove -y
# Install Mynewt
sudo mkdir /opt/mynewt
sudo chown user:user /opt/mynewt
git clone https://github.com/lupyuen/stm32bluepill-mynewt-sensor /opt/mynewt
cd /opt/mynewt
chmod +x scripts/*.sh
./scripts/install-arm.sh
Apply fixes from
https://gist.github.com/lupyuen/bbc2dae52a8fdac1e70a60757fed1467
newt build -v bluepill_boot
newt build -v bluepill_my_sensor
newt size -v bluepill_my_sensor
# Install Task Runner Extension for VSCode
# Allow upgrade Ubuntu to 19.04
sudo nano /etc/update-manager/release-upgrades
Change to "Prompt=normal"
# Upgrade to Ubuntu 18.10
sudo do-release-upgrade
When prompted to overwrite changed config files, enter Y
# Upgrade again to Ubuntu 19.04
sudo do-release-upgrade
Enable auto login
# Fix font antialiasing for 4K displays
Launch Gnome Tweak Tool
Set "Fonts -> Antialiasing" to "Greyscale"
Install gparted
# Download the Official NVIDIA Jetson driver package
sudo apt install binfmt-support qemu qemu-user-static debootstrap -y
cd /tmp
wget https://developer.nvidia.com/embedded/dlc/l4t-jetson-driver-package-32-1-jetson-nano
mv l4t-jetson-driver-package-32-1-jetson-nano l4t-jetson-driver-package-32-1-jetson-nano.tar.bz
tar -xvf l4t-jetson-driver-package-32-1-jetson-nano.tar.bz
sudo mv Linux_for_Tegra /opt
sudo chown user:user /opt/Linux_for_Tegra
mkdir /opt/Linux_for_Tegra/rootfs/etc/
cp /etc/nv_tegra_release /opt/Linux_for_Tegra/rootfs/etc/
# Prepare to create image for SD card. Remove files from last session
sudo rm /opt/Linux_for_Tegra/bootloader/system.img
sudo rm /opt/Linux_for_Tegra/bootloader/system.img.raw
sudo rm -r /opt/Linux_for_Tegra/rootfs/*
# Create image for SD card (based on https://gglabs.us/node/2060).
# Need to exclude the "sys" subfolders individually because "/opt/mynewt/repos" also contains a sys folder.
# Excluding absolute paths "/sys/.." does not work.
cd /
sudo rm /tmp/root.tar
sudo tar \
--exclude='proc/*' \
--exclude='sys/block' \
--exclude='sys/bus' \
--exclude='sys/class' \
--exclude='sys/dev' \
--exclude='sys/devices' \
--exclude='sys/firmware' \
--exclude='sys/fs' \
--exclude='sys/kernel' \
--exclude='sys/module' \
--exclude='sys/power' \
--exclude='dev/pts/*' \
--exclude='tmp/*' \
-cpf /tmp/root.tar \
bin boot dev etc home lib media mnt opt proc root run sbin srv sys tmp usr var
# Expand into staging area.
cd /opt/Linux_for_Tegra/rootfs
sudo tar -xpf /tmp/root.tar
# Create image from staging area.
cd /opt/Linux_for_Tegra
sudo rm /tmp/mynewt-jetson.img
sudo ./create-jetson-nano-sd-card-image.sh -o /tmp/mynewt-jetson.img -s 28G -r 200 >create.log 2>&1
[DRAFT Ubuntu 18.04] mynewt-jetson: microSD Card image for Nvidia Jetson Nano
Complete source code and tools for building Mynewt for STM32 Blue Pill, packaged as a bootable microSD card for Nvidia Jetson Nano. The code is described in the third article of the series...
Build Your IoT Sensor Network — STM32 Blue Pill + nRF24L01 + ESP8266 + Apache Mynewt + thethings.io
-
Download the 6-part (5.2 GB) 7zip archive:
*7z.001
,*7z.002
, ... -
Run
7zip
orKeka
to expand the archive into a 16 GB microSD image filemynewt-jetson.img
-
Launch SD Memory Card Formatter for Windows or Etcher (for macOS) to write the image file
mynewt-jetson.img
into a 16 GB UHS-1 microSD card (or larger) -
Insert the microSD card into Jetson Nano and power on. Wait for the desktop to appear.
-
SSH is enabled for hostname
jetson.local
...
User:user
Password:password
For example:ssh user@jetson.local
-
Source code is located in
/opt/mynewt
, based on Mynewt 1.6.0 -
Includes open-source version of Visual Studio Code for Arm64. Enter
code-oss
to launch Visual Studio Code, open the folder/opt/mynewt
-
Visual Studio Remote SSH is NOT supported on Arm64
-
Excludes Rust support
-
Operating system is Ubuntu 18.04. To upgrade to Ubuntu 19.04:
# Allow upgrade Ubuntu to 19.04
sudo nano /etc/update-manager/release-upgrades
Change to "Prompt=normal"
# Upgrade to Ubuntu 18.xx
sudo do-release-upgrade
When prompted to overwrite changed config files, enter Y
# Upgrade again to Ubuntu 19.04
sudo do-release-upgrade
- Script used to generate this image:
Disable screensaver, screen timeout
# Install open-source build of Visual Studio Code
wget -qO - https://packagecloud.io/headmelted/codebuilds/gpgkey | sudo apt-key add -
sudo -s
. <( wget -O - https://code.headmelted.com/installers/apt.sh )
exit
sudo apt autoremove -y
# Install Mynewt
sudo mkdir /opt/mynewt
sudo chown user:user /opt/mynewt
git clone https://github.com/lupyuen/stm32bluepill-mynewt-sensor /opt/mynewt
cd /opt/mynewt
chmod +x scripts/*.sh
./scripts/install-arm.sh
Apply fixes from
https://gist.github.com/lupyuen/bbc2dae52a8fdac1e70a60757fed1467
newt build -v bluepill_boot
newt build -v bluepill_my_sensor
newt size -v bluepill_my_sensor
# Install Task Runner Extension for VSCode
# Download the Official NVIDIA Jetson driver package
sudo apt install binfmt-support qemu qemu-user-static debootstrap -y
cd /tmp
wget https://developer.nvidia.com/embedded/dlc/l4t-jetson-driver-package-32-1-jetson-nano
mv l4t-jetson-driver-package-32-1-jetson-nano l4t-jetson-driver-package-32-1-jetson-nano.tar.bz
tar -xvf l4t-jetson-driver-package-32-1-jetson-nano.tar.bz
sudo mv Linux_for_Tegra /opt
sudo chown user:user /opt/Linux_for_Tegra
mkdir /opt/Linux_for_Tegra/rootfs/etc/
cp /etc/nv_tegra_release /opt/Linux_for_Tegra/rootfs/etc/
# Remove files from last session
sudo rm /opt/Linux_for_Tegra/bootloader/system.img
sudo rm /opt/Linux_for_Tegra/bootloader/system.img.raw
sudo rm -r /opt/Linux_for_Tegra/rootfs/*
# Create image for SD card (based on https://gglabs.us/node/2060)
cd /
sudo rm /tmp/root.tar
sudo tar \
--exclude='proc/*' --exclude='sys/*' --exclude='dev/pts/*' --exclude='tmp/*' \
-cpf /tmp/root.tar \
bin boot dev etc home lib media mnt opt proc root run sbin srv sys tmp usr var
cd /opt/Linux_for_Tegra/rootfs
sudo tar -xpf /tmp/root.tar
cd /opt/Linux_for_Tegra
sudo rm /tmp/mynewt-jetson.img
sudo ./create-jetson-nano-sd-card-image.sh -o /tmp/mynewt-jetson.img -s 15G -r 200 >create.log 2>&1
Ubuntu VirtualBox with Source Code and Build Tools
Complete source code and tools for building Mynewt for STM32 Blue Pill, packaged as Ubuntu 19.04 (64-bit) VirtualBox. The code is described in the third article of the series...
Build Your IoT Sensor Network — STM32 Blue Pill + nRF24L01 + ESP8266 + Apache Mynewt + thethings.io
-
Download the 4-part (3.4 GB) 7zip archive:
*7z.001
,*7z.002
, ... -
Run
7zip
orKeka
to expand the archive into an 8.57 GB VirtualBox -
SSH is enabled for hostname
ubuntu1904.local
...
User:user
Password:password
For example:ssh user@ubuntu1904.local
-
Source code is located in
/opt/mynewt
, based on Mynewt 1.6.0 -
Includes Visual Studio Code for Ubuntu. Enter
code
to launch Visual Studio Code, open the folder/opt/mynewt
-
You may also use Visual Studio Code for Windows or Mac and connect to the VirtualBox with the Remote SSH Extension:
-
On Windows or Mac, launch Visual Studio Code and install the Remote SSH Extension
-
Click
View → Command Palette → Remote SSH: Connect To Host
-
Enter
user@ubuntu1904.local
. Password ispassword
-
Select the folder
/opt/mynewt
Remote build works OK, but remote debugging not yet tested. Watch the video: https://youtu.be/CI2VSZkZYaI
-
-
Excludes Rust support
-
Script used to generate this image:
sudo mkdir /opt/mynewt
sudo chown user:user /opt/mynewt
git clone https://github.com/lupyuen/stm32bluepill-mynewt-sensor /opt/mynewt
cd /opt/mynewt
./scripts/install-linux
Apply fixes from
https://gist.github.com/lupyuen/bbc2dae52a8fdac1e70a60757fed1467
newt build -v bluepill_boot
newt build -v bluepill_my_sensor
newt size -v bluepill_my_sensor