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

App note: EPIC: Electro-Pyrotechnic Initiator Chip Resistor
App note: EPIC: Electro-Pyrotechnic Initiator Chip Resistor
App note: Noise analysis for high-speed op amps
App note: Noise analysis for high-speed op amps
Skill Sunday: Arrays
Skill Sunday: Arrays
App note: Infrared remote control implementation with MSP430FR4xx
App note: Infrared remote control implementation with MSP430FR4xx
Gesture Controlled Smart Home
Gesture Controlled Smart Home
Design for a Wideband, Differential Transimpedance DAC Output
Design for a Wideband, Differential Transimpedance DAC Output
Wrist thrusters let you fly through the water effortlessly
Wrist thrusters let you fly through the water effortlessly
Bertan/Spellman 225-20R HV power supply teardown
Bertan/Spellman 225-20R HV power supply teardown
Blinking Christmas Lights
Blinking Christmas Lights
Adjusting clock with alarm, hygrometer & thermometer on 1.8″ ST7735 display
Adjusting clock with alarm, hygrometer & thermometer on 1.8″ ST7735 display
Adding an “extra sense” with rangefinders
Adding an “extra sense” with rangefinders
This wireless game controller looks like a rug
This wireless game controller looks like a rug
How to run your ESP8266 for years on a battery
How to run your ESP8266 for years on a battery
Calibration of a 3-Phase Energy Meter Board on the ADE7754
Calibration of a 3-Phase Energy Meter Board on the ADE7754
Making beats on a tiny Arduino DJ controller
Making beats on a tiny Arduino DJ controller
Qinsi-QS5100 Sn63Pb37 solder profile
Qinsi-QS5100 Sn63Pb37 solder profile
Water Detection System
Water Detection System
Professional Hi-Fi 15W Tube Amplifier circuit
Professional Hi-Fi 15W Tube Amplifier circuit
This Arduino machine will judge how sick your ollies are
This Arduino machine will judge how sick your ollies are
Turn an old payphone into a boombox for ’90s hits
Turn an old payphone into a boombox for ’90s hits

Top


Shares