#include "board.h"
#include <USBDescriptors.h>
#include <USBRequests.h>
#include "USBD.h"
#include <USBD_HAL.h>
#include <USBDDriver.h>
#include <VIDEODescriptors.h>
#include <USBVideo.h>
#include <stdint.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
Go to the source code of this file.
Detailed Description
This file contains all the specific code for example usb_video_gray
Contents
The code can be roughly broken down as follows:
- Configuration functions
- Configure TWI
- Configure pins for OV sensor
- Configure ISI controller
- Interrupt handlers
- The main function, which implements the program behaviour
Definition in file main.c.
Define Documentation
#define BOARD_BASE_TWI_ISI TWIHS0 |
TWI base address for Sensor configuration
Definition at line 151 of file main.c.
#define BOARD_ID_TWI_ISI ID_TWIHS0 |
TWI peripheral ID for Sensor configuration
Definition at line 149 of file main.c.
#define BOARD_PINS_TWI_ISI PINS_TWI0 |
TWI Pins definition
Definition at line 146 of file main.c.
#define ISI_BASE SDRAM_CS_ADDR |
ISI DMA buffer base address
Definition at line 155 of file main.c.
#define ISI_MAX_PREV_BUFFER 10 |
Frame Buffer Descriptors , it depends on size of external memory, more is better
Definition at line 162 of file main.c.
TWI clock frequency in Hz.
Definition at line 143 of file main.c.
#define USB_BASE (ISI_BASE + VIDEO_WIDTH * VIDEO_HEIGHT) |
ISI DMA buffer base address
Definition at line 158 of file main.c.
Function Documentation
TWI interrupt handler. Forwards the interrupt to the TWI driver handler.
Probe & Commit Controls
Buffer for USB requests data
Definition at line 212 of file main.c.
Application entry point for ISI USB video example.
- Returns:
- Unused (ANSI-C compatibility).
Definition at line 707 of file main.c.
Invoked whenever a SETUP request is received from the host. Forwards the request to the standard handler.
Definition at line 614 of file main.c.
void USBDDriverCallbacks_InterfaceSettingChanged |
( |
uint8_t |
interface, |
|
|
uint8_t |
setting | |
|
) |
| | |
Invoked whenever the active setting of an interface is changed by the host. Reset streaming interface.
- Parameters:
-
| interface | Interface number. |
| setting | Newly active setting. |
Definition at line 660 of file main.c.
Variable Documentation
ISI pins to configure.
Definition at line 175 of file main.c.