Martin + others. Please review my notes below for accuracy and completeness. I can update with further information as required.
Once it looks good, I can upload it as a file to Groups.io file syste.
Lane, VE7IHL
The following is notes made by Lane and Martin, that describes how to compile the tinySA firmware under a Windows 10 environment.
It also describes the software tools needed to perform the compile. This information was written up on Dec. 15, 2022.
Compiling from source code (using Git) on Windows 10
Using the Mingw64 Git Bash shell, in the drive folder you wish to hold the tinySA source code, do the following git / GitHub commands. This provides and easy cold start:
git clone?
cd tinySA
git checkout V4.3
git pull
git submodule update --init ¨Crecursive
Now you're almost ready to start, this would build the latest firmware, but with a wrong version number ¨C don¡¯t know why, neither does Erik. The Make file uses the command "git describe" to get a version number like "v1.3-nnn-gxxxxxxx", where "v1.3" is the latest tag, "nnn" is the number of commits since this tag and "xxxxxxx" is the unique git commit hash. Without the trick below, it gives a wrong nnn, but xxxxxxx is correct, but the short version on the left margin is "1.3nnn".
Temporary fix for wrong version number (do this once)
git tag -d v1.3
git tag -a -m v1.3 v1.3 12a96bb
Now the nnn is in sync with Erik.
To build tinySA firmware you can type:?
make
To build tinySA Ultra firmware you can type:
make TARGET=F303
This should produce the *.bin *.hex and *.elf in directory build. ARM GCC toolchain 11.x will work, you can also use 8.x and Erik's builds are still on 7.x, so it should work without an issue.
With every new version that Erik puts on GitHub you should do a new:
make clean? ?? or???????? make TARGET=F303 clean
git pull
and you can start again.
If you want to make your own changes etc. you should create a new branch with:
git checkout -b MyNewFeature
You will then be on your new branch.
The easiest way to find out where (and which branch) the latest code is? The development branch is currently "V4.3" since quite a long time, unfortunately Erik's default branch is still on "master". So, you should always look at:
Firmware Compile Tools Required
1.)??? ARM GNU Tools
2.)??? MinGW tools
Getting/Installing the ARM GNU Tools:
Go to click on Download to download the ARM GNU toolchain installer. As of Dec 15, 2022, recommend using the 11.3Rel1 installer. Newer versions may work as well.
Arm-gnu-toolchain-11.3.rel1-mingw-w64-i686-arm-none-eabi.exe
Download the installer and run it installing the files into the default locations.
Getting/Installing MinGW tools:
There does not appear to be a single/simple method of installing the MinGW tools. The MinGW tools are required to provide the ¡°make¡± tool used to build the tinySA firmware. There are multiple sources and ways to do this. Download and then using the ¡°mingw-get-setup.exe¡± tool from SourceForge. It will then download the next level installer allowing you to download the parts of the MinGW package you need. ?This is just one method, MinGW is contained within other software development tool too.
Obtain WinGW Get Installer from SourceForge:
?
Run the mingw-get-setup.exe to get MinGW installer:
When running the MinGW installer, you only need the "minw32-base" package. Recommend that you install the MinGW files into a high-level folder on your PC such as: C:\MinGW
?
See various tutorials: (There are lots)
https://www.ics.uci.edu/~pattis/common/handouts/mingweclipse/mingw.html
https://www.youtube.com/watch?v=sXW2VLrQ3Bs&ab_channel=ProgrammingKnowledge2
https://www.geeksforgeeks.org/installing-mingw-tools-for-c-c-and-changing-environment-variable/
https://www.youtube.com/watch?v=Zcy981HhGw0&ab_channel=SemicolonDotDev
https://www.youtube.com/watch?v=dRxPUblx2SY&ab_channel=AnielMaharajh
?
Last step is to run the Windows Environment variable tool: Windows->Settings->Advanced System Settings->Environment Variables. Using this tool, you will need to add to the PATH environment variable, either user or System variables, the path that you used when you installed the MinGW tools. The example above shows the path as C:\MinGW
Run this command from the Mingw64 Git Bash shell:
Make --version
Ensure that it runs and displays the current version number of the make tool. If this does not work, then check the .bashrc file in your windows home folder (Typically look in C:\Users\<Your_Login_Name>) and make sure it contains this line:
alias make=mingw32-make.exe
?