- Notifications
You must be signed in to change notification settings - Fork3
This project is an independent approach to acquire patient data from Philips patient monitors via network interface.
License
re-sirb/Vital-signs
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
This project is an independent approach to acquire patient data from Philips patient monitors via network interface. It has no association with the Philips corporation.
The Python-module published here emphasizes especially ease of use, giving researchers an easy way to interact with Philips patient monitors.
An attempt was made to use Python Standard Library modules as much as possible.
This application is for research use only and may not be used for diagnostic or therapeutic applications.
In theory this module should work with X2, MP Series, MX Series, FM Series of Philips patient monitors. Though this project was developed and tested only using a MP70-type patient monitor. The communication protocol was reverse engineered using mainly packet sniffing and to some extent the (in my opinion) poorly written documentation of the manufacturer, that can be found on the internet. Not all data is parsed completely (as it should be done) and to some extent the communication is purely based on empiric packet sniffing. So there is a chance it might not work with certain patient monitors or firmware versions.All in all, the code is still very raw and still contains many debugging functions that have only been commented out. If anyone wants to take the time to improve it, you are very welcome.There are two flags in the init method that can be set toTrue to make the module more verbose and to help narrow down problems.
Options for debugging:
- debug_info
- debug_error
Also refer tosomno/einstein here on github for more useful information on communication with Philips patient monitors.
When creating a new insctance of piv_data_source the correct IP of the patient monitor is required as parameter.
Starts the UDP-client thread and begins to acquire data from the monitor.
Starts the additional watchdog, that restarts the connection when exceptions occur. The connection-watchdog is automatically startet when starting the UDP-client. If you don't use the watchdog you will have to monitor the current connection yourself. This is necessary because the monitor sometimes terminates the connection spontaneously or does not process requests correctly.
Terminates the connection, the UDP-client and the start_watchdog. Should be called before the object is deleted to terminate the connection correctly.
Returns a list with patient vital signs.
Returns a list with patient admission information.
Reads patient admission information again to check for changes (usually it is only read once when a new connection is started).
Returns a boolean whether the connection is working properly.
A simple example how to use thepiv_data_source module. It starts a connection, reades some data and terminates the connection.
frompiv_data_sourceimportpiv_data_source# time module is just used to create some delay to give the monitor time to respondimporttime# Insert the correct IP of the patient monitor here!device=piv_data_source("127.0.0.1")# Start clientdevice.start_client()# delay 15 seconds to give the monitor time to gather datatime.sleep(15)# read patient information and vital signsprint(device.get_patient_data())print(device.get_vital_signs())# Terminate connectiondevice.halt_client()
In the directoryplotting_example you can find a simple tool that plots vital sign data for testing, using matplotlib.
Have fun!