Removed use of old INPUT and OUTPUT defines (NUM_USB_CHAN_ used instead)

This commit is contained in:
Ross Owen
2014-04-29 18:03:34 +01:00
parent c01e193b23
commit b93fe11839

View File

@@ -644,11 +644,11 @@ void decouple(chanend c_mix_out,
) )
{ {
unsigned sampFreq = DEFAULT_FREQ; unsigned sampFreq = DEFAULT_FREQ;
#ifdef OUTPUT #if (NUM_USB_CHAN_OUT > 0)
int aud_from_host_flag=0; int aud_from_host_flag=0;
xc_ptr released_buffer; xc_ptr released_buffer;
#endif #endif
#ifdef INPUT #if (NUM_USB_CHAN_OUT > 0)
int aud_to_host_flag = 0; int aud_to_host_flag = 0;
#endif #endif
@@ -707,7 +707,7 @@ void decouple(chanend c_mix_out,
/* Wait for usb_buffer() to set up globals for us to use /* Wait for usb_buffer() to set up globals for us to use
* Note: assumed that buffer_aud_ctl_chan is also setup before these globals are !0 */ * Note: assumed that buffer_aud_ctl_chan is also setup before these globals are !0 */
#ifdef OUTPUT #if (NUM_USB_CHAN_OUT > 0)
while(!aud_from_host_flag) while(!aud_from_host_flag)
{ {
GET_SHARED_GLOBAL(aud_from_host_flag, g_aud_from_host_flag); GET_SHARED_GLOBAL(aud_from_host_flag, g_aud_from_host_flag);
@@ -721,7 +721,7 @@ void decouple(chanend c_mix_out,
XUD_SetReady_OutPtr(aud_from_host_usb_ep, g_aud_from_host_wrptr+4); XUD_SetReady_OutPtr(aud_from_host_usb_ep, g_aud_from_host_wrptr+4);
#endif #endif
#ifdef INPUT #if (NUM_USB_CHAN_OUT > 0)
/* Wait for usb_buffer to set up */ /* Wait for usb_buffer to set up */
while(!aud_to_host_flag) while(!aud_to_host_flag)
{ {
@@ -897,7 +897,7 @@ void decouple(chanend c_mix_out,
} }
} }
#ifdef OUTPUT #if (NUM_USB_CHAN_OUT > 0)
/* Check for OUT data flag from host - set by buffer() */ /* Check for OUT data flag from host - set by buffer() */
GET_SHARED_GLOBAL(aud_from_host_flag, g_aud_from_host_flag); GET_SHARED_GLOBAL(aud_from_host_flag, g_aud_from_host_flag);
if (aud_from_host_flag) if (aud_from_host_flag)
@@ -980,7 +980,7 @@ void decouple(chanend c_mix_out,
} }
#endif #endif
#ifdef INPUT #if (NUM_USB_CHAN_IN > 0)
{ {
/* Check if buffer() has sent a packet to host - uses shared mem flag to save chanends */ /* Check if buffer() has sent a packet to host - uses shared mem flag to save chanends */
int tmp; int tmp;
@@ -1057,7 +1057,7 @@ void decouple(chanend c_mix_out,
continue; continue;
} }
} }
#endif // INPUT #endif /* NUM_USB_CHAN_IN > 0 */
} }
} }