Project

General

Profile

Download (959 Bytes) Statistics
| Branch: | Tag: | Revision:
1

    
2
#include <stdint.h>
3

    
4
#include "req_ctx.h"
5

    
6
/* Some thoughts:
7
 * If we're running at 1MS/s, and the USB-HS microframe occurs every 125uS, we
8
 * need to transfer 125 samples at eech microframe.  125 samples with 2
9
 * channels of 2 bytes equals 500 bytes.
10
 */
11

    
12
#define AUDDLoopRecDriver_SAMPLERATE	500000
13
#define	AUDDLoopRecDriver_NUMCHANNELS	2
14
#define AUDDLoopRecDriver_BYTESPERSAMPLE 2
15

    
16
#if 0
17
#define AUDDLoopRecDriver_SAMPLESPERFRAME (AUDDLoopRecDriver_SAMPLERATE / 8000 \
18
					   * AUDDLoopRecDriver_NUMCHANNELS)
19

    
20
#else
21
#define AUDDLoopRecDriver_SAMPLESPERFRAME (128 * AUDDLoopRecDriver_NUMCHANNELS)
22
#endif
23

    
24
#define AUDDLoopRecDriver_BYTESPERFRAME (AUDDLoopRecDriver_SAMPLESPERFRAME * \
25
					 AUDDLoopRecDriver_BYTESPERSAMPLE)
26

    
27
#include <usb/common/core/USBGenericRequest.h>
28

    
29
extern unsigned char fastsource_interfaces[3];
30

    
31
void fastsource_init(void);
32
void fastsource_start(void);
33
void fastsource_dump(void);
34

    
35
void usb_submit_req_ctx(struct req_ctx *rctx);
(2-2/12)
Add picture from clipboard (Maximum size: 48.8 MB)