Organize and Share your Electronics the way you want. Sign-Up for a free account now. It takes only 30 seconds!

Using PIC Forth

Using PIC Forth

If you program the PIC, there is one programming language that builds a simple idea into a powerful system and still gives you a great deal of control over your program: Forth.
You probably use assembly language. Assembly language is great because it gives you such control over the processor and its resources. Most high-level languages force you to compromise, and you wind up with bigger programs (which means fewer features on a chip with 4 or 8K of program space).

Forth isn’t new — it has been around seemingly forever. But it is extremely well-suited to small processors like the PIC.

I had started writing a Forth system for the PIC about a year ago. It wasn’t the first Forth I’ve written, and I did get a version of it working. However, I stumbled upon an open source project called PIC Forth (by Samuel Tardieu) that is based on the GNU gForth compiler. It was so amazing, I gave up on my pitiful Forth compiler.

Forth is a great language to run with our GPMPU28 or APP-II boards. It targets any 16F87x processor. It has plenty of features including two ways to write multitasking programs!

If you are running Linux, it is pretty simple to install gForth and PIC Forth following the instructions. If you are using Windows, just download the Windows binary for gForth (see the link to the left). The current Windows version is gforth-0.5.0.exe. Then you can simply grab gForth from its home page.

If you are using Cygwin (and if you are a Unix/Linux guy running Windows you HAVE to have Cygwin) the situation is a bit more complicated. You can grab the source distribution of gForth.

Visit Here for more.

 

More Articles to Read

Bus Pirate v3.8 free PCB build
Bus Pirate v3.8 free PCB build
App note: Testing inductors at application frequencies
App note: Testing inductors at application frequencies
1968 Princeton Reverb Repairs
1968 Princeton Reverb Repairs
Skill Sunday: Power Over Ethernet for Arduino
Skill Sunday: Power Over Ethernet for Arduino
More on Color TFT Displays ~ The Big Ones — 240 X 320
More on Color TFT Displays ~ The Big Ones — 240 X 320
Magnetic Rotary Encoder
Magnetic Rotary Encoder
Vertical Pole Climbing Robot
Vertical Pole Climbing Robot
ESP8266 Weather Station Projects
ESP8266 Weather Station Projects
Single tube Lethal Nixie clock
Single tube Lethal Nixie clock
How to make a simple 1 watt audio amplifier (LM386 based)
How to make a simple 1 watt audio amplifier (LM386 based)

Top




Shares