Commit dc68de15 authored by Dean Camera's avatar Dean Camera
Browse files

Make Audio device demos compatible with AVRs running at 16MHz instead of 8MHz.

Fix up demo documentation device compatibility list to be as general as possible to reduce changes required as Atmel releases more devices within the same USB AVR series.
parent be9d0a5a
......@@ -84,9 +84,9 @@ void EVENT_USB_Device_Connect(void)
LEDs_SetAllLEDs(LEDMASK_USB_ENUMERATING);
/* Sample reload timer initialization */
OCR0A = (F_CPU / AUDIO_SAMPLE_FREQUENCY) - 1;
OCR0A = (F_CPU / 8 / AUDIO_SAMPLE_FREQUENCY) - 1;
TCCR0A = (1 << WGM01); // CTC mode
TCCR0B = (1 << CS00); // Fcpu speed
TCCR0B = (1 << CS01); // Fcpu/8 speed
}
/** Event handler for the USB_Disconnect event. This indicates that the device is no longer connected to a host via
......
......@@ -8,12 +8,11 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -79,9 +79,9 @@ void EVENT_USB_Device_Connect(void)
LEDs_SetAllLEDs(LEDMASK_USB_ENUMERATING);
/* Sample reload timer initialization */
OCR0A = (F_CPU / AUDIO_SAMPLE_FREQUENCY) - 1;
OCR0A = (F_CPU / 8 / AUDIO_SAMPLE_FREQUENCY) - 1;
TCCR0A = (1 << WGM01); // CTC mode
TCCR0B = (1 << CS00); // Fcpu speed
TCCR0B = (1 << CS01); // Fcpu/8 speed
#if defined(AUDIO_OUT_MONO)
/* Set speaker as output */
......
......@@ -8,13 +8,11 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,12 +8,10 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - Series 7 USB AVRs
* - Series 6 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,17 +8,12 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB1286
* - AT90USB647
* - AT90USB646
* - ATMEGA32U6
* - ATMEGA32U4
* - ATMEGA16U4
* - AT90USB162
* - AT90USB82
* - Series 7 USB AVRs
* - Series 6 USB AVRs
* - Series 4 USB AVRs
* - Series 2 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,10 +8,9 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB647
* - Series 7 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,10 +8,9 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB647
* - Series 7 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,10 +8,9 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB647
* - Series 7 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,10 +8,9 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB647
* - Series 7 USB AVRs
*
* \section SSec_Info USB Information:
*
......
......@@ -8,10 +8,9 @@
*
* \section SSec_Compat Demo Compatibility:
*
* The following table indicates what microcontrollers are compatible with this demo.
* The following list indicates what microcontrollers are compatible with this demo.
*
* - AT90USB1287
* - AT90USB647
* - Series 7 USB AVRs
*
* \section SSec_Info USB Information:
*
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment