Code Monkey home page Code Monkey logo

pcecg500's Introduction

1.引入依赖

implementation project(path: ':ecg500')
<manifest ...>
  <uses-feature android:name="android.hardware.usb.host" /> <!-- usb权限 -->
  <uses-sdk android:minSdkVersion="12" />
  ...
  <application>
      <!-- 适配7.0 -->
       <provider
            android:name="androidx.core.content.FileProvider"
            android:authorities="${applicationId}.fileprovider"
            android:exported="false"
            android:grantUriPermissions="true">
            <meta-data
                android:name="android.support.FILE_PROVIDER_PATHS"
                android:resource="@xml/provider_paths" />
        </provider>
   
      <activity ...>
         ...
           <!-- usb连接 -->
          <intent-filter>
              <action android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED" />
          </intent-filter>
   
          <meta-data android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED"
           android:resource="@xml/device_filter" />
      </activity>
   </application>
   </manifest>
  
<?xml version="1.0" encoding="utf-8"?>

<resources>
   <usb-device vendor-id="1027" product-id="24597" /> <!-- FT230X -->
</resources>

3.设备通信流程提示,详例参见demo

  1. 连接

    usbConnManager.connectFunction()
    
  2. 获取数据

    usbConnManager.collectReadData()
    

4.生成Hl7Xml文件上传获取心电报告

具体参见GetPDFViewModel

  1. 在管理平台http://www.lepuaicloud.com(这是测试环境,生产环境https://wisemedical.creative-sz.com)创建统一客户账号
  2. 通过账号密码获取接口请求令牌,具体请参考示例及接口文档
  3. 注意:在上传用户信息patient.setUserId中一定要与客户账号一致

5.切换波形展示

MainEcgManager.getInstance().updateMainEcgShowStyle(LeadType.LEAD_6)

6.本地心电传统分析

具体参见:viewViewModel.getValue().getLocalPdf(ecgDataArray)
结论:viewViewModel.getValue().getMLocalResult().observe()
全部分析数据:viewViewModel.getValue().getMLocalResultBean().observe()

pcecg500's People

Contributors

zrenjun avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.