Purpose
The adcife_window_monitor example demonstrates how to use window monitor mode.
Requirements
This example can be used on SAM4L boards.
Description
This example uses continuous mode for ADCIFE conversion. It would trigger the ADCIFE to start a conversion on the given channel which is DAC internal selection. This example shows a menu as below upon running:
-- Menu Choices for this example--
-- 0: Modify DAC output voltage.--
-- 1: Modify low threshold.--
-- 2: Modify high threshold.--
-- 3: Choose comparison mode.--
-- i: Display ADCIFE information.--
-- m: Display
this main menu.--
With the user interface, DAC output voltage, window threshold and mode could be set. After setting, it will start a conversion and enable window monitor interrupt. If conversion result fall into comparison window, then it will generate relative interrupt and display information in terminal.
Usage
- On the computer, open and configure a terminal application (e.g., HyperTerminal on Microsoft Windows) with these settings:
- 115200 bauds
- 8 bits of data
- No parity
- 1 stop bit
- No flow control
- In the terminal window, the following text should appear (values depend on the board and the chip used):
-- ADCIFE Window Monitor Example xxx --
-- xxxxxx-xx
-- Compiled: xxx xx xxxx xx:xx:xx --
-- Menu Choices for this example--
-- 0: Modify DAC output voltage.--
-- 1: Modify low threshold.--
-- 2: Modify high threshold.--
-- 3: Choose comparison mode.--
-- i: Display ADCIFE information.--
-- m: Display
this main menu.--
- Input the command according to the menu.