<4D6963726F736F667420576F7264202D20DAC8CF20C7E1D1CDE3E420E6CF20DDD1C7CA20E6CF20E3E5E4CF2E2038382D203937> This is an open access article under the CC BY license Al-Khwarizmi Engineering Journal Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, September, (2023) P. P. 88- 97 Creating a LabVIEW Sub VI for the INA219 Sensor for Detecting Extremely Low-Level Electrical Quantities Abdulrahman B. Khudhair* Furat I.Hussein** Muhannad Ahmed Obeidi*** *,** Department of Mechatronics Engineering / Al-Khwarizmi College of Engineering/ University of Baghdad/ Baghdad/ Iraq ***Form Advanced Manufacturing Research Centre/ School of Mechanical and Manufacturing Engineering/ Dublin City University/ Dublin/ Ireland. Corresponding Author: *Email : abd.basheer2102m@kecbu.uobaghdad.edu.iq furatnejjar@uobaghdad.edu.iq Email :** muhannad.ahmedobeidi@dcu.ie Email :*** (Received 8 February 2023; accepted 8 May 2023) https://doi.org/10.22153/kej.2023.05.001 Abstract An impressed current cathodic protection system (ICCP) requires measurements of extremely low-level quantities of its electrical characteristics. The current experimental work utilized the Adafruit INA219 sensor module for acquiring the values for voltage, current, and power of a default load, which consumes quite low power and simulates an ICCP system. The main problem is the adaptation of the INA219 sensor to the LabVIEW environment due to the absence of the library of this sensor. This work is devoted to the adaptation of the Adafruit INA219 sensor module in the LabVIEW environment through creating, developing, and successfully testing a Sub VI to be ready for employment in an ICCP system. The sensor output was monitored with an Arduino Uno microcontroller and the LabVIEW Linx firmware toolkit. Pulse Width Modulation (PWM) technique, which ranges from 0% to 100%, was applied by the Arduino to supply the l298N voltage driver in order to regulate the voltage input to the load. A moving average filter was employed to measure the ripple voltage averaging, and a median filter was utilized to stabilize the readings. A passive low-pass filter circuit smoothed the PWM voltage before supplying the load. The results from the MATLAB- Simulink environment showed a cut-off frequency of 2.33 Hz, ripple voltage peak to peak was 41.1 mV and a settling time of 0.157 seconds. The calibrated results of the INA219 module sensor showed an absolute voltage inaccuracy of around 2.3% at full scale. In addition, an absolute error in the current of 2.2% at 25 mA shows a gradual increase as the current increases to 7% at 43 mA, while the highest absolute error for the full scale of power was at 5.8%. The obtained measurements were highly precise, and the values of the coefficient of variation were 0.36 %, 0.28% and 0.17% for the voltage, current, and power, respectively. Keywords: INA219, LabVIEW, Sub VI, MATLAB, Low pass filter, L298N. 1. Introduction Detecting and measuring the characteristics of low-consumption electrical circuits such as current, voltage, and power at extremely low levels has a variety of technical challenges. [1] [2] [3] Electrical systems that consume very small power values in the range of milliwatts require the use of sensitive and accurate instruments for that purpose [4]. Many techniques were used and are still being used in low-current measurements. The hall-effect-based technique utilizes the generated magnetic field around a conductor in the measurement of passed current. The ACS 712 Abdulrahman B. Khudhair Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, P.P. 88- 97 (2023) 89 Hall-effect sensor is used to measure current in both (DC) and (AC [5]. Another technique utilizes Ohm's law by measuring the voltage drop across a resistor of less than 1 Ω, called a shunt resistor, in order to measure the current flowing in the circuit. The Adafruit INA219 sensor module is used to measure the current flowing in an electrical circuit by reading the voltage drop on the terminals of a 0.1 Ω (R100) shunt resistor [6]. Many researchers have investigated routes and systems for detecting and monitoring accurate minimal current measurement circuits. Kinyua AP et al. [7] utilized the ACS712 current sensor to measure the current generated from a tomato after increasing the ADC resolution of the icrocontroller from 4.88 mV to detectable low values of 0.83 mV. In that work, the measured current was between 0.002 and 0.05 mA, associated with a little amount of visible noise in the readings. Muhammad Nizam et al. [8] described the usage of an ACS712 current sensor module in monitoring battery consumption. According to the research findings, the precision and accuracy of the current sensor were 64.91% and 83.75%, respectively. H. Maghfiroh et al. [9] applied a comparison of multi-meter readings with those of the INA219 current sensor in monitoring the inverter's input current. The study reveals an error of 1.27% as an inaccuracy in sensor readings. Afrizal Abdi Musyafiq et al. [10] utilized the INA219 power sensor to monitor the power output of the pico-hydro power plant, which was reported to be 24.82 mW. At values below 14 mA, the least difference was found to be 0.1 mA, while the highest difference was found to be 1.3 mA. S. H. Cheragee et al. [11] utilized an INA 219 current sensor module and a shunt resistance to monitor the generated current from solar PV panels. The maximum and minimum observed current values in specific time intervals are roughly 1 mA and 0.5 mA, respectively. The greatest observed power was 2.5 mW, while the least observed power was approximately 1.5 mW. According to the results of Eri Wiyadi et al. [12], concerned with the data acquisition of solar module characteristics, INA219 sensor module output showed an error value of 0.76% and a linear correlation with an R-square of 0.98. The INA219's effective detection range was between 10 mA and 3 A. A. T. Nugraha et al. [13] utilized the INA219 sensor in their study to measure the current generated as a result of wind energy, and it was able to detect extremely small values of the current around 1.8 milliamps. The motivation of this study is the need for an extremely low current measurement technique in order to detect the low current of impressed current cathodic protection system (ICCP). The current study was devoted to the modification of the INA219 bidirectional sensor by adapting it to the LabVIEW environment in order to develop an automated current measurement system for less than 25 mA. 2. Experimental Work This section discusses the instrumentation system that has been designed and implemented using the following hardware (practical system) and software systems (LabVIEW and MATLAB): 2.1 Hardware Figure (1) shows the hardware of the instrumentation system which includes the following parts: Fig. 1. The components of the instrumentation system (created by Fritzing software). 1. The microcontroller: The Arduino development board serves as the control unit's primary component. Six built-in analog input pins and fourteen digital input/output pins, six of which are used for PWM, are included [14]. 2. Current/power sensor: The INA219 sensor, introduced by Texas Instruments, serves as the foundation of the current measurement circuit. The bidirectional sensor INA219 detects the bus voltage within a range from 0 to 26 V. The instrument requires a supply voltage of 3 to 5.5 V and consumes up to 1 mA of supply current. The sensor's operating temperature range is -40°C to 125°C. The voltage across a 0.1Ω resistor can be measured by a precision amplifier. It can measure up to 3.2 A because the amplifier's highest input difference is 320 mV. The internal 12-bit ADC precision at the 3.2 A range is 0.8mA. The maximum capability of current and resolution Abdulrahman B. Khudhair Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, P.P. 88- 97 (2023) 90 detection is 400 mA and 0.1 mA respectively, with the internal gain set to the lowest of div8. The I2C protocol can be utilized to interface the Adrfruit INA219 module sensor to an Arduino Uno [15]. This sensor can detect the voltage, current, and power on the load by measuring the bus voltage and the voltage drop on the terminals of a shunt resistor of 0.1Ω to measure the current. The accuracy of measurements can be improved by programming registers .A bank of 16 bit registers ranging from 00 to 05 hexadecimal are used by the INA219 to store configuration parameters, measurement data, maximum- minimum limits, and status details (Table (1)). With the configuration of registers, the function and mode of operation are set. For example, Figure (2) illustrates the features of each bit in the first register with address 00 HEX, which indicates that it is a read-write configuration register and that it holds data. Table 2 tabulates the selected data to support the requested goal and objectives of the current work. Fig. 2. Configration of 00 HEX register. Table 2, The content of configruation rgister INA219 sensor. BIT Config Num. BIT Fill Discription RST 15 0 Power-off Reset - 14 0 BRNG 13 0 0 =16V FSR (Full Scale Range) PG1 ,PG0 12, 11 00 Range = ±40 mV BADC 10,9,8,7 0001 Mode ( 10 bit) SADC 6,5,4,3 0001 Mode ( 10 bit) MODE 2,1,0 111 Shunt and bus, continuous The 16-bit configuration register is loaded with the binary (0000 0000 1000 1111) or 008F in hexadecimal. The values for shunt voltage, bus voltage, power, and current are stored in the registers with addresses 01 through 04 HEX, which are read only. The last address 05 HEX register is a calibration register that is set accordance to the data sheet's equations and the work requirements as [15]: Current � � � 2�� … �1� where IM is the maximum expected current which equals to 0.4 A. By substituting IM in Equation (1) and rounding to the nearest: Current � � �.� ��,��� � 0.00001221 � 0.0001 The Current LSB is multiplied by Current Register (04h) content to convert a value to the actual current in amperes. Table 1, The registers of INA219. By substituting the value of the currentLSB and value of the Shunt Resistance of the Adafruit INA219 sensor module in Equation (2) with truncate the decimal values from the result . [15]: Cal � trun ! 0.04096 Current� % R '()* + … �2� where Cal is the calibration, trun is the truncate, RSHUNT is the shunt resistance (Ω). Based on Equation (2) , the Calibration Register is calculated. Cal � trun ! 0.04096 0.0001 % 0.1+ � 4096 By substituting the value of the currentLSB in Equation (3) [data sheet – ina219]: PowerLSB = 20×CurrentLSB … �3� PowerLSB = 20×0.0001 = 0.002 For a power value in watts, the Power Register (03h) content is multiplied by Power LSB, which is 20 times the Current LSB. 3. Voltage Driver: L298N dual H-Bridge module used supply the system requird voltage (0V to 5V) and current up to 2A as maximum output current. The ENA port is delivered a PWM signal out from Arduino. The driver outputs 1 and 2 were utilized, and high and low voltages were delivered to IN1 and IN2, respectively, to generate positive POINTER ADDRESS REGISTER (Legend- R=read, W=write) HEX 00 Configuration (R/W) 01 Shunt voltage (R) 02 Bus voltage (R) 03 Power (R) 04 Current (R) 05 Calibration (R/W) Abdulrahman B. Khudhair Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, P.P. 88- 97 (2023) 91 and negative voltages, at Out1 , OUT2 respectively. Driver input was connected to a DC source with a 500 mA, 11.85 V output that ranged from 0 V at 0% duty cycle (DC) to 11 V at 100%. 4. Low pass filter (LPF): A passive low pass filter is a resistor-capacitor (RC) circuit used to smooth the analog output of the L298N by cutting off the higher frequency and passing the low frequency. The values of the resistor and capacitor are 201.7 Ω and 338.2 µF respectively. The transfer function for this LPF is given by[16]: -�.� ≡ 0123 045 � 1 1 6 78. … �3� 5. The applied load: To analogize the ICCP system and observe the value of current flow in milli Ampere and power consumption in milli Watt, a resistor of 55 Ω was utilized, which requires less voltage than the RC low pass filter resistance. 2.2 Software MATLAB/Simulink and the graphical pramming LabVIEW were utilized in driving and executing the setup harware: 1. MATLAB/Simulink: Used to illustrate the output voltage profile, cut-off frequency, and transfer function analysis utilizing bode diagram as shown in Figure (3). Fig. 3. Block diagram in Simulink. 2. LabVIEW Sub VI design: LabVIEW was implemented to programming the embedded platform (Arduino Uno) through the Linx firmware. It acquire data from the INA219 sensor and adjust the DC for the L298N voltage driver. Figure (4a) illustrates the designed LabVIEW's front panel that is employed to control the DC's value from 0% to 100%. In addition monitoring the system during performance namely the voltage, current and power as well as other control operations. Figure (4b) shows the connector pane after the Sub VI creation, design, and setting of the terminals that correspond to the controls and indicators of the INA219 sensor. The help, or benefit, for the user, of the interface of the INA219 sensor with LabVIEW is presented in Figure (4c). Utilizing the I2C linx toolkit built into the LabVIEW block diagram, the INA219 current sensor is configured by identifying a slave address with a value of 40 HEX. The RC low pass filter circuit causes ripple voltage. This problem was solved using a moving average filter in the LabVIEW code. More stable values were obtained by employing a median filter for every 10 samples. A while loop with a 10-millisecond waiting time is utilized. Fig Fig. 4. LabVIEW Sub VI for the INA219 bidirectional sensor: (a) Front panel, (b) connector pane and (c) Sub VI help. As illustrated in Figure (5), the flowchart presents the steps involved in adapting the INA219 sensor to work with LabVIEW software. The LabVIEW graphical code was developed to read the electrical data from the sensor and display it on the user interface. Finally, the code was tested and refined to ensure accurate and reliable electrical measurements. Abdulrahman B. Khudhair Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, P.P. 88- 97 (2023) 92 3. Result and Discussion The created Sub VI for the Adafruit INA219 sensor module was tested and analyzed through behavior data acquisition during the field tests of the system. The features were modified to meet the requirements of each test, necessitating redesigns. This modification accommodated the needs in regard to the connection between all the components of the instrumentation system. This system offers the benefits of being dependable, low-power, and efficient for very low-level DC electrical measurements. The current, voltage, and power measurements, as well as the performance of this instrumentation system, are presented and discussed in the next subsections. Fig. 5. Flowchart presents the steps involved in adapting the INA219 sensor with LabVIEW. Abdulrahman B. Khudhair Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, P.P. 88- 97 (2023) 93 3.1 RC Low pass filter As mentioned before, the role of the RC circuit is to smooth the applied PWM voltage for the load. A square voltage of 11 V was applied at a frequency of 980 Hz and a DC of 50%. The applied voltage takes a settling time of 0.157 sec to reach the steady state of 4.95 V, as shown in the graph extracted from MATLAB/Simulink in Figure (6). Referring again to Figure (6), the steady-state voltage shows regular periodic ripples with a peak-to-valley difference of 41.1 mV, which were passed by the RC low pass filter. The bode diagram in Figure (7) shows the cut- off frequency is 2.33 Hz at magnitude -3 (dB) and a phase angle of -45o at the same the cut-off frequency. Fig. 6. The profile of applied voltage of 4.95 V at DC frequency of 980 Hz to the load (extracted from Simulink). Fig. 7. The bode diagram reveals a cut-off frequency of 2.33 Hz (-3dB) and phase angle of -45 o . 3.2 Electrical characteristics The experiments were achieved by PWM control for the power across the system with a duty cycle from 0% to 100% via the Arduino and LabVIEW code in order to supply the load and RC filter with a range of voltage from 0 to 11 V. An increment of 5% in duty cycle results in a spectrum of voltage, current, and power data across the load, which is acquired by the INA219 sensor. To investigate the error and performance of the instrumentation system, the experiments were repeated after switching the INA219 sensor with a sensitive multimeter of type UNI-T UT39A+. The experiments were conducted twice with the multimeter, the first time with the components connected in parallel to measure the voltage and the second time with the components linked in series to measure the current. The data obtained from the experiments for the voltage, current, and load across the load will be presented as follows: 1. Voltage: Figure (8) shows the measured voltage by the INA219 sensor (Vs) and the multimeter (Vm) for the range of duty cycle from 0% to 100%. The graph shows a great matching betweem the true and measured values of voltages. This match is expressed by the percentage of full scale error (Er) which has inverse proportionality with the duty cycle. The INA219 sensor shows lowest error value of 1.5 % and highest value of 2.3% which considere a highly acceptable narrow band over the range of employed duty cycle. Abdulrahman B. Khudhair Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, P.P. 88- 97 (2023) 94 Fig. 8. Vs of INA219 sensor versus Vm of multimeterover the employed range of duty cycle. 2. Current: The current detected by the INA219 sensor (Is) and the multimeter (Im) during the range of 0% to 100% duty cycle are shown in Figure (9). The differences between the sensor and multimeter values exaggerate as the duty cycle increase where the error between reading extends. These graphs of Is and Im are correlated with acceptable error values up to 40% duty cycle which starts to expand after this value. At 5% duty cycle the error is 0.1% which became in itsan maximum value of 7% at 95% duty cycle. Fig. 9. Is of INA219 sensor versus Im of multimeter over the employed range of duty Fig. 3. Power: The electrical power consumed by the load was obtained from the sensor output (Ps) as well as that calculated theoretically (Pc) by multiplying the Vm with Im for each value of the duty cycle is graphed in Figure (10). The sensor shows a threshold value in reading up to the duty cycle of 10%. After the threshold the sensor detects the least amount of Ps equals to 4 mW versus 3.4 mW for Pm at a duty cycle of 15%. The full-scale error of power keeps its minimum values at a duty cycle of 60% before climbing to higher values. Fig. 10. Ps of INA219 sensor versus calculated Pc over the employed range of duty cycle. 3.3 Performance Characteristics Some of the static characteristics, such as resolution and linearity, of the system were investigated. From the above data that was obtained from the sensor, the minimum value of the current that can be detected, which is represented by the resolution, was calculated. The resolution of the INA219 sensor at 1% duty cycle was 1 mA, which shows high manufacturing, with the resolution value of the multimeter represented by 1.012 mA in the same measurement conditions and duty cycle. This indicates a percent absolute error of 1.18%. M. Mariappan et al. stated in their work that the ACS712 current sensor with the Arduino Uno shows a resolution of 26.4 mA [17]. The output of the instrumentation system shows significant linearity, as represented by the acceptable coincidence between the output curves of Vs and Is and the linear trendlines of each curve, as illustrated in Figures (11). The coefficient of determination (R2) value of 0.9966 for both graphs determines the average difference between the predicted values by the fitted line (trendline) and the actual values for the sensor. The value of sensitivity was estimated for voltage to be equal to 0.0233 volts/% duty cycle and for Abdulrahman B. Khudhair Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, P.P. 88- 97 (2023) 95 current to be 0.4436 mA/% duty cycle. These results revealed that the adaptation of the employed sensor with LabVIEW makes this coupling suitable for the measurement of weak current values in corrosion-inhibiting applications. The levels of the measured electrical characteristics come in good agreement with the observed corrosion current values in the protection of low-carbon steel in Amel S. Merzah et al, work [18]. Fig. 11. The linearty of the instrumentation system output, Vs and Is, supported by the linear equations over the employed range of duty cycle. The precision of the system in this work was evaluated by the coefficient of variation. The reading of the voltage, current and power show significant average precision of 0.36 %, 0.28% and 0.17% respectively. 4. Conclusions One of the obstacles to employing sensors with the LabVIEW-Arduino interface is the absence of their sub-VIs. This study was devoted to building and programming a Sub-VI for the INA219 bidirectional sensor suitable for extremely low electrical measurements. The following are the concluding remarks for the current study: 1. The highest absolute error was calculated for the full scale voltage around 2.3% at a value of 2.22 V. 2. The absolute error of the current at 2.2%, which is less than 25 milli-amps. It increases gradually with the increasing in current until it equals 7% at the current of 43 mA. 3. The highest absolute error for the full scale of power was at 5.8%. 4. The linearity of voltage and current were investigated utilizing fitting line, and the value of the coefficient of determination R2 was estimated as both were 0.9966. 5. measurements were highly precise and the values of the coefficient of variation were 0.36 %, 0.28% and 0.17% for the voltage ,current and power respectively. References [1] R. B. Northrop, INTRODUCTION TO INSTRUMENTATION AND MEASUREMENTS, 3rd ed., Broken Sound Parkway NW: Taylor & Francis Group, 2014. [2] J. M. Shah, R. Anand, S. Saini, R. Cyriac, D. Agonafer, P. Singh and M. Kaler, "DEVELOPMENT OF A TECHNIQUE TO MEASURE DELIQUESCENT RELATIVE HUMIDITY OF PARTICULATE CONTAMINANTS AND DETERMINATION OF THE OPERATING RELATIVE HUMIDITY OF A DATA CENTER," in Proceedings of the ASME 2019 International Technical Conference and Exhibition on Packaging and Integration of Electronic and Photonic Microsystems, Anaheim, CA, USA, 2019. [3] M. Nizam, H. Maghfiroh, A. Ubaidilah, I. and F. Adriyanto, "Constant current-fuzzy logic algorithm for lithium-ion battery charging," International Journal of Power Electronics and Drive Systems (IJPEDS), vol. 13, no. 2, pp. 926-937, June 2022. [4] W. Indrasari, R. Fahdiran, E. Budi, U. Umiatin and N. S. Yusuf, "Development of static solar panel equipped by an active reflector based on LDR sensors," in 5th International Seminar on Mathematics, Science, and Computer Science Education, Bandung, 2019. [5] Đ. Lazarević, M. Živković, Đ. Kocić and J. , "The Utilizing Hall Effect-Based Current Sensor ACS712 for TRUE RMS Current Measurement in Power Electronic Systems," vol. 72, no. 1, pp. 27-32, 2022. [6] N. Cameron, Electronics Projects with the ESP8266 and ESP32: Building Web Pages,Applications, and WiFi Enabled Devices, Edinburgh, UK: Apress, 2021. Abdulrahman B. Khudhair Al-Khwarizmi Engineering Journal, Vol. 19, No. 3, P.P. 88- 97 (2023) 96 [7] K. AP, M. JK, I. KO, M. D and K. JG, "Current and voltage data logging from microbial fuel cells using arduino based sensors," International Journal of Robotics and Automation, vol. 7, no. 3, pp. 90-93, 5 November 2021. [8] M. Nizam, H. Maghfiroh, ,. F. N. Kuncoro and F. Adriyanto, "Dual Battery Control System of Lead Acid and Lithium Ferro Phosphate with Switching Technique," World Electric Vehicle Journal, vol. 12, no. 4, 1 January 2021. [9] H. Maghfiroh, J. T. Affandy, F. Adriyanto and M. Nizam, "Single Phase Inverter with Power Monitoring using Arduino," in 2nd International Conference on Science & Technology, Yogyakarta, 2020. [10] A. A. Musyafiq, N. A. Ilahi, R. P. Dewi and U. Barokah, "Simulation of Piko Hydro Power Generator Using Thread Turbine With 10-Watt Power," Journal of Telecommunication Network, vol. 12, no. 2, pp. 100-104, 2022. [11] S. H. Cheragee, N. Hassan, S. Ahammed, A. Z. Md and T. Islam, "A STUDY OF IOT BASED REAL-TIME SOLAR POWER REMOTE MONITORING SYSTEM," International Journal of Ambient Systems and Applications, vol. 9, no. 1, pp. 27-36, June 2021. [12] E. Wiyadi, A. Wati, Y. Hamzah and Y. , "Simple I-V acquisition module with high side current sensing principle for real time photovoltaic measurement," in International Seminar on Sensors, Instrumentation, Measurement and Metrology, Padang, 2020. [13] A. T. Nugraha, D. Priyambodo and S. T. Sanera, "Design A Battery Charger with Arduino Uno-Based for A Wind Energy Power Plant," Journal of Physical Science and Engineering, vol. 7, no. 1, pp. 23-38, 18 April 2022. [14] R. Singh, A. Gehlot, B. Singh and S. Choudhury, Arduino-Based Embedded Systems Interfacing, Simulation, and LabVIEW GUI, Broken Sound Parkway NW: Taylor & Francis Group, 2018. [15] Data sheet, INA219 Zerø-Drift, Bidirectional Current/Power Monitor With I2C Interface, Texas Instruments Incorporated, 2015. [16] W. H. Hayt Jr, J. E. Kemmerly and S. M. Durbin, ENGINEERING CIRCUIT ANALYSIS, 8 ed., New York: McGraw-Hill, 2012. [17] M. Mariappan, H. F. Shun and K. Muthukaruppan, "Electrical Consumer Panel with Automated Leakage Current Detector System," INTERNATIONAL JOURNAL OF INTEGRATED ENGINEERING, vol. 12, no. 2, pp. 46-54, 2020. [18] A. S. Merzah, M. H. Hafiz and S. k. Mohammed, "Corrosion control of Buried Low Carbon Steel Structure by Using Alteration Medias method," Al-Khwarizmi Engineering Journal vol. 10, no. 2, pp. 65-74, 2014. ���� ���� � د19ا��� ��� ا� �� ���� ا���ارز�� �� ا��� )2023( 88-97، ! �� 3، ا� 97 , Adafruit INA219�*+ ��LabVIEW ��(� ا������� )� ا� Sub VI و ة إ$�#ء ا�1 �#ت ا����1#��0 ��� �� ا� +,�ى ��.#-� ,�+*� *���� ���� � ا���� **��+ )�ات ا��اھ�4 ي��� ا� أ���*** اد *،**�� ا���ارز��/ ����� ا������ /� ا�$���#"و �� اد/ ا��"اق)'& ھ��� / ا�$��� ��� وا�,.��- /�"�2 أ��0ث ا�,.��- ا�$,+ م***� ا������/ 3��4 د� � ����/ 3� إ4"�� ا /د� abd.basheer2102m@kecbu.uobaghdad.edu.iq*ا�8"4 ا�7�,"و �: furatnejjar@uobaghdad.edu.iq**ا�8"4 ا�7�,"و �: muhannad.ahmedobeidi@dcu.ie **ا�8"4 ا�7�,"و �: ا��8!� �< =�م ا�4�$0 ا���>�د4 ���,��ر ا�+'"ي (?,4ICCPس��( ( &�( 4���� BC���� D$ا ا��Eھ �F . �H��"��ا� I.H�.� &# � �عم ا�$اأٌ�,�'0, Adafruit INA219 س���+ �Lا�,��ر وا�و )�& ا� �H��"��رة ا� + �Nا",Fا D$0� ر��E$ا��=�م ا� D$O ���04ICCP و 4���� BC��� .ا�Eي 4',��Q ط�) �'�H"ا� ��R$3 ا�$�# �Fا�+��س ��$S ھ��F ا�"اءات V���#ا�$�'0, INA219 �F ICظ��# �S X�� ا�"����L�"8ا�LabVIEW م S >8'� 8,�� "F�#I� �C4"�# او اي اداة Yا��� I,. �F D$ا ا��Eھ &# V���# ���$Adafruit INA219 Dا�$,0'� X�� �F LabVIEW ء�R ة �3 \]ل إ Oو �L�"� Sub VI ح � �وا\,�8رھ �و#?�4"ھ�L��, ً2ن ��ھ��ة D$�� و�$Hم ��ا�= ICCP `�� "� -�LabVIEW. a$# ��$S ج"\ ا�$,0'� �"ا)8 دوات ا�8"ا7و Arduino Uno$,0�& ا����,� ام �L� LabVIEW-Linx. c8ض ا��"S D4 �# ��+# e�8?# &# PWM 3� 0وا�,� #,"اوح fإ� ٪ ��=&�,2و4 $,0�& ا� �3 \]ل٪ 100�Lا�L298N ض"�� �Lا�$ #�=�& ا�h�' f�S ا.D$0� م#& ا�,�<[< [F"# وھ� ",�F ع� Moving average filter �� h��,� ا�,$�ج �+��س Ripple و",�Cا� Median filter اء"( f�S 0.�ل��," داH"ة4 وا�,+"ار��>�)� و ا�i" ات�Cا� Passive low-pass filter &���,� &�( �Lا�PWM D8(I?��'# S.D$0ا� f� Vظ��# &# X�� ا�$�#]ب MATLAB-Simulink ا�#"دد �+��س-?+ �aCR و�� k�O ا�,$�ج ره ا��,�3S `H )�& #"دد )?-(2.33 Hz و ره �3 ا�+$ ا�f ا�+$ #$�ج ��( 41.1 mV ره �$',�R" ا�$��4"ة أظ�"ت ,�s. `H 0.157وز�3 ا�,+"ار ) INA219 $�( e��ا��?m ا�$?� �L �H��"��ظ�" ٪.2.3��0ا�� ا� ، Qذ� fإ� F�Np��ا� ت &�( m?ا�� ��F e ا�,��ر ��'8?$2.2 �S ٪25 mA ��42دة و �L4ر # 4 S�.# f7إ� �S ٪43 mA �� �$���a f�Sأ $�(�� e�?� m?\رة ���� "اءاتا�+ ٪.5.8 ھ� +S ا�,� #& ا�0.�ل �a د)L� و ���S DL� وا�,��ر وا�0.17٪ و 0.28٪ و 0.36 )�& ) رھ� ����D اr\,]ف�L�� ٪ �H��"��رة ا� �f ا�,�ا��. +S