|
Zephyr API Documentation 4.5.99
A Scalable Open Source RTOS
|
Macros | |
| #define | DT_COUNTER_ALARMS_CTLR_BY_IDX(node_id, counter_alarm_pha, idx) |
| Get the node identifier for the counter controller from a counter-alarms property at an index. | |
| #define | DT_COUNTER_ALARMS_CTLR_BY_NAME(node_id, counter_alarm_pha, name) |
| Get the node identifier for the counter controller from a counter-alarms property by name. | |
| #define | DT_COUNTER_ALARMS_CTLR(node_id, counter_alarm_pha) |
| Equivalent to DT_COUNTER_ALARMS_CTLR_BY_IDX(node_id, counter_alarm_pha, 0). | |
| #define | DT_COUNTER_ALARMS_CELL_BY_IDX(node_id, counter_alarm_pha, idx, cell) |
| Get counter alarm specifier's cell value at an index. | |
| #define | DT_COUNTER_ALARMS_CELL_BY_NAME(node_id, counter_alarm_pha, name, cell) |
| Get a counter alarm specifier's cell value by name. | |
| #define | DT_COUNTER_ALARMS_CELL(node_id, counter_alarm_pha, cell) |
| Equivalent to DT_COUNTER_ALARMS_CELL_BY_IDX(node_id, counter_alarm_pha, 0, cell). | |
| #define | DT_COUNTER_ALARMS_CHANNEL_BY_IDX(node_id, counter_alarm_pha, idx) |
| Get a counter alarm specifier's channel cell value at an index. | |
| #define | DT_COUNTER_ALARMS_CHANNEL_BY_NAME(node_id, counter_alarm_pha, name) |
| Get a counter alarm specifier's channel cell value by name. | |
| #define | DT_COUNTER_ALARMS_CHANNEL(node_id, counter_alarm_pha) |
| Equivalent to DT_COUNTER_ALARMS_CHANNEL_BY_IDX(node_id, counter_alarm_pha, 0). | |
| #define | DT_INST_COUNTER_ALARMS_CTLR_BY_IDX(inst, counter_alarm_pha, idx) |
Get the node identifier for the counter controller from a DT_DRV_COMPAT instance's counter-alarms property at an index. | |
| #define | DT_INST_COUNTER_ALARMS_CTLR_BY_NAME(inst, counter_alarm_pha, name) |
Get the node identifier for the counter controller from a DT_DRV_COMPAT instance's counter-alarms property by name. | |
| #define | DT_INST_COUNTER_ALARMS_CTLR(inst, counter_alarm_pha) |
| Equivalent to DT_INST_COUNTER_ALARMS_CTLR_BY_IDX(inst, counter_alarm_pha, 0). | |
| #define | DT_INST_COUNTER_ALARMS_CELL_BY_IDX(inst, counter_alarm_pha, idx, cell) |
Get a DT_DRV_COMPAT instance's counter alarm specifier's cell value at an index. | |
| #define | DT_INST_COUNTER_ALARMS_CELL_BY_NAME(inst, counter_alarm_pha, name, cell) |
Get a DT_DRV_COMPAT instance's counter alarm specifier's cell value by name. | |
| #define | DT_INST_COUNTER_ALARMS_CELL(inst, counter_alarm_pha, cell) |
| Equivalent to DT_INST_COUNTER_ALARMS_CELL_BY_IDX(inst, counter_alarm_pha, 0, cell). | |
| #define | DT_INST_COUNTER_ALARMS_CHANNEL_BY_IDX(inst, counter_alarm_pha, idx) |
| Equivalent to DT_INST_COUNTER_ALARMS_CELL_BY_IDX(inst, counter_alarm_pha, idx, channel). | |
| #define | DT_INST_COUNTER_ALARMS_CHANNEL_BY_NAME(inst, counter_alarm_pha, name) |
| Equivalent to DT_INST_COUNTER_ALARMS_CELL_BY_NAME(inst, counter_alarm_pha, name, channel). | |
| #define | DT_INST_COUNTER_ALARMS_CHANNEL(inst, counter_alarm_pha) |
| Equivalent to DT_INST_COUNTER_ALARMS_CHANNEL_BY_IDX(inst, counter_alarm_pha, 0). | |
| #define DT_COUNTER_ALARMS_CELL | ( | node_id, | |
| counter_alarm_pha, | |||
| cell ) |
#include <zephyr/devicetree/counter-alarm.h>
Equivalent to DT_COUNTER_ALARMS_CELL_BY_IDX(node_id, counter_alarm_pha, 0, cell).
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| cell | lowercase-and-underscores cell name |
| #define DT_COUNTER_ALARMS_CELL_BY_IDX | ( | node_id, | |
| counter_alarm_pha, | |||
| idx, | |||
| cell ) |
#include <zephyr/devicetree/counter-alarm.h>
Get counter alarm specifier's cell value at an index.
Example devicetree fragment:
counter1: counter-controller@... {
compatible = "vnd,counter";
#counter-alarm-cells = <1>;
};
counter2: counter-controller@... {
compatible = "vnd,counter";
#counter-alarm-cells = <1>;
};
n: node {
counter-alarms = <&counter1 1>, <&counter2 3>;
};
Bindings fragment for the "vnd,counter" compatible:
counter-alarm-cells: - channel
Example usage:
DT_COUNTER_ALARMS_CELL_BY_IDX(DT_NODELABEL(n), counter_alarms, 0, channel) // 1 DT_COUNTER_ALARMS_CELL_BY_IDX(DT_NODELABEL(n), counter_alarms, 1, channel) // 3
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| idx | logical index into counter_alarm_pha |
| cell | lowercase-and-underscores cell name |
idx | #define DT_COUNTER_ALARMS_CELL_BY_NAME | ( | node_id, | |
| counter_alarm_pha, | |||
| name, | |||
| cell ) |
#include <zephyr/devicetree/counter-alarm.h>
Get a counter alarm specifier's cell value by name.
Example devicetree fragment:
counter1: counter-controller@... {
compatible = "vnd,counter";
#counter-alarm-cells = <1>;
};
counter2: counter-controller@... {
compatible = "vnd,counter";
#counter-alarm-cells = <1>;
};
n: node {
counter-alarms = <&counter1 1>, <&counter2 3>;
counter-alarm-names = "alpha", "beta";
};
Bindings fragment for the "vnd,counter" compatible:
counter-alarm-cells: - channel
Example usage:
DT_COUNTER_ALARMS_CELL_BY_NAME(DT_NODELABEL(n), counter_alarms, alpha, channel) // 1 DT_COUNTER_ALARMS_CELL_BY_NAME(DT_NODELABEL(n), counter_alarms, beta, channel) // 3
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| name | lowercase-and-underscores name of a counter-alarms element as defined by the node's counter-alarm-names property |
| cell | lowercase-and-underscores cell name |
| #define DT_COUNTER_ALARMS_CHANNEL | ( | node_id, | |
| counter_alarm_pha ) |
#include <zephyr/devicetree/counter-alarm.h>
Equivalent to DT_COUNTER_ALARMS_CHANNEL_BY_IDX(node_id, counter_alarm_pha, 0).
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| #define DT_COUNTER_ALARMS_CHANNEL_BY_IDX | ( | node_id, | |
| counter_alarm_pha, | |||
| idx ) |
#include <zephyr/devicetree/counter-alarm.h>
Get a counter alarm specifier's channel cell value at an index.
This macro only works for counter alarm specifiers with cells named channel. Refer to the node's binding to check if necessary.
This is equivalent to DT_COUNTER_ALARMS_CELL_BY_IDX(node_id, counter_alarm_pha, idx, channel).
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| idx | logical index into counter_alarm_pha |
idx | #define DT_COUNTER_ALARMS_CHANNEL_BY_NAME | ( | node_id, | |
| counter_alarm_pha, | |||
| name ) |
#include <zephyr/devicetree/counter-alarm.h>
Get a counter alarm specifier's channel cell value by name.
This macro only works for counter alarm specifiers with cells named channel. Refer to the node's binding to check if necessary.
This is equivalent to DT_COUNTER_ALARMS_CELL_BY_NAME(node_id, counter_alarm_pha, name, channel).
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| name | lowercase-and-underscores name of a counter-alarms element as defined by the node's counter-alarm-names property |
| #define DT_COUNTER_ALARMS_CTLR | ( | node_id, | |
| counter_alarm_pha ) |
#include <zephyr/devicetree/counter-alarm.h>
Equivalent to DT_COUNTER_ALARMS_CTLR_BY_IDX(node_id, counter_alarm_pha, 0).
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
counter_alarm_pha | #define DT_COUNTER_ALARMS_CTLR_BY_IDX | ( | node_id, | |
| counter_alarm_pha, | |||
| idx ) |
#include <zephyr/devicetree/counter-alarm.h>
Get the node identifier for the counter controller from a counter-alarms property at an index.
Example devicetree fragment:
counter1: counter-controller@... { ... };
counter2: counter-controller@... { ... };
n: node {
counter-alarms = <&counter1 1>, <&counter2 3>;
};
Example usage:
DT_COUNTER_ALARMS_CTLR_BY_IDX(DT_NODELABEL(n), counter_alarms, 0)
// DT_NODELABEL(counter1)
DT_COUNTER_ALARMS_CTLR_BY_IDX(DT_NODELABEL(n), counter_alarms, 1)
// DT_NODELABEL(counter2)
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| idx | logical index into counter_alarm_pha |
idx | #define DT_COUNTER_ALARMS_CTLR_BY_NAME | ( | node_id, | |
| counter_alarm_pha, | |||
| name ) |
#include <zephyr/devicetree/counter-alarm.h>
Get the node identifier for the counter controller from a counter-alarms property by name.
Example devicetree fragment:
counter1: counter-controller@... { ... };
counter2: counter-controller@... { ... };
n: node {
counter-alarms = <&counter1 1>, <&counter2 3>;
counter-alarm-names = "alpha", "beta";
};
Example usage:
DT_COUNTER_ALARMS_CTLR_BY_NAME(DT_NODELABEL(n), counter_alarms, alpha)
// DT_NODELABEL(counter1)
DT_COUNTER_ALARMS_CTLR_BY_NAME(DT_NODELABEL(n), counter_alarms, beta)
// DT_NODELABEL(counter2)
| node_id | node identifier |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| name | lowercase-and-underscores name of a counter-alarms element as defined by the node's counter-alarm-names property |
| #define DT_INST_COUNTER_ALARMS_CELL | ( | inst, | |
| counter_alarm_pha, | |||
| cell ) |
#include <zephyr/devicetree/counter-alarm.h>
Equivalent to DT_INST_COUNTER_ALARMS_CELL_BY_IDX(inst, counter_alarm_pha, 0, cell).
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| cell | lowercase-and-underscores cell name |
| #define DT_INST_COUNTER_ALARMS_CELL_BY_IDX | ( | inst, | |
| counter_alarm_pha, | |||
| idx, | |||
| cell ) |
#include <zephyr/devicetree/counter-alarm.h>
Get a DT_DRV_COMPAT instance's counter alarm specifier's cell value at an index.
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| idx | logical index into counter_alarm_pha |
| cell | lowercase-and-underscores cell name |
idx | #define DT_INST_COUNTER_ALARMS_CELL_BY_NAME | ( | inst, | |
| counter_alarm_pha, | |||
| name, | |||
| cell ) |
#include <zephyr/devicetree/counter-alarm.h>
Get a DT_DRV_COMPAT instance's counter alarm specifier's cell value by name.
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| name | lowercase-and-underscores name of a counter-alarms element as defined by the node's counter-alarm-names property |
| cell | lowercase-and-underscores cell name |
| #define DT_INST_COUNTER_ALARMS_CHANNEL | ( | inst, | |
| counter_alarm_pha ) |
#include <zephyr/devicetree/counter-alarm.h>
Equivalent to DT_INST_COUNTER_ALARMS_CHANNEL_BY_IDX(inst, counter_alarm_pha, 0).
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| #define DT_INST_COUNTER_ALARMS_CHANNEL_BY_IDX | ( | inst, | |
| counter_alarm_pha, | |||
| idx ) |
#include <zephyr/devicetree/counter-alarm.h>
Equivalent to DT_INST_COUNTER_ALARMS_CELL_BY_IDX(inst, counter_alarm_pha, idx, channel).
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| idx | logical index into counter_alarm_pha |
idx | #define DT_INST_COUNTER_ALARMS_CHANNEL_BY_NAME | ( | inst, | |
| counter_alarm_pha, | |||
| name ) |
#include <zephyr/devicetree/counter-alarm.h>
Equivalent to DT_INST_COUNTER_ALARMS_CELL_BY_NAME(inst, counter_alarm_pha, name, channel).
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| name | lowercase-and-underscores name of a counter-alarms element as defined by the node's counter-alarm-names property |
| #define DT_INST_COUNTER_ALARMS_CTLR | ( | inst, | |
| counter_alarm_pha ) |
#include <zephyr/devicetree/counter-alarm.h>
Equivalent to DT_INST_COUNTER_ALARMS_CTLR_BY_IDX(inst, counter_alarm_pha, 0).
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| #define DT_INST_COUNTER_ALARMS_CTLR_BY_IDX | ( | inst, | |
| counter_alarm_pha, | |||
| idx ) |
#include <zephyr/devicetree/counter-alarm.h>
Get the node identifier for the counter controller from a DT_DRV_COMPAT instance's counter-alarms property at an index.
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| idx | logical index into counter_alarm_pha |
idx | #define DT_INST_COUNTER_ALARMS_CTLR_BY_NAME | ( | inst, | |
| counter_alarm_pha, | |||
| name ) |
#include <zephyr/devicetree/counter-alarm.h>
Get the node identifier for the counter controller from a DT_DRV_COMPAT instance's counter-alarms property by name.
| inst | DT_DRV_COMPAT instance number |
| counter_alarm_pha | lowercase-and-underscores counter alarm property with type "phandle-array" |
| name | lowercase-and-underscores name of a counter-alarms element as defined by the node's counter-alarm-names property |