add more atmel studio framework code
This commit is contained in:
52
watch-library/hal/documentation/flash.rst
Executable file
52
watch-library/hal/documentation/flash.rst
Executable file
@@ -0,0 +1,52 @@
|
||||
The Flash Driver
|
||||
================
|
||||
|
||||
Flash is a re-programmable memory that retains program and data
|
||||
storage even with power off.
|
||||
|
||||
User can write or read several bytes from any valid address in a flash.
|
||||
|
||||
As to the erase/lock/unlock command, the input parameter of address should
|
||||
be a bytes address aligned with the page start, otherwise, the command will fail
|
||||
to be executed. At the meantime, the number of pages that can be locked or unlocked
|
||||
at once depends on region size of the flash. User can get the real number
|
||||
from the function return value which could be different for the different devices.
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
* Initialization/de-initialization
|
||||
* Writing/Reading bytes
|
||||
* Locking/Unlocking/Erasing pages
|
||||
* Notifications about errors or being ready for a new command
|
||||
|
||||
Applications
|
||||
------------
|
||||
|
||||
* Mini disk which can retain program and data storage
|
||||
* Boot loader
|
||||
* Non volatile storage
|
||||
|
||||
Dependencies
|
||||
------------
|
||||
|
||||
The peripheral which controls a re-programmable flash memory.
|
||||
|
||||
Concurrency
|
||||
-----------
|
||||
|
||||
N/A
|
||||
|
||||
Limitations
|
||||
-----------
|
||||
|
||||
User should pay attention to set a proper stack size in their application,
|
||||
since the driver manages a temporary buffer in stack to cache unchanged data
|
||||
when calling flash write and erase function.
|
||||
Due to flash memory architecture of SAMD21/D20/L21/L22/C20/C21/D09/D10/D11/R21,
|
||||
write operation erazes row content before each write.
|
||||
|
||||
Known issues and workarounds
|
||||
----------------------------
|
||||
|
||||
N/A
|
||||
43
watch-library/hal/documentation/rand_sync.rst
Executable file
43
watch-library/hal/documentation/rand_sync.rst
Executable file
@@ -0,0 +1,43 @@
|
||||
==========================================
|
||||
Random Number Generator Synchronous driver
|
||||
==========================================
|
||||
|
||||
Random Number Generator (RAND) generates a sequence of numbers that can not
|
||||
be reasonably predicted better than by a random chance.
|
||||
|
||||
In some implementation cases, seed is required for the Random Number Generator
|
||||
to generate random numbers. rand_sync_set_seed is used to update the seed.
|
||||
If it's actually not required by the generator implementation, the function just
|
||||
returns ERR_UNSUPPORTED_OP.
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
* Initialization and de-initialization
|
||||
* Enabling and Disabling
|
||||
* Setting seed
|
||||
* 8-bit and 32-bit random data/data array generation
|
||||
|
||||
Applications
|
||||
------------
|
||||
|
||||
* Generate random keys for data encryption
|
||||
|
||||
Dependencies
|
||||
------------
|
||||
|
||||
* Random number generation hardware/software
|
||||
|
||||
Concurrency
|
||||
-----------
|
||||
N/A
|
||||
|
||||
Limitations
|
||||
-----------
|
||||
|
||||
N/A
|
||||
|
||||
Known issues and workarounds
|
||||
----------------------------
|
||||
N/A
|
||||
|
||||
51
watch-library/hal/documentation/spi_master_sync.rst
Executable file
51
watch-library/hal/documentation/spi_master_sync.rst
Executable file
@@ -0,0 +1,51 @@
|
||||
The SPI Master Synchronous Driver
|
||||
=================================
|
||||
|
||||
The serial peripheral interface (SPI) is a synchronous serial communication
|
||||
interface.
|
||||
|
||||
SPI devices communicate in full duplex mode using a master-slave
|
||||
architecture with a single master. The master device originates the frame for
|
||||
reading and writing. Multiple slave devices are supported through selection
|
||||
with individual slave select (SS) lines.
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
* Initialization/de-initialization
|
||||
* Enabling/disabling
|
||||
* Control of the following settings:
|
||||
|
||||
* Baudrate
|
||||
* SPI mode
|
||||
* Character size
|
||||
* Data order
|
||||
* Data transfer: transmission, reception and full-duplex
|
||||
|
||||
Applications
|
||||
------------
|
||||
|
||||
Send/receive/exchange data with a SPI slave device. E.g., serial flash, SD card,
|
||||
LCD controller, etc.
|
||||
|
||||
Dependencies
|
||||
------------
|
||||
|
||||
SPI master capable hardware
|
||||
|
||||
Concurrency
|
||||
-----------
|
||||
|
||||
N/A
|
||||
|
||||
Limitations
|
||||
-----------
|
||||
|
||||
The slave select (SS) is not automatically inserted during read/write/transfer,
|
||||
user must use I/O to control the devices' SS.
|
||||
|
||||
Known issues and workarounds
|
||||
----------------------------
|
||||
|
||||
N/A
|
||||
|
||||
58
watch-library/hal/documentation/usart_sync.rst
Executable file
58
watch-library/hal/documentation/usart_sync.rst
Executable file
@@ -0,0 +1,58 @@
|
||||
The USART Synchronous Driver
|
||||
============================
|
||||
|
||||
The universal synchronous and asynchronous receiver and transmitter
|
||||
(USART) is usually used to transfer data from one device to the other.
|
||||
|
||||
User can set action for flow control pins by function usart_set_flow_control,
|
||||
if the flow control is enabled. All the available states are defined in union
|
||||
usart_flow_control_state.
|
||||
|
||||
Note that user can set state of flow control pins only if automatic support of
|
||||
the flow control is not supported by the hardware.
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
* Initialization/de-initialization
|
||||
* Enabling/disabling
|
||||
* Control of the following settings:
|
||||
|
||||
* Baudrate
|
||||
* UART or USRT communication mode
|
||||
* Character size
|
||||
* Data order
|
||||
* Flow control
|
||||
* Data transfer: transmission, reception
|
||||
|
||||
Applications
|
||||
------------
|
||||
|
||||
They are commonly used in a terminal application or low-speed communication
|
||||
between devices.
|
||||
|
||||
Dependencies
|
||||
------------
|
||||
|
||||
USART capable hardware.
|
||||
|
||||
Concurrency
|
||||
-----------
|
||||
|
||||
Write buffer should not be changed while data is being sent.
|
||||
|
||||
|
||||
Limitations
|
||||
-----------
|
||||
|
||||
* The driver does not support 9-bit character size.
|
||||
* The "USART with ISO7816" mode can be only used in ISO7816 capable devices.
|
||||
And the SCK pin can't be set directly. Application can use a GCLK output PIN
|
||||
to generate SCK. For example to communicate with a SMARTCARD with ISO7816
|
||||
(F = 372 ; D = 1), and baudrate=9600, the SCK pin output frequency should be
|
||||
config as 372*9600=3571200Hz. More information can be refer to ISO7816 Specification.
|
||||
|
||||
Known issues and workarounds
|
||||
----------------------------
|
||||
|
||||
N/A
|
||||
Reference in New Issue
Block a user