dexcom 1.0.2 copy "dexcom: ^1.0.2" to clipboard
dexcom: ^1.0.2 copied to clipboard

dexcom for Dart allows you to use Dexcom Share to get your Dexcom CGM data, or anybody else's, to run your application.

example/lib/example.dart

import 'package:dexcom/dexcom.dart';

void main({String username = "", String password = ""}) async {
  Dexcom dexcom = Dexcom(username: username, password: password, debug: false);
  DexcomStreamProvider provider = DexcomStreamProvider(
    dexcom,
    debug: true,
    buffer: 10,
  );

  print("Dexcom: $dexcom");
  print("Provider: $provider");

  print("Dexcom readings: ${await dexcom.getGlucoseReadings(maxCount: 3)}");
  print("Dexcom verify: ${await dexcom.verify()}");

  provider.listen(
    onData: (data) => print('Stream received: $data'),
    onError: (error) => print('Stream errored: $error'),
    onTimerChange: (time) {
      print("Stream timer: $time");
    },
  );
}
1
likes
0
points
573
downloads

Publisher

verified publishercalebh101.com

Weekly Downloads

dexcom for Dart allows you to use Dexcom Share to get your Dexcom CGM data, or anybody else's, to run your application.

Homepage
Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

http, intl

More

Packages that depend on dexcom