Kinetis SDK v.1.3 API Reference Manual  Rev. 0
Freescale Semiconductor, Inc.
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages

Overview

The section describes the programming interface of the AOI HAL driver. AOI HAL driver is a set of API functions used to access and configure the AOI hardware registers.

Enumerations

enum  aoi_status_t {
  kStatus_AOI_Success = 0U,
  kStatus_AOI_InvalidArgument = 1U,
  kStatus_AOI_Failed = 2U
}
 AOI status return codes. More...
 
enum  aoi_input_config_t {
  kAoiConfigLogicZero = 0x0U,
  kAoiConfigInputSignal = 0x1U,
  kAoiConfigInvInputSignal = 0x2U,
  kAoiConfigLogicOne = 0x3U
}
 
enum  aoi_product_term_t {
  kAoiTerm0 = 0x0U,
  kAoiTerm1 = 0x1U,
  kAoiTerm2 = 0x2U,
  kAoiTerm3 = 0x3U
}
 Defines the product term numbers. More...
 
enum  aoi_input_signal_index_t {
  kAoiInputA = 0x0U,
  kAoiInputB = 0x1U,
  kAoiInputC = 0x2U,
  kAoiInputD = 0x3U
}
 AOI input signal indexes. More...
 
enum  aoi_event_index_t {
  kAoiEvent0 = 0x0U,
  kAoiEvent1 = 0x1U,
  kAoiEvent2 = 0x2U,
  kAoiEvent3 = 0x3U
}
 AOI event indexes, where an event is the collection of the four product terms (0, 1, 2, and 3) and the four signal inputs (A, B, C, and D). More...
 

Functions

void AOI_HAL_Init (AOI_Type *base)
 Initializes the AOI module to the reset state. More...
 
void AOI_HAL_Reset (AOI_Type *base, aoi_event_index_t event)
 Resets the configuration registers of a specific AOI event. More...
 
void AOI_HAL_SetSignalLogicUnit (AOI_Type *base, aoi_event_index_t event, aoi_product_term_t productTerm, aoi_input_signal_index_t input, aoi_input_config_t config)
 Defines the Boolean evaluation associated with the selected input in the selected product term of the desired event. More...
 
aoi_input_config_t AOI_HAL_GetSignalLogicUnit (AOI_Type *base, aoi_event_index_t event, aoi_product_term_t productTerm, aoi_input_signal_index_t input)
 Gets the Boolean evaluation associated with the selected input in the selected product term of the desired event. More...
 

Enumeration Type Documentation

Enumerator
kStatus_AOI_Success 

Success.

kStatus_AOI_InvalidArgument 

Invalid argument existed.

kStatus_AOI_Failed 

Execution failed.

Enumerator
kAoiConfigLogicZero 

Forces the input to logical zero.

kAoiConfigInputSignal 

Passes the input signal.

kAoiConfigInvInputSignal 

Inverts the input signal.

kAoiConfigLogicOne 

Forces the input to logical one.

Enumerator
kAoiTerm0 

Product term 0.

kAoiTerm1 

Product term 1.

kAoiTerm2 

Product term 2.

kAoiTerm3 

Product term 3.

Enumerator
kAoiInputA 

Input configuration A.

kAoiInputB 

Input configuration B.

kAoiInputC 

Input configuration C.

kAoiInputD 

Input configuration D.

Enumerator
kAoiEvent0 

Event 0 index.

kAoiEvent1 

Event 1 index.

kAoiEvent2 

Event 2 index.

kAoiEvent3 

Event 3 index.

Function Documentation

void AOI_HAL_Init ( AOI_Type *  base)

This function initializes the module to the reset state. This state is defined in the chip Reference Manual, which is the power on reset value.

Parameters
baseRegister base address for AOI module.
void AOI_HAL_Reset ( AOI_Type *  base,
aoi_event_index_t  event 
)

This function resets all product term inputs of a selected event to the reset values. This state is defined in the chip Reference Manual, which is the power on reset value.

Parameters
baseRegister base address for AOI module.
eventEvent of AOI to be reset of type aoi_event_index_t.
void AOI_HAL_SetSignalLogicUnit ( AOI_Type *  base,
aoi_event_index_t  event,
aoi_product_term_t  productTerm,
aoi_input_signal_index_t  input,
aoi_input_config_t  config 
)

This function defines the Boolean evaluation associated with the selected input in the selected product term of the desired event.

Parameters
baseRegister base address for AOI module.
eventNumber of the event which will be set of type aoi_event_index_t.
productTermThe term which will be set of type aoi_product_term_t.
inputThe input which will be set of type aoi_input_signal_index_t.
configSelected input configuration of type aoi_input_config_t.
aoi_input_config_t AOI_HAL_GetSignalLogicUnit ( AOI_Type *  base,
aoi_event_index_t  event,
aoi_product_term_t  productTerm,
aoi_input_signal_index_t  input 
)

This function returns the Boolean evaluation associated with the selected input in the selected product term of the desired event.

Parameters
baseRegister base address for AOI module.
eventNumber of the event which will be set of type aoi_event_index_t.
productTermThe product term which will be set of type aoi_product_term_t.
inputThe input which will be set of type aoi_input_signal_index_t.
Returns
Selected input configuration of type aoi_input_config_t.