Abstract
Introduction and Objective:
Continuous bladder irrigation (CBI) is used in a variety of clinical settings, including post-transurethral surgery and the emergency department. Currently, CBI administration relies on nurses to diligently monitor and switch irrigation bags, as well as titrate the inflow rate based on effluent color. Inappropriate administration can result in discomfort to patients, clot urinary retention, repeat injury to the pathologic or surgical site, extended hospital stays, and even operative management. Our objective was to create an autonomous CBI system that decreases the incidence of disrupted irrigation flow and monitors the outflow to alert clinicians of critical events.
Methods:
3D printing and off-the-shelf microcontrollers were used to design a device to fit the needs identified by stakeholders at our institution. An in vitro model of the bladder was created to test our design. The mechanical, electrical, and software subsystems were adjusted accordingly to meet our design requirements.
Results:
Our in vitro CBI model was able to simulate routine CBI administration with sudden bleeding. Bovine blood was used to simulate the bleeding events. A device was created that met identified stakeholder needs. Accurate detection of critical bleeding events, catheter blockage, and empty irrigation bags were achieved. The device responds to bleeding appropriately by increasing the irrigation rate. When the catheter is blocked, it stops the irrigation and alerts the nurse. Our system accurately titrated the irrigation rate to match a set outflow blood level parameter, conserving irrigation and minimizing nursing workload. Continuous monitoring of CBI effluent was recorded.
Conclusions:
We anticipate our device will decrease the cognitive load on nurses in busy clinical settings and improve workflow. Moreover, the detection of critical events will likely decrease patient morbidity. Continuous monitoring of the CBI outflow may prove to be a new clinical decision-making tool for ongoing hematuria. Clinical trial is pending.
Introduction
Continuous bladder irrigation (CBI) is used extensively in a variety of clinical settings, including post-transurethral surgery and gross hematuria presentations to the emergency department. 1 CBI is a key component of postoperative inpatient care as it prevents clot urinary retention and allows the surgical site to heal. In the emergency department, patients with clot retention are manually irrigated free of clot and started on CBI. CBI may be the only intervention needed for the pathologic site to heal in this situation. CBI outflow color is evaluated during patient assessments and is used as a clinical sign of ongoing bleeding in the urinary tract. Currently, CBI administration is a subjective process whereby nurses visually assess the effluent color and subjectively titrate the inflow rate to ultimately prevent clot formation.
This process requires diligent monitoring of irrigation bags, continuous reassessment of outflow color, and replacement of irrigation bags when they are empty. Nurses may have to check the administration as frequently as every 15 to 30 minutes to ensure smooth operation. 1 If the irrigation bags are depleted or the outflow is blocked, either by a clot or a kink in the associated tubing, CBI can be interrupted whereas the clinician is unaware. This interruption can result in significant pain, clot retention, repeat injury to the pathologic or surgical site, extended hospital stays, and even emergency operative management. 2
CBI administration is labor intensive and subjective, and incorrect administration can lead to significant patient morbidity. To our knowledge, there have only been two attempts to tackle this problem. In 2016, Ding et al. randomized 146 patients who underwent a transurethral resection of prostate to receive postoperative CBI with either an automated regulatory device or conventional administration. 3 They found that the group that used the device had significantly decreased incidence of clot retention and cystospasm compared with the control group. However, little detail is provided on the device or its performance characteristics and since 2016, no such devices have been available for commercial purchase and research in this area appears stagnated.
Furthermore, 20/70 patients experienced clot retention postoperatively in the control group compared with 8/76 in the experimental group. The high incidence of clot retention postoperatively in the control group calls into question the generalizability of the findings. In 2022, an abstract was presented at the American Urological Association conference that describes an open source, noninvasive, and inexpensive assembly for automatic hematuria monitoring during CBI. 4 The design details are available online and the results appear to show good correlation for hematuria estimation against known serial dilutions of bovine blood. However, this device does not titrate the inflow of irrigation based on those hematuria estimations and thus does not administer CBI autonomously. Moreover, although the device can determine if the outflow is slowing, it is unable to differentiate whether it is caused by empty irrigation bags or, more critically, a catheter blockage, which is paramount to prevent patient injury.
Our objective was to develop an autonomous CBI system to mitigate some of the pitfalls of manual CBI administration. Our goal is to decrease the incidence of disrupted irrigation flow and thus patient morbidity associated with CBI, decrease the burden on nurses performing the task, and standardize CBI administration.
Methods
IRB approval was obtained (REB 23-044). Stakeholder needs were determined through interviews with nurses, residents, fellows, and staff at our institution. Computer-aided design (CAD) software, 3D printing, and off-the-shelf hardware and microcontrollers were used to design a patent-pending device to fit these needs. Software controllers were designed in-house using Python programming language deliberately so that it may be ported relatively easily to different microcontrollers.
A device with the following features was created: Ability to control inflow rate of irrigation based on CBI effluent blood concentration. Ability to automatically switch between irrigation bags (up to four 3-L bags) once a bag is empty. Ability to notify clinicians through audible alarm in advance of when all bags have depleted. Ability to notify clinicians through audible alarm when effluent has been bloody for an extended duration of time even though the system is running at the maximum inflow rate. Ability to notify clinicians through audible alarm when outflow is blocked, whereas at the same time automatically stopping inflow to prevent patient discomfort and possible bladder rupture. Ability to record data on instillation volume of inflow and outflow, catheter blockage, unexpected irrigation cessation, and effluent blood concentration for the entire duration of CBI administration.
The device consists of three components: (1) irrigation flow controller, (2) outflow monitor, and (3) integration controller. A schematic is shown in Figure 1. All components of the device will fit on a standard hospital irrigation pole so that the patient will be able to ambulate with one pole just like how patients ambulate with CBI currently without the device.

Block diagram of device design.
Irrigation flow controller
The irrigation flow controller subsystem was designed to have the ability to control the inflow rate of irrigation and to automatically switch between irrigation bags (up to four) after each bag is depleted. A stepper motor is connected to a 3D printed pinching mechanism (Fig. 2A), which can control the irrigation inflow from completely open to completely closed. The inflow rate and need to switch irrigation bags are determined by weight sensors attached to a standard intravenous pole on which the irrigation bags hang (Fig. 2B). The motor is controlled by an Arduino Nano®, which in turn receives commands to increase or decrease irrigation based on the current situation as determined by the integration controller described as follows.

Irrigation flow controller.
Outflow monitor
The outflow monitor consists of two parts: (1) effluent blood detector and (2) an outflow rate detector (Fig. 2C, D). The Foley catheter bag tubing is attached to the outflow effluent detector. This detector is housed in a 3D printed encasing that surrounds the tubing to block out ambient light. It can theoretically be placed anywhere along the outflow tubing. We placed it in a dependent part of the tubing so that the detector could have more effluent to sample and to avoid air bubbles, which may make the effluent falsely appear clear.
When placed in this location, bubbles are not persistent in the tubing, particularly at higher flow rates. Within the housing, a light-emitting diode emits white light through the tubing and is received by a light sensor on the other side (an off-the-shelf USB web camera; ELP OV5640), which computes the intensity of light that passes through the tubing. We refer to the signal produced by the blood detector as a light intensity score. The outflow rate detector consists of a weight sensor where a regular catheter bag can be hung. It continuously measures the outflow rate using rate-of-change calculations. The monitoring system operates at 10 Hz; a high enough frequency to obtain accurate effluent assessments and detect critical events.
Integration controller
Signals from the outflow monitor are filtered by an integration controller and processed to titrate the CBI inflow rate based on the outflow light intensity score and rate. This controller algorithm was written and implemented on the low-cost computer; the Raspberry Pi® (Fig. 2E). The titration algorithm was determined by expert consensus (Appendix A1). The controller prioritizes safety of CBI administration and increases the flow rapidly when outflow becomes bloody and slowly decreases the flow rate when the outflow is clear.
In addition, the controller integrates all information from the system and delivers the alarms to the critical events described earlier. Of note, the integration controller compares the volume of outflow to the volume of inflow. If the volume of inflow is less than the volume of outflow by a set percentage for a set duration of time, an alarm is triggered. The most likely scenario of an inflow–outflow mismatch is a catheter blockage but can also represent a situation where the inflow is lost from the system (e.g., disconnected CBI components or bladder perforation). If an inflow–outflow mismatch is detected, the inflow is stopped automatically in addition to alerting the clinician.
In vitro bladder model
An in vitro model of the bladder and CBI was created to test our design (Fig. 2F). A 22F three-way Foley catheter was attached to a rubber balloon. A hole was cut into the balloon where a cut two-way catheter was fashioned to allow administration of bovine blood (through a 60 cc syringe) into the balloon to simulate bleeding.
Results
Outflow sensor characteristics
The outflow sensor was able to accurately detect the blood concentration of the effluent flowing through the Foley bag tubing. Tubes of bovine blood at 0%, 5%, 10%, 15%, 20%, 25%, 30%, 40%, 50%, 75%, and 100% concentrations were prepared by serial dilution (Fig. 3). The outflow effluent intensity was taken for 5 seconds at each concentration, sampling at 10 Hz for a total of 50 samples. Figure 4 shows the scatter of the log intensities at each concentration. The log intensity has a very small variance at each concentration and scales linearly with concentration providing excellent sensor characteristics to accurately detect blood concentration in the outflow effluent. The experiment was performed in an office building setting with ambient overhead lights on and off without significant difference in intensity score at each concentration.

Bovine blood at 0%, 5%, 10%, 15%, 20%, 25%, 30%, 40%, 50%, 75%, and 100% concentrations from top to bottom.

Scatterplot of log outflow intensity vs blood concentration. A closer look reveals tight spread of log light intensity score at each concentration.
Experiment 1: CBI inflow titration
For this experiment, CBI was initially running clear when a bolus of bovine blood was injected into the in vitro bladder model [Fig. 5 at point (a)]. The device accurately detected outflow blood concentration and titrated the inflow rate accordingly by increasing flow rate for high blood concentration and decreasing it for low concentration. Of note, although not depicted, the device will set off an alarm if it is running at maximum flow rate for a prolonged period without resolution of hematuria. In our experiment, this period was set to 10 seconds to ensure the alarm works but can be set to a more realistic duration during clinical implementation.

Experiment 1 graphs of log intensity score, pinch position of inflow controller, and actual flow rate measured by the system. At point (a), a bolus of bovine blood is introduced into the in vitro bladder model.
Experiment 2: CBI outflow blockage detection
For this set of experiments, CBI was initially running clear. A bolus of blood was injected into the in vitro model (Fig. 6i) at point (a). Thereafter, at point (b), the outflow was clamped. The device detected the blockage of the outflow and set off an audible alarm. Detection of catheter blockage is achieved by comparison of inflow volume and outflow volume (Fig. 6ii). The inflow was stopped (depicted as a negative pinch position to denote complete cessation of inflow below the minimum running rate). At point (c), the blockage was relieved, and instillation of irrigation resumed. The blood was cleared, and the irrigation flow was titrated back down to the minimum flow.

(i) Experiment 2 graphs of log intensity score, pinch position of inflow controller, actual inflow rate, and blockage detection determination. At point (a), a bolus of bovine blood is introduced into the in vitro bladder model. At point (b), the outflow is clamped to simulate outflow obstruction. At point (c), the clamp is removed to simulate release of outflow obstruction. (ii) Examination of the determination of blockage in Experiment 2. Graphs of inflow volume, outflow volume, determination of blockage, and pinch position of inflow controller are shown for the period when the outflow is clamped [point (b)]. Negative pinch position denotes complete cessation of irrigation inflow.
Discussion
We have created and described an autonomous CBI system that accurately measures effluent blood concentration, titrates the inflow rate, and automatically switches between irrigation bags. Such a completely automated system has not been previously described in literature to our knowledge. Although Ding et al. had conducted a randomized trial with an automated CBI device, details about the devices, including its hematuria measurement accuracy were not described. In this study, we have been able to show a high confidence in estimating effluent hematuria concentration through our light intensity score. The system responds quickly and appropriately to bleeding in the urinary tract in our in vitro model. When outflow is blocked, the system's safety features stop instillation of irrigation to prevent high intravesical pressures and bladder rupture.
Our outflow detector operates at 10 Hz and our integration controller operates at an even higher frequency to integrate the signals from the other sensors. Thus, this system can respond to changes 10 times per second. We used a simplistic titration algorithm built on expert consensus that prioritizes patient safety (as opposed to conservation of irrigation fluid). The variables of how quickly to titrate instillation and the length of duration to wait before notifying a clinician are all adjustable and subject to further investigation. Currently, these variables are set to allow efficient demonstration that our system works in our in vitro experiments. Before clinical implementation, these can be further optimized by expert consensus to improve patient safety whereas decreasing the nursing intensive task of switching bags too frequently.
The integration controller is built on a Raspberry Pi, which can record and transmit information over Wi-Fi. Alerts need not be only auditory but can be programmed to send to remote devices such as mobile phones through text message, Electronic Medical Records (EMRs), or other mobile applications. In fact, decreasing the number of audible alarms from numerous medical devices in patient rooms is necessary to prevent alarm fatigue and even delirium in patients. 5 Beyond improving safety and workflow, we believe our device has the potential to inform clinical decision-making as it records effluent blood concentration during the entire duration of CBI administration. This newly available clinical information can estimate blood loss and guide management decisions such as whether to pursue operative management or if further investigations are necessary.
The device has a small physical footprint and is easy to install and use. We do not foresee significant barriers to clinical application, although packaging and human factors design need to be optimized to ensure seamless clinical integration. The total cost of our design is ∼$250 CAD. Our design has been optimized for speed and ease of development and not for cost, reliability, or durability. In the future iterations, these additional factors will be considered as they become relevant to our product. We estimate the cost of the device can be reduced by at least 50% by using lower power components that can meet our specifications. These readily available lower power components were not selected for our prototype as they would add design time and effort without contributing to our current design goals.
Next steps to bring our device to the clinical setting include optimization of our titration algorithm, cleaning up human factors design to allow easy acceptance by nursing staff on inpatient wards and the emergency department, and performing a clinical trial to validate improved quality of CBI delivery. Clinical endpoints in the trial include patient comfort, occurrence of clot retention, length of stay in hospital, and early detection of need for reoperation.
Conclusion
We have developed an autonomous CBI system. We believe that this system will ultimately decrease nursing workload and improve clinical outcomes for patients by preventing inappropriate CBI administration and providing more detailed clinical information about ongoing hematuria. A clinical trial to validate the device's clinical utility is underway.
Footnotes
Authors' Contributions
Methodology, software, investigation, formal analysis, and writing—original draft by K.-H.F. Methodology and writing—review and editing by S.S. Investigation and methodology by R.J. and J.L. Investigation by S.M. Conceptualization, methodology, software, engineering design, investigation, writing—review and editing by B.C. Conceptualization, supervision, writing—review and editing, project administration, and funding acquisition by M.F.
Author Disclosure Statement
No competing financial interests exist.
Funding Information
This study was supported by the St. Michael's Foundation, Toronto, Ontario, Canada through the Angels' Den competition and the Keenan Foundation, as well as Alayne and Ron Metrick.
