:orphan:
.. raw:: html
.. dtcompatible:: atmel,sam-i2c-twim
.. _dtbinding_atmel_sam_i2c_twim:
atmel,sam-i2c-twim
##################
Vendor: :ref:`Atmel Corporation `
Description
***********
These nodes are "i2c" bus nodes.
.. code-block:: none
Atmel SAM4L Family I2C (TWIM) node
The Atmel Two-wire Master Interface (TWIM) interconnects components on a
unique two-wire bus, made up of one clock line and one data line with speeds
of up to 3.4 Mbit/s, based on a byte-oriented transfer format. The TWIM is
always a bus master and can transfer sequential or single bytes. Multiple
master capability is supported. Arbitration of the bus is performed
internally and relinquishes the bus automatically if the bus arbitration is
lost.
When using speeds above standard mode, user may need adjust clock and data
lines slew and strength parameters. In general, slew 0 and minimal strength
is enougth for short buses and light loads. As reference, the below
is the lowest power configuration:
std-clk-slew-lim = <0>;
std-clk-strength-low = "0.5";
std-data-slew-lim = <0>;
std-data-strength-low = "0.5";
hs-clk-slew-lim = <0>;
hs-clk-strength-high = "0.5";
hs-clk-strength-low = "0.5";
hs-data-slew-lim = <0>;
hs-data-strength-low = "0.5";
For best performances, user can tune the slope curves using an osciloscope.
The tuning should be performed by groups defined -. The prefix
std- configures fast/fast-plus mode speeds and hs- selects the
high speed mode. The tune should be performed for both clock and data lines
on both speed modes.
Properties
**********
.. tabs::
.. group-tab:: Node specific properties
Properties not inherited from the base binding file.
.. list-table::
:widths: 1 1 4
:header-rows: 1
* - Name
- Type
- Details
* - ``peripheral-id``
- ``int``
- .. code-block:: none
peripheral ID
This property is **required**.
* - ``std-clk-slew-lim``
- ``int``
- .. code-block:: none
Slew limit of the TWCK output buffer. This should be adjusted with
std-clk-strength-low to fine tune the TWCK slope.
This property is **required**.
Legal values: ``0``, ``1``, ``2``, ``3``
* - ``std-clk-strength-low``
- ``string``
- .. code-block:: none
Pull-down drive strength of the TWCK output buffer in fast/fast plus
mode. This should be adjusted to provide proper TWCK line fall time.
The value represents the port output current in mA when signal on
low level.
This property is **required**.
Legal values: ``'0.5'``, ``'1.0'``, ``'1.6'``, ``'3.1'``, ``'6.2'``, ``'9.3'``, ``'15.5'``, ``'21.8'``
* - ``std-data-slew-lim``
- ``int``
- .. code-block:: none
Slew limit of the TWD output buffer. This should be adjusted with
std-data-strength-low to fine tune the TWD slope.
This property is **required**.
Legal values: ``0``, ``1``, ``2``, ``3``
* - ``std-data-strength-low``
- ``string``
- .. code-block:: none
Pull-down drive strength of the TWD output buffer in fast/fast plus
mode. This should be adjusted to provide proper TWD line fall time.
The value represents the port output current in mA when signal on
low level.
This property is **required**.
Legal values: ``'0.5'``, ``'1.0'``, ``'1.6'``, ``'3.1'``, ``'6.2'``, ``'9.3'``, ``'15.5'``, ``'21.8'``
* - ``hs-clk-slew-lim``
- ``int``
- .. code-block:: none
Slew limit of the TWCK output buffer in high speed mode. This
should be adjusted with both hs-clk-strength-high and
hs-clk-strength-low to fine tune the TWCK slope.
This property is **required**.
Legal values: ``0``, ``1``, ``2``, ``3``
* - ``hs-clk-strength-high``
- ``string``
- .. code-block:: none
Pull-up drive strength of the TWCK output buffer in high speed
mode. This should be adjusted to provide proper TWCK line rise time.
The value represents the port output current in mA when signal on
high level.
This property is **required**.
Legal values: ``'0.5'``, ``'1.0'``, ``'1.5'``, ``'3.0'``
* - ``hs-clk-strength-low``
- ``string``
- .. code-block:: none
Pull-down drive strength of the TWCK output buffer in high speed
mode. This should be adjusted to provide proper TWCK line fall time.
The value represents the port output current in mA when signal on
low level.
This property is **required**.
Legal values: ``'0.5'``, ``'1.0'``, ``'1.6'``, ``'3.1'``, ``'6.2'``, ``'9.3'``, ``'15.5'``, ``'21.8'``
* - ``hs-data-slew-lim``
- ``int``
- .. code-block:: none
Slew limit of the TWD output buffer in high speed mode. This
should be adjusted with hs-data-strength-low to fine tune the TWD
slope.
This property is **required**.
Legal values: ``0``, ``1``, ``2``, ``3``
* - ``hs-data-strength-low``
- ``string``
- .. code-block:: none
Pull-down drive strength of the TWD output buffer in high speed
mode. This should be adjusted to provide proper TWD line fall time.
The value represents the port output current in mA when signal on
low level.
Legal values: ``'0.5'``, ``'1.0'``, ``'1.6'``, ``'3.1'``, ``'6.2'``, ``'9.3'``, ``'15.5'``, ``'21.8'``
* - ``hs-master-code``
- ``int``
- .. code-block:: none
3-bit code to be prefixed with 0b00001 to form a unique
8-bit HS-mode master code (0000 1XXX)
This property is **required**.
Legal values: ``0``, ``1``, ``2``, ``3``, ``4``, ``5``, ``6``, ``7``
* - ``clock-frequency``
- ``int``
- .. code-block:: none
Initial clock frequency in Hz
* - ``pinctrl-0``
- ``phandles``
- .. code-block:: none
Pin configuration/s for the first state. Content is specific to the
selected pin controller driver implementation.
* - ``pinctrl-1``
- ``phandles``
- .. code-block:: none
Pin configuration/s for the second state. See pinctrl-0.
* - ``pinctrl-2``
- ``phandles``
- .. code-block:: none
Pin configuration/s for the third state. See pinctrl-0.
* - ``pinctrl-3``
- ``phandles``
- .. code-block:: none
Pin configuration/s for the fourth state. See pinctrl-0.
* - ``pinctrl-4``
- ``phandles``
- .. code-block:: none
Pin configuration/s for the fifth state. See pinctrl-0.
* - ``pinctrl-names``
- ``string-array``
- .. code-block:: none
Names for the provided states. The number of names needs to match the
number of states.
.. group-tab:: Deprecated node specific properties
Deprecated properties not inherited from the base binding file.
(None)
.. group-tab:: Base properties
Properties inherited from the base binding file, which defines
common properties that may be set on many nodes. Not all of these
may apply to the "atmel,sam-i2c-twim" compatible.
.. list-table::
:widths: 1 1 4
:header-rows: 1
* - Name
- Type
- Details
* - ``reg``
- ``array``
- .. code-block:: none
register space
This property is **required**.
See :ref:`zephyr:dt-important-props` for more information.
* - ``interrupts``
- ``array``
- .. code-block:: none
interrupts for device
This property is **required**.
See :ref:`zephyr:dt-important-props` for more information.
* - ``#address-cells``
- ``int``
- .. code-block:: none
number of address cells in reg property
This property is **required**.
Constant value: ``1``
* - ``#size-cells``
- ``int``
- .. code-block:: none
number of size cells in reg property
This property is **required**.
* - ``status``
- ``string``
- .. code-block:: none
indicates the operational status of a device
Legal values: ``'ok'``, ``'okay'``, ``'disabled'``, ``'reserved'``, ``'fail'``, ``'fail-sss'``
See :ref:`zephyr:dt-important-props` for more information.
* - ``compatible``
- ``string-array``
- .. code-block:: none
compatible strings
This property is **required**.
See :ref:`zephyr:dt-important-props` for more information.
* - ``reg-names``
- ``string-array``
- .. code-block:: none
name of each register space
* - ``interrupts-extended``
- ``compound``
- .. code-block:: none
extended interrupt specifier for device
* - ``interrupt-names``
- ``string-array``
- .. code-block:: none
name of each interrupt
* - ``interrupt-parent``
- ``phandle``
- .. code-block:: none
phandle to interrupt controller node
* - ``label``
- ``string``
- .. code-block:: none
Human readable string describing the device (used as device_get_binding() argument)
See :ref:`zephyr:dt-important-props` for more information.
This property is **deprecated**.
* - ``clocks``
- ``phandle-array``
- .. code-block:: none
Clock gate information
* - ``clock-names``
- ``string-array``
- .. code-block:: none
name of each clock
* - ``dmas``
- ``phandle-array``
- .. code-block:: none
DMA channels specifiers
* - ``dma-names``
- ``string-array``
- .. code-block:: none
Provided names of DMA channel specifiers
* - ``io-channels``
- ``phandle-array``
- .. code-block:: none
IO channels specifiers
* - ``io-channel-names``
- ``string-array``
- .. code-block:: none
Provided names of IO channel specifiers
* - ``mboxes``
- ``phandle-array``
- .. code-block:: none
mailbox / IPM channels specifiers
* - ``mbox-names``
- ``string-array``
- .. code-block:: none
Provided names of mailbox / IPM channel specifiers
* - ``wakeup-source``
- ``boolean``
- .. code-block:: none
Property to identify that a device can be used as wake up source.
When this property is provided a specific flag is set into the
device that tells the system that the device is capable of
wake up the system.
Wake up capable devices are disabled (interruptions will not wake up
the system) by default but they can be enabled at runtime if necessary.
* - ``power-domain``
- ``phandle``
- .. code-block:: none
Power domain the device belongs to.
The device will be notified when the power domain it belongs to is either
suspended or resumed.