Commit Graph

5 Commits

Author SHA1 Message Date
Scott Shawcroft ccbb5e84f9 This introduces an alternative hardware API called nativeio structured around different functions that are typically accelerated by native hardware. Its not meant to reflect the structure of the hardware.
Docs are here: http://tannewt-micropython.readthedocs.io/en/microcontroller/

It differs from upstream's machine in the following ways:

* Python API is identical across ports due to code structure. (Lives in shared-bindings)
* Focuses on abstracting common functionality (AnalogIn) and not representing structure (ADC).
* Documentation lives with code making it easy to ensure they match.
* Pin is split into references (board.D13 and microcontroller.pin.PA17) and functionality (DigitalInOut).
* All nativeio classes claim underlying hardware resources when inited on construction, support Context Managers (aka with statements) and have deinit methods which release the claimed hardware.
* All constructors take pin references rather than peripheral ids. Its up to the implementation to find hardware or throw and exception.
2016-11-21 14:11:52 -08:00
Scott Shawcroft 2098515f6a atmel-samd: Rework pin definitions to share most of the data structures and included based on ASF defines. 2016-10-26 17:57:47 -07:00
Scott Shawcroft bb1822faea atmel-samd: Support external flash on the Metro M0 w/Flash.
This uses a scratch flash sector to save data before writing a full sector.
2016-10-21 15:44:09 -07:00
Scott Shawcroft 011056af15 atmel-samd: Add support for SPI.
Also separate out the ASF config headers that are shared across all boards.
2016-10-11 15:48:43 -07:00
Scott Shawcroft a6254f4344 atmel-samd: Add basic support for experimental Metro M0 with an external flash chip. 2016-10-07 15:09:01 -07:00