chipKIT32/chipKIT32-MAX — pull request #522 by KeithV (2014-10-22 18:58:17+00:00)
Title: Fix interrups, add DTWI, fix Wire, fix timer for MZ

With the new compiler interrupt processing changed and we need to explicitly specify IPLxSOFT or IPLxSRS or nothing at all on the interrupt() attribute for interrupts; specifying just IPLx will cause problems. Also, constructor initialization is now running before the interrupt vector manager is initialized and a default interrupt handler is being installed by the runtime. The interrupt manager initialization now accommodates this and that fixed WIRE on the MX. The MZ has a different I2C hardware implementation and DTWI I2C library was implemented to support both MX and MZ processors. WIRE continues to work for MX, but does not work for MZ, to use I2C on MZ use the DTWI library. Timer now operates at the appropriate 20ms speed for the MZ. An 80MHz version of the WiFIRE is supported in boards.txt, but requires an 80MHz bootloader. I added the standard MCHP peripheral "bits" structures to most of the p32_defs.h peripherals so the code can now use the same bit names as in the MCHP documentation; the old non-standard names are still supported.