aboutsummaryrefslogtreecommitdiffstats
path: root/LUFA/Drivers/USB/Class/Device/Audio.c
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2009-10-03 07:59:32 +0000
committerDean Camera <dean@fourwalledcubicle.com>2009-10-03 07:59:32 +0000
commit433399b05db8d4a8a3989e90614f7206d49568fc (patch)
tree7f69f5ea95c68005221caab40a9bb1e11ae5b80a /LUFA/Drivers/USB/Class/Device/Audio.c
parent3ebfb998ec4eef73543a8e8bde0019a3057b72dc (diff)
downloadlufa-433399b05db8d4a8a3989e90614f7206d49568fc.tar.gz
lufa-433399b05db8d4a8a3989e90614f7206d49568fc.tar.bz2
lufa-433399b05db8d4a8a3989e90614f7206d49568fc.zip
Changed Audio Class driver sample read/write functions to be inline, to reduce the number of cycles needed to transfer samples to and from the device (allowing more time for processing and output).
Fixed ClassDriver AudioOutput demo not selecting an audio output mode.
Diffstat (limited to 'LUFA/Drivers/USB/Class/Device/Audio.c')
-rw-r--r--LUFA/Drivers/USB/Class/Device/Audio.c61
1 files changed, 0 insertions, 61 deletions
diff --git a/LUFA/Drivers/USB/Class/Device/Audio.c b/LUFA/Drivers/USB/Class/Device/Audio.c
index c4fbc3d9c..337437c94 100644
--- a/LUFA/Drivers/USB/Class/Device/Audio.c
+++ b/LUFA/Drivers/USB/Class/Device/Audio.c
@@ -89,67 +89,6 @@ void Audio_Device_USBTask(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo
}
-int8_t Audio_Device_ReadSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
-{
- int8_t Sample;
-
- Sample = Endpoint_Read_Byte();
-
- if (!(Endpoint_BytesInEndpoint()))
- Endpoint_ClearOUT();
-
- return Sample;
-}
-
-int16_t Audio_Device_ReadSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
-{
- int16_t Sample;
-
- Sample = (int16_t)Endpoint_Read_Word_LE();
-
- if (!(Endpoint_BytesInEndpoint()))
- Endpoint_ClearOUT();
-
- return Sample;
-}
-
-int32_t Audio_Device_ReadSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
-{
- int32_t Sample;
-
- Sample = (((uint32_t)Endpoint_Read_Byte() << 16) | Endpoint_Read_Word_LE());
-
- if (!(Endpoint_BytesInEndpoint()))
- Endpoint_ClearOUT();
-
- return Sample;
-}
-
-void Audio_Device_WriteSample8(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, const int8_t Sample)
-{
- Endpoint_Write_Byte(Sample);
-
- if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpointSize)
- Endpoint_ClearIN();
-}
-
-void Audio_Device_WriteSample16(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, const int16_t Sample)
-{
- Endpoint_Write_Word_LE(Sample);
-
- if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpointSize)
- Endpoint_ClearIN();
-}
-
-void Audio_Device_WriteSample24(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo, const int32_t Sample)
-{
- Endpoint_Write_Byte(Sample >> 16);
- Endpoint_Write_Word_LE(Sample);
-
- if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpointSize)
- Endpoint_ClearIN();
-}
-
bool Audio_Device_IsSampleReceived(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
{
if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled))