element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Start a Movement Challenge
  • Challenges & Projects
  • Design Challenges
  • Start a Movement Challenge
  • More
  • Cancel
Start a Movement Challenge
Forum AVR Part 1 - The Concept
  • Blog
  • Forum
  • Projects
  • DC
  • Leaderboard
  • Files
  • Members
  • More
  • Cancel
  • New
Join Start a Movement Challenge to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • Replies 9 replies
  • Subscribers 45 subscribers
  • Views 634 views
  • Users 0 members are here
  • design challenge
  • avr
  • power
  • start a movement
Related

AVR Part 1 - The Concept

Gough Lui
Gough Lui 8 months ago

Welcome to my first project post. My project is called "AVR" and that's not named after the 8-bit microcontroller!

Why "Start a Movement"?

I decided to participate in this design challenge for a few reasons. The first was simply because it looked interesting as it involved stepper motors, something I've always wanted to employ in my own projects but never had the chance to. Such motors are great for making precise movements, being the driving force (quite literally) behind the positioning of heads in early hard drives and floppy drives, through to your humble dot-matrix printer, some CNC milling machines and even modern 3D printers. They're definitely something which can be very useful for open-loop control as well, saving the complexity of feedback control.

The next reason was simply because there seemed to be a few calls for competitors, suggesting there was a good chance to snag a kit. The prizes looked good too - I'm a big fan of eMobility solutions and I think they're a vital part of a decarbonised future.

But perhaps most importantly, I had a problem that I wanted to solve inexpensively. This is one that has been bugging me for many years and is something that you could theoretically buy your way out of, given enough money. But I didn't have that kind of money to spare.

The Problem and Concept

If you want a regulated DC power supply, you'd just grab a lab benchtop power supply or a plug-pack or perhaps even USB/USB-C PD and you'd be set. This is such a bread-and-butter requirement that we have a bread-and-butter solution to it.

But if you want a regulated AC mains power supply, then that's a whole different kettle of fish. Your wall-socket nominal 115/230V is never quite exactly that, as loads inside the house and loads along your street can change the voltage at any time. This is simply down to how resistance in the transmission lines cause voltage drop as a function of current flow (ohms law). Aside from that, the distribution network often has tap changing transformers which can boost or buck by fixed ratios to try and bring the voltages within a band, as loads can change significantly throughout the day. For example, this is a graph I previously made of line voltage in my house across a 24 hour period:

image

What is nominally 230V has quite a spread. But when testing certain sorts of appliances, the voltage has a direct bearing on energy consumption, so testing with a voltage that varies would be unfair. The IEC62301 standard that has to do with standby energy qualification, for example, sets stringent voltage requirements of +/-1% of nominal for accurate testing. As a result, ordinary mains power simply cannot do (and it likely can't for other reasons, including crest factor, but we can't do much about that in this challenge).

So, I called this project "AVR", short for "Automatic Voltage Regulator". The idea would be that by taking an autotransformer (e.g. a Variac) that allows for nearly-continuous output voltage control and connecting its mechanical input shaft in such a way that it can be computer controlled, we could "close the loop" on the system by using the readings from a power analyser (e.g. the Tektronix PA1000 I previously RoadTested) in order to counteract slow mains voltage movements (e.g. up to 2 adjustments per second) and keep the output voltage within a set band, hopefully rapid enough to take out most of the influence of grid voltage variation). This is not going to help if the mains voltage has a "step" change (e.g. due to tap changer operation) but the closer to the target voltage it is, the less likely such disturbances will push the output voltage out of band. In essence, we'd be trying to keep the voltage at the set-point all the time, similar to how someone would move around to keep a basketball balanced on their finger. It probably won't be able to guarantee a +/- 1% result, but it should mean that I can run my longer mains-powered appliance tests more comfortably with less "noise" in the readings.

For this, we need a Variac and thankfully, I have not one but two small ones. The one I will be using for this challenge is a Yamabishi Electric (Japanese) unit I wrote about here: A Shocking Variac Made a Little Less Shocking! 

image

My plan would be to take the knob off of the unit, design a 3D printed coupling that might take a trio of M3 screws as grub screws on both sides to couple the shafts together, all with an adapter plate that keeps the alignment of the motor and Variac body constant. Then, using the provided driver and evaluation board, I'd figure out how to get it hooked up to the computer, under computer control (USB would be fine) whereby a script could then poll my PA1000 power analyser and set appropriate adjustments on the Variac, making decisions at every step as to whether to move it or not (as the carbon brush is something that will wear down quickly if excessive unnecessary adjustments are made).

You might be thinking "Well, hold on a minute. Don't those newfangled UPSes have AVRs in them?" and you'd be right. Many line-interactive UPSes advertise the presence of AVR functionality. However, their form of AVR is made with discrete windings on a transformer, thus allowing you to "boost" or "buck" the input by a fixed percentage increment, usually something between 5-10%, causing a massive jump every time it happens. For precision AC applications, this is not ideal.

Another thought may be "Why not just use a DC to AC true sine-wave inverter as a source? They're stable, right?" and this is something I'm already doing. However, what they don't tell you is that the inverters have some higher frequency harmonic content and insufficient regulation to deal with high crest-factor loads which leads to noticeable load-modulation of the voltage. Another issue I'm also finding is that the voltages from such inverters also jump, due to temperature changes within the board and compensation for that, which are a pain whenever the inverter is not on a constant load (as every heat-up and cool-down cycle, especially with thermostatic fan) results in a voltage jump. They also seem to have an offset from the factory (230V nominal is often measured at 233V or 235V) which necessitates trimming and their limited reactive power capabilities seem to cause my power analyser to give very inaccurate power-factor readings.

Getting nice, regulated, powerful AC is something that, ideally, you should be using a synthetic mains AC source (such as these behemoths from GWInstek or Keysight) for. My pockets aren't quite so deep though ... so I'm going to try and be clever.

Conclusion

In this post, I've summarised my motivations for "starting a movement" and the project I intend to build. The whole concept of the "AVR" is to regulate mains AC voltage by allowing a mechanical autotransformer to be computer-controlled, which, when paired with a power analyser can allow for "closing the loop" forming a feedback control system that can serve to regulate the output voltage to a load within a set band on a nearly continuous basis without the jumps ordinarily associated with UPS-based AVR systems.

In the next posting, I'll be unboxing the kit and looking at its components.

P.S.

I'd like to apologise as this is an exceptionally late start to a design challenge and one that I am feeling like I am unlikely to complete. It has been about a month that I've been battling a sudden decline in my health, losing most of my central vision in one eye and losing mobility with one or both of my ankles on an on-and-off basis suffering from severe pain. This makes it a literal pain to do almost anything and really sapped away some of my motivation. Concurrently with this design challenge, I had also a period of triple-concurrent RoadTests (of which two still are in-progress), which put immense strain on the time and energy I had left.

I'm not looking for sympathy - just hoping to ensure that the community is not left empty-handed and to show that I've decided to give it a go nonetheless. While I will recover in time, it is not expected to be a quick road to recovery, expecting to take six or so months. As a result, I am intending to curtail future involvement in element14 programs until I am confident of my ability to deliver, as some of this is stress-related (likely imposed from both work and hobby). In the meantime, best of luck to my fellow challengers and I would appreciate if you would support their efforts.

  • Sign in to reply
  • Cancel

Top Replies

  • kmikemoo
    kmikemoo 8 months ago +2
    Gough Lui First, I'm sorry to hear of your health struggles. I hope they pass more quickly than you anticipate and that you can get back to being you. I love the project vision. When I see or hear "AVR…
  • Gough Lui
    Gough Lui 8 months ago in reply to dougw +2
    An excellent question, dougw . In terms of voltage variations, we get a mix. Fast changes usually occur with localised large load changes - e.g. turning on a 2kW kettle will certainly cause a volt or…
  • dougw
    dougw 8 months ago +1
    That is sad news, I wish you a speedy recovery. It sounds pretty painful and frustrating not to mention scary. Interesting project idea by the way - I hope to see it work. Do you see sudden fluctuations…
  • kmikemoo
    kmikemoo 8 months ago

    Gough Lui First, I'm sorry to hear of your health struggles.  I hope they pass more quickly than you anticipate and that you can get back to being you.

    I love the project vision.  When I see or hear "AVR", I only think of a voltage regulator.  I think the plan is super cool and I wish you great success in completion - whenever it might happen.

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Cancel
  • dougw
    dougw 8 months ago

    That is sad news, I wish you a speedy recovery. It sounds pretty painful and frustrating not to mention scary.

    Interesting project idea by the way - I hope to see it work.

    Do you see sudden fluctuations in AC voltage or are they  slow enough for the motor to keep up?

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • Gough Lui
    Gough Lui 8 months ago in reply to dougw

    An excellent question, dougw .

    In terms of voltage variations, we get a mix. Fast changes usually occur with localised large load changes - e.g. turning on a 2kW kettle will certainly cause a volt or two of drop. It helps that my grid impedance doesn't seem too high, being on an underground-wired circuit of relatively modern (20-30 year old) construction.

    But much of my bigger changes are longer timescale changes. Some of the "swells" in voltage I get have simply to do with the penetration of grid-connected PV in the area. When the sun shines brightly and the clouds shuffle out of the way, the voltage can swing 3-5 volts in rough time with the clouds. Cloud edges and soft and panels are distributed, so this isn't likely to be something a periodic "bump" here and there can't fix. For neighbouring loads, e.g. air conditioners, being in a more modern area, it seems most people have inverter air conditioners and so even that is likely to ramp up and down rather than just cut-in. Plus, you have the statistical benefit of seeing the superposition of everyone in the neighbourhood's load changing plus any corrective equipment (e.g. tap changers) reacting, plus an effect that depends on where along a feeder you are connected.

    Perhaps this is a question most easily answered by observing the mains directly ... back in 2018, I did just that: https://goughlui.com/2018/05/26/analysis-mains-power-quality-voltage-frequency-crest-factor-10-19-may-2018/

    image

    It's not an ideal scale (24 hours across the bottom), but the grid voltage mostly stays within a volt until any perturbation occurs, when a two or three volt change is common, and a peak change of up to 12 volts could be a possibility (but very rare). This is with a normal household usage too, but you can see there were days where the voltage was a bit low, and other days where it was a bit high. But this was taken before the explosion of grid-connected PV systems in my area - recent power bill price hikes have seen most houses outfit a 5-10kWp system.

    - Gough

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Cancel
  • Gough Lui
    Gough Lui 8 months ago in reply to kmikemoo

    Interesting to hear you are familiar with the term "AVR" kmikemoo . I hope that doesn't mean you've had to fight power quality issues in your past :).

    Thanks for the well wishes ... I'll try and keep the project rolling as best as I can, in part, quite literally as I have to roll around in a chair just to get anything done.

    - Gough

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • colporteur
    colporteur 8 months ago

    GL I do hope you health improves. I look forward to your posts as a source for learning.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • kmikemoo
    kmikemoo 8 months ago in reply to Gough Lui

    Gough Lui I work with generators.  As you can imagine, an AVR is a pretty critical component.

    I also fight power quality issues. With a generator being a limited power source, it cannot absorb all the "stuff" that the infinite grid is expected to absorb.  Leading power factors, high harmonic content, and those power factor correcting (switching) UPS's that you mentioned.  All create problems as their effects are quite pronounced on the smaller capacity system.

    I worked on one system (many years ago) that had a UPS that used switching power factor correction.  Unfortunately, it was ON/OFF.  No bandwidth on the threshold.  No hysteresis.  When the UPS powered the load, the voltage would dip and the pf correction would kick in.  Then the voltage was correct and the pf correction would drop out.  Back and forth.  Over and over again.  The load change was enough that you could hear a tone change in the engine when they ran on generator - ergo why we got called.  I believe that a firmware upgrade corrected the issue.  Our solution in the interim was to put more resistive load on the circuit and get beyond that tipping point.  I think it was as simple as leaving the server room lights on.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • javagoza
    javagoza 8 months ago

    I'm so sorry to hear about your health challenges. Wishing you the best.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • taifur
    taifur 8 months ago

    Sorry to hear about your health problem. Hope you will recover soon. 

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • DAB
    DAB 8 months ago

    I hope you have a speedy and complete recovery.

    Being disabled I understand how frustrating it can be to have your capabilities diminished by chronic pain.

    Hopefully things will improve.

    I greatly enjoy your work and blogs.

    Get well soon. 

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube