GithubHelp home page GithubHelp logo

atbrask / cms50dplus Goto Github PK

View Code? Open in Web Editor NEW
52.0 52.0 20.0 12 KB

Python code for downloading data from a Contec CMS50D+ pulse oximeter

License: BSD 2-Clause "Simplified" License

Python 100.00%

cms50dplus's People

Contributors

atbrask avatar bachmann1234 avatar bobronium avatar faustomilletari avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cms50dplus's Issues

Length not divisible by 3!

it looks like last night's recording has hit an edge-case.

python cms50dplus.py -s '2015-09-28 22:00:00'  RECORDED /dev/ttyUSB0 "out-`date --iso-8601=seconds`.csv"
Saving recorded data...
Please wait as the latest session is downloaded...
Traceback (most recent call last):
  File "cms50dplus.py", line 327, in <module>
    dumpRecordedData(args.starttime, args.serialport, args.output)
  File "cms50dplus.py", line 302, in dumpRecordedData
    for recordedData in oximeter.getRecordedData(starttime):
  File "cms50dplus.py", line 251, in getRecordedData
    raise Exception("Length not divisible by 3!")
Exception: Length not divisible by 3!

I adjusted the error message to show the length
"Length 253 not divisible by 3!"

any ideas whats going on with this?

Exception: No data stream from device! (CMS50Dplus firmware version 4.6)

Hi,
I tried to run this command but got this:

$ ./cms50dplus.py -s "2016-07-13 18:13:32" RECORDED /dev/ttyUSB0 /tmp/test
Saving recorded data...
Please wait as the latest session is downloaded...
Traceback (most recent call last):
  File "./cms50dplus.py", line 328, in <module>
    dumpRecordedData(args.starttime, args.serialport, args.output)
  File "./cms50dplus.py", line 303, in dumpRecordedData
    for recordedData in oximeter.getRecordedData(starttime):
  File "./cms50dplus.py", line 228, in getRecordedData
    raise Exception("No data stream from device!")
Exception: No data stream from device!

I'm not really sure, but could this be due to a newer firmware version of CMS50D+ (version 4.6)?
Has this python script been tested against 4.6 or only older versions?

Br,
airikka

Option to load data from binary file

I was asked to convert binary dump file from cms50d+ to CSV format and I soon discovered this wonderful project, that helped me a lot. Then I realized, that there is no possibility to read data from a binary file that I got. The firmware version of the device was v5.1, but it seemed compatible with implementations in this code.

I was able to change the data source to file and there's the implementation: szkocot@51e5cdf

I am not sure if can be integrated into this project smartly, but in case someone has a similar case it might help.
It was tested on 6 recordings and 5 of them were successful and one had synchronization issues.

date in output

thanks for the script! can the output CSV include the time of day? its difficult to plot otherwise.

Control of device (feature query/request)

Is it possible to control the device via the serial interface? I would like to turn the device on and off, so that the laser is not running all the time (according to the manual, the device should not be worn for extended periods (more than 2 hours))

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.