File tree Expand file tree Collapse file tree 2 files changed +4
-0
lines changed
src/viam/examples/modules/simple Expand file tree Collapse file tree 2 files changed +4
-0
lines changed Original file line number Diff line number Diff line change 1111using namespace viam ::sdk;
1212
1313int main () {
14+ // Every Viam C++ SDK program must have one and only one Instance object which is created before
15+ // any other C++ SDK objects and stays alive until all Viam C++ SDK objects are destroyed.
1416 Instance inst;
1517
1618 const char * uri = " http://localhost:8080/" ; // replace with your URI if connecting securely
Original file line number Diff line number Diff line change @@ -76,6 +76,8 @@ ProtoStruct MySensor::get_readings(const ProtoStruct&) {
7676}
7777
7878int main (int argc, char ** argv) try {
79+ // Every Viam C++ SDK program must have one and only one Instance object which is created before
80+ // any other C++ SDK objects and stays alive until all Viam C++ SDK objects are destroyed.
7981 Instance inst;
8082
8183 Model mysensor_model (" viam" , " sensor" , " mysensor" );
You can’t perform that action at this time.
0 commit comments