Skip to content

AndreiLosev/eva_sdk

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

import 'package:eva_sdk/eva_sdk.dart';
import 'package:eva_sdk/src/debug_log.dart';

void main(List<String> args) async {
  bool isProd = !args.contains('--debug');
  // isProd = false;
  print(args);

  if (isProd) {
    dbgInit('/home/ut/log');
    await svc().load();
  } else {
    dbgInit('console');
    await svc().debugLoad('/home/andrei/documents/my/eva_sdk/bin/config.yaml');
  }

  await svc().init(ServiceInfo('losev', '0.0.0'));
  await svc().subscribeOIDs([(Oid('sensor:test1/sens1'), (x, y, z) => dbg([x.to<int>().toMap(), y, z]))], EventKind.any);
  await svc().subscribeRaw([('SVC/#', (a) => print([deserialize(a.payload), a.primarySender, a.topic]))]);
}

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages