INTRODUCTION
Abstract
Data collection is a crucial step in energy visualization and analysis research, necessitating the development of a reliable and efficient data collection system This thesis presents an innovative energy data collection method utilizing a compatible microcontroller to accurately read utility meters and wirelessly transmit real-time information to nearby businesses or residences This system enables effective monitoring of energy usage and budget status, specifically employing an optical current transformer sensor to measure the current of the electrical grid The invention focuses on systems and methods for measuring and wirelessly monitoring power consumption.
The system connects to a main power source and power-consuming devices, integrating home appliances with the electrical grid for effective power usage measurement and monitoring This data is encoded and stored in a database, with options to transmit it to a controlling assessment via a data network or a real-time IoT server Additionally, the system can determine and record the location of electrical appliances, allowing for enhanced control over power consumption Furthermore, a remote server can link multiple energy monitoring systems to improve efficiency and promote a community-based social network.
Scope of the study
The invention focuses on innovative systems and methods designed for monitoring and managing energy consumption and generation within households It emphasizes user-centric approaches that educate and empower homeowners to effectively control their energy usage habits.
Background of project inspiration
Electricity is essential in modern society and the energy industry, powering everyday devices like computers, light bulbs, and appliances As households increasingly rely on complex wiring systems, businesses and factories demand even more sophisticated electrical setups However, the rising power consumption is straining the energy industry, influenced by environmental and political challenges.
Concerns about global warming and rising electricity bills have left many residents in Vietnam anxious about their individual impact on national energy issues and monthly expenses In response, some individuals are striving to live off-the-grid by utilizing renewable energy sources like solar and wind power Terms like carbon credits and carbon footprints have become part of everyday language, frequently appearing in news reports and films Despite this heightened awareness regarding resource and energy conservation, significant challenges remain.
2 impossible for a concerned global citizen to be able to actively measure the effects of their day-to-day energy consumption
Energy consumers seeking to engage in conservation and environmental initiatives often find existing solutions inadequate Additionally, these circumstances leave them uninformed about their energy usage and costs, hindering their ability to make informed, energy-efficient choices for their homes and businesses.
Homeowners increasingly seek to monitor their daily energy consumption to make timely adjustments Traditionally, they rely on past energy bills, often evaluating the previous month's electric statement This method poses a challenge, as it delays immediate changes to energy usage until the end of the month, making it difficult for consumers to optimize their energy consumption effectively.
In response to a significant concern, we have decided to research how to create an effective home energy monitoring system This system must focus on key factors such as affordability, efficiency, and portability to ensure practical real-world application.
Sources and work cited
Our project will utilize essential materials and resources gathered from academic journals, technology-focused blogs, YouTube videos, equipment datasheets, and guidance from our mentor We will carefully select the necessary information and provide a comprehensive list of original references in this Diploma project.
Accomplishment of the project
The energy visualization and analysis system serves as a powerful tool for energy conservation and environmental research The initial and crucial step in this process is obtaining accurate energy consumption data, making the design and implementation of an effective data collection system essential To transition this project into a commercial product, several key implementation strategies must be carefully considered.
Initially, there are some integral goal for our project that is needed to be fulfill:
Introducing a non-invasive energy monitor designed for the entire household, this innovative device eliminates the need for wire-cutting and avoids placing meters between receptacles or electrical appliances By doing so, it significantly reduces the potential hazards associated with high voltage, ensuring a safer environment for your home.
Automatically taking measurements every second in order to get an accurate picture of power consumption, later may be depicted as a data-based graphs with a user-friendly display
Saving all the data in the cloud or server for later use and analytics
Database can be able to easily accessed during both realtime and offline-time
CONCEIVE
Internet of Things
The Internet of Things (IoT) refers to a network of interconnected devices, including machines, objects, and even living beings, that possess unique identifiers (UIDs) and can communicate digital data over a network without the need for human intervention.
The Internet of Things (IoT) has evolved through the integration of advanced technologies such as real-time analytics, Artificial Intelligence, various sensors, and embedded systems This development enhances traditional sectors like remote sensing, control systems, and automation, particularly in home and building management In the consumer market, IoT is often associated with smart home products, including lighting, thermostats, security systems, and other electrical appliances These devices work together within interconnected ecosystems and can be easily controlled via smartphones and smart speakers.
Concerns regarding privacy and security are rising as the Internet of Things (IoT) continues to expand, prompting both industry and government to take action to address these critical issues.
Figure 2.1 Practical Application of IoTs
IoTs are used in many types of home and industrial sector:
Smart cities include intelligent monitoring, automatic transportation, smart energy management systems, water distribution, urban security and environmental monitoring with sensors
The Industrial Internet leverages advanced sensors and sophisticated software to develop highly intelligent devices that outperform manual operations in data communication accuracy and consistency By harnessing the power of collected data, businesses and managers can address challenges more swiftly and effectively.
Smart wearable devices and accessories such as goggles, backpacks, smartwatches are set by the sensor to collect user information such as blood pressure, daily walking steps, etc
Smart home is the type of installed electrical equipment, electronics can be automatically controlled or semi-automated by voice command, replace homeowners in performing operations management and control
Therefore, IoTs has becoming such an intrinsic part of the modern monitoring system in general
The essence of the Internet of Things (IoT) lies in the ability to identify objects, including users, through unique markings This identification allows for comprehensive management via computer systems Various technologies, such as RFID, NFC, barcodes, and QR codes, facilitate this marking process Additionally, connectivity can be achieved through networks like Wi-Fi, broadband telecommunications (3G, 4G), and Bluetooth.
In addition to the aforementioned techniques, utilizing IP addresses allows for the unique identification of each object, as every device possesses a distinct IP address This facilitates seamless connectivity to the Internet and enables devices to communicate with one another effortlessly.
The Internet of Things (IoT) represents a transformative shift in the digital landscape, making it a crucial focus for researchers in embedded systems, computer science, and information technology Its diverse applications and the integration of various communication and embedded technologies in its architecture underscore its significance in contemporary research.
Amazon Web Services (AWS) is recognized as the most comprehensive and widely adopted cloud platform worldwide, providing over 175 fully featured services from data centers around the globe It serves millions of customers, including rapidly growing startups, major enterprises, and prominent government agencies, all leveraging AWS to reduce costs, enhance agility, and accelerate innovation.
According to the AWS website, the bouquet of featured services includes the following:
Amazon EC2 – Elastic virtual servers in the cloud
Amazon Simple Storage Service (S3) – Scalable storage in the cloud
Amazon Aurora – High-performance managed relational database
Amazon DynamoDB – Managed NoSQL database
Amazon RDS – Managed relational database service for MySQL, PostgreSQL
Oracle, SQL Server, and MariaDB
AWS Lambda – Run code without thinking about servers
Amazon VPC – Isolated cloud resources
Amazon Lightsail – Launch and manage virtual private servers
Amazon SageMaker – Build, train, and deploy machine learning models at scale
We choose to implement our graduation dissertation based on AWS console due to the fact that it is proudly present the most leading cloud platform, which has:
AWS offers a broader range of services and features than any other cloud provider, encompassing foundational technologies like compute, storage, and databases, as well as advanced solutions in machine learning, artificial intelligence, data analytics, and IoT This extensive suite of offerings simplifies and accelerates the migration of existing applications to the cloud, enabling businesses to build virtually any application they can envision in a cost-effective manner.
AWS provides a comprehensive range of services, including specialized databases tailored for various applications This allows users to select the most suitable tools for their specific needs, ensuring optimal cost-effectiveness and performance for projects.
AWS boasts the largest and most dynamic community, comprising a diverse array of clients, including startups, enterprises, and public sector organizations This extensive network actively utilizes a wide range of functional tools offered by AWS, highlighting its global reach and versatility.
AWS is designed to be a highly adaptable and secure cloud computing environment, featuring a robust framework of sensitivity associations This is reinforced by an extensive suite of cloud security measures, including 230 services and features dedicated to security, compliance, and governance AWS adheres to 90 security benchmarks and certifications, ensuring that all 117 AWS services that handle client data provide encryption capabilities for enhanced protection.
Cloud computing offers on-demand access to IT resources via the Internet at cost-effective prices Instead of investing in and managing physical servers, businesses can utilize cloud services for computing power, analytics, storage, and databases Organizations of all sizes and industries leverage the cloud for various applications, including data backup and recovery, email services, virtual desktops, and software development.
6 development and testing, analytics, and web application, etc Moreover, there are some huge benefits of cloud computing which:
Access a vast array of technological advancements through the cloud, enabling rapid growth and the realization of your creative visions Instantly provision resources such as infrastructure services, including computing power, storage, and databases, as well as cutting-edge solutions like the Internet of Things, machine learning, data lakes, and analytics.
In just minutes, technology services enable swift transitions from concept to execution, allowing you to explore and test innovative ideas that enhance customer experiences and drive business transformation.
CT model & current measurement techniques
For system modeling and different analysis in this project, the CT and its models is delineated and conveyed in this section 2.2 Measurement purposes of the
CT projects are defined by a standard of accuracy, which will be briefly addressed in this section Additionally, the strategy for estimating current in the sensor is a crucial aspect to consider This chapter will also explore various measurement techniques, providing essential information that underpins the decision-making process for collecting primary current.
This chapter focuses on the block diagram of sensors, with an emphasis on the measurement block and the derivation of an equivalent circuit for the current transformer (CT) Section 2.2.2 provides a detailed discussion and validation of equivalent circuits, alongside general information about CTs Additionally, section 2.2.3 reviews various techniques for current measurement, offering insights into their specific applications.
Current transformers designed for measuring current adhere to specific standards that dictate the maximum allowable ratio error for various current levels One widely recognized standard is IEC 61869-2, which outlines accuracy requirements for instrument transformers.
The standard outlines the ratio error, defined by equation 2.1, which is applicable for various classes, including class 8 and above This ratio error is determined by the formula, where N_P represents the number of primary turns and N_S denotes the number of secondary turns.
Table 2.1 presents the ratio error percentages for various classes at different rated current levels, while Figure 2.4 visually illustrates these classes A current transformer (CT) is assigned a specific class that ensures its measurements meet the required ratio error across the entire specified current range Although the IEC 61869-2 standard applies to CTs rather than current sensors derived from them, it serves as a guideline for classifying these current sensors Currently, there are no established standards for this type of sensor, so the CT standard is utilized to define the class of current sensors based on CT technology.
Table 2.1 Ratio error [%] according to IEC 61869-2
Figure 2.4 Ratio error according to IEC 61869-2 2.2.3 CT models
The currents in the primary winding can be very high and to prevent damage to the measurement equipment the CT transforms the current down to measurable
The secondary voltage of a current transformer (CT) is influenced by both the load and the transformer size, typically resulting in a low voltage As the CT reduces the current, it increases the voltage in accordance with the power balance principle Generally, a CT features one or a few primary turns and numerous secondary turns, with most designs utilizing an iron core to facilitate magnetic conduction.
Figure 2.5 illustrates the equivalent circuit of a transformer, which undergoes simplifications for simulation purposes In this circuit, 𝑅𝑝 and 𝑅𝑠 represent the winding losses of the primary and secondary turns, respectively, while 𝐿𝜎𝑝 and 𝐿𝜎𝑠 denote the leakage inductances of these windings The primary and secondary windings are linked by an ideal transformer characterized by the turns ratio 𝑁𝑠.
𝑁 𝑝 The magnetizing inductance and core losses are represented by 𝑅 𝑚 and 𝐿 𝑚
In this project, we focus on the secondary side of the transformer, transforming all circuit elements from Figure 2.5 to the secondary side, resulting in the configuration shown in Figure 2.6 This transformation includes the primary inductance and resistance, with the source of the circuit represented by the transformed primary current.
Figure 2.6 Secondary transposed transformer equivalent circuit
The values of \( L_p \) and \( R_p \) are dependent on the cable and application, making them unknown The secondary side parameters are minimal, leading to the neglect of primary side parameters in this analysis Additionally, core losses in the linear region are negligible, allowing for the simplification of the circuit from Figure 2.6 to the circuit shown in Figure 2.7.
Figure 2.7 Simplification of current transformer equivalent circuit
Figure 2.7 illustrates the equivalent circuit of a current transformer, which includes the magnetizing inductance (Lm) and the leakage inductance (Ls) of the secondary winding, along with the resistance (Rs) of the secondary winding.
The magnetizing inductance (𝐿 𝑚) is determined using the dimensions of the current transformer (CT), core characteristics, and the number of turns in the secondary winding This calculation is performed using equation 2.3, where 𝜇 0 represents the permeability in free space, 𝜇 𝑟 denotes the relative permeability of the core material, 𝐴 𝑒 is the cross-sectional area, 𝑁 𝑠 indicates the number of secondary turns, and 𝑙 𝑐 refers to the magnetic core path length.
The circuit depicted in Figure 2.8 represents the Thevenin equivalent of the current circuit, utilizing an AC voltage source rather than an AC current source The inductance, denoted as \( L_s \), is defined by the equation \( L_s = L_m + L_s \) Additionally, the voltage induced in the circuit is a result of the magnetic flux passing through the core of the current transformer, as described in equation 2.4.
Figure 2.8 Simplification of current transformer equivalent circuit
Applying Ampere's law to a magnetic core surrounding a wire allows for the determination of the magnetic field within the core By combining equations 2.5, 2.6, and 2.7, one can calculate the magnetic field generated by a wire carrying a current of amplitude I, with the contour C for this magnetic field represented as a circle of radius r.
Using Faraday’s law of induction and the cross-sectional surface area of the core, the relationship between magnetic flux (Φ) and magnetic flux density (B) is established as described by the equation Φ = ∬ B · dA = B · A · S e.
In equation 2.9 the expression of the primary current is given
If now equation 2.9 is inserted into equation 2.7 and equation 2.7 is inserted into equation 2.8 equation 2.10 is derived
2𝜋𝑟 𝐼 𝑝 cos(𝜔𝑡 + 𝜑) (2.10) The last step to obtain the relation between primary current (𝐼 𝑝 ) and induced voltage (𝑣 𝑠 ) is to substitute equation 2.10 in equation 2.4
While the equivalent circuit models, whether based on voltage or current sources, utilize lumped elements with fixed values, these values can vary in real-world applications Specifically, the magnetizing inductance \(L_m\) is affected by the magnetic saturation of the core, leading to its non-constant nature Further details on this non-linearity can be found in Appendix A A simulation incorporating a non-linear magnetizing inductance has been conducted in the circuit depicted in Figure 2.7.
Table 2.2 Parameters of lumped elements in current transformer equivalent circuit
Leakage inductance of secondary𝐿 𝜎𝑠 1.8 mH Secondary inductance𝐿 𝑠 = 𝐿 𝑚 + 𝐿 𝜎𝑠 1.7018 H
Conclusion
This article reviews various sensors based on three distinct current sensing principles, evaluating them on cost, size, accuracy, losses, and their ability to sense both AC and DC currents For this project, precise measurement techniques are crucial, with linearity being a key factor Table 2.6 summarizes the current measurement techniques discussed earlier, using a rating system where indicates poor performance, ++ signifies excellent performance, and +/- denotes average performance In assessing the accuracy of current measurement sensors, critical design considerations include their accuracy, AC and DC sensing capability, and size, while losses primarily matter at low primary current levels.
This analysis highlights that a shunt resistor is the optimal choice for measuring both AC and DC current When implemented correctly, it offers high accuracy and linearity for this project, while also being cost-effective and compact However, a notable downside of using a current shunt is the increase in losses.
In this project, a current shunt will be utilized as the current sensing element due to its effectiveness in minimizing losses associated with low current levels The relationship between current and resistor value reveals that losses increase quadratically with current, making it crucial to manage current levels to reduce these losses.
Sensor Accuracy Size Cost Losses AC/DC
CALCULATION AND DESIGN
Energy extraction and power conversion
This chapter discusses the utilization of a CT to harness energy from the magnetic field surrounding a current-carrying conductor This energy is essential for powering the electronics within the sensor, which facilitate measurement, data processing, and data transmission (Figure 3.1) A theoretical analysis is conducted based on the electrical circuit of a CT.
CT simulations and measurements validate the thesis, detailing the power conversion stages necessary to transform the CT output voltage and current into a stable ADC signal for electronic measurement applications.
Figure 3.1 Block diagram of sensor, energy extraction block is considered in this chapter
Section 4.2 explores the energy extraction capabilities of a CT, detailing the current output under standard conditions and examining methods to enhance energy extraction In section 4.3, the focus shifts to power conversion stages, analyzing how these conversions affect the source voltage and current waveforms.
Current in an electric circuit refers to the rate at which energy flows past a specific point within a closed circuit In alternating current (AC) circuits, components such as inductors and capacitors can occasionally reverse the direction of energy flow.
Active power refers to the unidirectional transfer of energy averaged over a complete cycle of an alternating current waveform, commonly known as real power This term is used to eliminate confusion, particularly when discussing loads with non-sinusoidal currents On the other hand, reactive power represents the portion of power associated with stored energy that cycles back to the source during each cycle.
Incandescent light bulbs, kettles, irons, electric water heaters, and electric cookers operate efficiently by utilizing all the energy supplied to them According to Ohm's Law, the current drawn by resistive loads is directly proportional to the voltage divided by the load resistance A purely resistive load produces a voltage and current waveform that reflects this relationship.
Figure 3.2 Phase relationships of voltage and current in a resistive load
Figure 3.2 illustrates instantaneous power, represented by the yellow line, which is calculated as the product of voltage and current at any specific moment It is important to note that the power remains consistently positive, indicating that energy is flowing to the load in the positive direction.
Certain electrical appliances, including fridges, washing machines, pillar drills, and arc welders, operate differently than standard devices, as they consume energy and also return some back to the power source These appliances feature inductive components, such as motors, or capacitive components, like arc welders, alongside resistive elements The voltage and current waveform output of a partially inductive load is illustrated in Figure 3.3.
Figure 3.3 Voltage and current phase relationships in a partially reactive load
Figure 3.3 illustrates a cautionary note indicating that the yellow line dips into negative territory for a certain duration This negative segment represents energy flowing back from the load, while the positive segment signifies energy being supplied to the load.
The other interesting point is that the voltage and current waveforms have been shifted separated Envision charging a genuinely large capacitor with a resistor in
In a series circuit, the capacitor cannot be charged instantaneously Initially, the capacitor is discharged, and when the supply voltage exceeds the capacitor voltage, current flows into the capacitor, causing its voltage to rise As the supply voltage decreases, the charged capacitor's voltage becomes higher than the supply voltage, leading to a reverse current flow towards the power supply This reversal creates a current waveform that appears shifted, a phenomenon known as phase shift.
Real Power, Reactive Power and Apparent Power
In a closed AC circuit with a source and a linear load, both current and voltage are sinusoidal When the load is purely resistive, the polarity of voltage and current reverses simultaneously Consequently, the product of voltage and current remains positive or zero at all times, ensuring that the direction of electric flow does not reverse In this scenario, only active power is transmitted.
In circuits with reactive loads, voltage and current are 90 degrees out of phase, resulting in positive power flow for half the cycle and negative for the other half, indicating that energy flows into and out of the load equally, with no net electric flow This scenario involves only reactive power, and while electrical power travels along the wires, it returns through the same path The current required for reactive power flow dissipates energy due to line resistance, even if the ideal load consumes no energy In practical applications, loads exhibit both resistance and reactance, leading to the flow of both active and reactive powers.
Apparent power is the result of the rms values of its voltage and current Apparent power is considered when structuring and operating electrical power
Reactive power is essential in electrical systems, as it must be supplied by the energy source even though it does not perform work at the load Conductors, transformers, and generators should be measured for the total current, not just the effective current Insufficient reactive power in electrical grids can lead to lower voltage levels and, in extreme cases, total system failure or power outages Additionally, calculating apparent power for loads does not accurately reflect total power unless the loads share the same phase difference between current and voltage, maintaining a consistent power factor.
Figure 3.5 The sinewave graph describing value types of power
At mains frequency, the power draw fluctuates 50 to 60 times per second, making it challenging to track changes in voltage, current, and power To better understand this, we use the average of instantaneous power, known as real or active power, which represents the energy consumed by a device to perform useful work In the accompanying graph, positive values indicate power supplied to the load, while negative values represent power returning to the supply The real power is calculated as the difference between the power delivered to the load and the power returned, reflecting the actual energy utilized.
Reactive power, also known as imaginary power, quantifies the energy that oscillates between the load and supply without performing any useful work Another important concept is Apparent Power, defined as the product of Root-Mean-Square (RMS) Voltage and RMS Current For purely resistive loads, real power is equivalent to apparent power; however, for other types of loads, real power is always less than apparent power While apparent power encompasses both real and reactive power, it does not simply represent their sum, as it accounts for phase differences between the two.
Energy flow in a system and assign each of them a different unit to differentiate between them are described as these international standard symbols below
Active power, P, or Real power: watt (W);
Reactive power, Q: volt-ampere reactive (var);
Complex power, S: volt-ampere (VA);
Apparent power, |𝑆|: the magnitude of complex power S: volt-ampere (VA);
Phase of voltage relative to current, 𝜑: the angle of difference (in degrees) between current and voltage; 𝜑 = arg(𝑉) − arg (𝐼).Current lagging voltage
(quadrant I vector), current leading voltage (quadrant IV vector)
Relationship between real, reactive and apparent power for IDEAL sinusoidal loads:
P= |𝑆| x cos 𝜑 (3.1) Q= |𝑆| x sin 𝜑 (3.2) cos 𝜑 is also known as power factor
However, a note about non-linear loads on equation 3.1 and 3.2 is the power factor relationship is valid only for linear sinusoidal loads Most power supplies for
DC devices like Laptop computers, present a non-linear load to the mains Their current draw is depicted in the Figure 3.6
Figure 3.6 Non-linear load simulation
Other forms of complex power (units in volt-amps, VA) are derived from Z, the load impedance (units in ohms, Ω) is expressed in equation 3.3
𝑍 ∗ (3.3) Consequentially, with reference to the power triangle, real power (units in watts, W) is derived equation 3.4:
In equation 4.5, for a purely resistive load, real power can be simplified to:
In which, R denotes resistance (units in ohms, Ω) of the load
Reactive power (units in volts-amps-reactive, var) is derived as equation 3.6:
|𝑍| 2 𝑋 (3.6) For a purely reactive load, reactive power can be simplified to equation 3.7:
𝑋 (3.7) Equation 4.8 is the calculation of power factor from the following equation 3.8: cos 𝜑 = 𝑃
|𝑆| (3.8) The apparent power (units in volt-amps, VA) as equation 4.9:
Determining the Direction of Power Flow
Figure 3.7 Four quadrant power flow directions
Power factor correction techniques (PFC)
AC/DC current converters negatively impact the input power factor, particularly when using wireless current sensors for measurement The pulsating current wave generated can lead to inaccurate readings of the primary side circuit's current This low power factor issue not only affects AC/DC converters but also poses challenges for power supplies.
Passive power factor correction involves the use of an LC filter placed between the AC source and the diode rectifier, offering a straightforward solution; however, it tends to be bulky due to the large inductors and capacitors required, resulting in limited power factor improvement In contrast, active power factor correction employs active shaping of the input current to achieve near-unity power factor, utilizing Switch Mode Power Supply (SMPS) techniques These active PFC methods can be categorized into various classifications.
PWM converters, including buck, flyback, boost, buck-boost, and Cuk, each offer unique advantages and disadvantages for power factor correction when switched appropriately The Cuk converter is notable for providing continuous input current even in discontinuous conduction mode, and it can produce an output voltage that is either higher or lower than the instantaneous input voltage However, it also has drawbacks, such as the need for an additional inductor and capacitor, a lack of isolation, and increased stress on power devices.
(a) Resonance PFC in conversion stage (b) Soft-switching PFC in conversion stage
Figure 3.24 Two schematic circuits of PFC techniques
The resonant converter minimizes switching losses by shaping the voltage across a switch or the current through it to zero during turn-on or turn-off, utilizing the resonance of inductors and capacitors This design achieves a high power factor due to the inherent gain-boosting properties of the resonant converter However, it presents challenges such as increased voltage and current stress on the power switch compared to PWM mode, along with a variable switching frequency Despite these drawbacks, this method is still employed in certain applications to enhance power factor, as illustrated in the schematic design of the converter in Figure 3.24a.
The soft-switching power factor correction (PFC) technique integrates the benefits of PWM and resonant mode operations through a resonant network that includes a resonant inductor, resonant capacitor, and an auxiliary switch During most of the switching cycle, the AC/DC converter functions in PWM mode, while it transitions to resonant mode during the turn-on and turn-off intervals of the switch This approach enables the PFC circuit to maintain a constant switching frequency, allowing the power switch to operate under zero current or zero voltage conditions, which enhances both efficiency and power factor By employing zero-current-switching or zero-voltage-switching, the stress on switching components is minimized, leading to improved performance A basic schematic of the soft-switching circuit is illustrated in Figure 3.24b.
PFC is currently only available in applications where energy output ranges from several watts and above The primary reason for the limited use of PFC in low-energy converters is the adverse effect these converters have on line currents.
In our diploma project, we focus on the 53 and its associated equipment, where Power Factor Correction (PFC) techniques are primarily aimed at shaping the current According to measurements and simulations related to current transformation, the current waveform is primarily affected by the rectifier's forward voltage, leading to voltage waveform distortion However, since the voltage waveform is not a critical factor in our project, we have chosen not to implement PFC.
Network structure
At the outset of our project, there were no existing components for an energy data monitoring system Demonstrating the functionality of a sensor network requires careful consideration of network topology and wireless communication protocols, as they significantly impact power extraction levels and time synchronization capabilities This chapter delves into the importance of these elements in ensuring effective collaboration among sensors to deliver comprehensive insights into network currents.
This chapter presents a block diagram illustrating the structure of sensors, wireless communication, and networks To ensure accurate phase calculations, it is essential for all sensors to share a synchronized time reference Additionally, power consumption is a critical factor, as the output power of the current transformer (CT) is limited at low primary currents The network topology is explored in section 5.2, followed by a discussion of various communication protocols in section 5.3 With the chosen communication protocol and network topology, node synchronization is addressed, and two concepts are tested to validate effective synchronization in section 3.4.
Wireless Sensor Networks (WSN) can be organized in various configurations, each influencing power consumption, implementation costs, and data transmission capacity The choice of network structure significantly affects the power requirements and the volume of data that can be transmitted This section examines different network architectures, focusing on the gateway's location and the arrangement of nodes relative to it Subsequent sections will address the communication protocols among the network nodes Three specific structures are analyzed based on the gateway's positioning.
When considering a Wireless Sensor Network (WSN), one viable option is to utilize an existing location situated a few kilometers from the sensor nodes This integration can occur within established telecom networks like 3G and 4G, or through specialized networks designed specifically for wireless sensors, such as LoRaWAN.
Telecom networks are not inherently designed to support Wireless Sensor Networks (WSN), which require a specialized telecom chip with a unique identifier to function within these systems While telecom networks offer the advantage of high data rates and virtually unlimited data transfer capacity, they come with significant energy demands due to their high communication frequencies and long-distance capabilities.
To address the challenge of high energy demands while maintaining the ability to cover vast distances, specialized networks for Wireless Sensor Networks (WSN) have been introduced LoRaWAN, which operates based on location, is a low-power, long-range network that utilizes lower radio frequencies This protocol features reduced overhead and allows for limited data transmission, resulting in significantly lower power requirements for sensors operating within this network.
Figure 3.26 Network structure of LoRa network 3.3.4 Existing gateway nearby
To address the high energy demands caused by the distance between sensor nodes and gateways, a solution involves utilizing an existing gateway located near the sensor nodes Wi-Fi is a widely recognized and integrated network that allows wireless sensor nodes equipped with Wi-Fi transceivers to connect directly to the Internet through routers.
Wi-Fi technology, commonly found in nearly every building, offers the advantage of easy installation wherever a Wi-Fi connection is available However, it has notable drawbacks, including relatively high energy consumption primarily due to network overhead and the power demands of its frequency Additionally, communication and synchronization between sensor nodes are constrained by the limitations of the network technology.
One key benefit of this structure compared to LoRaWAN, SigFox, or traditional telecom networks is its enhanced capability to incorporate a concentrator, which facilitates the aggregation of data and enables advanced calculations.
Figure 3.27 Network structure with IP router 3.3.5 Custom gate way
A custom gateway designed specifically for current transformer sensors offers flexibility in placement and communication distance compared to existing gateways While implementing this application-specific gateway requires more effort, it allows for optimal positioning within a project The choice of communication type between the sensor and the gateway, as well as between the gateway and the Internet of Things (IoT), influences the gateway's location Additionally, longer links increase power requirements, necessitating a cost-benefit analysis regarding the communication method and gateway placement.
The connection between a gateway and a sensor offers flexibility in implementation, allowing for customizable data rates and volumes This adaptability is beneficial for managing the amount of data transmitted and the necessary power levels for communication Examples of low-power communication methods include sub-1 GHz communication, 6LoWPAN, and Zigbee.
This gateway enables the integration of measurements, allowing for the combination of current and voltage sensors By doing so, it provides valuable insights into power flow dynamics.
Figure 3.28 Network structure with custom gateway 3.3.6 Conclusion
This section evaluates various network structures based on critical factors such as required power level, implementation cost, and data rate A decision regarding the most suitable network structure is made following this analysis Table 3.1 presents a rating system where "–" indicates the worst rating, "++" signifies a very good rating, and "+/-" represents an average rating.
Network structure Power Cost Data rate
In our diploma project, electrical energy consumption is a crucial parameter, as it determines the minimum power level required for the current sensor to operate While information rate and cost are less critical in this context, the flexibility of the solution is essential Implementing a custom gateway nearby provides the necessary elasticity, allowing for the selection of the lowest power link and significantly expanding the operating range of the sensor.
Communication Protocol
UART is a type of serial communication a synchronous, UART is often used in industrial computers, communications, microcontrollers, or some other communication devices
The baud rate is essential for asynchronous communication between two modules, as it defines the time interval for transmitting and receiving a single bit Before data transmission begins, it is crucial to establish the baud rate, which indicates the number of bits sent per second.
To prevent data loss in serial communication, a frame is implemented from the outset to ensure reliable transmission This frame defines the number of bits transmitted, including essential components such as start bits, stop bits, parity check bits, and the total number of data bits.
Bit Start: This is the start bit in the frame This bit is to notify the device that the transmission starts on the AVR bit Start with a status of 0
Data: The data to be transmitted is not necessarily 8 bits, possibly 5, 6, 7, 8, 9
In the UART bit LSB is transmitted first, the MSB bit is transmitted later
Parity bit: is the data check bit
Parity can be classified into two types: even parity and odd parity Even parity involves adding a parity bit to ensure that the total number of 1 bits in the data plus the parity bit is even, while odd parity ensures that this total is odd The use of bit parity is optional, allowing for flexibility in its application.
Stop: is the transmission frame end report bit, usually 5V and may have 1 or 2 stop bits The diagram in Figure 3.29 shows data transmitted by UART
Figure 3.29 UART data transfer scheme 3.4.2 I2C (Inter-Integrated Circuit)
This is the bus communication between the ICs together I2C bus is used as an external communication bus for many different types of ICs such as 8051 Microcontroller, PIC, AVR, ARM
Figure 3.30 Bus I2C and external devices I2C communication characteristics:
The I2C interface operates using two wires: Serial Data (SDA) for bidirectional data transmission and Serial Clock (SCL) for synchronization When an external device connects to the I2C bus, its SDA pin links to the SDA wire, and the SCL pin connects to the SCL wire To facilitate proper communication, pull-up resistors are essential due to the open-drain or open-collector configuration of peripheral devices, with resistor values typically ranging from 1K to 4.7K, depending on the specific devices and interfaces used.
Operating mode (baud rate): The I2C bus can operate in three modes:
Transmitted bit sequence on line:
Figure 3.31 Transmitted bit sequence on line
Master device creates a start condition This condition notifies all devices that listen to data on the line
The primary device transmits the address of the secondary device it intends to communicate with, along with a write flag; if this flag is set to 1, the subsequent byte will contain the data to be written.
59 transmitted from the secondary device to the main device, if the flag is set to 0 the next byte is transmitted from the main device to the secondary device)
When the secondary device on the I2C bus has the correct address with the address sent by the main device, it will respond with an ACK pulse
Communication on the data bus initiates between the main and secondary devices, allowing both to either receive or transmit data based on the read or write operation The transmitter sends 8 bits of data to the receiver, which then acknowledges receipt with an ACK bit.
To end the communication process, main device creates a stop condition
In I2C bus communication, the START and STOP conditions are essential for establishing communication between devices The START condition indicates the beginning of the communication process, while the STOP condition signifies its conclusion.
Initially, both SDA and SCL lines are high, indicating that the I2C bus is free and ready for communication The essential conditions for communication between I2C devices are the START and STOP signals.
Figure 3.32 START and STOP conditions START condition: a state transition from high to low on the SDA line while the SCL line is high (high = 1; low = 0) signals a START condition
The STOP condition in I2C communication occurs when there is a transition from low to high on the SDA line while the SCL line is high Both START and STOP conditions are initiated by the main device Once the START signal is sent, the I2C bus enters a busy state, and it remains in this active mode until the main device issues a STOP signal, which indicates that the bus is now free and available for new communication.
In I2C communication, when a START condition is followed by a repeated START signal instead of a STOP signal, the bus remains busy Both START and repeated START signals serve the same purpose of initiating communication on the I2C bus.
Each clock pulse has one data bit to be transmitted The SDA signal level is only changed when the clock is low, and stable when the clock is high
Figure 3.33 I2C data transmission 3.4.3 SPI (Serial Peripheral Interface)
SPI, or Serial Peripheral Interface, is a duplex communication method that allows simultaneous transmission and reception of data It is referred to as a four-wire serial bus due to its four essential communication lines: SCK (Serial Clock), MISO (Master Input Slave Output), SS (Slave Select), and MOSI (Master Output Slave Input) As a synchronous interface, SPI synchronizes data transmission with a common clock signal generated by the master device Each of the four signal types plays a crucial role in facilitating effective communication between devices.
SCK (Serial Clock): Signal transmission for slave device
SS (Slave Select): Select Slave to communicate
MISO (Master Input / Slave Output): master side input, slave side output, for data transmission from slave device to master device
MOSI (Master Output / Slave Input): master side output, passive side input, for data transmission from master device to slave device
Figure 3.34 Basic SPI bus example 3.4.4 Wi-Fi
Wi-Fi, short for Wireless Fidelity, refers to a wireless network based on the 802.11 standard that utilizes radio waves to transmit data, similar to cell phones, televisions, and radios This technology enables internet access in various locations without the need for physical cables, providing convenience and flexibility for users.
Wi-Fi technology utilizes radio waves, akin to those employed by handheld devices and mobile phones, to facilitate wireless communication It effectively transmits and receives these radio waves, converting binary codes of 1s and 0s into radio signals and back again.
However, Wi-Fi have some differences from other radio waves in that: they transmit signals at the frequency of 2.5 GHz or 5 GHz This frequency is higher than
61 the frequencies used for mobile phones, handheld devices and televisions Higher frequencies allow the signal to carry more data
This section evaluates various communication protocols, considering key factors such as required power levels, data rates, and ease of implementation After thorough analysis, we have selected the Wi-Fi connection protocol as the optimal choice for our project, which will be carefully implemented in the subsequent chapter.