The board comes with boot code so that it can be programmed from the USB, there is no need for a special programmer although if you like it can be programmed with a PICkit 2.
There are three sections of software: the Boot, the BIOS (called Micro-BOS) and the Application BV-Basic.
The Boot
The purpose of this code is to provide a method of re-installing the Micro-BOS should it get erased or damaged in some way without the need of a specialised programmer, it can simply be done through the USB and downloading the Micro-BOS as a hex file. If a PICkit 2 is available then there is also a programming interface for that so the boot will not be required.
Micro-BOS
This started out as an operating system so that the application could easily be ported over to other devices without too much trouble. It has ended up as mainly the Disk, or more correctly the SD Card operating system. All calls to the BOS are through a single address and example code in C will be provided so that users can write C applications rather then BASIC applications. The DOS is fully compatible with FAT16 including long file names and subdirectories. This enables the card to be read in a PC as well as in the device. Another important function the BOS has is an Xmodem downloader that allows the rapid download of binary files.
BV-Basic
It has been over 4 years since I retired TCB (Tiny Control Basic) from the 8 bit world of the Atmel. BV-Basic could not be more different as it takes full advantage of the Micro-BOS and 32 bit register set of the PIC running at 80MHz. Some of the features:
Variable types: Character (8 bit), Integer (32 bit), Hex (32 bit) Float (64 bit) and String - variable length. Arrays are also supported up to 4 dimensions.
Line Numbers: None, the unit of this basic is the SUB (subroutine), which can accept local variables and return values.
Register Access: Interactive access to the processors is available so it is possible to see what's going on. Or to set particular registers for special purposes such as Multiple timer or Comparator access.
Scheduling: A subroutine can be placed in a queue and called in the background at intervals, this is a form of multi-tasking and interrupt handling. For example a sub could be written to handle a particular event and take action on it, lets say when a motor reached the end of its travel there is a switch. The switch could be monitored in the background and halt the motor if the switch is closed. The main body of the could would not need to deal with this. Another example would be a keypad; a sub could be written to put the keys in a buffer when a key is pressed, the main code would only need to look at the buffer and not worry about missing any keys.
File Operations: All of the usual fileopen, read and write commands are available as well as DIR, CD etc. for seeing the directory of the SD card and changing directory. Data can also be written and read to a particular position in the file so that a database could be produced.
To get an idea of what a BV-Basic program look like here is an example
// creates some test files for reading
sub mf(size)
fn=openfile("test1.txt", 'w')
writeln$ fn "Test 1 start"
for j=1 to size
write$ fn j, *0x0a
next
closefile fn
endsub
The comment is // and all programs consist of subroutines beginning 'sub'. In this example the sub requires a parameter (size) that will determine the size of the file that is created. Here are some points to note about the above code:
Hopefully this will be available in small quantities at the end of May this year. The software will continue to be developed after release and updates can be provides as binary or hex downloads.