# Battery Life Prediction for Ensuring Robust Operation of IoT Devices in Remote Metering
## 3 Remote Metering Life Prediction Method
### Data Collection and Preprocessing  
To analyze the discharge characteristics of MSD primary batteries in a real-world setting, we implemented the printed circuit board (PCB) embedded within the remote gas meter for collecting data (refer to Figure 3a). Figure 3b shows the MSD Primary battery installed in the remote gas meter. Figure 3c shows that the rear part of the board is equipped  
Figure 2: Discharge curve of the MSD primary battery. Batteries produced through electrolyte mixing exhibit a primary point at 15% of \(SOC_{Prim}\). \(DOD_{Prim}\) represents the depth of discharge at the primary point, while \(SOC_{Prim}\) denotes the state of charge at the primary point. with a PMIC for overseeing voltage and current, a Cortex-M0 microcontroller's temperature sensor to measure temperature, and an SX1276 Long Range Radio (LoRa) module for wireless data transmission. We deployed 50 remote gas meters within households (as illustrated in Figure 3d) and harnessed a power management integrated circuit (PMIC) embedded in each remote gas meter to capture the data. The collected data include timestamps, discharge capacity, temperature, voltage, and the communication count, as outlined in Table 1. We utilized temperature, voltage, and communication count as input data for the C-SDFormer model, while discharge capacity was employed as the ground truth for prediction. This approach was adopted because, in real-world scenarios, measuring discharge capacity requires expensive equipment, making it impractical for widespread applications such as smart metering. The data were recorded at 10 min intervals and subsequently transmitted to the server for storage at hourly intervals. For clarity, Table 2 presents a sample excerpt of the collected data over a one-hour period, showing representative values for timestamps, voltage, temperature, and communication count. This sample illustrates the typical range of input values observed during operation and highlights how communication events affect voltage changes. Additionally, Table 3 presents summary statistics (mean, standard deviation (Std), minimum (Min), and maximum (Max)) for the measured input variables, providing an overview of the range of operating conditions observed in our dataset. These statistics illustrate the diversity in temperature, voltage, and communication count values, which helps the model capture variations in operating conditions and improve the accuracy of discharge capacity predictions. Raw data acquired from remote gas meters frequently contain missing values and noise, which may hinder the performance of machine learning models. To address these challenges and improve model performance, we implemented a four-step data preprocessing procedure including missing value interpolation, noise reduction, primary point identification, and normalization. First, missing values in voltage, temperature, and communication count were addressed using Algorithm 1, while discharge capacity was handled through linear interpolation. To ensure the reliability of this process, missing values were \begin{table}
\begin{tabular}{c c} \hline \hline
**Collected Data** & **Detail** \\ \hline Timestamp [Second] & Timestamp of data collection \\ Discharge Capacity [mAh] & Battery usage using Coulomb Counter \\  & (Used as the ground truth for SOC prediction) \\ Temperature [\({}^{\circ}\)C] & Battery operating temperature \\ Voltage [V] & Present voltage \\ Communication Count [count] & Number of communications attempts per 10 min \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Data collected from smart gas meters. Figure 3: Remote gas meters and data collection board. (**a**) Remote gas meter with built-in PCB. (**b**) MSD primary battery installed in remote gas meter. (**c**) Rear part of PCB for data measurement. (**d**) Remote gas meter installed in house (deployed to 50 households). analyzed across multiple test sets, and different interpolation techniques were compared to minimize bias in data imputation.