2-D Optical-CDMA Modulation With Hard-Limiting for Automotive Time-of-Flight LiDAR

—In this proof-of-principle paper, the application of 2-D optical code-division multiple-access (OCDMA) modulation to long-range automotive time-of-ﬂight (ToF) light detection and ranging (LiDAR) is studied. The regulations and physical constraints that govern the design parameters are reviewed. Using 2-D carrier-hopping prime codes (CHPCs), the modulation model and a novel 2-D hard-limiting decoder are designed and validated with OptiSystem TM simulations. Based on the design parameters, the 2-D CHPCs have six times as many distinct sequences (for sensor identiﬁcation) as 1-D code sequences. Analytical and simulation


I. INTRODUCTION
L IGHT detection and ranging (LiDAR) is receiving attention in the research and development of automated vehicles because of greater benefits and capabilities, such as long-range performance, fast scanning, low cost, and superior resolution, reliability, and interference robustness, than conventional technologies using radar, ultrasound, and cameras [1], [2]. One promising application of automotive LiDAR is long range, pulse Manuscript  scanning, time-of-flight (ToF) measurement to determine an object's presence and distance by using avalanche photodiodes (APDs) and single-photon avalanche diodes (SPADs) with various data processing methods [3]- [7]. A conventional ToF signal consists of a train of short, high-power laser pulses emitted periodically from a sensor of a LiDAR-equipped vehicle to an object. The round-trip time of the ToF signal is recorded and then the sensor-object distance is calculated. Studies have been performed on characterizing and improving the hardware aspects and processing techniques of this kind of pulsed-ToF systems. For example, Chen, et al. [4] reviewed existing data processing approaches and workflows on SPADbased ToF LiDAR systems and then suggested future research directions. Donati, et al. [5] developed a theoretical framework to evaluate the precision of ToF measurements by analyzing the timing errors in APD-and SPAD-based receivers. Buchner, et al. [6] analyzed the distribution of higher-order photon detections in SPADs. The theoretical model was validated in a LiDAR system with a SPAD circuit that could detect multiple photons in a single measurement under high background noise power. Beer, et al. [7] statistically analyzed the effects of the dead time on the photon counts in indirect ToF measurements with SPADs. The model was useful to correct systematic and random errors of this kind of ToF measurements.
To alleviate the fundamental issues of pulsed-ToF measurements, including range ambiguity and frequent false detections, the applications of optical code-division multiple-access (OCDMA) modulation using 1-D unipolar time-spreading sequences, such as prime codes, modified prime codes, and optical orthogonal codes (OOCs) [8]- [12], were recently studied [13]- [15]. Each sensor was assigned a distinct time-spreading sequence. Every ToF pulse was encoded into and emitted in form of a sensor's assigned sequence. Due to pseudo-orthogonality, every sequence served as a distinctive tag (or address signature) of the ToF signal, thus supporting sensor identification. Fersch, et al. [16] also implemented a field programmable gated array (FPGA)-based correlation receiver for the 1-D OCDMA modulation with OOCs. These studies showed that 1-D OCDMA could extend the ToF measurement distance and potentially support faster scanning rate and better angular resolution than the conventional pulsed-ToF methods. Besides LiDAR applications, Oberdorfer, et al. [17] applied 1-D binary-phase-shiftkeyed (BPSK) CDMA to enhance cross-talk robustness in ultrasonic ToF measurements of an opto-acoustic indoor positioning system. This work is licensed under a Creative Commons Attribution 4.0 License. For more information, see https://creativecommons.org/licenses/by/4.0/ However, three deficiencies were found in these studies [13], [14], [16]. First of all, Fersch, et al. [13] only demonstrated the correlation properties of OOCs with only one sequence arriving at the decoder of a sensor each time. The interfering effect of multiple arrival sequences (i.e., interference robustness) of 1-D OCDMA modulation was never studied. (A high degree of interference robustness is beneficial because it can support simultaneous ToF measurements of different objects from multiple sensors or multiple spots of the same object [3]. Either case can result in faster scanning and frame rate, higher resolution, and more measurement points.) Secondly, due to laser-safety regulations and hardware constraints, the allowed code weight, length, and cardinality of 1-D time-spreading sequences were very limited [13]. As a result, very few sensors or simultaneous ToF measurements could be supported. Finally, the powers of arrival sequences can be different due to the reflections from objects at different distances and of different texture/reflectivity. This kind of near-far (power) problem has never been considered in the 1-D OCDMA ToF studies. Hence, Kwong, et al. [18] introduced, for the first time, 2-D OCDMA modulation for ToF LiDAR and reported one OptiSystem TM simulation result, which showed the interference robustness of 2-D OCDMA. However, the study was preliminary, the near-far problem was never resolved, and no performance analytical model was derived.
To address the above deficiencies, this proof-of-principle paper investigates the application of 2-D OCDMA modulation [11], [12], [19]- [21] to fast-scanning, long-range, automotive ToF LiDAR in Section II. A novel 2-D "hard-limiting" decoder is designed to overcome the near-far (power) problem. The construction algorithm and properties of carrier-hopping prime codes (CHPCs) [11], [12], [19], a family of 2-D wavelengthhopping time-spreading (or, in short, wavelength-time) sequences, are reviewed. Employing wavelengths as the second coding dimension, the 2-D CHPCs have the advantages of enlarged cardinality, flexible choices of code weight and length, and ideal correlation properties. Large cardinality can support many sensors with distinctive ToF tags (i.e., identifications) to alleviate range ambiguity [13]. Multiple wavelengths and ideal correlation properties can enhance interference robustness and make false detections less likely than 1-D time-spreading sequences. These characteristics also support multiple simultaneous ToF measurements for faster scanning/frame rate and higher angular resolution [13], [14]. Also in Section II, the constraints imposed by laser-safety regulations and hardware in the design of code parameters (e.g., weight, length, and cardinality) are reviewed. Section III reports the OptiSystem TM simulations of the proposed 2-D OCDMA modulation model. The degree of interference robustness and elimination of the near-far effect by the novel 2-D hard-limiting decoder are demonstrated. Finally, the performance of the proposed model under the near-far effect is analyzed and the performance benefits of the hard-limiting decoder are investigated in Section IV. The analytical and simulation studies show that the 2-D OCDMA modulation model can support more sensors and simultaneous ToF measurements as well as carry better properties and performances than the 1-D counterparts. In conclusion, although the 2-D approach is more complex, it is more beneficial and cost efficient.

II. 2-D OCDMA AUTOMOTIVE TOF LIDAR DESIGN
In the proposed 2-D OCDMA modulation design, every ToF pulse is encoded into a 2-D wavelength-time sequence in the emitter of a LiDAR sensor. Each sequence consists of short optical pulses of multiple wavelengths within one (time) period T , which is equal to the repetition period of the conventional pulsed-ToF model. To accommodate the sequence's elements, T is divided into multiple time slots (or chips) of duration τ . The code length or period N (i.e., total number of chips) is governed by N = T /τ . The code weight w denotes the number of pulses in each sequence. (E.g., see Fig. 3 for a 2-D wavelength-time sequence of w = 3 and N = 31.) These 2-D sequences belongs to the class of sparse codes with small w and large N so that the cross-correlation function (i.e., the amount of interference) created by each of the unwanted sequences to the desired one at any time is bounded by one-the lowest possible value in wavelength-time codes [8]- [12]. Fig. 1 shows the block diagram of the proposed 2-D OCDMA modulation design for an ToF LiDAR sensor module. At the emitter of a sensor, a short ToF pulse is first created at a fixed interval (i.e., repetition period). The pulse width, power, and period are governed by various factors, such as laser safety regulations, scanning hardware speed, number of measurement points, angular resolution, as described in Section II-B. In the conventional pulsed-ToF model, this pulse will trigger a laser to create an optical ToF pulse, which is then emitted to an object for the ToF measurement. However, in the proposed 2-D OCDMA modulation model, this pulse will instead be encoded into a wavelength-time sequence in the 2-D encoder in Fig. 1. In the 2-D encoder, the short pulse is first split into w pulses by a 1 × w power splitter. Each of these w pulses is delayed along its path by a programmable delay-line. The amount of time delay is determined by the location of the pulse in the wavelength-time sequence assigned to the sensor. (Details of the 2-D wavelengthtime sequences are given in Section II-A.) Afterward, each of these w delayed pulses triggers a laser of a specific wavelength (e.g., λ 0 , λ 1 , . . ., or λ w−1 ) that is assigned to the pulse. These w optical pulses are combined by a w × 1 (optical) power splitter to form the intended wavelength-time sequence, which is then emitted to an object for the ToF measurement. A scanner is used to direct the emitting 2-D sequences (i.e., ToF signals) to the targeted object. To perform angular resolution pixel by pixel, the scanner can be made of microelectromechanical systems (MEMS) scanning mirror or a rotating mirror to steer the sequences laterally [13], [14].
At the sensor's receiver, multiple ToF sequences can arrive simultaneously. While some of them are originated from the same sensor (at adjacent measurement points), some come from different sensors. They are considered as interference from the receiver's perspective. The arrival sequences are detected by a 2-D decoder with its address signature configured as an inverted filter of its associated encoder. An arriving sequence with the correct address signature (i.e., from the emitter of the same sensor) will create an autocorrelation function with a high peak of height equal to the code weight w at the output of the decoder. However, those arrival sequences that do not match with the address signature are considered as interference, and they give an accumulated crosscorrelation function at the decoder's output. As exemplified in Section II-A, properly designed 2-D wavelength-time sequences is important to maintain high degree of pseudo-orthogonality (i.e., very low cross-correlation function) so that the correct ToF signal (i.e., desired sequence) can be distinguished from many incorrect ones.
Due to different object distances, surface textures, or reflection angles, sequences will arrive at the receiver with unequal pulse powers, thus creating the near-far problem. While some arrival sequences can have the same or weaker power, those have stronger power than the desired sequence are more problematic. This is because the latter scenario will create stronger interference (i.e., higher cross-correlation function), which can be as strong as or even higher than the autocorrelation peak, thus causing false detections. To eliminate the near-far effect without complex signal processing [14], a novel 2-D "hard-limiting" decoder is designed in this section. In addition, arrival (interfering) sequences may have their pulses localized at some chip locations and thus create unexpected strong interference [11], [12]. The hard-limiting decoder can also equalize these interfering pulses such that they will contribute equally toward the crosscorrelation function, thus enhancing interference robustness, as demonstrated in Section III.
As shown in Fig. 2, the pulses of the arrival ToF sequences at the front end of the decoder are routed to their corresponding wavelength paths (denoted λ 0 , λ 1 , . . ., and λ w−1 , respectively) by a 1 × w wavelength-division-multiplexing demultiplexer (WDM DEMUX). The optical pulses in each path are then converted to electrical pulses by an APD. The novelty of the decoder is on the use of hard-limiters (e.g., limiting amplifiers) to equalize the powers of pulses that have unequal powers caused by the near-far problem. The threshold of each hard-limiter is set to the expected power level of the sensor's sequence reflected from the targeted object. The pulses of interfering sequences with power level equal to or above the threshold will trigger the saturated gain of the hard-limiter to clip them to the same power level as that of the sensor's sequence. On the other hand, the interfering pulses with power level lower than the threshold cannot trigger the hard-limiter and thus are suppressed. Using the same mechanism, the hard-limiter can also clip any unexpected strong power caused by the localization of multiple overlapping pulses in a chip location to constant power [11], [12]. The simulations in Section III-B and performance analyses in Section IV-B are based on this (optimized) threshold model. Since the emitter and receiver are both housed in the same sensor, the receiver knows the emitted power level of the sensor's sequences and the threshold level can be adjusted and optimized by maximizing the autocorrelation-peak-to-interference ratio in the correlation function at the decoder's output.
After the 2-D decoder, a demodulator is used to thresholddetect the high autocorrelation peak (rising above the accumulated cross-correlation function) and restore the proper format of the ToF signal. Finally, a timer is used to record the round-trip time t of the ToF signal between the sensor and targeted object.
The nonlinearity of opto-electrical devices, such as APDs and SPADs, is an issue in the conventional pulsed-ToF model [6], [22]. However, the prospect of triggering unwanted nonlinearity in the APDs, which are the main opto-electrical devices in the proposed 2-D CDMA modulation model with hard-limiting, is much reduced. This is because every highpower optical pulse used in the conventional pulsed-ToF measurement is now split into w lower-power optical pulses in every wavelength-time sequence. Also, by routing pulses of different wavelengths to their respective paths, the WDM DEMUX at the front end of the 2-D decoder split the incident power on every APD by another factor of w.
Fersch, et al. [16] demonstrated a FPGA correlation receiver (i.e., decoder) for 1-D OCDMA ToF signals. The receiver was programmable and successfully correlated three 1-D OOC sequences of weight w = 3 and period N = 31 (chips) separately at a repetition period of 155 ns and chip-width of 5 ns. The address signature of the FPGA correlation receiver was implemented in a digital delay-line, which consisted of a chain of synchronous registers. Each register stored every incoming 5-ns pulse for one clock cycle before shifting it to the next register. To generate the required time-delays for the address signature of the decoder, the corresponding locations of the register chain were tapped. Finally, the tapped pulses were combined to give the correlation function. This delay-line design can also be used in an encoder to generate the 1-D OOC sequences. As studied in Section II-A, the same repetition period, code length, and chip-width are used in the 2-D OCDMA modulation scheme. Hence, the same delay-line design can be implemented in the 2-D encoder and decoder.  [18]. Each colored square indicates the chip (time-slot) location and wavelength of an optical pulse (i.e., a mark chip) in the sequence.

A. 2-D Asynchronous Wavelength-Time Codes
To demonstrate the operating principles of the 2-D OCDMA modulation, a family of wavelength-time sequences, the 2-D (L × N, w, λ a , λ c ) = (w × N, w, 0, 1) CHPCs of L wavelengths, N chips (i.e., code length), and w pulses (i.e., code weight) are used [11], [12]. The CHPCs are chosen because they have ideal correlation properties: 1) the maximum autocorrelation sidelobe λ a is always equal to 0, thus giving zero self-interference, and 2) the maximum cross-correlation value λ c is always bounded by 1, thus giving the lowest possible mutual interference.

B. Design Constraints Due to Laser Safety Regulations and Hardware Limitations
To apply OCDMA modulation to the ToF measurements, the code parameters are governed by the following regulations and constraints.

1) Code Weight Constraint From Laser Safety Regulations:
The admissible exposure limit per pixel (AEL pixel ) restricts the maximum allowable optical energy per ToF-measurement period for eye safety. The total optical energy contained in one complete OCDMA emission (per period), E CDMA , should be bounded by AEL pixel . Hence, the peak power of each one of the w pulses (or chips) of width τ in every sequence is governed by [13], [14] which is the same in both 1-D and 2-D OCDMA modulation. According to (3), smaller number of pulses w or narrower chip-width τ translates to higher peak chip-power for a given AEL pixel . This, in turn, gives higher signal-to-noise ratio (SNR) against background and hardware noise [23], such as APD's thermal and shot noise, at the receiver. As power attenuation is inversely proportional to the square of ToF distance, Kim and Park [14] showed that, for a given false-alarm rate, longer ToF distance could be covered using 1-D time-spreading sequences with smaller w due to better SNR. On the other hand, larger w could improve the accuracy and precision of ToF measurement due to higher signal-to-interference ratio (SIR) (i.e., a higher autocorrelation peak atop the cross-correlation function) [11], [12]. According to [14], the maximum ToF-measurement distance was usually given priority over accuracy or precision. Thus, it was better to use lower code weight, such as w = 3. This code weight constraint also holds for the proposed 2-D OCDMA modulation.
2) Code Length Constraint From Scanner: The choice of code length in the OCDMA ToF measurement is restricted by the chip-width τ and the scanner time window, which is limited by the frame rate, total pixel count per frame, and signal-processing time [14]. Usually, the direction of the laser beam is continuously steered by a rotatory MEMS mirror. If the code length N is too long, the laser beam will be moved to a different spot of the object before the whole sequence can be reflected from one spot back to the sensor and thus the ToF measurement becomes inaccurate or in failure.
According to [14], the MEMS mirror typically could steer the laser beam over a horizontal field-of-view of α = 60 • in T hor = 125 μs. For a measurement distance of D = 100 m using a 1-D sequence of N = 31 with τ = 5 ns, the lateral spot (or pixel) size could not be greater than and the scanning or measurement period of each spot should be completed within one sequence period of 31 × 5 = 155 ns. Usually, the ToF measurement required a sensor-object distance of at least D = 100 m, which corresponded to the (oneway) travel time of D/c = 333.3 ns. To have at least two complete ToF measurements per spot (or pixel), N = 31 was found as the longest allowable code length for the 1-D OCDMA modulation [14]. This code-length constraint also holds for the proposed 2-D OCDMA modulation.
3) Code Cardinality Constraint From Johnson's Bound: Never mentioned in the 1-D OCDMA ToF studies, the parameters and correlation properties of code sequences impose a constraint to the cardinality. The code cardinality is governed by the famous Johnson's upper bound [11], [12] where λ c > 0 and λ a > 0. The term L represents the number of wavelengths when 2-D wavelength-time sequences are used. For 1-D time-spreading sequences, such as the OOCs or prime codes, L = 1 is used. As mentioned earlier, w ≈ 3 and N ≈ 31 should be used for both 1-D and 2-D OCDMA ToF measurements. Eq (5) dictates the cardinality upper bound of (1 × 31, 3, 1, 1) 1-D time-spreading sequences to be no greater than Φ(1 × 31, 3, 1, 1) ≤ 1 × (1 × 31 − 1)/[3 × (3 − 1)] = 5. In fact, the (1 × 31, 3, 1, 1) 1-D OOCs used in [13] and [14] had exactly the cardinality of 5. Hence, they can only provide distinctive ToF tags for up to five sensors. As shown in Section IV, a much lower number of simultaneous emissions from these sensors can be supported because small code weight (i.e., w = 3) gives very small SIR and low degree of interference robustness.
The cardinality limit is less of a problem in the 2-D wavelength-time sequences because the number of wavelengths L and code length N are scalable independently. From (5), a set For the 2-D (L × N, w, 0, 1) CHPCs, the number of wavelengths L, code weight w, and code length N can be adjusted independently as long as w ≤ L ≤ N . The cardinality of the CHPCs is governed by N . In other words, the (L × 31, 3, 0, 1) CHPCs always have six times as many distinct sequences as the 1-D (31, 3, 0, 1) OOCs, no matter using L = 3, 4, or even up to 31 wavelengths. The benefit of using more wavelengths is for lowering hit probabilities, which, in turn, improves performance, as shown in Section IV.

III. 2-D OCDMA TOF LIDAR SIMULATIONS
To proof the operation principles of the proposed 2-D OCDMA modulation design, OptiSystem TM simulations are performed and reported in this section. Fig. 4(a) shows the simulation set-up of the emitter in a ToF LiDAR sensor. A bit sequence generator is used to repeatedly create one "1" followed by thirty "0"s, 10000 00000 00000 00000 00000 00000 0, to trigger a NRZ pulse generator to create a pulse of width τ = 5 ns for a 2-D encoder to generate a CHPC sequence of length N = 31 at a repetition period of 155 ns.
To generate the (3 × 31, 3, 0, 1) CHPCs, the 2-D encoder consists of a splitter, which split every incoming 5-ns pulse into w = 3 pulses, one pulse for each of the three paths. These pulses are delayed in their own paths by programmable delay-lines to create 0, 3, and 6 chips (i.e., 0, 15, and 30 ns) of time delays, respectively, in order to create the CHPC sequence x 3 = (0, 3, 6) = λ 0 00λ 1 0 0λ 2 000 00000 00000 00000 00000 0. (By programming these delay-lines accordingly, every one of the 31 CHPC sequences in the set can be generated.) These three properly delayed pulses then trigger their corresponding direct-modulated lasers of wavelengths λ 0 = 650, λ 1 = 660, and λ 2 = 670 nm, respectively. Finally, the three optical pulses are recombined at the wavelength multiplexer (MUX) to form sequence x 3 , which is then emitted as a coded ToF signal to the target for the distance measurement.
The reflected 2-D CHPC sequences (i.e., ToF signals), which are originated from the sensor's emitter as well as emitters of other sensors, will arrive at the receiver of the sensor. To distinguish the desired sequence from interfering sequences and, for the first time, overcome the near-far problem, Fig. 4(b) shows the simulation set-up of the 2-D hard-limiting decoder. The decoder consists of a wavelength DEMUX, a set of w = 3 APDs with limiting amplifiers, programmable delay-lines, and a 1 × 3 power combiner. The DEMUX routes the arrival pulses to their corresponding wavelength paths: top path for λ 0 = 650-nm pulses, middle path for λ 1 = 660-nm pulses, and bottom path for λ 2 = 670-nm pulses. The APDs convert the optical pulses into electrical ones. The programmable delay-lines are configured to reverse the time delays of the pulses to their proper chip locations in accordance to the address signature of the decoder. Thus, the pulses of the desired sequence will ride atop each other to give an autocorrelation peak. (By programming the time delays accordingly, every one of the 31 CHPC sequences in the set can be correlated in the decoder.) To correlate the CHPC sequence x 3 = (0, 3, 6), the time delays on the λ 0 , λ 1 , and λ 2 wavelength paths need to be 30, 15, and 0 ns (i.e., 6, 3, and 0 chips), respectively, as shown in Fig. 4(b).
The power combiner combines the delayed pulses from the three paths to generate the correlation function. If an arriving ToF signal consists of the desired sequence, an autocorrelation function with a high peak results; otherwise, a low crosscorrelation function will be generated. By threshold-detecting the autocorrelation peak, the desired ToF signal will be detected. To multiplex the sequences from all the encoders, an 1 × 17 optical combiner is used. In addition, programmable delay-lines with different amounts of time delays are used to simulate the asynchronous nature of the sensors because different sensors should be found at different locations. It is important to point out that the CHPCs are designed to function normally and the ideal correlation properties can always be preserved without systemwise (time) synchronization. Adjustable optical attenuators are used at the outputs of the encoders to emulate the near-far problem. A reflective filter is used to emulate the reflections of the ToF signals by the target. The hard-limited decoder has an address signature equivalent to x 3 = (0, 3, 6), meaning that an autocorrelation peak of w = 3 units in height (i.e., power) will be created when a coded ToF signal containing x 3 arrives at the decoder.

A. Simulation Results on Interference Robustness
The simulation results of the proposed 2-D OCDMA model with the (3 × 31, 3, 0, 1) CHPCs are shown in Fig. 6(a) and (b).  Among them, only three pulses come from the desired sequence x 3 and will add atop to give an autocorrelation peak of 3 units in height [labeled as red "3" on the vertical axis in Fig. 6(a)]. The other 45 pulses are classified as interfering pulses, which are spread over the period of N = 31 chips. The cross-correlation function consists of a flat interference level of one unit in height (labeled as red "1") and some pulses even ride atop to give two units in height (labeled as red "2") in Fig. 6(a). In summary, this example illustrates that simultaneous emissions of up to 16 sensors can potentially be supported by the proposed 2-D modulation design without any false autocorrelation peak (i.e., false detection). Fig. 6(b) show one period of the accumulated correlation function of all 17 (3 × 31, 3, 0, 1) CHPC sequences, including x 3 and x 18 . While the original autocorrelation peak from x 3 can still be found at the same chip location, the cross-correlation function from the other 16 CHPC sequences create a total of 16 × 3 = 48 interfering pulses, instead of 45 as in Fig. 6(a). These extra interfering pulses ride atop the already high cross-correlation function and create a false peak, which will result in a false detection and then ToF-measurement error. Fig. 6(c) shows one period of the accumulated correlation function of the five sequences in the 1-D (1 × 31, 3, 1, 1) OOC. The simulation uses sequence (0,3,15) as the desired sequence and sequences (0,1,7), (0,2,11), (0, 4,14), and (0,5,13) as the interferers. Because each sequence contains three pulses (of the same wavelength), a total of 15 pulses per period will arrive at the decoder of (0, 3,15). At the decoder, these 15 pulses are detected by an APD and then split by a 1 × 3 power splitter into three paths and each path contains the same 15 pulses [11], [12]. These pulses are time-delayed by the delay-lines on the three paths and recombined at a 3 × 1 power combiner to give a correlation function with a total of 45 pulses. Among them, only three pulses are come from the desired sequence (0,3,15) and will add atop to give an autocorrelation peak. The other 42 (interfering) pulses give a strong accumulated cross-correlation function with two false peaks, which will result in false detections and then ToF-measurement errors.
In this simulation example, the 1-D OOCs carry false peaks even when there are as few as five simultaneous emitting sensors. Using three wavelengths, the 2-D CHPCs can accommodate up to sixteen simultaneous emitting sensors without false detections. Hence, 2-D OCDMA can enlarge the cardinality by six times (see Section II-A) and support about four times as many simultaneous emitting sensors without false detections as 1-D OCDMA. In summary, although it is more complex and expensive to implement, 2-D OCDMA is more cost efficient overall because it can support more sensors with distinctive ToF tags and allows more simultaneous ToF measurements.

B. Simulation Results on Near-Far Elimination
To illustrate the benefits of the 2-D hard-limiting decoder, Figs. 7(a) and (b) show the simulation results for one period of the accumulated correlation function of the 17 CHPC sequences before and after turning on the hard-limiters, respectively. The near-far effect is demonstrated by reducing the pulse (or chip) power of the desired CHPC sequence x 3 to 1/2 (i.e. 3 dB attenuation) of those of the 16 interfering sequences. This represents the worst-case scenario because x 3 has the lowest power and is thus embedded in the 16 interfering sequences. Fig. 7(a) shows the simulation result without hard-limiting. The original autocorrelation peak (at around 435 ns) is now embedded in the accumulated correlation function. On the other hand, the crosscorrelation function created by the 16 interfering sequences is unaffected and thus has the same false peak (at around 490 ns) as in Fig. 6(b). The hard-limiters have two functions: 1) eliminating the near-far effect and 2) reducing localization of interfering pulses. The original height of the autocorrelation peak (at around 435 ns) is recovered in Fig. 7(b) because the saturated gain of the hard-limiters restores the three pulses of x 3 to full power when they are turned on. The false peak (at around 490 ns) in Fig. 7(a) is caused by the localization of some of the pulses from the interfering sequences and these pulses overlap on top of each other. When the hard-limiters are turned on, the (high) power of these overlapping pulses gets clipped and the false peak is eliminated, as also shown in Fig. 7(b).
Similarly, Fig. 8 shows the simulation results for one period of the accumulated correlation function of the same 17 CHPC sequences, but now the near-far effect is further worsened by reducing the pulse power of x 3 to 1/4 (i.e. 6 dB attenuation) of those of the 16 interfering sequences. Fig. 8(a) shows the simulation result without hard-limiting. The original autocorrelation peak is now imbedded even more than that in Fig. 7(a). When the hard-limiters are turned on, the original autocorrelation peak is restored and the false peak is eliminated, too, as shown in Fig. 8(b).
In summary, although there exist the near-far problem and strong interference (i.e., false peaks), the original ToF signal carried by the desired CHPC sequence can still be recovered in the 2-D hard-limiting decoder. These benefits can translate into performance improvement, as shown in Section IV.

IV. PERFORMANCE ANALYTICAL MODELS
The applications of OCDMA in telecommunications traditionally assume on-off-keying (OOK) data-bit transmissions, in which data bits of "1" are encoded with 1-D or 2-D code sequences but "0" are not conveyed. Without considering the near-far effect, the error probabilities of a user in the conventional OOK OCDMA modulation using (L × N, w, λ a , 1) optical codes without and with hard-limiting were formulated as [11], [12] respectively, where K is the number of simultaneous users (including the desired one). While 1-D codes carry λ a = 1 and L = 1, 2-D codes usually have λ a = 0 and L > 1. Because λ c = 1 is commonly used, h j denotes the probability of getting j ∈ {0, 1} hits in the cross-correlation function. They are related by h 0 = 1 − h 1 and h 1 = w 2 /(2LN ) [11], [12]. The factor 1/2 in (6), (7), and h 1 are due to no sequence transmission for data bits of "0."

A. Analysis of 2-D OCDMA ToF LiDAR Model
Different from OOK in telecommunications, the ToF measurements require continuous emission of sequences from active sensors. Then, the factor 1/2 is removed. The error probabilities of a sensor in the proposed 2-D OCDMA modulation model using (L × N, w, 0, 1) optical codes without and with hardlimiting can be formulated as respectively, where the hit probabilities are given by q 0 = 1 − q 1 and q 1 = w 2 /(LN ), and K is the number of emitting sensors (including the desired one). These equations can also be applied to the 1-D OCDMA model by setting L = 1. Fig. 9 compares the error probabilities, P e of (8) and P e,hard of (9), of a sensor in the In general, the performance (i.e., error probability) gets worsened as K increases because of stronger interference. The performance improves as code weight w increases because a larger w gives a higher autocorrelation peak. The performance also improves as code length N increases because the w pulses in each sequence are spread out more and thus reduces the hit probabilities. Similarly, the number of simultaneous emitting sensors K increases with the number of wavelengths L because the hit probabilities, q 0 and q 1 , in (8) and (9) are inversely proportional to L. This, in turn, lowers the P e curves (i.e., better error probability) in Fig. 9 when L = w is increased from 3 to 4. In other words, for the same P e value, more simultaneous emitting sensors will be supported when L increases. The performance of the 1-D OOCs (i.e., red curves) is always worse than that of the 2-D CHPCs (i.e., black curves) because the use of multiple wavelengths enables the latter to create less interfering pulses and thus a lower cross-correlation function. As a result, the 2-D CHPCs have superior interference robustness to the 1-D OOCs and can always support more simultaneous sensors and better performance. The solid curves (with hard-limiting) always have lower error probabilities than the dashed curves (without hard-limiting) because the hard-limiters in the decoder can lower the interference caused by pulse localization, as demonstrated in Section III-A. The "*" and " " symbols show the computer simulation results, which closely match the analytical curves, thus validating the theoretical model of (8) and (9).
The computer simulation is based on the so-called Monte-Carlo method. For a given combination of w and N , the simulation iteration begins with randomly assigning a sequence from the code set to the decoder as its address signature. The time frame is divided into N chips per period. For a given K emitting sensors, K − 1 interfering sequences are randomly selected from the code set. All K sequences can begin their emissions at any one of the N chips to simulate the (time) asynchronism among the sensors. Since there are multiple interfering sequences, each wavelength may see multiple pulses falling in the same chip location. In the hard-limiting decoder, the same-wavelength pulses at the same chip location are only counted as one pulse. Correlation is performed by comparing the wavelengths in all w chip locations of the address sequence of the decoder with the wavelengths and locations of the hard-limited pulses. If there exists a pulse with the wavelength and chip location matching one of the pulses of the address sequence, "one hit" is added to the count. Afterward, the numbers of hits at the w chip locations of the address sequence are summed up. If the total number of hits at the expected chip location of the autocorrelation peak is as high w, this will contribute a detection error and then the ToF signal will be recovered wrongly. Finally, the error probability is calculated as the ratio of the number of detection errors to the total number of emitted sequences (i.e., ToF signals) of the desired sensor. The above simulation iteration is repeated 100 times the reciprocal of the targeting error probability in order to provide sufficient randomness in the selection of the K sequences and asynchronism among their emission times.

B. Analysis of 2-D OCDMA ToF Model With Near-Far Effect
As studied in Section II-B, the ToF measurements require continuous emission of sequences under the same-AEL pixel restriction, which is similar to the same-bit-power constraint in the OCDMA analytical model [24]. Assuming the worst-case near-far scenario similar to Section III-B, the arrival sequences of the desired sensor always have the lowest pulse (or chip) power than all other sensors (i.e., interferers). Then, the twochip-power OCDMA analytical model [24] can be modified for the proposed 2-D OCDMA ToF model under the near-far effect. In the new model, the original chip power of all emitting sequences is denoted as P org = P bit /w, while the near-far effect will create lower chip power P low in the w pulses of the arrival sequences at the decoder of the desired sensor, where the bit power P bit = AEL pixel and P org > P low .
Assume that the desired sequence and other K low − 1 interfering sequences arrive at the decoder with lower chip power P low but all other K org sensors arrive with the original chip power P org . Hence, the hard-limiting error probability of the desired sensor using (L × N, w, 0, 1) optical codes in the 2-D OCDMA ToF model under the near-far effect can be formulated by modifying [24, eq. (2)] as where q 1 = w 2 /(LN ) and q 0 = 1 − q 1 . Eq (10) can also be applied to 1-D optical codes by setting L = 1 and λ a = 1.
Because the receiver sees the desired sequence arriving with lower chip power, the decision threshold of the hard-limiters is then set to P low in order to minimize the interference. The hard-limiting decoder equalizes the chip power of all received signals to the same level of P low so that all pulses will contribute equally towards the cross-correlation function. In other words, the interfering sequences of original chip power P org will be cilipped to the same level as the low-chip-power sequences. The desired sensor sees the same level of interference from all sequences, no matter how much P low is smaller than P org . As a result, when the desired sequence is among those K low , (10) shows that the same performance P e,hard low results no matter how much power attenuation is caused by the near-far problem. By the same reason, the performance is also a function of the total number of interfering sequences, meaning that the same P e,hard low is found as long as the combinations of K org and K low carry the same K low + K org − 1 value.
On the other hand, if the desired sequence does not encounter any near-far effect, then it will carry the original chip power and belong to one of the K org sequences. The decision threshold of the hard-limiters should be set to P org in order to optimize the performance. Assume that there are K low interfering sequences with lower chip power, for example, P low = P org /2 (i.e., −3 dB attenuation) or P org /4 (i.e., −6 dB attenuation). Hence, the hard-limiting error probability of the desired sensor using (L × N, w, λ a , 1) where q 2 = wt/(NL) and q 2 = w(w − t)/(NL).
Each hit generated by the interfering sequences of P low can contribute only P org /P low of one complete hit onto a pulse of the desired sequence of P org . In other words, there must exist at least c = P org /P low interfering lower-chip-power sequences in order to generate one complete hit after hard-limiting, where · is the ceiling function. This is because the decision threshold of the hard-limiter at the original-chip-power desired sensor is now set to P org . The hard-limiters will block those received pulses of P low that cannot reach the power level of P org . Hence, the contribution of the K low low-chip-power sequences toward the cross-correlation function will not be the same as that of the K org original-chip-power sequences after hard-limiting. As a result, if the desired sequence does not encounter the near-far problem, the performance P e,hard org in (11) of the desired sensor depends on K org and K low separately and the power ratio c = P org /P low . Note that (11) will converge to (9) when K low approaches to zero for a given number of interfering sequences K low + K org − 1. Fig. 10 compares the hard-limiting error probabilities, P e,hard low of (10) (i.e., black curves) and P e,hard org (11) (i.e., green and red curves), of the desired sensor using the 2-D (w × N, w, 0, 1) CHPCs as a function of the number of emitting low-chip-power sensors K low without and with the near-far effect of −3 and −6 dB power attenuation (i.e., c = 2 and 4, respectively) for some combinations of w = {3, 4} and N = {31, 37, 61}. The total number of emitting sensors (i.e., sequences) is fixed to K low + K org = 17. The " " symbols show the computer simulation results, which closely match the analytical curves, thus validating the theoretical model of (10) and (11).
The computer simulation procedure follows that in Fig. 9 but now includes the near-far effect and the total number of emitting sequences is fixed to K low + K org = 17. For a given K low value, the low-chip-power sequences are assigned with P low = P org /2 or P org /4, depending on which near-far power attenuation case is simulated. In the −3 dB (resp. −6 dB) case, if there exists a pulse with the wavelength and location matching with one of the chip locations of the address sequence, one 1-hit is added to the cross-correlation function of K org and one 1/2-hit (resp. 1/4hit) is added to the cross-correlation function of K low after hardlimiting. Afterward, the numbers of hits at the w chip locations of the address sequence are summed up. If the total number of hits at the expected chip location of the autocorrelation peak is as high as w, this will contribute a detection error and then the ToF signal will be recovered wrongly. Finally, the error probability is calculated as the ratio of the number of detection errors to the total number of emitted sequences (i.e., ToF signals) of the desired sensor. The above simulation iteration is repeated 10 6 times in order to provide sufficient randomness in the selections of K low and K org sequences and asynchronism among their emission times.
In Fig. 10, the black curves show the performance P e,hard low of the desired sensor when its sequence carries lower chip power P low caused by the near-far effect. In general, the error probability improves as w (resp. N ) increases because heavier code weight (resp. longer code length) reduces the hit probabilities and also a larger w increases the height of the autocorrelation peak. From (10), P e,hard low depends on K low + K org − 1. Thus, different K 1 values will give the same P e,hard low if the total number of emitting sequences is kept the same (i.e., K low + K org = 17 in this example). As explained in the derivation of (10) and due to the benefits of the hard-limiting decoder, the desired sensor sees the same level of interference from all sequences, no matter how much P low is smaller than P org . As a result, the black curves are always flat and independent of K low or the power ratio c = P org /P low when the total number of emitting sequences is kept the same. The computer simulation includes the variations of P low at −3 and −6 dB power attenuation and confirms the same P e,hard low results. The simulation results (i.e., black " ") match closely the theoretical (black) curves, thus validating the analytical model of (10).
On the other hand, if the desired sensor does not encounter any near-far problem and thus belong to one of the K org sequences with original chip power P org , its performance is given by P e,hard org in (11). The green (resp. red) curves show P e,hard org of the desired sensor when the K low interfering sequences encounter near-far power attenuation of −3 dB (resp. −6 dB). In general, the error probability improves as w (resp. N ) increases due to the same reasons in Fig. 9. The performance gets worsened as K low increases because of stronger interference. The red curves, representing −6 dB attenuation in the K low low-chip-power sequences, have less interference to the desired sensor than the green curves. Hence, the desired sensor has the best performance as P low decreases. Finally, the red and green curves overlap with the black curves when K low = 0 because this corresponds to the extreme case that all sequences carry the original chip power (i.e., maximum interference) when there is no near-power problem. The computer simulation results (i.e., green and red " ") match their respective theoretical curves, thus validating the analytical model of (11).

V. CONCLUSION
In this proof-of-principle paper, the application of 2-D OCDMA modulation using wavelength-time sequences to the long-range automative ToF LiDAR sensors was studied and simulated. The regulations and physical constraints governing the design parameters were presented. Using the 2-D CHPCs, the modulation model and 2-D hard-limiting decoder were designed and validated with OptiSystem TM simulations. The superiority of the 2-D OCDMA modulation on interference robustness and elimination of the near-far (power) effect were demonstrated. The analytical and simulation studies showed that the proposed 2-D OCDMA modulation design supported more sensors with distinctive ToF tags, more simultaneous ToF measurements, better interference robustness, and better performance than the 1-D counterparts. Based on the design parameters, the 2-D CHPCs had six times as many distinct sequences (for sensor identification) as 1-D OOCs. The simulation results showed that the 2-D OCDMA design could support four times as many simultaneous emitting sensors without false detections as the 1-D one. As a result, 2-D OCDMA modulation was more cost efficient, even though it was more complex.