Table 1. Record of Changes
Rev Date Author Note

1.1

2016-05-12

MH

Auto gen tables.

1.0

2015-03-01

MH

Initial version.

1. Introduction

The serial console is a simple endpoint for serial traffic that you can connect a device’s UART to. It echos received data to stdout and optionally logs the data in an unbounded log.

2. Dedicated API

There is a dedicated API for accessing the console log. Note that the functions are defined in libTEMUConsole.so.

// Include the Console API
#include "temu-c/Models/Console.h"

// These functions are defined in libTEMUConsole.so
uint64_t temu_consoleGetLineCount(void *Con);
const char* temu_consoleGetLine(void *Con, uint64_t Line);

3. Creation

The Console class is defined in libTEMUConsole.so. The constructor takes no parameters.

4. Configuration

config.caretControl can be used to eliminate some VT100 characters that are printed to the console otherwise.

config.recordTraffic can be set to enable data recording in the console model, this data can then be extracted with the API.

5. Attributes

5.1. Properties

Name Type Description

config.caretControl

uint8_t

config.recordTraffic

uint8_t

lastByte

uint8_t

object.timeSource

object

Time source object (a cpu or machine object)

outByte

uint8_t

serial

iref

5.2. Interfaces

Name Type Description

SerialIface

SerialIface

5.3. Ports

Prop Iface Description

serial

SerialIface

serial port

6. Limitations

  • The record buffer cannot be cleaned without deleting the console object.

  • Caret control only omits caret sequences from being put on stdout (especially nice when booting Linux). It doesn’t act on the sequences in any way at the moment e.g. a delete character will be ignored and not actually delete anything.

  • The record buffer will not be checkpointed.