@startuml End_Treatment participant TD as TD participant SW as SW participant UI as UI actor USER as US 'Possible actions and interaction types ' External on CANBus ' TD -> SW: MSG: Message ' SW -> TD: MSG: Message ' Internal to the application ' XX -> YY: CMD: Command ' XX -> XX: ACT: Action ' External on OS/FS ' SW -> Script: ACT: Command ' Script -> OS: CMD: Command ' Script -> SW: MSG: Message ' OS -> Script: MSG: Message ' US -> UI: User actions are: ' ASK: Display a ' ENT: User enters a value or string ' TCH: User touches a button (RadioButton, CheckBox, ...) ' SCL: User scrolls a flip-able area == End of Treatment == TD -> SW: MSG: [x3C: #7] End Treatment \ \n\t TDTreatmentStates.TREATMENT_END_STATE \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 SW -> UI: ACT: Notify UI UI -> US: ACT: Notify user with Treatment Complete dialog group Stay on Treatment US -> UI: TCH: Stay on Treatment button US -> UI: ACT: Allowable actions: \ \n\t Adjust blood flow rate (blood sampling) \ \n\t Perform Isolated Ultrafiltration \ \n\t Perform a saline bolus \ \n\t Take a vitals measurement \ \n\t Adjust or reset venous, arterial, and TMP pressure limits UI -> UI: ACT: Disable Adjustments: \ \n\t Dialysate flow \ \n\t Dialysate temperature \ \n\t Dialysate conductivity \ \n\t Ultrafiltration \ \n\t Treatment duration US -> UI: TCH: Open End Treatment dialog through headerbar button end group End Treatment US -> UI: TCH: End Treatment button UI -> SW: ACT: Request End Treatment SW -> TD: MSG: [xXX: #0] Request End Treatment TD -> SW: MSG: [xXX: #2] \ \n\tResponse: \ \n\t(U32) mAccepted\ \n\t(U32) mReason SW -> UI: ACT: End Treatment Response alt Accepted UI -> UI: ACT: Close Popup TD -> SW: MSG: [x3C: #7] Rinseback \ \n\t TDTreatmentStates.TREATMENT_RINSEBACK_STATE \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 \ \n\t(U32) 0 SW -> UI: ACT: Notify UI UI -> US: ACT: Show Rinseback screen else #Pink Rejected UI -> US: ACT: Notify User displaying rejection reason end end @enduml