Skip to content

Commit de2c20f

Browse files
author
Cam K.
committed
Whisker documentation
1 parent 78fdb07 commit de2c20f

File tree

1 file changed

+18
-9
lines changed

1 file changed

+18
-9
lines changed

include/cats/whisker.h

+18-9
Original file line numberDiff line numberDiff line change
@@ -175,36 +175,41 @@ typedef struct cats_whisker {
175175
struct cats_whisker* next;
176176
} cats_whisker_t;
177177

178-
/* @brief Encode a whisker into a byte array
178+
/**
179+
* @brief Encode a whisker into a byte array
179180
*
180181
* @param whisker The whisker to encode
181182
* @param out The byte array to write to
182183
* @return The number of bytes written to out
183184
*/
184185
size_t cats_whisker_encode(const cats_whisker_t* whisker, uint8_t* out);
185186

186-
/* @brief Decode a whisker from a byte array
187+
/**
188+
* @brief Decode a whisker from a byte array
187189
*
188190
* @param data The byte array to decode
189191
* @param out The whisker to write to
190192
* @return CATS_SUCCESS on success, CATS_FAIL on failure
191193
*/
192194
int cats_whisker_decode(const uint8_t* data, cats_whisker_t* out);
193195

194-
/* @brief Get the length of a whisker base type
196+
/**
197+
* @brief Get the length of a whisker base type
195198
*
196199
* @param type The whisker type
197200
* @return The length of the whisker base type
198201
*/
199202
int cats_whisker_base_len(const cats_whisker_type_t type);
200203

201-
/* @brief Create a new whisker
204+
/**
205+
* @brief Create a new whisker
202206
*
203207
* @return A pointer to the new whisker
204208
*/
205209
cats_whisker_t* cats_whisker_new();
206210

207-
/* @brief Add a future hop to a route whisker
211+
/**
212+
* @brief Add a future hop to a route whisker
208213
*
209214
* @param route The route whisker to add to
210215
* @param callsign The callsign of the hop
@@ -213,7 +218,8 @@ cats_whisker_t* cats_whisker_new();
213218
*/
214219
cats_route_hop_t* cats_route_add_future_hop(cats_route_whisker_t* route, const char* callsign, uint8_t ssid);
215220

216-
/* @brief Add a past hop to a route whisker
221+
/**
222+
* @brief Add a past hop to a route whisker
217223
*
218224
* @param route The route whisker to add to
219225
* @param callsign The callsign of the hop
@@ -223,21 +229,24 @@ cats_route_hop_t* cats_route_add_future_hop(cats_route_whisker_t* route, const c
223229
*/
224230
cats_route_hop_t* cats_route_add_past_hop(cats_route_whisker_t* route, const char* callsign, uint8_t ssid, float rssi);
225231

226-
/* @brief Add an internet hop to a route whisker
232+
/**
233+
* @brief Add an internet hop to a route whisker
227234
*
228235
* @param route The route whisker to add to
229236
* @return A pointer to the new hop
230237
*/
231238
cats_route_hop_t* cats_route_add_inet_hop(cats_route_whisker_t* route);
232239

233-
/* @brief Destroy a route whisker
240+
/**
241+
* @brief Destroy a route whisker
234242
*
235243
* @param route The route whisker to destroy
236244
* @note This function must be used rather than free()
237245
*/
238246
void cats_route_destroy(cats_route_whisker_t* route);
239247

240-
/* @brief Create a new route whisker
248+
/**
249+
* @brief Create a new route whisker
241250
*
242251
* @param max_digipeats The maximum number of digipeats
243252
* @return The new route whisker

0 commit comments

Comments
 (0)