Field testing of an onsite sanitation system on apartment building blackwater using biological treatment and electrochemical disinfection †

The Closed Loop Advanced Sanitation System (CLASS) was designed to treat, disinfect, and recycle toilet blackwater from existing flush toilets in a multi-story apartment building. Two systems were tested at two unique sites in Coimbatore, India for a combined 7500+ treatment hours resulting in more than 180000 L of treated water. The CLASS prototypes used a combination of biological pretreatment and electrochemical oxidation processes to produce treated water that nearly met the stringent requirements outlined in the standard ISO 30500. The nutrient and organic loading from the toilet blackwater was predominantly reduced by over 85 – 95% and 80 – 87%, respectively, through biological processes that were achieved using either a sequencing batch reactor (SBR, site A) or an anaerobic – aerobic biodigester (EcoSan, site B). Complete disinfection of E. coli with nil CFU per ml was achieved using electrochemical processes that also served to remove the remaining organic and nutrient loading to over 90 – 96%. The treated water was reused for flushing by the residents of the apartment building for 89 days. reduce this pollution while mitigating pressure on scarce water resources. This article describes a lengthy field-testing campaign to characterize an onsite blackwater treatment and recycling technology for residential buildings in two sites in India.


Introduction
Minimizing the use of water or producing high quality water is of particular interest in water stressed areas of the world such as India 1 that has been recently facing life-threatening water shortages in its cities. 2 To an increasing extent, wastewater is being seen as a resource that has potential for reuse after appropriate treatment. For instance, as illustrated by Sushmitha et al., diverse greywater treatment and recycling technologies like membrane bioreactors, rotating biological contactors, and constructed wetlands are being implemented in increasing numbers across India. 3 Therefore, treatment and recycling of remaining household wastewater (i.e., blackwater) presents an excellent opportunity to completely recycle wastewater generated at the household scale and alleviate the need for sewer connection. 4,5 The challenges with onsite treatment of excreta are multiple: the treatment technology must be reliable, easy to use, low-cost, and, more importantly, used by the intended people.
Although the biological treatment processes like the complete mix activated sludge process and sequencing batch reactor process are proven effective for significant removal of organic and nutrient loading from wastewater, 6 they do not ensure complete removal of pathogens. Further, if this treated wastewater is to be reused, several site-specific regulations for disinfection are enforced. 6 Schmalz et al. acknowledged that electrochemical oxidation could be a promising alternative to membrane filtration, ozonation, UV irradiation and chlorination for the disinfection of biologically treated effluents. 7 Also, the study proposed that the combination of biological and electrochemical treatment systems could be safe, reliable and operationally economical for reuse systems.
Led by the "Reinvent the Toilet Initiative" sponsored by the Bill & Melinda Gates Foundation, transformative blackwater treatment technologies have been developed to treat toilet effluent onsite and disinfect the liquid for reuse. [8][9][10][11] These emerging technologies aim to produce pathogen-free water for onsite reuse, with the overarching goal of preventing the discharge of untreated wastewater into the environment and improve public health.
As Radjenovic and Sedlak identified, 12 electrochemical wastewater treatment is a promising technology for onsite treatment of blackwater at a single-family (<10 users per day) or small community level (<100 users per day). At present, electrolysis of chlorides into aqueous reactive chlorine species using semiconductor oxide anodes (e.g. Ir x Ta y O 2 /TiO 2 ) developed by some investigators [13][14][15][16] has shown extremely high levels of disinfection and treatment of toilet wastewater under laboratory conditions 10,17 and in early field trials in India. 9 While the electrochemical system tested by Cid et al. had a simple sedimentation tank for pretreatment to allow the solids to settle before entering the electrochemical system, it was recommended that replacing the sedimentation tank with advanced biological pretreatment systems could significantly reduce the amount of organic and inorganic contaminants entering the electrochemical reactor. This further enables to lower the power consumption needed to complete the electrochemical treatment.
The treatment system tested by Cid et al. was exclusively designed for usage in public areas (i.e., a park and a university campus), and tested with a relatively limited number of users. The system presented in this study was scaled up and re-engineered with a biological pretreatment system to treat and recycle the daily toilet wastewater of small apartment buildings with approximately 15 to 25 residents and 12 toilets.
At present, such apartment buildings, which often have an onsite septic management system, hold promise as a market segment for this combined technology of biological pretreatment and electrochemical disinfection. It could achieve an optimal balance between capital expenditure and operational expenses for the treatment on one side, and water savings and environmental impact on the other side. 18 This paper reports, for the first time, the demonstration of an onsite sanitation system for apartment building blackwater using biological pretreatment and electrochemical disinfection. Here, we present the long-term performance study of the system in two residential buildings meeting the specific criteria for this application. The goal of the study was to answer the following questions and help the translation of this system into a commercial product: how does the electrochemical system perform at this scale and outside the lab in a relevant environment? Does the effluent meet the relevant pathogen and nutrient threshold requirements such as ISO 30500 (an accepted international standard that was developed to inform the designers of toilet systems)? And what are the pretreatment, additive, and maintenance requirements for the electrochemical system?

System design
The Closed Loop Advanced Sanitation System (CLASS) was designed as a standalone blackwater treatment unit for multi-story apartment buildings. The CLASS is connected to existing flush toilets, and the treated water is recycled for flushing after meeting stringent pathogen removal requirements. The target effluent quality requirements (Table 1) were based on ISO 30500 "Non-Sewered Sanitation Systems -Pre-fabricated integrated treatment units -General safety and performance requirements for design and testing". 19 Initially, three prototypes of CLASS version 1 (v1), which featured a "simple" settling-based pretreatment and a high packing density of electrodes, were assembled and connected to toilets in three different apartment buildings with 20 residents in Coimbatore, India. However, field testing of the units with adequate blackwater availability was conducted for 10 months for only two prototypes (unit A and unit B) and many lessons were learned leading to the significant changes in the design of CLASS version 2 (v2). The performance results for the v1 prototypes are presented in Tables S1 and S2. † In CLASS v2, blackwater treatment was achieved with a two-stage system including 1 biological pretreatment followed by 2 electrochemical oxidation of Cl − into reactive chlorine species in an electrochemical reactor (ECR). The ECR design was similar to the one described by Cid et al. 9 with an improved mechanical design after learning from field testing v1 of the system. 20 Further, two identical CLASS v2 prototypes (unit A and unit B) were retrofitted for the same two sites as v1 (site A and site B, respectively) with independent biological pre-treatment technologies to reduce the nutrient and organic loading in the ECR. A custom-designed sequencing batch reactor (SBR) was deployed at site A, and a commercially available anaerobic-aerobic biodigester (EcoSan, Yixing, China) was deployed at site B.

CLASS description
A flow diagram of the CLASS v2 installation is presented in Fig. 1. The CLASS v2 unit, including the ECR, is measured 2.8 m (l) × 1.5 m (w) × 1.8 m (h). The dimensions of the biological pre-treatment stages differed between the sites. Blackwater (including flush and wash water) that was flushed down the toilet was collected in a 1000 L sump and pumped into a 3000 L multi-chamber settling tank. The settled liquid was pumped into the biological pre-treatment subsystem (vide infra). The treated water was filtered through a series of two filters (20 μm mesh bag filter, 70 cm in length) and pumped into the ECR. After the completion of the electrochemical treatment cycle, the water passed through a 20 μm mesh polypropylene spun-type filter (outside diameter: 114.3 mm, length: 508 mm) and collected in a 1000 L rooftop tank (treated water tank, TWT). The toilet cisterns connected to the CLASS were gravity-fed with the water from the TWT when the water was found to be adequate for re-use (closed loop configuration). During open loop operation, the toilet cisterns were connected to a second 1000 L makeup water tank (MUWT) that was connected to tap water; this also served as a back-up water supply during closed loop operation. As a precaution, each tank had a built-in safety provision that permitted overflow to the local sewer if necessary. Sampling ports located throughout the treatment stages (i.e., including untreated influent, pre and post biological pre-treatment, and post electrochemical treatment) enabled detailed characterization of the processes.

Biological pre-treatment
The blackwater that was collected in the sump and settling tanks served as feed to the biological pre-treatment systems at a set rate. At site A (Fig. 2), biological pre-treatment was achieved using a custom SBR. At site B (Fig. 3), a commercially available EcoSan biodigester was used. Pictures of the system are shown in Fig. S1. † Sequencing batch reactor. The SBR was designed to incorporate selector phase biology in a single tank reactor (Fig. 2) to maximize the removal of the high ammonia and organic loading in the incoming blackwater. The reactor volume was sized to 1000 L and operated to decant 200 L per cycle. A coarse bar screen with 6 mm openings was incorporated into the sump to prevent large solids from passing downstream. The water from the sump was pumped into pre-settling chambers that were followed by an equalization tank (24 hour retention period) before passing to the SBR.
The SBR operated on demand based on the availability of blackwater. Each batch cycle comprised four operational phases and one idle phase: fill (0.5 h), react/aerate (6 h; air a Unrestricted urban uses refer to all uses where public access is not restricted (e.g. landscape irrigation, toilet flushing). b Restricted urban uses refer to the discharge into surface water where public access is controlled.  EcoSan biodigester. The EcoSan biodigester (Yixing Eco-Sanitary Manufacture Co. Ltd., Yixing, China) is a commercially available continuous flow wastewater treatment system. The selected system was sized for a treatment capacity of 1500 L per day (Fig. 3) and was placed on a cement base 5 × 3.5 m 2 . The 10 000 L EcoSan biodigester was subdivided into four chambers: anaerobic (3800 L), aerobic (3000 L), settling (1740 L), and a holding (1560 L) chamber. Water flowed passively from one chamber to the other, and there was a built-in provision to return the active sludge between the aerobic and anaerobic chambers.
The EcoSan biodigester is typically used as an underground system, but it was installed above ground for the purpose of this work. The CLASS settling tanks were used as pre-settling/equalization tanks (24 hour retention time), and a positive displacement pump was used to provide continuous flow (45-55 L h −1 ) to the EcoSan biodigester. The system was operated with the addition of cow dung and activated sludge from the Coimbatore Ukkadam STP to both the anaerobic and aerobic chambers.

Electrochemical reactor system
After biological pre-treatment, the water was filtered through a series of two bag filters (coarse filtration) and further treated through an electrochemical oxidation process that was followed by a microfiltration system for final polishing (Fig. 1). The electrochemical oxidation process took place in the ECR. The ECR was designed as a 70 L fiberglass tank with an acrylic top cover (Fig. S1B, †). In order to ensure adequate levels of Cl − for treatment, a saturated brine solution was injected automatically into the ECR tank prior to the start of each treatment cycle. The brine solution was kept in an external tank and pumped into the ECR (Fig. S1 †). The injection time was controlled through software so that it could be adjusted based on the blackwater properties.
Two identical sets of electrode stacks were housed in the ECR. Each electrode stack comprised seven anodes and eight cathodes in an alternating configuration such that the outermost electrodes were cathodes. The anodes were optimized for the generation of chemical oxidation species such as reactive chlorine species 13,14 and were constructed from grade 2 titanium with a mixed metal oxide coating (TiO 2 /Ir x Ta y O 2 /Ti; Nanopac, South Korea). The cathodes were constructed from untreated 316 stainless steel. The total active submerged area of the anodes in the ECR was approximately 2.65 m 2 , and the spacing between the anodes and cathodes was fixed at 3 mm. Previous work by Hoffmann and colleagues has demonstrated the efficiency of the ECR to treat and disinfect toilet blackwater and described the relevant mechanisms. 10,[15][16][17][21][22][23][24][25] From January through June 2018, the electrodes were powered in constant current (CC) mode at 45 A m −2 (Y05LX7000C5E, ACOPAIN) and the voltage at the electrode stacks ranged from approximately 3.3-3.8 V. From September through December 2018, the electrodes were powered in a different mode at a higher current density. A power supply with higher capacity (HRPB-600-5, MEAN WELL) was used and the electrodes were powered in constant voltage (CV) mode; the voltage at the electrode stacks was 3.7-3.8 V and the current density was typically around 90 A m −2 . This increased the current density at the electrodes and the impacts on treatment efficiency were studied to compare with those at lower current densities.

System operation
The CLASS prototypes and biological pre-treatment systems were connected to a 3-phase 220 V power source. PLC control systems for the biological pre-treatment and CLASS were developed by ThoughtFocus (Bangalore, India) and housed independently along with dedicated remote monitoring control units (RMCUs). The CLASS control panel also included the dedicated power supplies for the electrodes.
SBR control system. The SBR control system operated two single phase pumps, one single phase air blower, and four level sensors. The pumps were used to fill and decant the SBR tank based on the input from the level sensors. The placement of the level sensors as well as the programming of the controller was implemented to protect against pumps running dry. The control logic was written to operate each  pump independently from the others, and thus each pump had its own set of error conditions. The pumps were driven by sending a logic signal to a series of relays, and the instantaneous current was monitored to determine the pump's ON/OFF state. The measured current was compared with a predefined threshold, and a fault code was triggered if the measured current was lower than this value when the pump was turned ON or higher that this value when the pump was turned OFF. The RMCUs logged the system-related parameters such as the number of cycles, status readouts of all the connected peripherals, and sensor values every 10 minutes. The data were timestamped with the local date and time. EcoSan biodigester control system (unit B). The EcoSan biodigester control system operated a single-phase air blower, two 3-phase sump pumps, one 3-phase displacement pump, and one level sensor in the holding tank. Similar to the SBR system, the control logic was written to operate each pump independently, and the system parameters were timestamped and logged every 10 minutes.
ECR control system. The filling and emptying operations, as well as powering of the electrodes for a pre-defined reaction time were handled by the ECR control system. Brine injection (including a software adjustable dosing time) and activation of the stirrer in the ECR 20 were also handled by the ECR control system. The RMCUs timestamped and tracked the operational parameters (the number of ECR and cleaning cycles, fault codes, etc.), sensor values (level sensors, water flow meters, and energy meter), the status readouts of all the connected peripherals, and the voltage and current at each electrode stack.

Water quality measurements
Disinfection was routinely confirmed by measuring the fecal coliform levels according to MPN methods adapted from the method described by Blodgett 26 with a resolution of 3 MPN per ml. Disinfection was confirmed by measuring the E. coli and total coliform bacteria levels using both agar plate and MPN methods (by T.S. Stanes Laboratories, Coimbatore, India). Helminth egg enumeration was conducted according to a modified Ambic method by isolation and microscopic evaluation as described by Grego et al. 27 Water quality was also routinely monitored using handheld equipment: • The health of the biological pre-treatment system was monitored by measuring dissolved oxygen (DO; Hanna Instruments, Model: HI9146) and pH (Myron L Ultrameter II, Model: 6P).
• The electrochemically treated water quality was assessed by measuring free and total chlorine (DPD method, Hach Method 8021/8167 for the Hach DR900 Multiparameter Portable Colorimeter) and electrical conductivity (EC; Myron L Ultrameter II, Model: 6P).
• The performance of the biological pre-treatment and electrochemical systems was further assessed by measuring chemical oxygen demand (COD; Reactor Digestion method, Hach Method 800 for the Hach DR900 Multiparameter Portable Colorimeter) and ammonia (NH 3 ; Salicylate Method, Hach Method 8155 for the Hach DR900 Multiparameter Portable Colorimeter).
Additional physicochemical water parameters were also measured by the T.S. Stanes Laboratory according to standard methods (Table S3 †).

Testing locations
Two CLASS v2 prototypes ( Fig. 2 and 3) were tested at two different locations in the city of Coimbatore, Tamil Nadu, India. Coimbatore is the second largest city in the state of Tamil Nadu (population: 1.6 million) and has a hot semi-arid climate with a short wet season from September to November.
The test sites have connections to existing freshwater sources and sewers so that wastewater treatment services for the residents would not be disrupted during the start-up evaluation phase and in the case of system maintenance. Blackwater at these sites was also piped separately from graywater, and only the blackwater was piped to the CLASS.
Site A: SBR + CLASS. At site A, the CLASS v2 prototype was connected to 12 toilets (apartments were located on the first and second floors), with 15-20 users. The MUWT (section 2.1) was connected to a municipal water supply. All the toilets serviced by the CLASS were western-style. Blackwater flowing to the system ranged between 500-1000 L daily.
Site B: EcoSan biodigester + CLASS. At site B, the CLASS v2 prototype was connected to 12 toilets (apartments were located on the ground, first, and second floors), with 15-20 users. The MUWT (section 2.1) was sourced by the local reverse osmosis (RO) treatment plant. The toilets serviced by the CLASS were all squat toilets except for one western-style toilet. Blackwater flowing to the unit ranged between 700-1400 L daily.

System operation
The CLASS v2 prototype with the SBR pre-treatment system was installed and tested at site A for 12 months. The CLASS v2 prototype with the EcoSan biodigester pre-treatment system was installed and tested at site B for 16 months. The biological pre-treatment systems operated continuously, but the electrodes were tested in shorter 3-6 month periods within this operational time frame to accommodate electrical upgrades to the system. The cumulative electrochemical treatment time was 2450 hours (100 days) at site A and 5185 hours (216 days) at site B.
Regular maintenance tasks included cleaning the filters between the settling tanks and biological pre-treatment systems; this was performed every 10 days for the trash trap preceding the SBR and weekly for the EcoSan biodigester to prevent the pump from clogging (note: this would not be necessary if the EcoSan biodigester was installed as designed). The polishing filter installed after the ECR was View Article Online changed monthly as a precaution to ensure that the helminth eggs were properly stopped. Sludge was periodically removed from the biological systems to maintain treatment quality. The CLASS settling tanks did not require desludging during the testing period. The sludge thickness was measured at the completion of the study and it occupied approximately 10% of the tank volume after 12+ months of use (Table S4 †). Also, with the redesign of the ECR and additional focus on the sealing of the CLASS system overall, the issue of odor during system operation was eliminated.
In addition to these maintenance tasks, daily addition of additives to the system was needed to ensure treatment quality. Sodium carbonate was added during the biological pre-treatment processes to enable complete nitrification and increase the buffering capacity of the water entering the ECR to maintain a near neutral pH or higher during electrochemical treatment. Brine injection was also needed prior to the start of electrochemical treatment to ensure adequate chloride concentration for chlorine generation; brine injection was also required during the closed loop operation, which was a major learning from this study. Originally, the technology was envisioned with single brine addition at start-up because it was assumed that the chloride concentration of recycled water would continuously increase over time due to the influx of urine. During field testing, the groups have observed similar low chloride concentrations in the inlet, 9 which are partially explained by the large amount of fresh water that is poured into the toilet from the water tap located in the bathroom.
The biological pre-treatment systems were installed to reduce the nutrient and organic loading to enable more energy efficient electrochemical treatment. A target of 70% reduction in both COD and ammonia levels was defined prior to testing. Table 2 summarizes the influent and effluent characteristics of the biological pre-treatment systems installed at sites A and B. The blackwater at site A was consistently more concentrated than that at site B. For example, the inlet COD at site A averaged 735 mg O 2 per L versus 365 mg O 2 per L at site B. The inlet NH 3 concentration at site A averaged 213 mg N per L and was less than half of this at site B (83 mg N per L).
For site A, in order to achieve the targeted 70% reduction in COD and NH 3 levels, the SBR was operated with an average oxygen transfer rate of 0.14 kg O 2 per h during the aeration phase only (dissolved oxygen maintained at 3-4.5 mg O 2 per L), and the hydraulic retention time (HRT) was maintained at 40 h. An 8 hour SBR cycle design was found to effectively create a selective environment for microbes to carry out biological organic and NH 3 removal reactions in a healthy sludge volume. During testing, the MLSS ranged from 3000-4500 mg L −1 and MLVSS ranged from 2400-3000 mg L −1 , resulting in a food-to-microbe ratio (F/M) of 0.15. The sludge volume index (SVI) was found to be 80-100 ml g −1 , which indicated well settling sludge. The 30 day solids retention time (SRT) was maintained throughout the study through periodic draining of the excess sludge.
Furthermore, for site B, in order to achieve the targeted 70% reduction in COD and ammonia levels, the EcoSan biodigester was operated with a diffused aeration rate of 20 LPH in the aerobic chamber (dissolved oxygen DO was maintained between 3-4 mg O 2 per L). The DO in the anaerobic chamber was maintained between 0.2-0.6 mg O 2 per L. As recommended by the manufacturer, the recirculation of sludge between the aerobic/settling chambers and the anaerobic chamber was driven through the air lift mechanism to enhance the denitrification process. The MLSS was maintained at 2500-3000 mg L −1 in both the anaerobic and aerobic chambers, and the SVI was in the range of 80-100 ml g −1 . Approximately 500 L of biological sludge (1% sludge consistency) was disposed of after 6 months.

Results and discussion
4.1 Biological pre-treatment SBR (site A). The water post SBR appeared clear, with the turbidity measuring below 1 NTU (Table S5 †) and a total suspended solids (TSS) of 13 mg L −1 (Fig. 4c). The SBR effectively reduced the nutrient and organic loading, with the outlet COD levels averaging 157 mg O 2 per L (80% reduction, Fig. 4a). Initially, the SBR did not meet the target levels for ammonia reduction, and the outlet levels averaged 47 mg N per L. Beginning in July 2018, sodium carbonate was added to the blackwater at a rate of 650 g per 5 SBR cycles to maintain adequate alkalinity and achieve complete nitrification during aeration (EPA Nitrification 2002). With the addition of sodium carbonate, NH 3 was reduced to an average of 20 mg N per L, corresponding to a 91% reduction (Fig. 4b). Despite achieving excellent nitrogen removal, the SBR operation was fragile. For example, the nutrient removal was limited, and the water appeared greenish in color for a period of 3 weeks for unknown reasons (this data is not included in Table S5 †).
EcoSan biodigester (site B). The EcoSan biodigester effluent appeared clear, with the turbidity measuring below the detection limit and the TSS averaging 6 mg L −1 (Fig. 4c). The EcoSan biodigester effectively reduced the nutrient and organic loading. The COD levels averaged 46 mg O 2 per L (87% reduction, Fig. 4a) and the NH 3 levels averaged <20 mg N per L. In response to the pH becoming acidic after electrochemical treatment, 150 g per day of sodium carbonate was added to the settling tank, feeding the EcoSan biodigester beginning in August 2019. This also improved the ammonia reduction from 79% to 85%.

Electrochemical treatment
Electrochemical disinfection relies on robust chlorine production. The current density and the concentration of ammonia and chloride in the water post biological treatment were strong contributors to the electrochemical performance (Fig. 5). The electrodes used in the CLASS v1 prototypes were operated in CV mode with a potential of 3.6 V at the electrodes. Over 12 months of operation, the current density was observed to be reduced and the CLASS v2 prototypes were initially operated in CC mode (45 A m −2 ) from January-June 2018 to mitigate this problem. Due to the high resistance of the quick-disconnect connectors used, a potential of only 3.3-3.8 V was measured at the electrodes.
For the second phase of this study from September-December 2018, the electrodes were operated in CV mode (3.7-3.8 V at the electrodes), and different power supplies able to deliver up to 90 A m −2 were installed (the current was varied based on EC; Fig. S2 †). The electrodes operating in the prototype at site A were replaced when the CV operation was initiated, but the same electrodes were used during both phases of field testing at site B. The system running hours, number of treatment cycles, and treated water volume for the different CLASS v2 field testing periods are summarized in Table 2. In order to calculate the number of treatment hours (i.e., the system running hours continue to increase if the system is on, even if there is not enough water to treat), the number of treatment cycles was multiplied by the treatment time.
Chlorine production depends on the electrochemical oxidation of Cl − present in blackwater. Previous work has shown that chlorine production is optimal when the Cl − concentration is between 10 and 30 mM. 17 Due to the addition of external fresh water by the inhabitants through bucket flushing and anal cleansing, the Cl − level was below this target at both sites (5.3 mM, n = 19), necessitating the addition of a supersaturated brine solution prior to electrochemical treatment. The brine injection time was controlled using the software and varied based on the properties of the blackwater (injection times ranging from 40-140 s increased the chloride concentration to 10-35 mM). Regular measurements of EC were used as an indicator of the level of chloride addition. EC levels were also optimized at both sites, with the prototype at site A operating at a higher EC than that at site B due to a higher initial mineral concentration in the flush water (i.e., municipal water was used in the bathrooms at site A vs. RO water at site B; Fig. 5C and F). At site A, chlorine production was modest during the first phase of field testing when the electrodes were operated in CC mode at a current density of 45 A m −2 (free chlorine: 0.11 mg Cl 2 per L and total chlorine: 1.70 mg Cl 2 per L, n = 27; Fig. 5A). The ammonia content of the water post biological pre-treatment was still higher than that of the optimal during this time (47 mg N per L, n = 20; Fig. 5B). During the second phase of field testing, the electrodes were operated in CV mode at a higher current density of 90 A m −2 . Sodium carbonate was also added to the SBR to enhance ammonia removal (20 mg N per L, n = 36; Fig. 5E). The median free and total chlorine increased to 1.10 mg Cl 2 per L and 5.00 mg Cl 2 per L, respectively (n = 57; Fig. 5D). Breakpoint chlorination was achieved on some occasions, and the free and total chlorine was measured to be 50+ mg Cl 2 per L for those treatment cycles (note: median values were used so that this behavior would not skew the overall results).
At site B, chlorine production was modest during the first phase of field testing when the electrodes were operated in CC mode at a current density of 45 A m −2 (free chlorine: 0.12 mg Cl 2 per L and total chlorine: 1.21 mg Cl 2 per L, n = 34; Fig. 5A). Chlorine levels rose at the end of the first phase corresponding to higher EC operation and lower levels of ammonia post biological pre-treatment (free chlorine: 0.29 mg Cl 2 per L and total chlorine: 2.07 mg Cl 2 per L, n = 24; Fig. 5A-C). During the second phase of field testing when the electrodes were operated in CV mode at a current density of 90 A m −2 , chlorine production increased substantially (Fig. 5D). The median free and total chlorine increased to 50 and 54 mg Cl 2 per L, respectively (n = 52), and were in excess of the levels reported by Cid et al. 9

System performance
Physicochemical properties of treated water. A summary of other water quality indicators used to evaluate the CLASS v2 performance is provided in Table 3. The treated water at both sites was clear and met the ISO 30500 standard threshold for TSS.
The treated water at site A met the restricted urban water reuse ISO 30500 threshold for both COD (62 mg O 2 per L, 90% overall reduction) and total nitrogen (73% removal post addition of sodium carbonate). Ammonia levels were also significantly reduced (96% post sodium carbonate addition). Before the addition of sodium carbonate, the treated water was acidic. After the addition of sodium carbonate, the treated water was basic and met the ISO 30500 standards for  The treated water at site B met the discharge standards for total nitrogen outlined in the ISO 30500, and the ammonia levels were near zero during the second phase of field testing. Notably, the unrestricted urban reuse standard for COD was met in 85% of the tests, and the results are compared to those presented by Cid et al. 9 At 90 A m −2 , the ammonia in the effluent was near zero. Before the addition of sodium carbonate, the treated water was too acidic for discharge. After the addition of sodium carbonate, the treated water was often too basic for discharge. Furthermore, the treated water did not meet the target levels for phosphorus removal.
Bacterial counts in treated water. The absence of E. coli in the treated water was used to indicate disinfection, which consistently measured below the detection limit of the assay (note: the ISO 30500 standard requires ≤0.1 CFU per ml; Fig. 6). The biological pre-treatment systems reduced the bacterial loading by 1-2 log orders.
Helminth egg enumeration. The blackwater and treated water were periodically screened for the presence of soiltransmitted helminth eggs and other parasites ( Table 4). The ISO recommended test for the disinfection of these intestinal parasites includes a spiking procedure that was not implemented out of safety concerns for the users. The blackwater from the settling tank was initially characterized for the presence of helminth eggs. The number of eggs found Table 3 Effluent parameters after ECR treatment and % removal from the biological treatment system inlet reported in Table S5; † ISO 30500  parameters from Table 1   Environmental Science: Water Research & Technology Paper in the blackwater from the settling tanks varied widely from sample to sample (1-500 eggs per L). Most eggs evaluated were non-pathogenic free-living species, although pathogenic hookworm eggs were found on some occasions in the blackwater (1-5 egg per L). Typical microscopy images of egg species, free living larvae, and protozoa isolated from the blackwater in this study are shown in Fig. S3. † The treated water at both sites was found to be consistently negative for helminth eggs and larvae, meeting the requirements of the ISO 30500 standard. The treated water at site A periodically tested positive for free-living protozoa (listed as "Other" in Table 4). These organisms are found in water sources throughout India and do not present an increased health risk to the population. This contamination was likely due to the fresh water supply to the building.

Energy consumption
Data logged by the RMCUs were averaged over a period of continuous operation for at least 8 days for each reported condition ( Table 5). The energy consumption was calculated by multiplying the voltage by the average current and factoring in the operation time of the system based on the availability of blackwater. These energy consumption values include all the ancillary pumps, sensors, and control systems required for the operation. The calculated values were verified by comparing them to the readings of the energy meter.
At site A, the SBR required 5.8 W h L −1 to run (calculation based on an 8 hour cycle). The electrochemical treatment process required 33 W h L −1 for the CC operation at 45 A m −2 , which is in agreement with the energy consumption previously reported for a similar system with the same electrodes (Cid 2018 9 ). When electrochemical treatment was carried out using the CV operation at 90 A m −2 , the required energy increased to 49 W h L −1 .
At site B, the aeration chamber in the EcoSan biodigester required 2 W h L −1 to operate the air blower. The system was designed to operate by gravity, and as such this should be the only energy requirement. Due to site limitations, the EcoSan biodigester was installed above ground during field testing and needed to be fed in a controlled manner. The selected pumps were inefficient and increased the energy requirement by an additional 24 W h L −1 . The electrochemical processes at site B had similar energy requirements to site A under both operating conditions. When the treatment time was reduced to 75 versus 120 minutes (during CV operation at 90 A m −2 only), the electrochemical treatment energy requirement also dropped to 26 W h L −1 ; this was the most efficient condition tested.

Conclusion
This paper reports, for the first time, the demonstration of a combined biological and electrochemical disinfection technology at the scale of an apartment building. Blackwater from two apartment buildings in India was treated onsite for 12+ months, producing over 180 000 L of reclaimed water. The recycled water was used for toilet flushing for a sustained period of three months (89 days) during this field testing period. The CLASS v2 prototypes consistently achieved high disinfection rates with E. coli counts below the assay detection limit. Efficient organic and nutrient removal was dependent upon the blackwater characteristics, which differed between the sites, as well as the performance of the biological pre-treatment and electrochemical systems. More than 90% of the organic loading was removed during the treatment process, and the effluent nearly met the stringent thresholds outlined in the ISO 30500 standard. The nutrient removal was variable for nitrogen (53-73%) and minimal for phosphorus. Ongoing studies have incorporated new electrodes with different coating formulations, which hold promise for better performance by achieving high effluent quality with minimal biological pretreatment of blackwater.

Conflicts of interest
There are no conflicts to declare.