Building the NanoVNA - Source in Ubuntu 19.04
Hi
This will be a guide to building the NanoVNA source code from a fresh Ubuntu machine.
First off, we need git.
In a terminal window run the following:
sudo apt-get install git
Following the guide available on GitHub we generate and add an ssh key:
ssh-keygen -t rsa -b 4096 -C "your_email@domain.com"
eval "$(ssh-agent -s)"
ssh-add ~/.ssh/id_rsa
We need to copy this key to the clipboard with xclip:
sudo apt-get install xclip
xclip -sel clip < ~/.ssh/id_rsa.pub
Login to GitHub to add ssh key:
Click the green New SSH Key button
Give it a Title and paste the copied key in this window
Once that is done we can add some prerequisites:
In a terminal window run the following:
wget https://developer.arm.com/-/media/Files/downloads/gnu-rm/8-2018q4/gcc-arm-none-eabi-8-2018-q4-major-linux.tar.bz2
sudo tar xfj gcc-arm-none-eabi-8-2018-q4-major-linux.tar.bz2 -C /usr/local
PATH=/usr/local/gcc-arm-none-eabi-8-2018-q4-major/bin:$PATH
sudo apt install -y dfu-util
Once that's dusted off we can clone the repo :
In a terminal window run the following:
git clone https://github.com/ttrftech/NanoVNA.git && cd NanoVNA
git submodule update --init --recursive
Type yes when asked
If you see something like this
Submodule path 'ChibiOS': checked out '669d4bbc8da1ee0e4ccdf93a472b06d183922320'
All is good!!!
Build the library with:
make
That's a successful build right there!
Flash by setting the device to DFU boot, either in software or by short of pins :
Update :
Short the two pins in the red circle with the device powered off, then with the pins shorted power on the device.
This will enter DFU mode, with a blank white screen.
The device can now be flashed.
Software Reset to DFU
Then to flash:
make flash
This is what to expect when flashing the device.
Windows Flashing:
For conversion to dfuse dfu file format for Windows flashers:
In the ubuntu terminal still:
dfu-tool convert dfuse ./build/ch.hex test.dfu
Set PID, VID:
dfu-tool set-product test.dfu df11
dfu-tool set-vendor test.dfu 0483
Experimental build from a branch that enables Time Domain Stuff
Added menu items
Hopefully, this will help some folks get to building the firmware of this device.
Kind Regards
Ohan
ZS1SCI
Comments
Comments are closed