## 2 Materials and Methods
### Switched Capacitor Biphasic Current Stimulator  
Figure 4a illustrates a detailed schematic diagram of the developed biphasic current stimulator circuit, which is integrated with the SiNW photodetector. The current generated by the SiNW is converted into voltage using a switched-capacitor structure, ensuring a stable voltage supply. Subsequently, a rail-to-rail folded cascode amplifier is designed to utilize the entire voltage input range from 0 to Vdd. The output stage of the amplifier, which is designed as a single-end output, is connected to the NMOS, which regulates the current flowing through the working electrode (WE) and counter electrode (CE) in the biphasic current stimulator. The stimulation current can also be controlled by adjusting the load resistor (Rload) connected to the H-bridge. The SiNW photodetector array and stimulator circuit operate at a relatively low supply voltage of 3V. The stimulator-integrated circuit (IC) operation employs four control signals. Figure 4b presents a timing diagram of the control signal and the generated stimulation current. The stimulator circuit begins operation upon receiving the Pinit signal and concludes by discharging and resetting the accumulated charge via the Prst signal. The Pinit signal charges the capacitor with the current flowing through the SiNW photodetector and converts it into voltage. The voltage across the capacitor is proportional to the integral of the current in the photoresistor over time. Consequently, the gain and amplitude of the stimulation current can be effectively regulated by adjusting the duration of the Pinit signal, which determines the charging time of the capacitor. The biphasic current pulse generator comprises switches, P1 and P2. Figure 4c depicts each state of the biphasic current pulse flow. The stimulator is designed to control the injected current to 200 \(\mu\)A, with two switches operating complementarily. When P1 is ON and P2 is OFF, the current flows from the working electrode (WE) to the counter electrode (CE) through \(Z_{\text{load}}\). Subsequently, P1 is turned off and P2 is turned on simultaneously for charge balance, since the same amount of injected charge must be removed to prevent electrode corrosion. In retinal stimulation, the stimulation IC interfaces with the retinal tissues  
Figure 3: Fabrication process for the vertically stacked silicon nanowire photodetector: (**a**) SOI wafer, (**b**) first photolithography, (**c**) Ti and Al deposition, (**d**) lift-off process, (**e**) second photolithography, (**f**) deep reactive ion etching (DRIE) with detailed process flow steps (**i**–**iv**), and (**g**) PR removal followed by rapid thermal annealing (RTA). via an MEA, utilizing a parallel configuration of a resistor (R) and capacitor (C) [28; 29]. As shown in Figure 4c, the Zload is composed of faradic charge transfer resistance, tissue layer impedance, and double-layer capacitance. The values utilized in this paper are derived from data obtained in a previous study [30] and have been employed to design the circuit accordingly. The Faradic charge transfer resistance (R\({}_{\text{F}}\)) is 13.18 M\(\Omega\), and tissue impedance (R\({}_{\text{T}}\)) is 250.62 \(\Omega\). The double-layer capacitance (C\({}_{\text{D}}\)) is 124.58 nF. Figure 4d depicts the top layout of the stimulator circuit. The stimulator is fabricated using the CMOS 180 nm TSMC technology, and the dimension of a pixel is 740 \(\upmu\)m \(\times\) 400 \(\upmu\)m.  
The optical and electrical characteristics of the SiNW photodetectors are measured using a semiconductor parameter analyzer (4200A-SCS; Keithley, Cleveland, OH, USA). The measurements are conducted in a probe station inside a dark box, where the probes are connected to the electrodes, as shown in Figure 5a. A halogen light source is used for illumination, and the light intensities are measured using a digital lux meter (MEXTECH, LX-1010B; Mextech, Mumbai, India).