deep

a Cross Development Platform for Java

User Tools

Site Tools


runtime_library:drivers:start

Device Drivers

Currently we support the mpc555 and mpc5200 PowerPC processors. They differ in their core features as well as in their built-in peripherals. Both are rich in built-in peripheral modules. In order to facilitate the use of those modules the runtime system offers a lot of software drivers. In the following sections there are short descriptions of drivers available. Details about a specific driver and its use can be found API of the Runtime Library.

mpc555

Digital I/O’s

The mpc555 offers several general purpose I/O-ports. Most of the pins including TPU pins, analog input pins and the pins for the serial communication interface can be config-ured for I/O operation if not used for their specific purpose. However, there are 16 pins in the MIOS-Module which serve solely for digital I/O. These 16 pins are controlled in the sub module MPIOSM. They are designated MPIOBx on the expansion connector. Each of the pins can be easily programmed for input or output operation (see class Mpiosm_DIO). If more than 16 pins are needed, a TPU pin can work as a digital I/O pin (see TPU_DIO). This gives another 32 I/O pins. Another possibility for more digital I/O are the pins of the ADC. Instead of using these ports with 32 pins in total as analogue inputs you can configure them for digital operation (see ADC_DIO). Pins for PWM generation also offer digital I/O's (MPWMSM_DIO) as well as pins for serial communication (QSMCM_DIO).

Multiple Input/Output System

This peripheral interface offers among many other things 8 pulse with modulated outputs (MPWMSM_PWM).

Serial Communication Interface (SCI, RS232)

The mpc555 offers two independent SCI interfaces. The necessary bus converters for RS232 voltage level are already incorporated on the microcontroller board. An easy to use interface is offered by SCI1 for the first and SCI2 for the second serial communication interface. An Input or OutputStream can be connected to any of those channels. The System.out stream can be put on this connections as follows.

  // 1) Initialize SCI2 (9600 Bd, 8N1)
  SCI sci2 = SCI.getInstance(SCI.pSCI2);
  sci2.start(9600, SCI.NO_PARITY, (short)8);
  // 2) Use SCI2 for stdout
  System.out = new PrintStream(sci2.out);
  // 3) Redirect stderr to stdout (optional)
  System.err = System.out;

We offer a dedicated driver BlueRS for the Stollmann BlueRS+I Bluetooth module which directly connects to one of the SCI. For WLAN there is a driver RN131WiFly which uses a Roving RN-131C WiFly module.

Serial Peripheral Interface (SPI)

Up to 4 external units can be directly connected to the SPI. With further decoding this can be extended to 16 units. As the SPI makes use of a synchronous serial bus with shared signals for transferring data, it is not possible to combine two or more of these drivers without adaptation of the chip-select signals, serial clock rate and serial clock edge control. Please refer to the user manual of the mpc555. You can find TLC549. It uses an external low-cost 8-bit ADC on the SPI bus. For analogue output there is a driver for a 12 bit, 4 channels DAC (DAC7614) or you can use MAX512.

Time Processor Unit (TPU)

The mpc555 has two independent TPUs, called TPUA and TPUB. Each of them presents 16 individual channels. A multitude of timing functions can be produced without any processor interaction. Software drivers for the following functions exist:

  • TPU_PWM: PWM generation
  • TPU_PPWA: Pulse and period measurement
  • StepMotor: For step motor control. Various modes can be selected. 2 or 4 pins are used depending on half or full step mode
  • TPU_FQD: Fast quadrature decode function for digital encoders (uses 2 channels)

Analog-Digital Converters (ADC)

The mpc555 has two independent 10-bit ADCs with 16 input channels each. QADC_AIN offers an easy to use interface for these two devices. Please make sure to connect the analog ground to digital ground. This can be done on a custom board onto which the mpc555 microcontrollerboard is mounted. If you use our base platform for easy experimenting you must connect the Pin AGnd with ground. Especially for our various roboter projects we developed a driver HLC1395Pulsed for up to 16 low-cost close range distance sensors. They work up to several centimetres but need additional dedicated hardware.

Bus Interface Unit

The mpc555 has a universal bus interface unit to connect any memory or external component with a parallel bus interface to the system bus. A chip-select mechanism eliminates the need for external glue logic. You can find a driver for the popular character-LCD controller HD44780U which uses the system bus (HD44780U).

CAN Bus

The mpc555 offers to indepedent CAN controllers. On the headerboard the necessary physical driver is already included (but no 120Ω termination resistor). An basic driver for CAN and CANopen exists. Please ask for assistance.

Support for NTB Hardware

Several dedicated drivers exist for in-house hardware like our control board (RTBoard) or our two-wheel robot (Robi2).

Flash File System

Part of the external flash on the microcontroller board can be used for storing user data. This could be data files such as log files for permanent storage or font files for display purposes. Therefore a flash file system offers a simple interface for creating, registering and deleting files. Please ask for assistance.

mpc5200

Please check the API of the Runtime Library for available drivers.

runtime_library/drivers/start.txt · Last modified: 2016/02/25 13:33 (external edit)