Engin_clear_dot.gif (49 bytes)

PicBasic Pro/PicBasic Editors

*** NEW Version ***  PicMate now supports the Pro & Standard Versions of PicBasic *** NEW Version ***

A BIG thanks to John Cole of Creative Contraptions Inc. for these new PicBasic Pro & PicBasic Editors.

Probably one of the most time consuming routines you'll encounter when using the picbasic compilers is the constant switching back-and-forth between the editor & EPIC programming software.

With a good editor capable of launching the picbasic compiler, and the EPIC programming software, the time you save can really add-up quickly.  Johns editors are extremely simple to use, and can save you countless hours during the design & debugging phase when using picbasic.

We have tested Johns editors for picbasic pro and picbasic, and quickly trashed our old version of the programmers file editor.  Johns editor is much simpler, considerably faster, and can be setup in just a matter of minutes. The programmers file editor is still an excellent editor, but PicMate is much easier to setup & use.

Here's a screen capture of the PicMate Pro Editor:

Notice the lower section of the editor screen.  The results of each compiler session are shown in this lower window to indicate success or errors during compile-time.

When you first install PicMate you'll need to setup your preferences.  Your preferences will automatically be loaded each time you start PicMate after the initial set-up.

Note: The new version of PicMate now supports PicBasic Pro, and PicBasic together.

Setting-up PicMate:

Step 1:

The first step is to download the editor and unzip the files into a temporary directory.  Below is the download link for the newest version of PicMate that can be used with Picbasic Pro and Picbasic.

1. PicMate: (For the PicBasic Pro & PicBasic Standard Compilers).

Once you have downloaded PicMate --- unzip the files into a temporary directory.

Step 2:

Start PicMate by clicking on the file named PicMatePro.exe located in the directory that PicMate was installed in.

Once you have the editor running, the default settings will need to be changed so PicMate can start-up each time with your preferred settings.  The settings you need to configure are stored in a text-based file named PicMate.ini.  When you start PicMate, this file is read by the software, and your preferred settings are activated.  Here are the settings PicMate will let you change:

1. The directory where your picbasic compiler is located, (Compiler Path).
2. The directory path to the EPIC programming software, (Programmer Path).
3. The directory where your picbasic source code is stored, (Source Code Directory).
4. Compiler options, (Command Line Switches).
5. Editor screen fonts & colors.

The tool-bar on the top of the PicMate screen allows quick access to the different settings that you're allowed to change and save.

Use the tool-bar to set-up your preferences.  The icon (shown above) that resembles tools will bring up the Tool Options window (shown below).  This window will let you set the default directories for the picbasic compiler, EPIC programming software, source code directory, and even let you change the default screen fonts & colors.

The screen for the tool options is pretty self explanatory, but here's a screen-shot showing the different options:

Once you have entered the information as shown above (depending of course on where your own files are actually located), PicMate will save each option, and know where your files are located each time you start PicMate.  The path to the picbasic compiler and EPIC programmer software will let PicMate launch each one directly from PicMate while you're working on your code.

The source code path will direct PicMate to your source code when you open new files, and save you the time of looking for your source code directory each time you open a new file.

The compiler options box lets you set-up any command-line switches for use with the picbasic compiler.  For more information on command-line switches with picbasic, refer to the picbasic users manual.

Note:  By default, picbasic will compile basic files targeted for the PIC16F84 unless you use the command-line switches to tell picbasic that you're compiling a file for another PIC.  You (do not) have to add these command line switches in the Compiler Options window.  PicMate will automatically insert the switches to compile for whatever PIC you have selected in the PIC selection window.

The Compiler Options window is only if you want to use the compiler Command Line Options for adding additional compile-time options as indicated in the picbasic users manual.  Refer to the manual for explanations on these other options. 

Set Fonts & Screen Colors:

With the tool-options window still open --- you can also change the screen colors, and fonts.  The two command-buttons on the lower right section of the tool-options form will bring up windows that allow you to change the default screen fonts & colors.  Once you're finished, select the close button.

Step 3:

Once you have told PicMate where your compiler, EPIC programming software, source code files are located, and set-up your choice of screen fonts & colors, your default settings will be in effect each time you start PicMate.

When PicMate reloads, it will automatically load your saved preferences, and know where the compiler, EPIC programming software, and your source code is located.  Your selected fonts & screen colors should also be in effect now..

Test PicMate:

When you re-start PicMate, open a picbasic file by selecting file, then open from the top file menu.  If you set-up PicMate correctly, you'll see a window similar to the one below waiting for you to make your file selection:

Once you have opened your picbasic file, it's time to try compiling the file using the compiler button on the top tool-bar.  The compiler button icon is the red check-mark on the tool-bar (shown below).

Note:  Be sure to select the specific PIC that you're compiling the picbasic source code for.  The drop-down menu (shown below), lets you quickly select the target PIC you're compiling the code for.

The window on the tool-bar shows the PIC selected as well as the source code filename you currently have open.  Notice to the right of the PIC selection window that onint2.bas is shown.  I really like this feature John added since it's fast & easy to see the file name with its associated target PIC.

If your source code compiled OK, you're almost finished.  If something went wrong, re-trace your steps as outlined above to make sure you told PicMate the (exact path) to your picbasic compiler files.

If your source code compiled without any problems, you're ready to test the Programmer-button.  This is a real no-brainer.  Just click the programmer-button icon that looks like a small IC (shown above) to the left of the red check-mark.  This button will launch the EPIC programming software.  If the EPIC programming software screen pops-up, you're finished.  If not, go back to the beginning to see if you entered the (exact path) to your EPIC programming software.

Start The EPIC Programming Software:

After you have successfully compiled your PicBasic source-code, you're ready to launch the EPIC programming software. If you have already set the path to the EPIC software, just click the tool-bar icon of the IC, or use the drop-down menu and select programmer from the list.

The EPIC software should start, and you'll see the EPIC programmer software screen as shown below.

If you don't see the EPIC programming interface, go back to step-2 and make sure you have set the correct path to the EPIC files on your PC..

Additional Features:

John added the really nice feature of a communications terminal that allows you to send/receive serial data.  Here's what it looks like:

The serial debugger window is pretty handy.  It can be used with a stand-alone PIC communicating with your PC, or the debug command built-in to the picbasic pro compiler.

This feature doesn't really need much explanation, but it's extremely handy.  If you're new to RS-232 (serial) communications, browse around our site here.  We have several complete projects that explain how to handle serial communications between microcontrollers and the PC.


1. How to make PicMate start with your choice of PIC selected.

The first line of the PicMate.ini file loads the default PIC to be programmed.  This can be seen in the PIC selection window on the PicMate screen.  This first line of the PicMate.ini file (as shown below) can be modified to automatically load any PIC by default when you start PicMate.  If you work with a specific PIC such as the PIC16F84 more than others, this can save you even more time.

12C671        ; Default PIC to load on start
C:\Micros\pbp ; Default path to compiler
C:\Micros\pbp ; Default path to EPIC software
C:\Micros\pbp ; Default path to source code files
16316664      ; 
-2147483640   ; Screen colors
Monospac821 BT; Screen font
8             ; Font size

The first line can be edited to load you choice of PIC when PicMate first starts.  If you prefer the PIC16F84, just replace the first line with the name of this PIC.

Example:  16F84 in the first line will load the PIC16F84 as your default. For the PIC16F877, just enter 16F877.

2. How to add new PICs (supported by PicBasic) to PicMate

MicroEngineering Labs is constantly updating the picbasic compiler to support each new PIC almost as quickly as Microchip can pump them out.  John has made PicMate extremely simple to update for support of new PICs as they are added.

The file named micros.ini located in the same directory that PicMate was installed to, holds the name of each PIC supported by the compiler.  To add another PIC, simply place the number for that device in the file micros.ini.

3. Re-arrange the order of PICs in the list

You can also re-arrange the order each PIC shows up in the PIC selection window by re-arranging the PICs in the micros.ini file as shown below.


This can be handy if you work with a specific group of PICs by grouping the ones you use most often together.  This makes selecting from your group quicker by eliminating the long list of PICs you would otherwise have to scroll through.

Open the micros.ini file and examine it.  You'll see how simple it is to add each new PIC to the list or re-arrange them to best suit your specific requirements....

Note: Remember to exit PicMate and re-start it each time you modify one of the ini files.  PicMate will read each of these ini files when it is started, and load the values in the ini files.

That's it...!