Feature Summary
Swordfish is a highly structured, modular compiler for the PIC18 family of PIC® microcontrollers. Swordfish is a true compiler that generates optimised, stand alone code which can be programmed directly into you microcontroller. Swordfish is supplied with a powerful and flexible Integrated Development Environment (IDE) which includes an advanced code explorer, full syntax highlighting, third party programmer integration, serial communicator and integrated boot loader application. Just a single mouse click, or key press, will compile, assemble and program your project into the target microcontroller.
The following lists some of the key compiler features.
- Signed and unsigned ordinal, floating point, string and array constants
- Boolean, bit, 8, 16 and 32 bit signed and unsigned ordinal, floating point, char and string data types
- Arrays and structures, including arrays of strings and structures
- Alias and modifiers
- Addressable EEPROM data constants
- Conditional statements including if...then..elseif...else...endif and select...case
- Repetitive statements including while...wend, repeat...until and for...next. Also supports the break and continue constructs
- Short circuit Boolean expressions for faster code execution
- Subroutines and Functions, including support for local constants, structures and variables.
- Inline subroutines and functions
- Overloaded subroutines and functions
- Compound subroutines
- Full support for passing by value and passing by reference. Functions can return all Boolean, bit, 8, 16 and 32 bit signed and unsigned ordinal, floating point, char and string types. Functions can also return structure types.
- Powerful frame recycling algorithm ensures optimal RAM usage
- All constants and declaration types can be declared as private or public, facilitating encapsulation or 'information hiding'
- Typecasting support
- Support for embedded assembler
- Powerful hardware based interrupt support
- Rich set of compiler directives including #ifdef, #constant, #variable, #define, #undefine, #ifdef...#else...#endif, #ifndef...#else...#endif, #if...#elseif...#else...#endif, #error, #warning and #option.
- Predfined subroutines and functions, including AddressOf, BitOf, Bound, Dec, DelayMS, DelayUS, High, Inc, Input, Low, Output, Terminate and Toggle
- Extensive library support is provided with full source code, some of which include LCD, GLCD, EEPROM, ADC, software and hardware SPI, software and hardware I2C, software UART, USART, Secure Digital (SD), string manipulation, math, interrupt based RX and interrupt based timer libraries. Specific peripheral libraries are also included with full source. Some examples include the DS18B20, DS18S20 and DS2405.
- Comprehensive set of relational, mathematical and logical operators
Library Support
Swordfish provides extensive library support. Swordfish libraries include full source code.
Not only does this enable you to see how a particular library module works, it can also aid learning and become a code starting point for your own library modules.
Device Support
For an up to date list of supported devices, please check here.