Configuring JalEdit for Jaluino

On June 16, 2012 by sebastien.lelong

JalEdit is a dedicated Jal IDE, running under Windows. JalPacks exist, where JalEdit is combined with Jallib library set, for minimal setup and maximum experience… JalEdit currently doesn’t provide packs including Jaluino. Following are instructions explaining how to setup JalEdit to properly work with Jaluino.

I’m assuming you’re living at the cutting edge of Jaluino, meaning you’re using sources directly from SVN. You can follow instructions here. Simple: install a SVN client, such as TortoiseSVN, and “check out” Jaluino repository, Jaluino is then up-to-date, at most. Repository is composed with two main entries regarding Jal libraries. One is refering Jaluino-specific libraries, and lies into “lib” directory. Another is about Jallib repository itself, and this times is located in “3rdparty/jallib_svn/include”. This is actually a link, a reference to Jallib SVN repository itself. This means when you “update” your SVN repository, both Jaluino and Jallib will get updated. This is the simplest way to keep up-to-date on both projects at the same time.

OK, that said, let’s dive into this whole thing. First go to “bin” directory, and edit jaluino.bat. This script is a wrapper around jalv2 compiler and several library path setting. Adjust the following variable, according to where you’ve installed (“checked out”) your Jaluino repository. Make sure to use absolute paths. In the following case (mine), I’ve checked out repository on my desktop, so you’ll see C:\Documents and Settings\SirLoon.PIXIE\Bureau as the root path, just change it to fit your location.

Just below these comments, declare a JALUINO_ROOT variable.

rem #######################
rem #######################

set JALUINO_ROOT=C:\Documents and Settings\SirLoon.PIXIE\Bureau\jaluino

Then search for JALLIB_ROOT definition, and change it to:

set JALLIB_ROOT=C:\Documents and Settings\SirLoon.PIXIE\Bureau\jaluino\3rdparty\jallib_svn

Remember both entry points “lib” and “3rdparty/jallib_svn/include” ? By specifying these two variables, we’re telling wrapper to include these two paths, Jaluino libraries and also Jallib libraries.

Save your changes. Now you have a nice bat file you can use to compile Jal sources from command line, using “compile” action parameter:

C:\Documents and Settings\SirLoon.PIXIE\Bureau\jaluino>bin\jaluino.bat compile samples\jaluino_bee_blink.jal
jal 2.4o (compiled May  8 2011)
generating p-code
384 tokens, 181977 chars; 3608 lines; 7 files
generating PIC code pass 1
generating PIC code pass 2
writing result
Code area: 162 of 131064 used (bytes)
Data area: 8 of 3759 used
Software stack available: 3750 bytes
Hardware stack depth 1 of 31
0 errors, 0 warnings


We’ll now use this tool within JalEdit. Open up your favorite IDE, go to “Tools > Environment Options”. Remove entry in “Path of Jal lib folders”, our wrapper takes care of these. In “Path to jalv2.exe”, we’ll fake JAlEdit and specify our jaluino.bat wrapper. Finally in “Additional parameters”, just enter “compile”. Remove all remaining entry, and validate. This looks like this:

Note: if you’re planning to use USB bootloader, you need to specify this in parameters list: “compile -loader18 2048″. This will produce HEX code compatible with PDFUSB bootloader.

Now open a sample (jaluino_bee_blink.jal), press F9 to compile it and check your settings. Got a result ? Great, you’ve ready to rock using JalEdit and Jaluino. Having issues ? Check your paths, make sure you can compile from command line, and from anywhere, not just within your repository location. Check generated command line in output window.


As for programmer configuration, it obviously depends on which one your using. Here’s my setup using PDFUSB bootloader. It’s python based application, so “Programmer Executable Path” is your python.exe path. Parameters will be the remaining command line parameters. In my case:

"C:\Documents and Settings\SirLoon.PIXIE\Bureau\jaluino\bootloaders\pdfusb\hostapp\" -x write %F

(don’t forget %F at the end, this will be substitute with HEX file by JalEdit. -x option makes the PIC actually resets and run your freshly programmed code).


Comments, questions, suggestions, etc… ?  Join this topic.



Comments are closed.