![]() |
MCUSW
|
This file contains interface header for DIO MCAL driver to be used by other AUTOSAR MCAL Layers.
Go to the source code of this file.
Dio Service Ids | |
The Service Id is one of the argument to Det_ReportError function and is used to identify the source of the error | |
| #define | DIO_SID_READ_CHANNEL (0U) |
| Dio_ReadChannel() | |
| #define | DIO_SID_WRITE_CHANNEL (1U) |
| Dio_WriteChannel() | |
| #define | DIO_SID_READ_PORT (2U) |
| Dio_ReadPort() | |
| #define | DIO_SID_WRITE_PORT (3U) |
| Dio_WritePort() | |
| #define | DIO_SID_READ_CHL_GROUP (4U) |
| Dio_ReadChannelGroup() | |
| #define | DIO_SID_WRITE_CHL_GROUP (5U) |
| Dio_WriteChannelGroup() | |
| #define | DIO_SID_FLIP_CHANNEL (17U) |
| Dio_FlipChannel() | |
| #define | DIO_SID_GET_VERSION_INFO (18U) |
| Dio_GetVersionInfo() | |
| #define | DIO_PORT_WIDTH (32U) |
| Width of GPIO register in this platform not to be modified. | |
| #define | DIO_MCAL_2139_FIXED (0U) |
| Read back issue in Maxwell is resolved or not. | |
| enum | Dio_DirectionType { DIO_DIR_INPUT = 0x1U , DIO_DIR_OUTPUT = 0x0U } |
| typedef uint32 | Dio_ChannelType |
| type definition for identifying DIO channels (meaning single port pins) | |
| typedef uint32 | Dio_PortType |
| type definition for identifying ports | |
| typedef uint32 | Dio_PortLevelType |
| type definition for setting port level values | |
| typedef uint8 | Dio_LevelType |
| type definition for setting DIO channnel level values (allowed values: STD_HIGH and STD_LOW) | |
| Dio_LevelType | Dio_ReadChannel (Dio_ChannelType ChannelId) |
| Returns the value of the specified DIO channel. | |
| void | Dio_WriteChannel (Dio_ChannelType ChannelId, Dio_LevelType Level) |
| Service to set a level of a channel. | |
| Dio_PortLevelType | Dio_ReadPort (Dio_PortType PortId) |
| Returns the level of all channels of that port. | |
| void | Dio_WritePort (Dio_PortType PortId, Dio_PortLevelType Level) |
| Service to set a value of the port. | |
| Dio_PortLevelType | Dio_ReadChannelGroup (const Dio_ChannelGroupType *ChannelGroupIdPtr) |
| This Service reads a subset of the adjoining bits of a port. | |
| void | Dio_WriteChannelGroup (const Dio_ChannelGroupType *ChannelGroupIdPtr, Dio_PortLevelType Level) |
| Service to set a subset of the adjoining bits of a port to a specified level. | |
| void | Dio_GetVersionInfo (Std_VersionInfoType *versioninfo) |
| Service to get the version information of this module. | |
| Dio_LevelType | Dio_FlipChannel (Dio_ChannelType ChannelId) |
| Service to flip (change from 1 to 0 or from 0 to 1) the level of a channel and return the level of the channel. | |
| Std_ReturnType | Dio_RegisterReadback (Dio_ChannelType ChannelId, Dio_RegisterReadbackType *DioRegRbPtr) |
| This function reads the important registers of the hardware unit and returns the value in the structure. | |
Data Structures | |
| struct | Dio_ChannelGroupType |
| Type definition for identifying channel groups (meaning a set of pins in one port) More... | |
| struct | Dio_RegisterReadbackType |
Macros | |
DIO Driver Module SW Version Info | |
Defines for DIO Driver version used for compatibility checks | |
| #define | DIO_SW_MAJOR_VERSION (10U) |
| Driver Implementation Major Version. | |
| #define | DIO_SW_MINOR_VERSION (1U) |
| Driver Implementation Minor Version. | |
| #define | DIO_SW_PATCH_VERSION (0U) |
| Driver Implementation Patch Version. | |
DIO Driver Module AUTOSAR Version Info | |
Defines for DIO Driver AUTOSAR version used for compatibility checks | |
| #define | DIO_AR_RELEASE_MAJOR_VERSION (4U) |
| AUTOSAR Major version specification implemented by DIO Driver. | |
| #define | DIO_AR_RELEASE_MINOR_VERSION (3U) |
| AUTOSAR Minor version specification implemented by DIO Driver. | |
| #define | DIO_AR_RELEASE_REVISION_VERSION (1U) |
| AUTOSAR Patch version specification implemented by DIO Driver. | |
DIO Driver ID Info | |
| #define | DIO_VENDOR_ID ((uint16) 44U) |
| Texas Instruments Vendor ID. | |
| #define | DIO_MODULE_ID ((uint16) 120U) |
| DIO Driver Module ID. | |
Dio Error Codes | |
Error codes returned by Driver functions | |
| #define | DIO_E_PARAM_INVALID_CHANNEL_ID (0x0AU) |
| ERROR:API service called with invalid channel ID. | |
| #define | DIO_E_PARAM_INVALID_PORT_ID (0x14U) |
| ERROR:API service called with invalid port ID. | |
| #define | DIO_E_PARAM_INVALID_GROUP (0x1FU) |
| ERROR:API service called with invalid channel group ID. | |
| #define | DIO_E_PARAM_POINTER (0x20U) |
| ERROR:Dio_GetVersionInfo() called with NULL_PTR as parameter. | |