Microcontroller (MCU) Usage
Applicable to: K300 / K700 series systems
Karbon K300 and K700 series computers have an internal microcontroller (MCU) that manages features like DIO, CAN, Ignition sensing, and more. This microcontroller can be managed by sending commands to two virtual serial ports from the operating system.
This article will outline several methods for interfacing with the system’s MCU. It also provides a complete list of the exact command strings supported by the microcontroller.
Note: We recommend making sure your microcontroller firmware is up to date before trying any of the below.
Optional Methods:
1– Karbon Command Line Utility
The Karbon command line utility is a straightforward method for managing all core microcontroller functionality. You can download the utility for Windows or Linux systems here, and use it to communicate directly with the onboard MCU.
Windows
Linux
> karbon.exe op version
$ sudo ./karbon op version
Complete instructions on using the utility are included as part of the download package. This utility may also be used to update the microcontroller’s firmware version.
2– Pykarbon
What is the Pykarbon Module?
The Pykarbon module provides a set of tools for interfacing with the hardware devices on OnLogic’s ‘Karbon’ series industrial PCs. These interfaces include the onboard CAN bus, Digital IO, and other hardware devices.
The goal of the Pykarbon package is to provide a simple, powerful base platform that will allow users to quickly and easily integrate a Karbon into their own application.
The tools in the Pykarbon package are designed to work with the Karbon series rugged industrial computers; this will not work for more generalized systems.
What can the Pykarbon Module do?
Pykarbon offers a number of tools for automating and using Karbon series hardware interfaces. These include:
CAN and DIO background data monitoring
Exporting logged data to .csv
Registering and making functions calls based on these bus events:
CAN data IDs
Digital Input Events
DIO Bus States
Automated CAN message response to registered IDs
Automated setting of Digital Output states
Automatic CAN baudrate detection
Updating user configuration information:
Ignition sense enable/disable
Power timing configurations
Low battery shutdown voltage
Etc.
Firmware update
Setting Up the Pykarbon Module
You will need to install Python 3 prior to following this guide.
To get started with Pykarbon, follow these steps:
Open up a terminal and run:
Launch a python shell with:
In the python shell, import pykarbon with:
And finally create a control object using:
If all went well, you should now be ready to control a variety of systems, but for now let’s just print out some configuration information:
And close our session:
After the initial setup, visit our Pykarbon Github page to begin using the Pykarbon module for your Karbon series rugged PC.
3– Serial Interface
Connecting from Windows
Download and install the latest version of the PuTTY tool. Download Link

Open device manager and look for the USB serial devices.
Note their COM numbers, typically 4 and 5.

Open PuTTY and configure these options

Select the serial option
Change the COM number to match device manager, typically COM4
Click on default settings
Click Save
Click open
This configures PuTTY to automatically choose the correct options next time you run it.

Type config and press enter. The terminal should respond by printing out the current configuration. You may then enter commands from the next section.
If config does not work, try using the other COM port number from device manager.
Connecting from Ubuntu Linux

Install PuTTY
Note: If installing from a live CD, you will need to enable the multiverse/universe repositories
Run PuTTY as root

Set the options shown

Select the serial option
Change the COM device to ttyACM1
Click on default settings
Click Save
Click open
This configures PuTTY to automatically choose the correct options next time you run it.

Type config and press enter. The terminal should respond by printing out the current configuration. You may then enter commands from the next section.
If config does not work, try using other com ports from /dev
Serial Commands
Serial Commands – System Information
The serial terminal can report various system information to the host. This covers firmware version and build date, alongside physical and electrical status information. For instance, the K700 can report the current system input voltage, internal temperature, and internal humidity.
The available information is system dependent, and is not unified across all Karbon systems.
Commands for reporting this information include:
Serial Commands – System Configuration
The Karbon series has several configuration options that effect system behavior. These primarily include automotive features, like ignition sensing and battery drain protection.
The system can store up to four different configurations, one of which will be loaded as default when the system is first powered on. This allows for temporarily disabling automotive features, like low voltage shutdown. The active configuration may be cycled by pressing the settings switch.
The available commands for controlling system configurations include:
Several configuration parameters may also be set. They include:
Serial Interface Technical Details – Connection Specs
Baudrate
Recommended baud rate: 9600
Note: Because the Karbon series operates using a virtual serial port, it is able to support a broad range of baud rates. It is not required to operate the serial interface at the recommended rate.
Flow Control
XON/XOFF
Command Format
Commands are expected to be sent by line instead of by character, such that each command requires a single transaction. Line terminating characters will be ignored. The system is not sensitive to CRLF vs LF termination.
Received Data Format
Each line of returned data will be “/n/r” terminated
Commands sent to the Karbon computer should be in all lower case, and transmitted to the Serial Terminal port in a single transaction. Commands are not sensitive to line termination.\
An error response will be sent if an unsupported command is sent or if the command is transmitted with the wrong number of accompanying arguments. \
Serial Commands – CAN Bus
Some CAN configuration settings, alongside limited CAN messaging are supported through the Karbon Serial Interface. Sending complex messages, and receiving data, is handled by the dedicated CAN virtual serial port. More information is available in the CAN Bus FAQ.
Note: The CAN device is not internally terminated; a properly terminated cable or bus is required for correct CAN operation.
The commands available through the serial terminal include:
Serial Commands – Digital IO
Controlling the Karbon Digital IO (DIO) is handled entirely through the serial terminal interface. The DIO state may be read, and output states may be set. Additionally, when an input changes state, that event will be passed to the serial terminal.
More information is available in the DIO FAQ.
Note: The digital io is isolated, and requires external power for proper operation. The system manual has additional information on these electrical characteristics.
The commands available through the serial terminal interface include:
Last updated
