SPI Demos

# Sub Processor Peripheral Sample Demo

## Location

`$NitroSDK/build/demos/spi`

## Compilation

Move to the `$NitroSDK/build/demos/spi` directory and enter:

> `% make`

Executable (`.nef`, `.srl`) files are generated in `$NitroSDK/build/demos/spi/sample_name/bin/platform/target/`.

For example:

    $NitroSDK/build/demos/spi/tp-1/bin/ARM9-TEG/Release/

## Execution Method

Navigate to the `$NitroSDK/build/demos/spi/sample_name/bin/platform/target/` directory and perform one of the following:

- Execute `*.nef`, `*.srl` with ensata.
- Execute `*.srl` with the TEG version of the IS-NITRO-EMULATOR.
- Load and execute `*.nlf` with the IS-NITRO-DEBUGGER.
- Execute `*.srl` with the IS-NITRO-DEBUGGER.

## Description

`tp-1` | Displays touch panel input positions on the screen.
`tp-2` | Displays the track of touch panel input positions on the screen.
`mic-1` | Displays the microphone voice input status on the screen as a waveform.
`mic-2` | Displays microphone voice input status on the screen as a waveform, and outputs text data. The `mic2wav.exe` tool can convert the obtained data into a `wav` file.
`spiMonkey` | Displays touch panel and microphone input status on the screen while playing BGM.
`pm-1` | Enters sleep mode or power save mode by pressing the power button or closing the cover.

## Operation

`mic-1`, `mic-2`, `spiMonkey`, and `pm-1` do not function properly with ensata. When using a TEG board, if no touch panel device is attached `tp-1`, `tp-2`, and `spiMonkey` will not function properly. If no microphone device is attached, neither `mic-1` nor `spiMonkey` will function properly.

`tp-1` and `tp-2` attempt to read touch panel calibration values from the non-volatile memory (NVRAM) in the retail product. If they do not succeed they will move to a calibration screen in order to obtain calibration values. The calibration values obtained in the demo will not be saved to NVRAM. To save to NVRAM, use `BootMenu.srl` (changed from `BootMenu.bin` in SDK 2.0 PR5) to calibrate.

## See Also

`SPI Function List`

## Revision History

08/17/2004 Standardized the notation of the IS-NITRO-EMULATOR.
08/03/2004 Added pm-1.
07/10/2004 Changed from `.bin` to `.srl.`
06/18/2004 Initial version.