mac-rom-simm-programmer/hal/at90usb646/LUFA/DoxygenPages/AlternativeStacks.txt
Doug Brown 7425af761a Break out code into a HAL, optimize flash operations
This makes the code pretty easily portable to other architectures if someone
wants to make a more modern SIMM programmer. I also was pretty careful to split
responsibilities of the different components and give the existing components
better names. I'm pretty happy with the organization of the code now.

As part of this change I have also heavily optimized the code. In particular,
the read and write cycle routines are very important to the overall performance
of the programmer. In these routines I had to make some tradeoffs of code
performance versus prettiness, but the overall result is much faster
programming.

Some of these performance changes are the result of what I discovered when
I upgraded my AVR compiler. I discovered that it is smarter at looking at 32-bit
variables when I use a union instead of bitwise operations.

I also shaved off more CPU cycles by carefully making a few small tweaks. I
added a bypass for the "program only some chips" mask, because it was adding
unnecessary CPU cycles for a feature that is rarely used. I removed the
verification feature from the write routine, because we can always verify the
data after the write chunk is complete, which is more efficient. I also added
assumptions about the initial/final state of the CS/OE/WE pins, which allowed me
to remove more valuable CPU cycles from the read/write cycle routines.

There are also a few enormous performance optimizations I should have done a
long time ago:

1) The code was only handling one received byte per main loop iteration. Reading
   every byte available cut nearly a minute off of the 8 MB programming time.
2) The code wasn't taking advantage of the faster programming command available
   in the chips used on the 8 MB SIMM.

The end result of all of these optimizations is I have programming time of the
8 MB SIMM down to 3:31 (it used to be 8:43).

Another minor issue I fixed: the Micron SIMM chip identification wasn't working
properly. It was outputting the manufacturer ID again instead of the device ID.
2020-11-27 00:16:35 -08:00

70 lines
4.4 KiB
Plaintext

/** \file
*
* This file contains special DoxyGen information for the generation of the main page and other special
* documentation pages. It is not a project source file.
*/
/**
* \page Page_AlternativeStacks Alternative USB AVR Stacks
*
* LUFA is not the only stack available for the USB AVRs, although it is perhaps the best (see \ref Page_WhyUseLUFA).
* In the interests of completeness and user choice, other known USB AVR stacks are listed here.
*
* \section Sec_HardwareStacks Hardware USB AVR Stacks
* These are the known alternative USB stacks which are designed for and run exclusively on the USB AVR series microcontrollers,
* which contain on-chip USB controller hardware for maximum features and speed.
*
* - <b>Name:</b> Atmel USB AVR Stack (<i>Atmel Inc.</i>) \n
* <b>Cost:</b> Free \n
* <b>License:</b> Atmel Limited License (see Atmel download for details) \n
* <b>Website:</b> http://atmel.com/dyn/products/app_notes.asp?family_id=607#USB \n
* <b>Description:</b> This is the official Atmel USB AVR stack, for their 8-bit USB AVR lineup. Each series of
* USB AVR is separated into a separate download stack, which is both AVR-GCC and IAR compatible.
*
* - <b>Name:</b> Dr. Stefan Salewski's AT90USB1287 Stack (<i>Dr. Stefan Salewski</i>) \n
* <b>Cost:</b> Free \n
* <b>License:</b> GPL \n
* <b>Website:</b> http://www.ssalewski.de/AT90USB_firmware.html.en \n
* <b>Description:</b> This is a GPL'd library specifically designed for the AT90USB1287, by Dr. Stefan Salewski, a
* German Physicist. It compiles for AVR-GCC and can potentially be modified to work on other USB
* AVR models.
*
* - <b>Name:</b> FreakUSB Stack (<i>FreakLabs</i>) \n
* <b>Cost:</b> Free \n
* <b>License:</b> Modified BSD \n
* <b>Website:</b> http://freaklabs.org/index.php/FreakUSB-Open-Source-USB-Device-Stack.html \n
* <b>Description:</b> An open source simple USB stack for a selection of the USB AVRs. Contains a sample class driver
* for the CDC-ACM class, however other class driver implementations are also possible.
*
* - <b>Name:</b> PJRC Teensy Stack (<i>Paul Stoffregen</i>) \n
* <b>Cost:</b> Free \n
* <b>License:</b> BSD \n
* <b>Website:</b> http://www.pjrc.com/teensy/usb_debug_only.html \n
* <b>Description:</b> Not so much a complete stack as a collection of USB enabled demos, this library is specifically
* designed for the PJRC Teensy line of USB AVRs, and thus may need to be modified for other USB AVR
* chips. These minimal code samples shows the inner workings of the USB controller, without all the
* abstraction present in most other USB AVR stacks.
*
* \section Sec_SoftwareStacks Software AVR Stacks
* These are the known alternative USB stacks which can run on regular AVR models, lacking dedicated hardware USB controllers
* via a bit-banged (emulated) version of the USB protocol. They are limited in their capabilities due to the cycles required
* to be dedicated to managing the USB bus, but offer a cheap way to implement USB functionality into a design.
*
* - <b>Name:</b> AVR309: Software USB (<i>Atmel</i>) \n
* <b>Cost:</b> Free \n
* <b>License:</b> None Stated \n
* <b>Website:</b> http://www.atmel.com/dyn/Products/app_notes.asp?family_id=607 \n
* <b>Description:</b> Atmel's official software USB implementation, an Application Note containing work by Igor Cesko. This
* is a minimal assembly-only implementation of software USB, providing HID functionality. Less compile
* options than V-USB (see below).
*
* - <b>Name:</b> V-USB (<i>Objective Development</i>) \n
* <b>Cost:</b> Free for some uses, see website for licensing \n
* <b>License:</b> Dual GPL2/Custom \n
* <b>Website:</b> http://www.obdev.at/products/vusb/index.html \n
* <b>Description:</b> Well regarded and complete USB 1.1 software stack for several AVR models, implementing Low Speed HID.
* Used in many commercial and non-commercial designs, with user-submitted projects available for viewing
* on the company's website. Uses C language code mixed with assembly for time-critical sections.
*/