SWIG experiments: introduce context
This commit is contained in:
1 parent
a503dfcd98
commit
1562b75fc9
11 files changed
+434
-87
No files matched your search
@@ -1,8 +1,11 @@
|
||||
#include "pm3.h"
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
pm3_context *ctx;
|
||||
ctx = pm3_init();
|
||||
pm3_device *p;
|
||||
p = pm3_open("/dev/ttyACM0");
|
||||
p = pm3_open(ctx, "/dev/ttyACM0");
|
||||
pm3_console(p, "hw status");
|
||||
pm3_close(p);
|
||||
pm3_exit(ctx);
|
||||
}
|
||||
Reference in new issue
Block a user