aboutsummaryrefslogtreecommitdiffstats
path: root/LUFA/Drivers/USB/LowLevel
Commit message (Collapse)AuthorAgeFilesLines
...
* Optimized Endpoint_Read_Word_* and Pipe_Read_Word_* macros to reduce ↵Dean Camera2009-08-252-16/+32
| | | | | | compiled size. Fixed Programmer's Notepad project file to reflect new location of AVRISP project.
* Add LOAD ADDRESS command parsing to the V2 Protocol hander in the AVRISP ↵Dean Camera2009-08-202-21/+21
| | | | | | project. Fix up references to functions in the Endpoint/Pipe documentation.
* Fixed invalid data being returned when a GetStatus request is issued in ↵Dean Camera2009-08-181-0/+2
| | | | | | Device mode with an unhandled data recipient. Fix up Programmers Notepad Project file to show new Projects directory layout. Remove now moved AVRISP project from the Projects directory makefile.
* Added beginnings of a new AVRISP-MKII clone project.Dean Camera2009-08-171-0/+8
| | | | | | Added new Endpoint_SetEndpointDirection() macro to set the current endpoint direction for bidirectional endpoints. Renamed internal USB_INT_ENDPOINT_SETUP macro to USB_INT_RXSTPI to fit in with the rest of the interrupt vector macros.
* Added new EVENT_USB_Device_StartOfFrame() event, controlled by the new ↵Dean Camera2009-08-161-0/+15
| | | | USB_Device_EnableSOFEvents() and USB_Device_DisableSOFEvents() macros to give bus-synchronised millisecond interrupts when in USB device mode.
* Added CDC_Device_Flush() command to the CDC Device mode class driver.Dean Camera2009-08-131-4/+0
| | | | | | Minor updates to the unfinished SideShow demo for clarity. Added unfinished MassStorageHost class driver demo.
* Cleanups to RNDIS device demos. Fix issue in RNDIS demos where the memory ↵Dean Camera2009-08-071-11/+2
| | | | | | | | would become corrupted due to an incorrect bounds check when iterating over the port state table, causing random resets. Revert change to Template_Endpoint_Control_R.c, which broke control stream reads. Remove uneeded ADC.h include in the class driver AudioOutput demo.
* Make Endpoint control transfers more reliable; early-abort when an ↵Dean Camera2009-08-061-2/+11
| | | | | | incomplete packet is sent from the host (indicating end of transfer), add check for control reads to ensure that no more than wLength bytes are read from the interface. Condense sequential printf_P/puts_P calls to single printf_P calls for size and clarity.
* Make Control Endpoint stream transfers more reliable by adding in early ↵Dean Camera2009-08-053-31/+26
| | | | | | | | aborts for unexpected new SETUP tokens, or unexpected status stage during control stream writes. Fix corruption in Device RNDIS demos TCP stack when too many connections attempted simultaneously, freezing the device when a page was re-fetched before the first connection was closed. Fix incorrect model compatibility information in the Host LowLevel demo overview text files.
* Renamed all library events to properly seperate out Device and Host mode ↵Dean Camera2009-08-056-46/+34
| | | | | | | | events. Changed the firing conditions for some events to ensure that events are fired by their own USB mode only. Remove VBUS events - not needed as the library takes care of VBUS detection and feedback on supported AVRs via the USB_Device_Connected and USB_Device_Disconnected events. Fixed incorrect Host state assignment in the incomplete BluetoothHost demo.
* Cleanup and optimization of the internal serial retrieval routines.Dean Camera2009-08-032-16/+11
| | | | Renamed ATTR_NOINLINE to ATTR_NO_INLINE to fit with the rest of the library function attribute names.
* Rename TOTAL_NUM_CONFIGURATIONS to FIXED_NUM_CONFIGURATIONS, to match the ↵Dean Camera2009-08-022-3/+3
| | | | existing FIXED_CONTROL_ENDPOINT_SIZE compile time option. Add FIXED_NUM_CONFIGURATIONS to the descriptors of each project using the option.
* Renamed USB_Device_SetHighSpeed() to USB_Device_SetFullSpeed() so that the ↵Dean Camera2009-07-312-3/+5
| | | | | | correct terminology is used (thanks to Brian Dickman). Fix USB_PLL_Off() call in the series 4, 6 and 7 microcontroller disconnect interrupt handler code, which wasn't guarded by a test of USB_Options to check if the user has specified manual PLL control (thanks to Brian Dickman).
* Cleanup USBMode.h to simplify preprocessor logic.Dean Camera2009-07-291-0/+6
|
* Extend the automatic serial number descriptor code to read out and send all ↵Dean Camera2009-07-281-3/+3
| | | | 10 bytes (20 characters) of the internal serial number on supported AVRs, rather than just the first 6 bytes (12 characters).
* Corrected new Pipe_IsEndpointBound() function.Dean Camera2009-07-261-2/+2
| | | | Completed host CDC class driver enumeration code.
* Added new Pipe_BoundEndpointNumber() and Pipe_IsEndpointBound() functions.Dean Camera2009-07-263-4/+37
|
* Slight changes to TeensyHID bootloader to ensure it builds under the 2KB ↵Dean Camera2009-07-212-28/+12
| | | | | | boundary. Changed USB_Init() and USB_Shutdown() so that they are no longer dependant on oneanother for possible code savings when the interface is never explicitly shut down.
* Added new USB_DeviceState variable to keep track of the current Device mode ↵Dean Camera2009-07-2110-57/+193
| | | | | | | | | | | | USB state. Added new Endpoint_ClearStatusStage() convenience function to assist with the status stages of control transfers. Removed vague USB_IsConnected global - test USB_DeviceState or USB_HostState explicitly to gain previous functionality. Removed USB_IsSuspended global - test USB_DeviceState against DEVICE_STATE_Suspended instead. Fixed possible enumeration errors from spinloops which may fail to exit if the USB connection is severed before the exit condition becomes true.
* Move unfinished SideShow source files to nested Lib directory for clarity.Dean Camera2009-07-203-9/+4
|
* Fixed PrinterHost demo Printer_GetDeviceID() routine not removing the Device ↵Dean Camera2009-07-203-9/+20
| | | | | | ID string length from the start of the returned array (thanks to John Andrews). Fixed error in new pipe stream function template system not setting the right device token for R/W operations (also thanks to John Andrews).
* Fixed incorrect PIPE_EPNUM_MASK mask causing pipe failures on devices with ↵Dean Camera2009-07-191-1/+1
| | | | endpoint addresses of 8 and above (thanks to John Andrews).
* Fix small error in last commit preventing compilation in some circumstances.Dean Camera2009-07-161-1/+2
|
* Added new TOTAL_NUM_CONFIGURATIONS option, removed ↵Dean Camera2009-07-163-17/+90
| | | | | | USE_SINGLE_DEVICE_CONFIGURATION compile time option (but silently convert it to USE_SINGLE_DEVICE_CONFIGURATION internally for compatibility). Added new USE_FLASH_DESCRIPTORS compile time option. By default, descriptors can now lie in mixed memory spaces (specified by a new parameter to the CALLBACK_USB_GetDescriptor() function) unless one of the USE_*_DESCRIPTORS compile time option is specified.
* Fix HID class device driver -- if a SetIDle request is issued with the LSB ↵Dean Camera2009-07-152-45/+55
| | | | | | | | of wValue set to zero, the idle period must be set for all HID interfaces. Fix Keyboard and Mouse demos, Idle period is now multiplied by 4 as the period is read into and sent out of the device to ensure it is always stored as a multiple of 1ms. Fixes Keyboard demo using an initial Idle period of 2s rather than 500ms (thanks to Brian Dickman). Move out the internal device serial descriptor reading routine into a seperate static function, rather than being part of USB_Device_GetDescriptor.
* Fix broken Pipe stream function templates due to mixed const/no const use in ↵Dean Camera2009-07-131-6/+6
| | | | prototypes.
* Added new EEPROM and FLASH buffer versions of the Endpoint and Pipe stream ↵Dean Camera2009-07-139-879/+752
| | | | functions. Changed Endpoint.c and Pipe.c to use a templated system to build the seperate functions, rather than duplicating each function's code many times.
* Added new HOST_STATE_WaitForDeviceRemoval host state machine state for ↵Dean Camera2009-07-132-14/+101
| | | | | | non-blocking disabling of device communications until the device has been removed (for use when an error occurs or communications with the device have completed). Changed over all host mode demos to use the new state. Added verbose documentation for each of the USB Host state machine states.
* Seperated out parts of the PrinterHost incomplete demo into a seperate Lib ↵Dean Camera2009-07-132-9/+9
| | | | | | subdirectory. Fixed Host mode to Device mode UID change not causing a USB Disconnect event when a device was connected.
* Added const modifiers to device mode class drivers.Dean Camera2009-06-289-84/+484
| | | | | | Added parameter directions to function parameter documentation. Added new experimental FAST_STREAM_FUNCTIONS compile time option to speed up stream transfers at the expense of a higher FLASH consumption (needs testing to verify improved throughput).
* Optimize vendor/product description string display code in MassStorageHost.Dean Camera2009-06-262-1/+3
| | | | | | | | Remove all Host mode class demos other than the CDCHost class driver demo, so that they can be re-added as they are made once the host mode class framework is designed. Fixed USB_Host_SendControlRequest() not re-suspending the USB bus when initial device ready-wait fails. Fixed USB Pad regulator not being disabled on some AVR models when the USB_OPT_REG_DISABLED option is used.
* Fixed MassStorage demo not clearing the reset flag when a Mass Storage Reset ↵Dean Camera2009-06-231-2/+1
| | | | is issued while not processing a command.
* Pipe_ConfigurePipe() now automatically defaults IN pipes to accepting ↵Dean Camera2009-06-233-3/+6
| | | | infinite IN requests, this can still be changed by calling the existing \ref Pipe_SetFiniteINRequests() function.
* Fixed CDCHost demo unfreezing IN pipes during configuration, rather than ↵Dean Camera2009-06-232-1/+28
| | | | | | during use. Changed Pipe stream functions to automatically set the pipe token, allowing them to be used on bidirectional pipes without having to explicitly call Pipe_SetPipeToken() beforehand.
* Corrected the ADC driver for the ATMEGA16U4 and ATMEGA32U4 (thanks to ↵Dean Camera2009-06-221-2/+0
| | | | Opendous Inc.).
* Optimize unique serial number reading code for size -- remove atoi/toupper ↵Dean Camera2009-06-211-13/+35
| | | | references, replace with hand-rolled code as the input has known size constraints.
* Added new USE_INTERNAL_SERIAL define for using the unique serial numbers in ↵Dean Camera2009-06-212-11/+2
| | | | some AVR models as the USB device's serial number, added NO_INTERNAL_SERIAL compile time option to turn off new serial number reading code. Updated Mass Storage and CDC based demos to use the new device serial number if the device it is compiled for supports it.
* Trim unique serial number created by the USE_INTERNAL_SERIAL option to 12 ↵Dean Camera2009-06-211-2/+2
| | | | characters rather than 20 - apparently Windows will implode if a serial number is too long.
* Added USE_INTERNAL_SERIAL compile time option to automatically read out the ↵Dean Camera2009-06-202-1/+43
| | | | internal unique serial number as the device's serial number descriptor on supported AVR models.
* Fix makefiles -- the auto-addition of -D switches to each LUFA compile time ↵Dean Camera2009-06-192-2/+2
| | | | option was faulty, due to GNUMake becomming confused by the spaces in the USE_STATIC_OPTIONS lines. Make user add in the switches explicitly instead.
* Added new USB_Host_ClearPipeStall() convenience function to clear a stall ↵Dean Camera2009-06-184-2/+62
| | | | | | | | | | condition on an attached device's endpoint. Added new USB_Host_GetDeviceDescriptor() convenience function to retrieve the attached device's Device descriptor. Make Pipe_ConfigurePipe() mask the given endpoint number against PIPE_EPNUM_MASK to ensure the endpoint IN direction bit is cleared to prevent endpoint type corruption. Fix documentation mentioning Pipe_GetCurrentToken() function when real name is Pipe_GetPipeToken().
* Pipe_GetErrorFlags() now returns additional error flags for overflow and ↵Dean Camera2009-06-161-1/+10
| | | | | | underflow errors. Change MIDI demos to use real MIDI command values, and shift for the USB wrapper, rather than shift for the MIDI bytes. This is a little confusing for the MIDI USB wrapper, but allows for the use of real standardized MIDI command values.
* Added new USB_Host_SetDeviceConfiguration() convenience function. Change ↵Dean Camera2009-06-162-0/+30
| | | | over Low Level host demos to use the new routine.
* Fix errors from last commit.Dean Camera2009-06-142-7/+5
|
* Changed per-device controller preprocessor checks over to per-device series ↵Dean Camera2009-06-146-30/+37
| | | | | | for better device control. Fixed error in Endpoint.c using HSOFI rather than SOFI for counting elapsed milliseconds.
* Converted Host mode demos to schedulerless. Fixed host mode broken due to ↵Dean Camera2009-06-085-19/+11
| | | | earlier Start-of-frame event experiments.
* Removed new Start of Frame event from the library; performance suffered far ↵Dean Camera2009-06-021-5/+0
| | | | | | too much and it was only useful in one of the standard classes (HID). Altered HID demos to use the previous method of tracking millisecond periods via a hardware timer rather than the SOF events. Fixed MIDI class driver blocking on unread events to the host.
* Commit of new class abstraction APIs for all device demos other than the ↵Dean Camera2009-06-015-13/+22
| | | | | | | | | | MIDI demo - not documented yet. Removed scheduler and memory allocation libraries. Added new EVENT_USB_StartOfFrame event in the library to indicate the start of each USB frame (when generated). Removed Tx interrupt from the USBtoSerial demo; now sends characters via polling to ensure more time for the Rx interrupt.
* Fix broken Host mode, from the recent API changes.Dean Camera2009-05-261-1/+1
|
* Fix all device mode demos broken in the recent API changes.Dean Camera2009-05-261-3/+2
| | | | Change USBtoSerial Tx to polling-driven rather than interrupt driven, to ensure more time for the Rx interrupt to be serviced.