FiveForths

32-bit RISC-V Forth for microcontrollers

  • Devlog 39 Release V04 Toggling Leds

    January 23 Log 39 Release v04 Toggling LEDs Closing thoughts Log 39 In this session I’ll discuss the latest release which includes handling HEX numbers and manipulating hardware. Release v04 One of the major obstacles to working with hardware was the lack of support for hexadecimal numbers. That is, inputting...

  • Devlog 38 Release V03

    January 19 Log 38 Release v03 Bug fixes Enhancements Closing thoughts Log 38 In this session I’ll discuss the bugs I fixed, some enhancements, and documentation for FiveForths. Release v03 In release v0.3 I made quite a few changes, most importantly is regarding documentation, so let’s start there. A new...

  • Devlog 37 A Release Or Two

    January 10 Log 37 A release or two Why so much work Closing thoughts Log 37 In this session I’ll discuss the latest changes I’ve made to the source code, and provide information on the releases. A release or two In the last day I’ve published 2 releases to GitHub....

  • Devlog 36 From Dtc To Itc

    January 07 Log 36 From DTC to ITC Cleaning up lookup Closing thoughts Log 36 In this session I fix a few bugs which made me switch threading mode. From DTC to ITC In devlog 29 I mentioned my goal of implementing this Forth as a Direct Threaded Code (DTC)...

  • Devlog 35 Compiling Words Pt2

    January 06 Log 35 Compiling words pt2 Done Closing thoughts Log 35 In this session, I actually plan on fixing compilation and getting to DONE! Compiling words pt2 I decided to step through the execution of a compiled word: dup using GDB. The first problem I noticed was the indirect...

  • Devlog 34 Compiling Words

    January 06 Log 34 Printing strings Rebooting the MCU Compiling words Closing thoughts Log 34 In this session I will work on compiling words, but before that I want to add 2 new features to my Forth: printing strings and rebooting the mcu. Printing strings The previous approach to printing...

  • Devlog 33 Storing Numbers

    January 05, 2023 Log 33 Storing numbers Closing thoughts Log 33 I know I promised I would get to compile words, but that’s hard so instead in this session i’ll add the ability to store numbers on the stack. Once that works then I’ll get to compiling words hahaha. Storing...

  • Devlog 32 Fixing Bugs

    January 04, 2023 Log 32 Fixing DSP Fixing macros Fixing primitives Closing thoughts Log 32 In this session I’ll focus on fixing some bugs I discovered with the data stack. Fixing DSP In devlog 2, I introduced the idea of a TOS (top of stack) register. It’s not new to...

  • Devlog 31 Interpreting Words

    January 04, 2023 Log 31 Reviewing token Interpreting words Closing thoughts Log 31 In this session I’m going to review the token function from src/05-internal-functions.s before reviewing the interpreter in file src/09-interpreter.s. Reviewing token In my token function, I read characters backward from TOIN to the start of the word....

  • Devlog 30 Cleanup

    January 02, 2023 Log 30 Cleanup Closing thoughts Log 30 I can’t seem to find my way through fiveforths.s anymore. The file has grown to over 700 lines and even with a good text editor I have trouble finding stuff. In this session I’ll split things into various files to...