iomodule: xiomodule_selftest_example.c File Reference

| iomodule Xilinx SDK Drivers API Documentation

- Overview
- Data Structures
- APIs
- File List
- Examples

Functions
xiomodule_selftest_example.c File Reference

## Overview

This file contains a self test example using the IO Module driver (XIOModule) and hardware device.

Please reference other device driver examples to see more examples of how the interrupts, timers and UART can be used by a software application.

The TestApp Gen utility uses this file to perform the self test and setup of the IO Module.

Note

None

    MODIFICATION HISTORY:

    Ver   Who  Date     Changes

    1.00a sa   07/15/11 First release
    2.4   ms   01/23/17 Added xil_printf statement in main function to
                        ensure that "Successfully ran" and "Failed" strings
                        are available in all examples. This is a fix for
                        CR-965028.

## Functions
XStatus | IOModuleSelfTestExample (u16 DeviceId)
| This function runs a self-test on the driver/device. More...
int | main (void)
| This is the main function for the IO Module example. More...

## Function Documentation

XStatus IOModuleSelfTestExample | ( | u16 | DeviceId | ) |

This function runs a self-test on the driver/device.

This is a destructive test. This function is an example of how to use the IO Module driver component (XIOModule) and the hardware device. This function is designed to work without external hardware devices to cause interrupts. It may not return if the IO Module is not properly connected to the processor in either software or hardware.

Parameters

  DeviceId | is device ID of the IO Module Device, typically XPAR_<IOMODULE_instance>_DEVICE_ID value from xparameters.h

Returns
  XST_SUCCESS to indicate success, otherwise XST_FAILURE

Note
  None.

References XIOModule_Initialize().

Referenced by main().

int main | ( | void |  | ) |

This is the main function for the IO Module example.

This function is not included if the example is generated from the TestAppGen test tool.

Parameters

  None. |

Returns
  XST_SUCCESS to indicate success, otherwise XST_FAILURE.

Note
  None.

References IOModuleSelfTestExample().