Scamp – A self-contained Forth computer
udamonic.com
udamonic.com
Very recently I just wanted to speak some SPI to some RF IC on a breakout board. I narrowed down the quickest options to this:
* Use my UM232H (FTDI FT232H dev board) to do SPI from my Mac. Dismissed pretty quickly, since I did not feel like dealing with the drivers and FTDI library.
* Boot Linux on one of my FPGA/ARM combos and hope that the generic SPI driver also exposes itself to user space, so that I can just pipe my data on the shell using xxd -r to /dev/spi-foo or whatever. But even if the case, I had to probably at least mess with the device tree to get the I/O pins assigned (and boot Linux, and have the proper tools).
* Use the Arduino Uno that I got as a gift, but never used so far, and either use its SPI library or hope someone made a "Sketch" already that I could just paste.
In the end, the last option won out, because someone actually had made a Sketch already that I could literally just paste and run.
But that was kind of lucky. I feel like such a self-contained Forth computer that is always ready to accept some Forth (instead of having to mess with a C toolchain) could make tasks like this super quick and simple, with flexibility.
Experiences?
I wish I could knuckle down and figure out #1, or, how to get Python talking through one of those FTDI USB->GPIO/I2C/SPI/UART/kitchenSink chips in a way that works in between OS reformats.
https://www.raspberrypi.com/documentation/microcontrollers/m...
It's a USB-connected Swiss army knife of embedded electronics access-enabling fun. Really really recommended for anyone who has ever had a similar need.
It's by Dangerous Prototypes [2] but I linked to AdaFruit since it's one of the recommended retailers, their site is good, and so on. There is a legendary 4.x version "in the works", but ignore that and get the 3.x if you need to get work done.
I'm theorizing that it's just too difficult to built such a stack in Forth for a hobbyist to have reasonably done. And that's a bit of a letdown of course. I really would like Forth to be able to have system libraries for networking etc., but the language philosophy is not helping here.
The good news is that by some definition, bare-bones could mean 'developed on RTOS', where the TCP stack is implemented (in C, I think) in the low level OS. 1-9-9-1.com shows that it's possible/not too hard to implement a software stack on top of sockets.
Sixteen registers? I wonder what do use those for in their Forth? https://udamonic.com/uploads/1/2/1/3/121343112/scamp2-ff-uda... mentions a “p register” and an “a register”, but they must have lots of unused ones.
Certainly you could make your own for cheaper, but then... you wouldn't need their system and could just put FlashForth on your chip yourself.