Fix MassStorageKeyboard demo USE_INTERNAL_SERIAL check being performed before the required library headers were included, causing a compilation error.

Added notes to the class driver functions indicating which functions require what Device/Host state machine states to function.
This commit is contained in:
Dean Camera 2010-01-04 13:34:02 +00:00
parent 1e1cf2c499
commit 6122ba93cf
17 changed files with 159 additions and 19 deletions

View file

@ -112,6 +112,9 @@
void MIDI_Device_USBTask(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1);
/** Sends a MIDI event packet to the host. If no host is connected, the event packet is discarded.
*
* \note This function must only be called when the Device state machine is in the DEVICE_STATE_Configured state or
* the call will fail.
*
* \param[in,out] MIDIInterfaceInfo Pointer to a structure containing a MIDI Class configuration and state
* \param[in] Event Pointer to a populated USB_MIDI_EventPacket_t structure containing the MIDI event to send
@ -122,6 +125,9 @@
MIDI_EventPacket_t* const Event) ATTR_NON_NULL_PTR_ARG(1) ATTR_NON_NULL_PTR_ARG(2);
/** Receives a MIDI event packet from the host.
*
* \note This function must only be called when the Device state machine is in the DEVICE_STATE_Configured state or
* the call will fail.
*
* \param[in,out] MIDIInterfaceInfo Pointer to a structure containing a MIDI Class configuration and state
* \param[out] Event Pointer to a USB_MIDI_EventPacket_t structure where the received MIDI event is to be placed