Index: README.md =================================================================== diff -u -rfc1912b6369d6709c4c4a0bd83bfcd3fa0639a6f -r32e628abcbbd3fd70866505d9f2836a6f732ef06 --- README.md (.../README.md) (revision fc1912b6369d6709c4c4a0bd83bfcd3fa0639a6f) +++ README.md (.../README.md) (revision 32e628abcbbd3fd70866505d9f2836a6f732ef06) @@ -1,10 +1,28 @@ + + ![Diality](images/logo.jpg) # Dialin This repository contains the source code for the Dialin API. The Dialin API supports cross-functional testing of the Denali system. -It supports the Systems level testing, Software Verification & Validation, and pre-release SW and FW developmental testing by exposing and simulating interaction with - the UI, HD, and DG sub-components. +It supports the Systems level testing, Software Verification & Validation, and pre-release SW and FW developmental +testing by exposing and simulating interaction with the UI, HD, and DG sub-components. To use this API, it is recommended to install the API directly from this locally hosted git repository. It is also possible to install it from a pre-packaged .whl file. Once installed to your local @@ -15,37 +33,39 @@ Please understand that the structure of this repository is still under review and the architecture is likely to change as improvements are made. +This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). ## Using the API ### Install directly from this repository - Assumes your ssh key has already been setup with our internal BitBucket servers -- Assumes your computer is in the office or that you are on the VPN +- Assumes your computer is in the office or that you are using LogMeIn. The VPN has a DNS issue which may break +the installation. -How to install from the dialin_refactoring_3 branch (Available) +All release versions will eventually be placed on their own separate branch to facilitate +backwards compatibility and a fully accessible and testable API version history. + +How to install from the master branch + ``` #!/bin/bash virtualenv --python=python3 venv source venv/bin/activate -branch="dialin_refactoring_3" -pip3 install git+ssh://git@dvm-linux02:7999/vv/dialin.git@$branch +pip3 install git+ssh://git@dvm-linux02:7999/vv/dialin.git ``` -All release versions will eventually be placed on their own separate branch to facilitate -backwards compatibility and a fully accessible and testable API version history. +How to install a build from a specific branch. To change the branch, replace staging with the desired branch -How to install from the master branch (Not yet available) -- Will be possible as soon as the dialin_refactoring_3 branch has been merged with the master branch - ``` #!/bin/bash virtualenv --python=python3 venv source venv/bin/activate -pip3 install git+ssh://git@dvm-linux02:7999/vv/dialin.git +branch="staging" +pip3 install git+ssh://git@dvm-linux02:7999/vv/dialin.git@$branch ``` ### Install from a pre-built .whl file: @@ -55,48 +75,15 @@ virtualenv --python=python3 venv source venv/bin/activate -pip3 install dialin-0.0.1-py3-none-any.whl +pip3 install dialin--py3-none-any.whl ``` ### Modules -- See the tests directory for examples of how to use this API -- Also consult the Dialin API documentation which can be generated using the `tools/document.sh` script. +- Consult the Dialin API documentation which can be generated using the `tools/document.sh` script. +- See the tests directory for example usages of the API. -``` -from dialin.hd.alarms import HDAlarms -from dialin.hd.blood_flow import HDBloodFlow -from dialin.hd.buttons import HDButtons -from dialin.hd.constants import RESET, NO_RESET -from dialin.hd.dialysate_inlet_flow import HDDialysateInletFlow -from dialin.hd.dialysate_outlet_flow import HDDialysateOutletFlow -from dialin.hd.hemodialysis_device import HD -from dialin.hd.pressure_occlusion import HDPressureOcclusion -from dialin.hd.rtc import HDRTC -from dialin.hd.treatment import HDTreatment -from dialin.hd.ui_proxy import HDUIProxy -from dialin.hd.watchdog import HDWatchdog - - -from dialin.dg.dialysate_generator import DG - - -from dialin.protocols.CAN import (DenaliCanMessenger, - DenaliMessage, - DenaliChannels, - LongDenaliMessageBuilder) - - -from dialin.utils.conversions import (integer_to_bytearray, - float_to_bytearray) - - - -``` - - - ## Dialin API Internal Development Environment ### Linux @@ -111,37 +98,28 @@ ### Windows -Note that windows support for the python-can library has not been validated. -As a result, this API is not functional on windows and windows support may have to be removed -in the future. +Due to a limitation in the underlying python-can library, Dialin does not currently support Windows. -For a brand new setup, after cloning this repository: -``` -> setup_environment_windows.bat - -``` - -If the windows environment has been previously set up: - -``` -> activate_environment_windows.bat -``` - - ## Unit Testing -All internal tests of the dialin API can be found in the tests directory at the root of -this git repository: +All unit tests of the Dialin API can be found in tests/unit_tests. To run them: ``` -(venv) $ cd tests -(venv) $ python3 dialin_unit_test_example.py +$ cd tools +$ ./run_unit_tests.sh 127 ↵ ``` +If there is a failure, the script will indicate what failed. No output means all tests have passed. ## Building the Dialin package ``` $ ./build.sh ``` + +[Changelog](CHANGELOG.md) + +[LICENSE](./LICENSE) + +