@@ -170,13 +170,13 @@ There must be a function to check for syscall driver existence.
170170Signature:
171171
172172```
173- bool libtock_[name]_exists (void);
173+ bool libtock_[name]_driver_exists (void);
174174```
175175
176176Example:
177177
178178``` c
179- bool libtock_[name]_exists (void ) {
179+ bool libtock_[name]_driver_exists (void ) {
180180 return driver_exists(DRIVER_NUM_ [ NAME] );
181181}
182182```
@@ -202,7 +202,6 @@ The `[name].h` header file must look like:
202202#pragma once
203203
204204#include " ../tock.h"
205- #include " syscalls/[name]_syscalls.h"
206205
207206#ifdef __cplusplus
208207extern "C" {
@@ -215,7 +214,8 @@ extern "C" {
215214#endif
216215```
217216
218- The ` [name].h ` header file must include the syscalls header.
217+ The ` [name].h ` header file must NOT include the syscalls header. Applications
218+ wanting to use the syscalls directly must include the syscalls header.
219219
220220### Defining a Callback for Asynchronous Operations
221221
@@ -236,6 +236,24 @@ they should have the last argument be a callback function pointer.
236236returncode_t libtock_[name]_[desc](<arguments>, libtock_[name]_callback_[desc] cb);
237237```
238238
239+ #### Exists
240+
241+ There must be a function to check for syscall driver existence.
242+
243+ Signature:
244+
245+ ```
246+ bool libtock_[name]_exists(void);
247+ ```
248+
249+ Example:
250+
251+ ``` c
252+ bool libtock_[name]_exists(void ) {
253+ return libtock_ [ name] _ driver_exists();
254+ }
255+ ```
256+
239257### Example:
240258
241259
@@ -309,7 +327,6 @@ file is used in a C++ app.
309327#pragma once
310328
311329#include <libtock/tock.h>
312- #include <libtock/[category]/syscalls/[name]_syscalls.h>
313330
314331#ifdef __cplusplus
315332extern "C" {
@@ -379,7 +396,6 @@ The libtock-sync `[name].h` header file must look like:
379396``` c
380397#pragma once
381398
382- #include " syscalls/temperature_syscalls.h"
383399#include < libtock/tock.h>
384400
385401#ifdef __cplusplus
0 commit comments