Introduction

Ammonia (NH3) gas sensing plays a vital role in various industrial, agricultural, and environmental applications, necessitating the development of highly sensitive and reliable gas sensors.1,2,3 Among the innovative solutions, thin films based on cadmium oxide (CdO), zinc oxide (ZnO), and their composite, cadmium zinc oxide (CdZnO), have emerged as promising candidates. These advanced materials offer distinct advantages, such as high sensitivity, low power consumption, cost-effectiveness, and compatibility with microfabrication techniques.4,5,6,7 CdO thin films have garnered significant attention due to their unique physicochemical properties, including a wide band gap, high electron mobility, and excellent gas sensing characteristics.8 The deposition methods for CdO films include techniques such as chemical vapor deposition (CVD), sputtering, and atomic layer deposition (ALD).9,10 By carefully tuning the deposition parameters and optimizing the film morphology, CdO thin films demonstrate exceptional ammonia sensing performance with high sensitivity, fast response, and excellent selectivity.11,12 Similarly, ZnO thin films have exhibited remarkable potential as ammonia gas sensors due to their excellent gas sensing properties, large surface-to-volume ratio, and high electron mobility.13,14,15 Different deposition techniques such as pulsed laser deposition (PLD), nebulizer spray pyrolysis (NSP), and sol–gel have been employed to fabricate ZnO thin films.16,17,18 Through proper optimization of film thickness and morphology, ZnO-based sensors can achieve enhanced sensitivity, selectivity, and stability. To further enhance the gas sensing capabilities, researchers have explored composite thin films combining CdO and ZnO, known as CdZnO. The synergistic effects of the two materials have shown improved performance in terms of sensitivity, response time, and selectivity towards ammonia gas. These composite films can be deposited using various methods, including co-sputtering, electrodeposition, and chemical bath deposition.17,18,19,20 By controlling the composition and interface properties, CdZnO thin films have demonstrated superior gas sensing properties, making them highly suitable for ammonia detection.

In conclusion, CdO, ZnO, and CdZnO thin films have emerged as innovative solutions for ammonia gas sensing applications. These materials exhibit exceptional sensitivity, selectivity, and response time, making them ideal candidates for next-generation gas sensors. Continued research and development in optimizing their deposition methods, film morphology, and composite structures will pave the way for even more advanced gas sensing technologies.21,22,23,24,25

In this paper, we present the utilization of the NSP method to produce CdO, ZnO, and CdZnO thin films for the fabrication of a highly sensitive ammonia gas sensor.

Experimental Details

The deposition of CdO, ZnO, and CdZnO thin films was carried out using the nebulizer spray pyrolysis method. For the deposition process, analytical reagent grade chemicals (98.9% purity, obtained from Sigma-Aldrich) including cadmium acetate, zinc acetate, methanol, ethylenediaminetetraacetic acid salt (EDTA), and deionized water were used.

To prepare the CdO thin film, a solution of 0.1 M cadmium acetate dissolved in a mixture of methanol and deionized water (1:1 ratio) was prepared. The solution was stirred for 10 min using a magnetic stirrer, and then 0.02 M of EDTA was added. The pH of the solution was adjusted to 9. Similarly, for the ZnO thin film, a solution was prepared by dissolving 0.1 M of zinc acetate in 25 mL of deionized water mixed with methanol in a ratio of 1:3. The solution was stirred for 10 min using a magnetic stirrer until the pH reached 9. Similarly, to obtain the CdZnO thin film, a solution containing 0.1 M cadmium acetate and 0.1 M zinc acetate dissolved in 25 mL of deionized water was mixed with methanol in a ratio of 1:1. The solution was stirred for 10 min using a magnetic stirrer. The prepared solutions were then sprayed onto glass substrates, which were preheated to 400°C for 50 min. The spraying process was carried out at a fixed temperature of 400°C. The nebulizer spray pyrolysis experimental setup and the details of the procedure for depositing metal oxide thin films have been described elsewhere.26 The spray nozzle was at a distance of 5 cm from the substrate during deposition and the solution flow rate was held constant at 0.5 mL/min. Air was used as the carrier gas maintained at a pressure of 30 psi. When aerosol droplets come close to the substrates, a pyrolytic decomposition process occurs and high-quality CdO, ZnO, and CdZnO films are produced. The thickness of CdO, ZnO, and CdZnO films was measured using a stylus profilometer. The deposition of CdO, ZnO, and CdZnO films was controlled by two independent variables: (i) film thickness and uniformity, and (ii) surface morphology.27 The thickness of the sprayed CdO, ZnO, and CdZnO films was found to be 528 nm, 375 nm, and 452 nm deposited at substrate temperature 400°C.

The possible chemical reactions that can occur on a film heated to a substrate temperature of 400°C to produce CdO, ZnO, and CdZnO involve the decomposition of their respective precursor compounds. Here are the possible reactions:

Cadmium Oxide (CdO) Formation

Cadmium acetate dihydrate (Cd(CH3COO)2·2H2O) decomposes to form cadmium oxide (CdO), water (H2O), and acetic acid (CH3COOH):

$$ {\text{Cd}}\left( {{\text{CH}}_{{3}} {\text{COO}}} \right)_{{2}} \cdot{\text{2H}}_{{2}} {\text{O}} \to {\text{CdO}} + {\text{2CH}}_{{3}} {\text{COOH}} + {\text{2H}}_{{2}} {\text{O}} $$
(1)

Zinc Oxide (ZnO) Formation

Zinc acetate dihydrate (Zn(CH3COO)2·2H2O) decomposes to form zinc oxide (ZnO), water (H2O), and acetic acid (CH3COOH):

$$ {\text{Zn}}\left( {{\text{CH}}_{{3}} {\text{COO}}} \right)_{{2}} \cdot{\text{2H}}_{{2}} {\text{O}} \to {\text{ZnO}} + {\text{2CH}}_{{3}} {\text{COOH}} + {\text{2H}}_{{2}} {\text{O}} $$
(2)

Cadmium Zinc Oxide (CdZnO) Formation

When both cadmium acetate dihydrate (Cd(CH3COO)2·2H2O) and zinc acetate dihydrate (Zn(CH3COO)2·2H2O) are heated together, a solid-state double displacement reaction can occur, resulting in the formation of cadmium zinc oxide (CdZnO), water (H2O), and acetic acid (CH3COOH):

$$ {\text{Cd}}\left( {{\text{CH}}_{{3}} {\text{COO}}} \right)_{{2}} \cdot{\text{2H}}_{{2}} {\text{O}} + {\text{Zn}}\left( {{\text{CH}}_{{3}} {\text{COO}}} \right)_{{2}} \cdot{\text{2H}}_{{2}} {\text{O}} \to {\text{CdZnO}} + {\text{4CH}}_{{3}} {\text{COOH}} + {\text{4H}}_{{2}} {\text{O}} $$
(3)

These reactions illustrate the decomposition of the precursor compounds and the formation of the desired metal oxide compounds, along with the release of water and acetic acid as byproducts. It is important to note that the specific reaction conditions, such as temperature and reaction atmosphere, may influence the reaction pathways and final product compositions.

Fabrication of CdO, ZnO, and CdZnO Device

Figure 1 depicts the schematic diagram and photograph of the sensor device developed for this study, which comprises CdO, ZnO, and CdZnO thin layers deposited on ITO-coated glass substrates using the NSP technique. The inclusion of the ITO layer ensures that any changes in resistance detected between the contacts originate solely from resistance variations in the film under investigation. Electrodes made of Au were sputtered onto the surface through a shadow mask, with a distance of approximately 2 mm between them and a thickness of around 225 nm. Prior to the deposition process, the surface underwent a 15-min cleaning in acetone followed by a 15-min ultrasonic treatment to eliminate any organic contaminants.

Fig. 1
figure 1

(I) Schematic diagram of (a) CdO device, (b) ZnO device, and (c) CdZnO sensor device. (II) Photographs of the (d) CdO device, (e) ZnO device, and (f) CdZnO sensor device.

Impedance measurements for assessing the ammonia gas sensing properties were conducted using a Solartron 1360 Frequency Response Analyzer coupled with a Solartron 1296 Dielectric Interface.

Results and Discussion

XRD Analysis

Figure 2 illustrates the x-ray diffraction (XRD) patterns of thin films consisting of CdO, ZnO, and CdZnO, which were deposited using the NSP technique at a substrate temperature of 400°C. Distinct peaks corresponding to CdO were identified based on JCPDS card no. 05-0640, with peak positions at 33.0, 38.3, 55.3, 66.0, and 69.3, corresponding to (hkl) values of (111), (200), (220), (311), and (222), respectively. Likewise, the peaks corresponding to ZnO were determined using JCPDS card no. 36-1451, with peak positions at 31.7, 34.3, 36.2, 47.5, 62.8, 67.8, and 72.5, and (hkl) values of (100), (102), (220), (101), (102), (103), (112), and (004), respectively. The incorporation of cadmium oxide (CdO) into zinc oxide (ZnO) thin films to create cadmium zinc oxide (CdZnO) composites opens up intriguing possibilities for customizing the properties of the resulting films.

Fig. 2
figure 2

XRD pattern of nebulizer spray deposited (a) CdO thin films, (b) ZnO thin films, and (c) CdZnO thin films.

The determination of the crystallite size for the sample was accomplished by applying Scherrer's formula.

$$ D = \frac{0.9\lambda }{{\beta \cos \theta }} $$
(4)

In the equations mentioned earlier, β represents the full width at half maximum of the diffraction line, θ denotes the diffraction angle, and λ represents the wavelength of the X-radiation. When CdO is introduced as a dopant in ZnO thin films, it influences the growth kinetics and crystallization behavior during the film deposition process. The presence of CdO alters the atomic arrangement and lattice structure, leading to changes in the crystallite size. The incorporation of CdO ions into the ZnO lattice can affect the grain boundaries, resulting in modifications of the crystallite size and microstructure. XRD studies have demonstrated that the addition of CdO can lead to an increase in the average crystallite size of the CdZnO films compared to pure ZnO films. The increase in crystallite size with CdO addition can be attributed to various factors. The presence of CdO alters the surface energy and growth kinetics of the films, affecting the nucleation and growth processes. CdO dopants may also influence the diffusion and migration of atoms during film growth, affecting the grain size and morphology. Additionally, the incorporation of CdO can induce strain and lattice distortions, leading to changes in the crystal growth mode and subsequent increase in crystallite size. The enhanced crystallite size in CdZnO thin films has significant implications for various applications. In gas sensing, larger crystallites offer improved sensitivity and selectivity by providing a larger active surface area for gas interactions.28,29,30,31,32

SEM Analysis

Surface morphology analysis of CdO, ZnO, and CdZnO thin films was conducted using a state-of-the-art high-resolution scanning electron microscope (HRSEM), as depicted in Fig. 3. The results reveal intriguing features in Fig. 3a, with the presence of minute porous structures like nanofibers and distinct grain boundaries, exhibiting an average grain size of 36 nm. Additionally, certain regions of the porous surface display interconnected spherical structures. Figure 3b showcases the presence of nanostructures, presenting a hexagonal grain pattern with an approximate size of 50 nm, covering the entire substrate surface. Moreover, Fig. 3c illustrates a mixture of hexagonal and spherical structures, displaying an average grain size of 89 nm. In conclusion, surface morphology plays a vital role in influencing gas sensor applications.33,34,35,36,37,38 Figure 3a illustrates the results of quantitative analysis for CdO films deposited on glass substrates at 400°C. Elemental analysis focused solely on cadmium (Cd) and oxygen (O), revealing an approximate atomic ratio of 37.59:38.18, which approaches stoichiometry, showing a nearly 1:1 ratio for the deposited CdO film at 400°C. In Fig. 3b, the presence of both zinc (Zn) and oxygen (O) in the deposited ZnO films at 400°C is confirmed. The atomic percentage of ZnO nanoparticles is close to stoichiometry, with an average atomic ratio of 46.05:47.45 for Zn:O. Figure 3c illustrates the average atomic composition of Cd:Zn:O in the Cd0.5Zn0.5O film, which is 15.70:15.59:39.53 for x = 0.5. Additionally, the presence of a silicon (Si) peak in the spectra can be attributed to the glass substrate component.

Fig. 3
figure 3

(I) SEM images and EDAX spectrum of (a) CdO thin films, (b) ZnO thin films, and (c) CdZnO thin films. (II) EDAX spectrum of (a) CdO thin films, (b) ZnO thin films, and (c) CdZnO thin films.

Optical Properties

The optical properties of CdO, ZnO, and CdZnO films were investigated using transmittance spectra obtained from an ultraviolet–visible–near-infrared (UV–Vis–NIR) spectrophotometer. Figure 4 shows the transmittance spectra of CdO, ZnO, and CdZnO thin films on a glass substrate at 400°C. It is noteworthy that the transparency in the visible spectrum falls within the range of 90% to 99%. The optical band gap value can be determined by analyzing the fundamental absorption, which corresponds to the excitation of electrons from the valence band to the conduction band, as described by Equation39,40,41

$$ \alpha h\nu = A(h\nu - Eg)^{\frac{1}{2}} $$
(5)

where A is a constant and Eg represents the material's band gap. The exponent n varies depending on the type of transition, taking values of 1/2, 2, 3/2, and 3 for allowed direct, allowed indirect, forbidden direct, and forbidden indirect transitions, respectively. Assuming n = 1/2, we determined the direct optical band gap by extrapolating the linear portion of the (ahv)(1/n) versus plot (see Fig. 4) towards the -axis. The intersection point with the -axis provides the measurement of the direct band gap. The direct band gaps of Pure CdO, CdZnO, and ZnO were measured to be 2.3 eV, 3.03 eV, and 3.18 eV, respectively. The CdO film band gap falls within the range of transparent conducting oxides (TCOs). It can be used as a transparent electrode material in devices like solar cells, thin-film transistors, and light-emitting diodes (LEDs). The CdZnO is a ternary compound that combines the properties of CdO and ZnO. The band gap of CdZnO can be tuned by adjusting the composition ratio of CdO and ZnO. Its intermediate band gap makes it suitable for applications like solar cells, photodetectors, and transparent thin-film transistors. ZnO is a wide-band-gap semiconductor with excellent optical and electrical properties. It finds applications in ultraviolet (UV) LEDs, laser diodes, gas sensors, transparent electrodes, and various optoelectronic devices.42

Fig. 4
figure 4

Transmittance spectrum of CdO, ZnO, and CdZnO thin films (inset: band gap of CdO, ZnO and CdZnO thin films).

Electrical Properties

Figure 5 displays the current–voltage (I–V) characteristics of ZnO, CdO, and Cd ZnO thin films both under illumination and in the absence of light. The films exhibit a nearly linear response to applied voltage, indicating their semiconducting properties. Conductivity measurements conducted under illumination demonstrate an enhancement in the thin film conductivity, which correlates with the increased mixed CdZnO lattice composition. The electrical conductivity for CdO, ZnO, and CdZnO thin films was observed to vary within the range of 2.56 × 10−7–to 7.38 × 10−7 S/cm.

Fig. 5
figure 5

I–V Characteristics of spray-coated CdO, ZnO, and CdZnO thin films.

Gas Sensing Properties of CdO Thin Films

The sensing mechanism was investigated using alternating current (AC) impedance spectroscopy, which allowed for the analysis of potential contributors.43 Typically, the conduction process (R) and polarization behavior (C) play a significant role in the sensing mechanism. The microstructures of the device consist of grains, grain boundaries, and the CdO contact. In the Nyquist plot, the primary factors influencing high, intermediate, and low frequencies are the grains (bulk), grain boundaries (Rgb, Cgb), and the metal–semiconductor contact (Rc, Cc). To achieve a single semicircle representing these components, the associated time constant τ must be identical. The formula for calculating the concentration of ammonia (NH3) in parts per million (ppm) is as follows:

$$ {\text{Concentration }}\left( {{\text{ppm}}} \right) = \left( {{\text{Mass of NH}}_{{3}} {\text{in grams }}/{\text{ Volume of solution in liters}}} \right) \times {1},000,000 $$

This formula is used to express the concentration of ammonia in a solution in parts per million, where Mass of NH3 in grams is the mass of ammonia present in the solution. The volume of solution in liters is the total volume of the solution in which the ammonia is dissolved.

The sensing mechanism can be explained from the following perspectives: Initially, oxygen molecules from the surrounding atmosphere were adsorbed onto the CdO surface. Electrons were extracted from the conduction band of the CdO material and converted into single or double oxygen ions, which became ionosorbed on the surface. This led to a decrease in electron concentration and, consequently, an increase in resistance. This mechanism can be described as follows6:

$$ {\text{O}}_{2} (g) + e^{ - } \to {\text{O}}_{2}^{ - } ({\text{ads}}) $$
(6)

When ammonia or other reducing gases react with ionosorbed oxygen, the captured electrons are released back into the conduction band. This leads to an increase in electron concentration and a decrease in resistance. This phenomenon can be explained by the following reaction.7

$$ {\text{H}}_{2} {\text{O}}_{{{\text{ads}}}}^{ - } \to {\text{H}}_{2} {\text{O}} + e^{ - } $$
(7)

When a reducing gas like ammonia is introduced into the chamber, it physically interacts with chemisorbed oxygen species, causing the release of electrons into the conduction band. Consequently, there is an increase in electrical current. For instance, the following equation serves as an example.8

$$ 4{\text{NH}}_{3} + 3{\text{O}}_{2}^{{{\text{ads}}}} \to 2{\text{N}}_{2} + 6{\text{H}}_{2} {\text{O}} + 3e^{ - } $$
(8)

The CdO films have the ability to release more electrons into the conduction band of CdO. This enhances the interaction between electrons and chemisorbed oxygen species, which positively contributes to the electrical response to ammonia gas.44 The migration of oxygen atoms occurs on the surface of the grains, leading to the capture of electrons from the surface layer and the formation of an acceptor surface at the grain boundary. The presence of catalyst atoms plays a crucial role in facilitating the reaction between reducing gases and the adsorbed oxygen.

Figure 6 illustrates the impact of different concentrations of ammonia gas on the CdO sensor device. It was observed that as the gas concentration gradually increased from 50 ppm to 150 ppm, the diameter of the arc decreased, while it slightly increased for a gas concentration of 200 ppm. The maximum values of ZII were smaller than half of the ZI maximum values, indicating the contribution of constant phase elements (CPEs) in the equivalent circuit. To accurately represent the capacitance, a CPE was used instead of a simple capacitor. CPEs are commonly employed to describe the behavior of polycrystalline materials with inhomogeneous microstructures, such as grain boundaries that exhibit different distributions of relaxation time. The impedance of a CPE is well described in.45

Fig. 6
figure 6

Nyquist plot of ZnO device exposed to air and different ammonia concentrations from 50 ppm to 200 ppm at room temperature.

When CdO films are exposed to air, oxygen molecules can capture free electrons from the CdO films, leading to the formation of a surface depletion layer. This depletion layer reduces the conducting width of the CdO films and increases the potential barrier at the contacts between the CdO films. It controls the density and mobility of electrons within the CdO films. However, when CdO films are exposed to ammonia, the adsorbed oxygen releases the previously trapped electrons back into the conduction band. The depletion width decreases due to the decrease in surface oxygen, resulting in an increase in the electron concentration within the CdO films and a decrease in the barrier potential height at the grain–grain contacts. Consequently, the impedance of the CdO films decreases with increasing ammonia concentration. Therefore, it can be concluded that the ammonia concentration significantly affects the grain boundary resistance, thereby facilitating its detection. However, the variation in capacitance values was not significant, indicating that the ammonia gas mainly influences the surface charge region of the grain boundaries in CdO films.

The estimated peak frequencies, corresponding to the relaxation frequencies of the impedance, were plotted by displaying the curve of -ZII versus logarithmic frequency, as shown in Fig. 7. It was observed that the imaginary part of the impedance decreased as the gas concentration increased. The decrease in the imaginary part of impedance was attributed to changes in carrier concentrations. As the concentration of ammonia increased, the barrier height decreased, allowing for a higher flow of carriers. This resulted in a decrease in impedance. Additionally, the peak frequency was observed to shift towards higher frequencies with increasing ammonia concentration. This shift towards higher frequencies indicated an enhanced ease of charge carrier flow in response to the AC electric field. The broadening of the peak with increasing ammonia concentration was attributed to variations in the distribution of relaxation time. The relaxation process may be influenced by the presence of electrons and/or immobile species. The sensitivity of the fabricated CdO sensor was evaluated by considering the frequency and ammonia concentration, using the equation provided below:

$$ S = \frac{{Z_{a} }}{{Z_{g} }} $$
(9)
Fig. 7
figure 7

Imaginary parts of impedance for ZnO sensor device under different ammonia concentrations at room temperature.

Figure 8 illustrates the effect of frequency at different parts per million (ppm) values of ammonia on CdO films at room temperature. Notably, the sensitivity of our device at room temperature surpassed the values reported in the literature at 400°C. A significant change in sensitivity was observed within the frequency range of 1 Hz to 100 kHz. In this range, the conductivity process was primarily governed by the space charge region. A sharp decline in sensitivity occurred with increasing frequency, while the gain values showed little variation at frequencies higher than 100 kHz, where the conductivity was predominantly influenced by the surface charge of the grains. This indicated that an optimal selection of frequency could achieve maximum gain in sensitivity. As a result, the CdO film's surface allows for ammonia sensing at relatively low operating temperatures. It is observed that the In Fig. 8, it is observed that the maximum sensitivities increase from 1.3 to 1.8 with an increase in ammonia concentration up to 150 ppm. However, beyond an ammonia concentration of 200 ppm, the sensitivity decreases.

Fig. 8
figure 8

Gain curve for CdO sensor device as a function of different ammonia concentrations at room temperature.

Gas Sensing Properties of ZnO Thin Films

Figure 9 illustrates the Nyquist plot of a ZnO device when exposed to air and varying concentrations of ammonia ranging from 50 ppm to 200 ppm at room temperature. The figure demonstrates a decrease in the diameter of the semicircles as the concentration of ammonia gas increases from 50 ppm to 200 ppm. Moreover, the imaginary impedance values are smaller than the real values, indicating the contribution of the constant phase element (CPE) in the equivalent circuit. By replacing the capacitance with a CPE, the best-fitted values are obtained, and these results are depicted by the solid line, representing the optimal fit. The incorporation of a CPE element typically characterizes the behavior of the microstructure, such as the grain boundary, leading to different distributions of respective relaxation time. The estimation of peak frequencies associated with the relaxation process of the impedance was conducted by plotting the imaginary part of the impedance (-ZII) against the logarithm of the frequency, as depicted in Fig. 9. The peaks observed in the imaginary part of the impedance, corresponding to the tops of the relaxation semicircles, are consistent with the findings in Fig. 10. It was noted that the peak frequency shifted towards higher frequencies, while the peak height decreased with increasing exposure time and ammonia concentrations. The broadening of the peaks indicates the dependence of the relaxation process on the gas concentration.45

Fig. 9
figure 9

Nyquist plot of ZnO device exposed to air and different ammonia concentrations from ppm 50 to 200 ppm at room temperature.

Fig. 10
figure 10

Imaginary part of impedance for ZnO device exposed to various ammonia concentrations.

Figure 11 presents the sensitivity of the ZnO device for different concentrations of ammonia ranging from 50 ppm to 200 ppm at room temperature. Within the frequency range of 100 Hz to 1 MHz, where space charge transfer governs the conductivity process, the sensitivity of the sensor remains constant. However, as the frequency increases, the sensitivity experiences a sharp decrease and becomes nearly constant at frequencies higher than 100 kHz, indicating that the conductivity is primarily influenced by the surface charge transfer of the grains. These findings suggest that the sensor can be optimized to achieve maximum sensitivity by selecting an appropriate operating frequency range. In Fig. 11, it is evident that the maximum sensitivities increase from 1.05 to 1.15 as the ammonia concentration rises from 50 ppm to 200 ppm.

Fig. 11
figure 11

Gain curve for ZnO sensor device as a function of different ammonia concentrations at room temperature.

Gas Sensing Properties of CdZnO Device

The complex impedance spectrum of CdZnO films is illustrated in Fig. 12, displaying the Nyquist plot containing real (Z′) and imaginary (Z″) components. These plots provide insights into the resistance associated with various factors such as bulk grain, grain boundaries, relaxation times, and electrode interfaces in the complex impedance plane. The semicircular shape observed in the impedance spectrum represents the interfacial charge transfer resistance related to the carrier transfer interdigitated electrode (IDE). The sensitivity of the CdZnO device to ammonia gas was calculated using the equations mentioned above. Figure 12 depicts the response of the CdZnO device to ammonia exposure ranging from 50 ppm to 200 ppm. It is noteworthy that the arc of the semicircles in Fig. 12 decreases with an increase in ammonia concentration, indicating the influence of grains and the absorption of ammonia gas.

Fig. 12
figure 12

Nyquist plot consisting of real (Z′) and imaginary (Z″) in the complex impedance spectrum of the CdZnO films for different ammonia concentrations.

Additionally, the increase in diameter with increasing concentrations can be attributed to the Fermi energy level of the CdZnO films, resulting from the transfer of electrons from Cd to Zn. Figure 13 displays the imaginary part of impedance (Z″) plotted against logarithmic frequencies for the CdZnO thin device. With an increase in concentrations from 50 to 200 ppm, the imaginary part of the overall impedance of the CdZnO films increases, and the peak frequency shifts towards lower frequencies. The increase in the imaginary part of impedance indicates a decrease in conductivity, while the shifting of the peak suggests an increase in concentrations accompanied by a decrease in relaxation time. Therefore, the overall increase in the imaginary part of impedance with increasing concentrations from 50 ppm to 200 ppm signifies the flow of charge carriers in response to the AC electric field.

Fig. 13
figure 13

The imaginary part of impedance (Z″) against the logarithmic frequencies of the CdZnO thin device for different ammonia concentrations at room temperature.

Figure 14 illustrates the response of a CdZnO sensor at room temperature to ammonia exposure ranging from 50 ppm to 200 ppm, showcasing the concentration-dependent characteristics. The sensitivity of these sensors to ammonia exhibits similarities with that of CdZnO, primarily attributed to changes in the resistance of the grain boundaries. However, the sensitivity to ammonia is influenced by both intragrain and grain boundary resistance. It is noteworthy that the gas response time increases as the concentrations rise from 50 ppm to 200 ppm. In Fig. 14, it is evident that the maximum sensitivities were found to increase from 2.2 to 4.2 as the ammonia concentration increased from 50 ppm to 200 ppm. This can be attributed to the higher concentration of ammonia molecules on the film surface, leading to a more pronounced reaction with the absorbed oxygen species. The CdZnO film demonstrates a rapid response and recovery to ammonia at room temperature, highlighting its superior sensing properties compared to other CdO and ZnO devices.

Fig. 14
figure 14

Gain curve for CdZnO sensor device as a function of different ammonia concentrations at room temperature.

Conclusions

The successful development of an ammonia sensor using CdO, ZnO, and CdZnO through the nebulizer spray pyrolysis method represents a significant achievement. These sensors have demonstrated the remarkable ability to detect ammonia at room temperature, surpassing the sensitivity reported in the literature for thin film-based sensors utilizing CdO, ZnO, and CdZnO. When exposed to varying concentrations of ammonia ranging from 50 ppm to 200 ppm at room temperature, the CdZnO device, in particular, exhibited superior sensitivity to ammonia gas compared to the other devices. These results find strong support in the Nyquist plot analysis, which clearly indicates a decrease in grain boundary resistance and barrier height as the ammonia concentration increased from 50 ppm to 200 ppm. In conclusion, these results underscore the exceptional performance of the stable ammonia gas sensor based on CdZnO at the ppm level and at room temperature.