cgm图编辑器_桥接Dexcom分享CGM接收器和Nightscout

2024-01-01 14:30

本文主要是介绍cgm图编辑器_桥接Dexcom分享CGM接收器和Nightscout,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

cgm图编辑器

cgm图编辑器

I've long lamented the sad state of Diabetes technology. For the last 20 years I've been told that it'll be cured in the next few years. (Spoiler: That hasn't happened.)

我一直为糖尿病技术的悲哀感叹。 在过去的20年中,我被告知它将在未来几年内治愈。 (剧透:这没有发生。)

Fortunately some technological breakthroughs have happened, like the CGM (Continuous Glucose Meter). This device has a transmitted embedded in my belly that transmits to a small receiver. However, my wife couldn't see my blood sugar remotely, so the Nightscout open source project pretends to be computer connected to the receiver, then uploads it to your own website. Then you can see your blood sugar on your watch, or family and friends can log in also. This project has been moving along nicely for a year or so now.

幸运的是,发生了一些技术突破,例如CGM(连续血糖仪)。 该设备的发射器嵌入我的腹部,然后发射到小型接收器。 但是,我的妻子无法远程看到我的血糖,因此Nightscout开源项目假装将计算机连接到接收器,然后将其上传到您自己的网站。 然后,您可以在手表上看到血糖,或者家人和朋友也可以登录。 这个项目已经进行了一年左右。

Just last month Dexcom, the CGM maker, released an update to their receiver that includes Bluetooth, called the Dexcom Share. Now my transmitter goes to my Dexcom device which then bounces via Bluetooth LE to my phone, which is then uploaded to the Dexcom site. The Dexcom iPhone app will support the Apple Watch in the future as well, they say.

就在上个月,CGM制造商Dexcom向其接收器发布了包括蓝牙在内的更新,称为Dexcom Share。 现在,我的发射器转到我的Dexcom设备,然后该设备通过Bluetooth LE反弹到我的手机,然后将其上传到Dexcom站点。 他们说,Dexcom iPhone应用程序将来也将支持Apple Watch。

However, I'd like more control over my data. Dexcom's solution (as of the time of this writing) is iPhone/iPad only. Not everyone can afford an iWatch and iDevices. I'd like to use my Pebble Watch, for example, which is supported in Nightscout today.

但是,我想对数据进行更多控制。 Dexcom的解决方案(在撰写本文时)仅适用于iPhone / iPad。 并非每个人都能买得起iWatch和iDevices。 例如,我想使用我的Pebble手表,今天的Nightscout支持该手表。

I got the Dexcom Share at 3:30pm today in the mail. By 4:40pm it was paired to my iPhone and working nicely. So what I really need is a simple bridge that takes my Dexcom Share data and copies it to Nightscout. From there I can analyze it, send it to my Pebble, or do whatever.

今天下午3:30,我通过邮件收到了Dexcom Share。 到下午4:40时,它已与我的iPhone配对,并且运行良好。 因此,我真正需要的是一个简单的桥接器,它将我的Dexcom Share数据复制并复制到Nightscout。 从那里我可以分析它,将其发送到我的Pebble,或执行任何操作。

从Windows机器观看iPhone流量 (Watching iPhone Traffic from a Windows Machine)

First, I need to understand the Dexcom Api. Let's watch the iPhone talk to Dexcom. I'll install Fiddler on my Windows machine and configure Fiddler as a proxy server. I'll need to trust the Fiddler SSL cert (only for dev purposes) on both the iPhone and the Windows machine. My machine is called Hexpower7 and the proxy is on port 8888. I'll visit http://hexpower7:8888 on my iPhone and install the cert there also, which will allow me to watch the traffic and learn about the API.

首先,我需要了解Dexcom Api。 让我们看一下iPhone与Dexcom的对话。 我将在Windows机器上安装Fiddler并将Fiddler配置为代理服务器。 我需要在iPhone和Windows计算机上都信任Fiddler SSL证书(仅出于开发目的)。 我的机器称为Hexpower7,代理位于端口8888上。我将在iPhone上访问http:// hexpower7:8888,并在那里安装证书,这将使我能够观察流量并了解API。

I learned a few things by watching the traffic.

通过观察交通情况,我学到了一些东西。

Watching Traffic

使用CURL呼叫Dexcom (Calling Dexcom with CURL)

First, when you login to the Dexcom API you get a Session ID, which is common and to be expected. With that Session ID you can get your sugar values. After the login I retrieved my latest sugar number:

首先,当您登录Dexcom API时,您将获得一个会话ID,这是常见的并且是预期的。 使用该会话ID,您可以获取糖值。 登录后,我获取了最新的糖号:

curl -k -X POST "https://share1.dexcom.com/ShareWebServices/Services/Publisher/ReadPublisherLatestGlucoseValues?sessionID=GUID&minutes=1440&maxCount=1" -H "Accept: application/json" -H "Content-Length: 0"

resulting in:

导致:

[{"DT":"\/Date(1426290216000-0700)\/","ST":"\/Date(1426293817000)\/","Trend":4,"Value":113,"WT":"\/Date(1426290240000)\/"}]

Here's a screenshot:

这是屏幕截图:

Talking to Dexcom Share from CURL

Cool. So I pair-programmed with Benjamin West from the Nightscout project and we spent an hour writing a script to get my Dexcom Share data and bridge/POST it to Nightscout.

凉。 因此,我与Nightscout项目的Benjamin West进行了配对编程,我们花了一个小时编写脚本来获取我的Dexcom Share数据并将其桥接/发布到Nightscout。

I put the script in an Azure WebJob and it's pulling my Share data and putting it into Nightscout every few minutes. I won't post the code here, rather the Nightscout team will take our prototype from here, but the result is lovely.

我将脚本放在Azure WebJob中,每隔几分钟就会提取我的Share数据并将其放入Nightscout。 我不会在这里发布代码,但是Nightscout团队将从这里获取我们的原型,但是结果很不错。

I don't have to carry an extra Android device anymore, I just use my Dexcom Share and its supported iPhone uploader application. Very cool.

我不再需要携带额外的Android设备,只需使用我的Dexcom Share及其受支持的iPhone上传程序即可。 很酷。

Now it's 7:30pm, just a few hours after I got my Dexcom Share and I've got the best of both worlds. The API was easy to use and we didn't spend more than two hours on it. Most of the time was waiting for the transmitter to complete its warmup cycle.

现在是晚上7:30,这是我获得Dexcom Share的几个小时后,我已经两全其美。 该API易于使用,我们花了不超过两个小时的时间。 大部分时间都在等待发送器完成其预热周期。

My Blood Sugar in the Cloud

I'll do a formal Dexcom review soon, but I can already tell you it's a winner. Everyone who can get a CGM should get a Dexcom Share. It's a thrilling device. I would like the iPhone app to support iPhone 6 and 6+ screen-sizes better, and a nicer UI, but all in all, it's a great device.

我将很快进行正式的Dexcom审查,但我已经可以告诉您它是赢家。 每个能够获得CGM的人都应该获得Dexcom股票。 这是一个令人兴奋的设备。 我希望iPhone应用程序能够更好地支持iPhone 6和6+屏幕尺寸,以及更好的UI,但总而言之,它是一款出色的设备。

Don't forget, visit http://marchisformakers.com, tell your friends and tweet us at #MarchIsForMakers!

别忘了,访问http://marchisformakers.com ,告诉您的朋友,并在#MarchIsForMakers上鸣叫我们!

Sponsor: Big thanks to Aspose for sponsoring the blog feed this week! Are you working with Files?Aspose.Total for .NET has all the APIs you need to create, manipulate and convert Microsoft Office documents and many other formats in your applications. Start a free trial today.

赞助商:非常感谢Aspose本周赞助了博客提要! 您正在使用文件吗? .NET的Aspose.Total具有在应用程序中创建,处理和转换Microsoft Office文档以及许多其他格式所需的所有API。 立即开始免费试用。

相关阅读 (RELATED READING)

  • The Sad State of Diabetes Technology in 2012

    2012年糖尿病技术的悲惨境况

  • Scott's Diabetes Explanation: The Airplane Analogy

    斯科特的糖尿病解释:飞机类比

  • YOUTUBE: How my diabetes equipment works

    YOUTUBE:我的糖尿病设备如何工作

翻译自: https://www.hanselman.com/blog/bridging-dexcom-share-cgm-receivers-and-nightscout

cgm图编辑器

这篇关于cgm图编辑器_桥接Dexcom分享CGM接收器和Nightscout的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/559546

相关文章

Python虚拟环境与Conda使用指南分享

《Python虚拟环境与Conda使用指南分享》:本文主要介绍Python虚拟环境与Conda使用指南,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录一、python 虚拟环境概述1.1 什么是虚拟环境1.2 为什么需要虚拟环境二、Python 内置的虚拟环境工具

Python处理大量Excel文件的十个技巧分享

《Python处理大量Excel文件的十个技巧分享》每天被大量Excel文件折磨的你看过来!这是一份Python程序员整理的实用技巧,不说废话,直接上干货,文章通过代码示例讲解的非常详细,需要的朋友可... 目录一、批量读取多个Excel文件二、选择性读取工作表和列三、自动调整格式和样式四、智能数据清洗五、

JDK9到JDK21中值得掌握的29个实用特性分享

《JDK9到JDK21中值得掌握的29个实用特性分享》Java的演进节奏从JDK9开始显著加快,每半年一个新版本的发布节奏为Java带来了大量的新特性,本文整理了29个JDK9到JDK21中值得掌握的... 目录JDK 9 模块化与API增强1. 集合工厂方法:一行代码创建不可变集合2. 私有接口方法:接口

电脑系统Hosts文件原理和应用分享

《电脑系统Hosts文件原理和应用分享》Hosts是一个没有扩展名的系统文件,当用户在浏览器中输入一个需要登录的网址时,系统会首先自动从Hosts文件中寻找对应的IP地址,一旦找到,系统会立即打开对应... Hosts是一个没有扩展名的系统文件,可以用记事本等工具打开,其作用就是将一些常用的网址域名与其对应

Python+wxPython构建图像编辑器

《Python+wxPython构建图像编辑器》图像编辑应用是学习GUI编程和图像处理的绝佳项目,本教程中,我们将使用wxPython,一个跨平台的PythonGUI工具包,构建一个简单的... 目录引言环境设置创建主窗口加载和显示图像实现绘制工具矩形绘制箭头绘制文字绘制临时绘制处理缩放和旋转缩放旋转保存编

SpringBoot请求参数接收控制指南分享

《SpringBoot请求参数接收控制指南分享》:本文主要介绍SpringBoot请求参数接收控制指南,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录Spring Boot 请求参数接收控制指南1. 概述2. 有注解时参数接收方式对比3. 无注解时接收参数默认位置

使用Python开发一个带EPUB转换功能的Markdown编辑器

《使用Python开发一个带EPUB转换功能的Markdown编辑器》Markdown因其简单易用和强大的格式支持,成为了写作者、开发者及内容创作者的首选格式,本文将通过Python开发一个Markd... 目录应用概览代码结构与核心组件1. 初始化与布局 (__init__)2. 工具栏 (setup_t

Python通过模块化开发优化代码的技巧分享

《Python通过模块化开发优化代码的技巧分享》模块化开发就是把代码拆成一个个“零件”,该封装封装,该拆分拆分,下面小编就来和大家简单聊聊python如何用模块化开发进行代码优化吧... 目录什么是模块化开发如何拆分代码改进版:拆分成模块让模块更强大:使用 __init__.py你一定会遇到的问题模www.

Python解析器安装指南分享(Mac/Windows/Linux)

《Python解析器安装指南分享(Mac/Windows/Linux)》:本文主要介绍Python解析器安装指南(Mac/Windows/Linux),具有很好的参考价值,希望对大家有所帮助,如有... 目NMNkN录1js. 安装包下载1.1 python 下载官网2.核心安装方式3. MACOS 系统安

Java嵌套for循环优化方案分享

《Java嵌套for循环优化方案分享》介绍了Java中嵌套for循环的优化方法,包括减少循环次数、合并循环、使用更高效的数据结构、并行处理、预处理和缓存、算法优化、尽量减少对象创建以及本地变量优化,通... 目录Java 嵌套 for 循环优化方案1. 减少循环次数2. 合并循环3. 使用更高效的数据结构4