Skip to content

Oscar Software Framework Manual Logic Module

scs edited this page Jul 16, 2012 · 3 revisions

Go to Table of Contents.

This module is not used on leanXcam platform.

Table of Contents

Logic Module (lgx)

Description

The logic module represents the functionality of the firmware of the CPLD device on the indXcam. Thus it is empty by default and must be "installed" from another source before framework compilation, since the same hardware can contain different firmware implementations. It must be adapted/replaced if the firmware changes. The registers and fields for the options of the CPLD module are defined here. Basic register/field access is provided by the Cpld module. The logic module adds higher-level functionality for example the setting/getting of GPIO pin values which usually involves read-modify-write on several registers.

On the host, the GPIO activity is observed/controlled with an attached stimuli reader/writer.

The lgx module is installed with the 'make config' directive. Apart from an identifier for the hardware type the OSCar framework should be compiled for, this also takes a path to the location of an implementation of the lgx module. It then sets a symbolic link to the specified path, compiles and adds the module to the library. If no lgx module is installed, the CPLD can also be accessed via the Cpld module directly without the comfort of named registers etc.

Target Hardware Resource

See CPLD module.

Dependencies

Usage

The pseudo code shows the order of functions issues for logic module usage.

     ... doAlgorithm ...
 
     LgxIoPinWrite // target: write physical io; host: write io to stimuli file
 
     SimStep // advance simulation time
 }

Following two sequence diagrams illustrate the use of stimuli reader/writer as part of the logic module. In a similar manner the application may use the stimuli reader/writer functionality directely.

Stimuli Reader Usage

Stimuli Writer Usage

Clone this wiki locally