Detailed Instructions
First Steps
The easiest way is probably to run "make clean" from within the FURS project directory, Then run "make" and see if you have any errors or warnings.
Any errors probably mean that some dependency is missing or not installed, or it's a bug I'm not aware of, in which case a detailed email will get it fixed.
All Good, what happened ?
- "make clean" removed all non essential project files.
- "make" recreated them.
- The finished product is upload.fs. This is the file that is uploaded to the MCU.
Explore the Digital Thermometer project and files, compare them to the FURS output ?
Because FURS is still Beta software, several intermediate files are generated to assist bug analysis. They are:
bitfields_out.fs constants_out.fs intermediate_out.fs registers_out.fs stm32f051.abs.svd stm32f051.cleaned.svd stm32f051.unfolded.svd database.data
Everything is controlled by the Makefile
The following Makefile lines are the only parts you will need to change to suit your own project.
- SVD: This is the first Makefile line, change it to suit your STM32xx MCU. There must be a stm32f051.svd file in the project root directory
MCU = stm32f051
Project Files: Dependencies must be declared before they are needed, in the usual Forth manner. These files are concatenated and processed by FURS when 'make' is run.
PROJ_FILES= src/sys.fs src/gpio.fs src/leds.fs src/comparator.fs src/pulse.fs src/main.fs
Change these files to your project file names.
FURS Output File
- upload.fs - this is the output of FURS. From here you upload it to the MCU using your preferred method, i.e. Swdcom, ascii terminal, python uploader etc
Summary
That's it really, nothing more to do. You develop your project, writing code, running make, testing with the REPL, fixing errors and repeating until it's finished in the usual Forth way.Coding Your Project
While writing your project, you will require a searchable list of all the cmsis Words to access the peripherals in your mcu.The CMSIS-SVD Reader is included in the project root.
Future FURS Development
I've developed a Neovim pop-up database reader, but it won't work under NixOS which I'm currently running so it's not included as yet. Plus it needs to be converted from Plang2 to FURS. Here is the screenpic of that application also running the Neovim terminal with an active Forth session.