Delay Driver

This Delay driver provides an interface for basic delay functions for applications requiring a brief wait during execution.

Summary of the API's Functional Features

The API provides functions to:
  • Initialize the Delay driver and associated hardware

  • Delay for the given amount of microseconds

  • Delay for the given amount of milliseconds

Summary of Configuration Options

No configuration is needed in START.

Driver Implementation Description

The driver will first calculate the amount of cycles to delay for the given time according to the system clock, then use Systick to delay these cycles.

Example of Usage

The following shows a simple example of using the delay function. The delay driver must have been initialized by delay_init. This initialization will configure the operation of the SysTick.

          void delay_example(void)
          {
              delay_ms(5000);
          }
        

Dependencies

  • SysTick