External Links

Creative Science Centre



NOTE: As from September 2104 the preferred editor is BvSerial as it now incorporates an editor with some script files making the work environment much easier.

This terminal emulator (communications program) for use with ByPic as it has some specific features for the ByPic environment. Having said that any COM type program can be used, e.g. minicom (Lynux) or HyperTerminal for the basic functions.

No installation is necessary just unzip the program and double click on the .exe file.

Download BV_COM2

Version 1.35 (21/08/2014) has a longer delay for boot loading when erasing flash to cater for the newer MXn70 IC's

This is also (introduced December 2014) an alternative called BVSerial. This is a similar program but has colour output and very usefully has a command history that BV_COM lacks. This saves having to retype the same line when used interactively. It also has more accurate line number error reporting.

User Guide

This is a comprehensive terminal emulator and a collection of tools designed for BV products but can be used equally well for other terminal emulation jobs. Currently the version will only run on Windows.


  • Simple to use terminal emulator
  • Detects all COM ports available with rescan.
  • Text download using simple ACK protocol
  • Binary download
  • Converts BMP files to BMC, acceptable to colour displays
  • Boot loading for PIC32 devices using either boot loader version 1 or 2, hex or binary files
  • Scripts - standard text can be stored to scripts and sent over COM port


It does not need any installation on a Windows machine, simply run the exe file. BV_COM2 will write an ini file to the folder it is run from to keep your settings so it can easily be run from a USB stick etc. If it is run from a CD-ROM or other read only memory then it will complain when trying to write the ini file, also scripts will not be available as they also write files to the application directory (where BV_COM2 is run from).

Main Window

Double clicking on the exe file will give the above default window, any changes made to this window will be saved to the ini file for use next time. The COM port drop down list will hold all of the COM ports available on your machine. If you connect another COM port via the USB then you will need to refresh the ports using this  icon.

When you have selected a COM port you MUST use the connect  icon which will turn from red to green.

The 6 icons are important for using this tool and will be explained in this text in the order in which they appear.

Text Transfer

Text transfer is primarily intended for transferring BASIC programs form the PC to the device and optionally uses the simple "ACK" protocol.

The dialog box can remain open after sending a file by unchecking the 'Close on transfer end. This can be useful if there is room on the screen. When a text file has been selected it is remembered and placed in the drop down box for later use. The box that is checked by default 'End of line wait for character' is part of the protocol that the 'tload' command uses.

Transfer Protocol

BV Devices, particularly microcontrollers use a very simple but highly effective protocol for downloading files from a PC to the device. The procedure is as follows:

  1. The device will wait for a line of text - this can be a hex file generated by a compiler or a line of text, e.g. ByPic code
  2. BV_Com sends a line of text and waits for the device to send ACK which has a byte value of 6
  3. The device processes the line just received and when it is ready for another line will send ACK
  4. Once started if BV_Com does not receive an ACK within a reasonable time it will abort the transaction (timeout)

The settings must have the correct check box ticked for this. There is also another icon that will allow the same file to be sent without selecting it again. This is useful for the edit-download cycle of program development.


A very useful feature is that before the selected text file is sent, additional text can be sent first provided the 'Send first' check box is checked. Again pieces of text are remembered and stored in the drop down.

As an example when using a BV%xx device it is preferable to send 'cold' and then 'tload' prior to uploading a ByPic file. This can be done by entering "cold \n\w200 tload \n\w300cold\n" into the send box. Note the use of \n and \w to wait to give the command a chance to respond before sending the file.
The escape '\' character can be used to define the following.

  • \r will substitute 0x0d (13)
  • \n will substitute 0x0a (10)
  • \e will substitute 0x1b (escape) (27)
  • \w<number> waits for that number of milliseconds
  • \# Comment, nothing after the \# will be sent to the COM port
  • \0x<hex value> example \0x0d
  • \0n<octal value>
  • \n where n is a number for 0 to 9 up to 255 e.g. \255

When using the send text first box it is important to include the \n as you would normally press CR when entering the tload command. Also the wait (\w300) is important to give the command a chance to respond.

Binary Transfer

The purpose of this is to transfer non-text files, no protocol is used it will simply transfer byte for byte whatever is in the file.

When using this kind of transfer it becomes more important that the hardware handshaking is enabled, this is because there is no other start stop communication between the devices that is always needed except when perhaps transferring very small files. You can see that there is a warning the CTS has not been set, this can be done from the 'Serial' menu.


If this box is checked then a 24bit BMP (bitmap) picture file will be converted to a format that is acceptable to BV devices that are fitted with colour displays. In other words if you have a BMP picture, checking this box will enable it to be sent directly to the device.

Again it is possible to send a some text before sending the binary file and this is done in the lower dropdown box. For example to send a picture to the BV513 would be "dicls\r\w500diimage com2\r\w200". It is important to include the wait times after clearing the screen and sending the diimage command. The \r is equivalent to pressing CR after entering the command.


If this box is checked the input is expected to be a BFF file, it will then be translated to a BF file which is used by the BV devices as font information. For more details on this see the products that it applies to i.e. BV514.

The send first box is used to send text to a com port prior to the transfer, use the escape codes as described above.


Scrips (could be called Macro's) are just bits of text that can be sent to the com port. This is useful for storing hard to remember commands or other information that you need to send over and over again. The scripts themselves are stored in a file ending with an extension '.scr' and a script file can be loaded or created using the browse button.

The + adds a script to the selected script file, '-' removes it and 'U' updates it.

The escape '\' character can be used to define the following

  • \r will substitute 0x0d (13)
  • \n will substitute 0x0a (10)
  • \e will substitute 0x1b (escape) (27)
  • \w<number> waits for that number of milliseconds
  • \# Comment, nothing after the \# will be sent to the COM port
  • \0x<hex value> example \0x0d
  • \0n<octal value>
  • \n where n is a number for 0 to 9 up to 255 e.g. \255
  • \$<system commands>

System commands
Date - inserts date in the format DD/MM/YY DOW
Time - inserts time in the format HH:MM:SS

The date and time are case sensitive and must be represented exactly as above as an example setting the time on a BV5xx device would be settime "\$Time"

Boot Loader

The boot loader or application loader will download and update the firmware on BV devices with PIC32 boot loaders version 1 and version 2. It will also automatically detect hex or bin files and do the appropriate conversion. Simply select the file and send.

Erase all flash The boot loader will only erase the amount of Flash it need to accommodate itself. This may cause a problem on some BV devices that have user code saved to Flash, as the early part of this code may be corrupted by a slightly larger application. Also if the user code has and erroneous 'auto' then reloading the application will get rid of it if this box is checked. If in doubt then check this box it will do no harm.

Flash Size This is simply the Flash size as marked on the chip, currently all BV PIC32 devices that have a boot loader have 512k of flash.


This is connected to DTR of the serial device and will toggle that line. If connected to a microcontroller reset then this will reset the microcontroller. This is more convenient than having a button on the PCB.