naa2d: Analog to Digital Convert Example

This application only supports the NS9215 processor.  This application 
is only supported on the ConnectCore9p9215_a.  Since the A/D converter
shares the same interrupt as serial port D, you must set BSP_SERIAL_PORT_4 
in bsp_serial.h to BSP_SERIAL_NO_DRIVER.

This application demonstrates how to use the A/D converter built
into the NS9215.  

The NS9215 has a single A/D converter which can sample 8 input
pins.  The A/D converter continuously samples the pins once it 
has been configured.  The sampled values can be read by software, 
or the A/D converter can be programmed to write the values into 
memory buffers using DMA.

This application demonstrates both methods.  The 
demonstrateSimpleReads function:

1.  Configures the A/D converter.
2.  Reads the sampled values from all of the inputs.
3.  Writes the sampled values out stdout.

The demonstrateAutomaticReads function:

1.  Configures the A/D converter.
2.  Sets up the A/D converter to automatically write
    the sampled values into buffers.
3.  Places a set of buffers into the API's queue.
4.  Processes each buffer by computing the average value
    of a input.
5.  Writes the average sampled values out stdout.

To use this application, build it and then run it in the
debugger. 


One GNU make file is provided.  Build the target 'image' to
generate an image that can be debugged with gdb, and the file 
image.bin which can be written to flash if the bootloader is used.
Build the target 'rom.bin' to create the file rom.bin which 
can be written to ROM if the bootloader is not used.


The following files are provided with this application:

appconf.h           sets application configuration settings
makefile            Make file for the GNU toolset.
readme              this file
root.c              contains the demonstration code.  The applicationStart
                    function is the entry point for the program.

The application uses the following files located in the
netos\src\linkerScripts directory.  These files are generated
when the BSP is built.

bootldr.dat     bootloader configuration file used to generate the
                file image.bin.  It controls the information placed
                in the bootloader header of the image.

image.ldr       GNU linker script used to build an image that can
                be debugged and used with the bootloader.
                
customize.ldr   Customizable GNU linker script
