Skip to content

Commit d3f1b82

Browse files
committed
include: drivers: usb: bc12: fix doxygen comments
Trivial fixes to doxygen documentation of BC 1.2 header Signed-off-by: Benjamin Cabé <[email protected]>
1 parent d2f4497 commit d3f1b82

File tree

1 file changed

+20
-12
lines changed

1 file changed

+20
-12
lines changed

include/zephyr/drivers/usb/usb_bc12.h

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,9 @@ extern "C" {
6363

6464
/** @brief BC1.2 device role. */
6565
enum bc12_role {
66-
BC12_DISCONNECTED,
67-
BC12_PORTABLE_DEVICE,
68-
BC12_CHARGING_PORT,
66+
BC12_DISCONNECTED, /**< No BC1.2 device connected */
67+
BC12_PORTABLE_DEVICE, /**< BC1.2 device is a portable device */
68+
BC12_CHARGING_PORT, /**< BC1.2 device is a charging port */
6969
};
7070

7171
/** @brief BC1.2 charging partner type. */
@@ -88,25 +88,33 @@ enum bc12_type {
8888

8989
/**
9090
* @brief BC1.2 detected partner state.
91-
*
92-
* @param bc12_role Current role of the BC1.2 device.
93-
* @param type Charging partner type. Valid when bc12_role is BC12_PORTABLE_DEVICE.
94-
* @param current_ma Current, in uA, that the charging partner provides. Valid when bc12_role is
95-
* BC12_PORTABLE_DEVICE.
96-
* @param voltage_mv Voltage, in uV, that the charging partner provides. Valid when bc12_role is
97-
* BC12_PORTABLE_DEVICE.
98-
* @param pd_partner_connected True if a PD partner is currently connected. Valid when bc12_role is
99-
* BC12_CHARGING_PORT.
10091
*/
10192
struct bc12_partner_state {
93+
/** Current role of the BC1.2 device. */
10294
enum bc12_role bc12_role;
10395
union {
10496
struct {
97+
/**
98+
* Charging partner type.
99+
* Valid when @ref bc12_role is @ref BC12_PORTABLE_DEVICE.
100+
*/
105101
enum bc12_type type;
102+
/**
103+
* Current, in uA, that the charging partner provides.
104+
* Valid when @ref bc12_role is @ref BC12_PORTABLE_DEVICE.
105+
*/
106106
int current_ua;
107+
/**
108+
* Voltage, in uV, that the charging partner provides.
109+
* Valid when @ref bc12_role is @ref BC12_PORTABLE_DEVICE.
110+
*/
107111
int voltage_uv;
108112
};
109113
struct {
114+
/**
115+
* True if a PD partner is currently connected.
116+
* Valid when @ref bc12_role is @ref BC12_CHARGING_PORT.
117+
*/
110118
bool pd_partner_connected;
111119
};
112120
};

0 commit comments

Comments
 (0)