Command Line Tools v0.997+


Introduction


The main tools are scas and scwr.

Typically, you edit your config file(s), assemble them with scas, then load them onto the converter with scwr.

As long as it says 'device: complete' at the end, scwr has succeeded.

C:\sctools> scas foo.sc foo.scb
No errors. Wrote: foo.scb

C:\sctools> scwr foo.scb
Looking for Soarer's Converter: found
...
device: complete

On Windows, you may find scaswr more convenient. It simply combines the two steps.

Tools


ToolDescription
scasAssembles one or more config text files to a config binary file
scdisDissassembles a config binary file to a config text file
scwrWrites a config binary file to the converter
scrdReads a config binary file from the converter
scbootCauses the converter to jump to the bootloader v1.0+
scinfoDisplays converter's version and memory information v1.0+
scaswrCombination of scas and scwr (Windows only) v1.1+

scas


Assembles one or more config text files to a config binary file.

Usage:

scas <text_config> [<text_config> ...] <binary_config>

Output, if everything is fine:

No errors. Wrote: foo.scb

Output, if there's an error:

error at line 4: invalid argument

Output, if there's an error in an included file in an included file:

error at line 4: error at line 5: error at line 5: invalid argument

To find the error, start with the last line number given, which will be an include command.
Then look in that file for the next to last line number given, and so on.
The first line number given is where the actual error is.

Only the first error found is reported.

Alternatively, check that included files assemble successfully on their own, before including into another config.

scdis


Dissassembles a config binary file to a config text file.

Usage:

scdis <binary_config> [<text_config>]

There is no output unless an error occurs.

This tool might be useful to validate that your config assembles as you expected (it was very useful while I was writing scas).

scwr


Writes a config binary file to the converter.

Usage:

scwr <binary_config>

Output:

scwr: looking for Soarer's Converter: found
scwr: reading file: 139 bytes: ok
scwr: sending info request: ok
device: ok
protocol version check: converter=1.00, scwr=1.00: ok
settings version check: converter=1.01, file=1.01: ok
settings length check: max=1018, file=137 bytes: ok
scwr: sending write request for 137 bytes: ok
device: ok
device: ready
scwr: sending 60 bytes: ok
device: ok
device: ready
scwr: sending 60 bytes: ok
device: ok
device: ready
scwr: sending 17 bytes: ok
device: ok
device: complete

scrd


Reads a config binary file from the converter.

Usage:

scrd <binary_config>

Output:

scrd: looking for Soarer's Converter: found
scrd: sending read request: ok
device: has 137 bytes: ok
scrd: ready
device: sent 64 bytes: ok
scrd: ok
scrd: ready
device: sent 64 bytes: ok
scrd: ok
scrd: ready
device: sent 9 bytes: ok
scrd: ok
scrd: complete
scrd: writing file: 139 bytes: ok

scboot v1.0+


Causes the converter to jump to the bootloader.

Usage:

scboot

After running this command, the converter should be ready to have new firmware loaded into it. Note that, at this point, the converter will not be working as a keyboard any more! To cancel the bootloader mode, simply disconnect the converter from the computer and reconnect it.

Output:

scboot: looking for Soarer's Converter: found
scboot: sending boot request: ok
device: ok

scinfo v1.0+


Displays converter's version and memory information.

Usage:

scinfo

Output:

Code Version: v1.00
Max Settings Version: v1.01
Current Settings Version: v1.01
SRAM Size: 2560 bytes
SRAM Free: 1817 bytes
EEPROM Size: 1024 bytes
EEPROM Free: 883 bytes

scaswr.bat (Windows only) v1.1+


A combination of scas and scwr, designed so you can simply drag'n'drop a config file onto it (or a shortcut to it). It will assemble the text config and then write the resulting binary config to the converter, in a single step.

Of course, it can also be used from the command line...

Usage:

scaswr <text_config>

Building


Source code is provided, along with makefiles etc., to natively build on Windows, Linux and OS-X.
Additionally, a mingw32 cross-compile can be used to build the Windows tools on Linux.

To rebuild the tools, change directory to the sub-directory of build that's right for your OS, and type make.

Windows


The tools are built for Windows using MS Visual Studio 2003. Porting to later versions should be trivial.

scwr, scrd, scboot and scinfo rely on a small library of RAWHID routines from PJRC.
For Windows, this library was compiled to a DLL using the Microsoft DDK.

Linux v1.0+


The tools are built for Linux using gcc etc.

Mac OS-X v1.0+


The tools are built for Mac OS-X on Snow Leopard using Xcode 3.2.6 and the version 10.6 SDK.