Skip to content
View in the app

A better way to browse. Learn more.

Power Forum - Renewable Energy Discussion

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

HedgeSlammer

Members
  • Joined

  • Last visited

Reputation Activity

  1. Like
    HedgeSlammer got a reaction from BobA in Import Meter Pulse Reader (for InfluxDB)   
    Background: 
    I have certain 'trust issues' when it comes to utility supply companies.  Whether it was 'Good Energy', who helped themselves to £3,000 from my bank account in the week my first child was born (they apparently transposed two digits on a meter read), or the corporate behemoth 'Octopus Energy', who in the 18 months I was with them (and since) never once managed to produce a bill that reflected the tariff or rates that I was supposedly on, or any number of sh*t-weasels in between, I don't know.  Suffice to say, they all rank somewhere beneath Estate Agents in my book.
    So I like to keep tabs on my energy consumption.
    We have a 'SMETS2' Smart Meter (Landis + Gyr E470) on a dual-rate tariff.  Supposedly, this meter transmits usage data (over the 3G network) to the supply company (via the DCC, or 'Data Collection Company') and it can communicate over the HAN (home area network) with a display unit, to give the customer real-time information on consumption, daily totals, costs etc.
    In practice, though, forget it.  Even if they did eventually send me the display device, the data is only available via the display screen.  There are other (expensive) ways of obtaining the data that require a third-party company/device, but not for me.  I suspect it's only half-hourly logging, anyway.
    The only useful information that I can get from the meter itself are the two kWh (import) registers - visible on a tiny LCD panel, and accessible through an undocumented, utterly convoluted and unmemorable series of ninja key presses on the two buttons, plus a solitary blinking red LED that blinks once per Wh imported.  Smart, huh?
     
    So, I built a device to count the pulses with a 3DU5C Phototransistor, using a L239 comparator to clean the signal and send it on to an ESP8266 (I used a wemos D1 mini, as it's what I had).  It's largely based on this project, but adapted for my needs (influxdb).

    The D1 mini connects to my wifi network and every minute logs the number of pulses it's seen since the last successful database write.
    It also calculates the current Wattage (simply by multiplying the duration between pulses - (1000 / pulseDuration) * 3600.  It also writes to a 'night' db table when the rate changes, then a 'day' table when it changes back - the actual switching of rates I opted to do via a single UDP packet sent from a 'node-red' instance elsewhere, to avoid having to do any time keeping or NTP synchronisation on the device itself (I wouldn't want to risk missing any pulses).
    I found the pulses from my particular meter to be around 23ms long, so adjusted the MIN / MAX in the code accordingly.
    Naturally, there is an LED, which changes state whenever a pulse is detected.  All housed in my trademark little grey plastic 3D printed box and clipped to the front of the meter (you can just use blu-tac, if you can remember where you put it) and powered via the micro-USB on the D1 mini.

    Viewed in Grafana, I can select any period of time and sum the number of pulses to get a fairly accurate idea of consumption over that period, enabling me to very quickly check my bills.  I've also hard-coded in (to the Grafana dashboard) my tariff rates and standing charge -  It also writes a '1' to a separate db table every night when the rate changes, to enable easy calculation of the daily standing charge.

    You can just about see above that at around 4.45am, my router rebooted (so communication with the db failed for about 90 secs), but the pulse reader just kept totting up the pulses until the db came back online, hence the thin spike.
    I hope this is useful for someone, or if not, at least interesting. 🙂
    The code (I use 'Platformio') including libs is attached:
     
    Pulse Meter v0.05.zip
  2. Like
    HedgeSlammer got a reaction from Youda in Large 'Retro' Power System Display   
    Vital to being able to keep within the inverter output limits (and avoid importing expensive grid power unnecessarily) is having the means to display the relevant information in an immediate and accessible way.
    That's what I told my wife, anyway.  Really, I'd just scored a bunch of old RC servos on ebay for £5 and I wanted to play with them. 😉

     
    In context:

     
    It uses 6 servos, a Wemos d1 mini clone and a tri-colour LED.  Dial faces are 3D printed, with a filament change from white to black (which turned out much better than I imagined, TBH).
    The servos only had around 90° of sweep angle, so I 3D printed some little holder/gearbox things to get over 180° and provide a shaft for the needle to go on, plus some 'steampunk' needles.


     
    All run buy the obligatory D1 mini and held together using the very latest in 'twist and tape' technology.

     
    Yee-haw! 🤠
    It gets fed the data from 'node-red' running on a Victron CerboGX via UDP packets over WiFi, updating as often as the data changes (approx 3 second intervals).  The LED changes colour according to state, so 'All OK' is green, 'You're getting very close to/exceeding the inverter output limit, so if you don't want to pay for grid, don't turn anything else on' is red, then blue for 'dumping power into the hot water tank'.
    It's by no means silent in operation.  I originally made a single-servo version for just PV generation and coded it so that the meter movements were gradual (a kind of PID to get from one value to the next), but apparently it 'sounded like we have cockroaches' when it made it's ticky-scratchy transitions between values, so the big version just jumps between values with a 'zzziiiiiup!' sound.
    It's actually quite reassuring to have an audible indication when the sun comes out for 5 seconds, or it starts charging at night.
    I'd also put a little radar sensor in there, with the aim of having it detect when there was nobody around, so it could stop displaying to save power/noise.  Unfortunately, that meant that every time you entered the room, all 6 needles would suddenly move at the same time, making you jump out of your skin and spill your horlicks, so we just leave it 'on' all the time now.
    There's also a basic web UI, so you can see the same data on your phone or whatever, plus it's useful for troubleshooting:

     
    I had fun and learned loads making it - and now it's become a family game to try to cook dinner without making the red light come on. 🙂
     
    Libraries used are 'ESPUI' and 'servo', plus 'arduinoOTA'.  Code, FreeCad file for the gearbox & stl file for the arrow-head needle are all in the attached zip.
    Power_meters_v2..zip
  3. Like
    HedgeSlammer got a reaction from WannabeSolarSparky in Victron and Lithium   
    Yes.  🙂   But it depends on the BMS and you'll need an interface of some sort...
     
  4. Like
    HedgeSlammer got a reaction from zsde in Large 'Retro' Power System Display   
    How's your one coming along, @WannabeSolarSparky?
    I've got mine up on the wall... 😎

    Here's a video (note the 'fake PV' data injection, then SOC plus inverter load to demonstrate - I'm fighting the real data as it comes in, so it jumps around a bit, but you get the idea).
    I used the '144 LEDs per metre' WS2813 strip for the legs, battery, inverter and house, with 60 lpm WS2812 for the sun and pylon.  I'd made the legs to take 10mm wide strip, but the 144 was 12mm wide so I had to trim a mil off the power tracks on each side - luckily they were generous with the tracks, so I got away with it for such short runs.
    Getting it to bend around in nice curves and stay flat was a right pain, as the LEDs are less than 2mm apart, but it worked out in the end.  Basically, by folding it back on itself, squeezing one side sharp and then flattening it back out whilst bending it into a curve with the sharp crease on the inside of the curve.  It's best to completely remove the stick tape first, though.
    I didn't fill any/everything with hot glue (as a diffuser) as originally planned as it looks OK without it, plus it's too easy to lose the shape of the parts when they're heated.
    The code still needs a bit of fine tuning, plus there are a few oddities with the FastLED lib that need addressing (like the LEDs in the 'arms' don't go completely off when they should).
    I'll post the code / stl files once it's sanitised. 🤪
  5. Like
    HedgeSlammer got a reaction from Amit Bajpayee in Large 'Retro' Power System Display   
    Vital to being able to keep within the inverter output limits (and avoid importing expensive grid power unnecessarily) is having the means to display the relevant information in an immediate and accessible way.
    That's what I told my wife, anyway.  Really, I'd just scored a bunch of old RC servos on ebay for £5 and I wanted to play with them. 😉

     
    In context:

     
    It uses 6 servos, a Wemos d1 mini clone and a tri-colour LED.  Dial faces are 3D printed, with a filament change from white to black (which turned out much better than I imagined, TBH).
    The servos only had around 90° of sweep angle, so I 3D printed some little holder/gearbox things to get over 180° and provide a shaft for the needle to go on, plus some 'steampunk' needles.


     
    All run buy the obligatory D1 mini and held together using the very latest in 'twist and tape' technology.

     
    Yee-haw! 🤠
    It gets fed the data from 'node-red' running on a Victron CerboGX via UDP packets over WiFi, updating as often as the data changes (approx 3 second intervals).  The LED changes colour according to state, so 'All OK' is green, 'You're getting very close to/exceeding the inverter output limit, so if you don't want to pay for grid, don't turn anything else on' is red, then blue for 'dumping power into the hot water tank'.
    It's by no means silent in operation.  I originally made a single-servo version for just PV generation and coded it so that the meter movements were gradual (a kind of PID to get from one value to the next), but apparently it 'sounded like we have cockroaches' when it made it's ticky-scratchy transitions between values, so the big version just jumps between values with a 'zzziiiiiup!' sound.
    It's actually quite reassuring to have an audible indication when the sun comes out for 5 seconds, or it starts charging at night.
    I'd also put a little radar sensor in there, with the aim of having it detect when there was nobody around, so it could stop displaying to save power/noise.  Unfortunately, that meant that every time you entered the room, all 6 needles would suddenly move at the same time, making you jump out of your skin and spill your horlicks, so we just leave it 'on' all the time now.
    There's also a basic web UI, so you can see the same data on your phone or whatever, plus it's useful for troubleshooting:

     
    I had fun and learned loads making it - and now it's become a family game to try to cook dinner without making the red light come on. 🙂
     
    Libraries used are 'ESPUI' and 'servo', plus 'arduinoOTA'.  Code, FreeCad file for the gearbox & stl file for the arrow-head needle are all in the attached zip.
    Power_meters_v2..zip
  6. Haha
    Sorry, I didn't ever retry the CH340 with Win 11 after I got the PL2303 working.  I'd offer to test it, but I'd rather remove my own eyes with a spoon than look at Win 11 / .NET ever again.  😬
  7. Like
    HedgeSlammer reacted to Moffat in Large 'Retro' Power System Display   
    Food for thought on the original.
     

  8. Thanks
    HedgeSlammer got a reaction from fega in Youda's off-grid LAB   
    Regarding the Pylontech firmware...  First up, thanks for this thread.  It is without doubt the most useful resource on the internet relating to the issues discussed.
    So... I had the issue with the Victron GX + <v1.7 f/w on a couple of my US3000Cs - the misreporting of a voltage spike in one cell causing the Victron GX to panic and shut that battery down.
    I emailed Pylontech with a plot of the Vhigh readings (it would shoot to 4.1v for one reading, then back down again).  They responded very promptly (on a Sunday night, too) with a link to download a zip containing 'BatteryView 3.0.33' and a firmware zip file named 'USC_st2.8+NT2.2.zip', contained two binaries named 'US_E2_V2.2_Crc.bin' and 'US_C_V2.8_Crc.bin'.  Good so far.
    Then the real fun started...
    Couldn't get 'BatteryView' to connect, despite no problems accessing the serial terminal and getting appropriate responses from the batteries.
    Tried 'Batteryview' under wine/mono in Linux Mint 21, build a Windows 10 VM, fully updated it, installed Win 10 natively, updated that, .NET 4.8.1, tried every combination of v 3.0.28 through 3.0.33, 3 different USB/RS232 interfaces...  Wouldn't connect, but terminal was fine.
    Eventually did a native install of Win 11, same deal... Updated that (which took the best part of a day on a 40Mb/s fibre line) and finally, finally 'BatteryView' connected.  Downloaded all the 'history' and 'event' data, went to update the firmware on the first battery (according to the instructions provided by Pylontech, using the zip file) and...   it threw an 'unknown exception' error and just quit. 😭
    OK.
    Took a step back, sat down with a cup of tea and thought 'lets have a look at this firmware zip file'.  The one that 'thou shalt not unzip, least ye bricketh the unit'.  Re-read this thread, then thought that if I can work out which of the two bin files, maybe try that?  I mean, who's gonna know, right?
    And lo, it came to pass that I could not unzippeth.  Because the %&*$!£ zip-within-the-zip was corrupt.  Re-downloaded from the source (wetransfer.com), same.
    Came back here and grabbed the v1.8 zip, all 7 units are now updated fine. 🥳
     
    So basically, a massive 'Thank You' to Youda and all who have contributed to this thread.  I hope the above contribution to it might prove useful to someone else facing similar issues.
    Now I can hopefully sleep easy, or at least sleep without VRM waking me up with an email at 3.23am to inform me in panicked, breathless tones of some expensive-sounding 'internal failure' or 'cell imbalance' in battery 7 that means you have to get up and shuffle downstairs to silence the beep-of-doom and check that nothing's actually on fire. 🙂
  9. Like
    HedgeSlammer got a reaction from CobusK in Large 'Retro' Power System Display   
    Vital to being able to keep within the inverter output limits (and avoid importing expensive grid power unnecessarily) is having the means to display the relevant information in an immediate and accessible way.
    That's what I told my wife, anyway.  Really, I'd just scored a bunch of old RC servos on ebay for £5 and I wanted to play with them. 😉

     
    In context:

     
    It uses 6 servos, a Wemos d1 mini clone and a tri-colour LED.  Dial faces are 3D printed, with a filament change from white to black (which turned out much better than I imagined, TBH).
    The servos only had around 90° of sweep angle, so I 3D printed some little holder/gearbox things to get over 180° and provide a shaft for the needle to go on, plus some 'steampunk' needles.


     
    All run buy the obligatory D1 mini and held together using the very latest in 'twist and tape' technology.

     
    Yee-haw! 🤠
    It gets fed the data from 'node-red' running on a Victron CerboGX via UDP packets over WiFi, updating as often as the data changes (approx 3 second intervals).  The LED changes colour according to state, so 'All OK' is green, 'You're getting very close to/exceeding the inverter output limit, so if you don't want to pay for grid, don't turn anything else on' is red, then blue for 'dumping power into the hot water tank'.
    It's by no means silent in operation.  I originally made a single-servo version for just PV generation and coded it so that the meter movements were gradual (a kind of PID to get from one value to the next), but apparently it 'sounded like we have cockroaches' when it made it's ticky-scratchy transitions between values, so the big version just jumps between values with a 'zzziiiiiup!' sound.
    It's actually quite reassuring to have an audible indication when the sun comes out for 5 seconds, or it starts charging at night.
    I'd also put a little radar sensor in there, with the aim of having it detect when there was nobody around, so it could stop displaying to save power/noise.  Unfortunately, that meant that every time you entered the room, all 6 needles would suddenly move at the same time, making you jump out of your skin and spill your horlicks, so we just leave it 'on' all the time now.
    There's also a basic web UI, so you can see the same data on your phone or whatever, plus it's useful for troubleshooting:

     
    I had fun and learned loads making it - and now it's become a family game to try to cook dinner without making the red light come on. 🙂
     
    Libraries used are 'ESPUI' and 'servo', plus 'arduinoOTA'.  Code, FreeCad file for the gearbox & stl file for the arrow-head needle are all in the attached zip.
    Power_meters_v2..zip
  10. Like
    HedgeSlammer got a reaction from CobusK in Large 'Retro' Power System Display   
    Cheers!  I'm just glad it amuses someone else, too.
    Video (with 'Ziiiiurp!'), as requested:
    Booting up: https://sendvid.com/in7wrlwm
    'Test' mode: https://sendvid.com/v0ax5cka
    Kettle on: https://sendvid.com/evb63wvq
    Charging from grid: https://sendvid.com/q79l236l
    Yep, we had an old Android tablet stuck to the wall for a while (OK, so it's still there) with the 'Victron Remote Console' displayed, then a Grafana dashboard.  The thing just kept turning itself off after a while (no matter what I did), so it was never on when you looked at it.
    Then I made this rough-as-rats LED meter to display SOC:

    But it's pretty ugly... I figured that six of them would be (at least) six times as ugly.
    Like I said, I got pretty lucky with the RC servos - despite some of them being different makes, hence the slightly differing arcs of travel seen in the videos... also, making the 23-toothed internal splined bit of the bigger gear was a challenge... but you can get the smaller servos for a couple of GBP each and they would do the job, I reckon.  The first (single servo, no gears [so only 90°] PV generation) meter I made just had a cable tie end as the needle.  But if anyone wants a crack at making something similar, I'm happy to help where I can.  I've attached a zip below with all of the .stl files (for 3D printing), including a 'drilling template' to help get the holes in the face in the right place.
    I've an idea for my next project (visualisation again)...
    Basically, a hardware rendition of the 'animated power flow lines' as displayed on some inverter front panels, the Victron VRM/Remote Console and @slipxs' beautiful Home Assistant cards.
    Using an ESP8266 (or 32) to drive a ton of 74HC595N 8-bit shift registers to light LEDs in sequence, with the speed/direction/intensity(maybe?) proportional to the live system data.  The thing I'm stuck on is how to make it NOT look like that LED stick above...  I tried some of that twin-wall extruded PVC shower panel material (it's like a bunch of square tubes next to each other), then only poking the LEDs through one wall, but the light leaks too much.  I thought about clear PVC tube (for that 'Buck Rogers' vibe), but too many wires unless I manage to stuff the shift register chips in there, too.
    I'll find something, though. I always do. 🤔
     
    Oh, yes!  It goes really well with a dash of Brandy... so well that you can get away with buying the cheap stuff. 😉
    Power_meters_v2_All_STL_Files.zip
  11. Like
    HedgeSlammer got a reaction from tgrove69 in Large 'Retro' Power System Display   
    Vital to being able to keep within the inverter output limits (and avoid importing expensive grid power unnecessarily) is having the means to display the relevant information in an immediate and accessible way.
    That's what I told my wife, anyway.  Really, I'd just scored a bunch of old RC servos on ebay for £5 and I wanted to play with them. 😉

     
    In context:

     
    It uses 6 servos, a Wemos d1 mini clone and a tri-colour LED.  Dial faces are 3D printed, with a filament change from white to black (which turned out much better than I imagined, TBH).
    The servos only had around 90° of sweep angle, so I 3D printed some little holder/gearbox things to get over 180° and provide a shaft for the needle to go on, plus some 'steampunk' needles.


     
    All run buy the obligatory D1 mini and held together using the very latest in 'twist and tape' technology.

     
    Yee-haw! 🤠
    It gets fed the data from 'node-red' running on a Victron CerboGX via UDP packets over WiFi, updating as often as the data changes (approx 3 second intervals).  The LED changes colour according to state, so 'All OK' is green, 'You're getting very close to/exceeding the inverter output limit, so if you don't want to pay for grid, don't turn anything else on' is red, then blue for 'dumping power into the hot water tank'.
    It's by no means silent in operation.  I originally made a single-servo version for just PV generation and coded it so that the meter movements were gradual (a kind of PID to get from one value to the next), but apparently it 'sounded like we have cockroaches' when it made it's ticky-scratchy transitions between values, so the big version just jumps between values with a 'zzziiiiiup!' sound.
    It's actually quite reassuring to have an audible indication when the sun comes out for 5 seconds, or it starts charging at night.
    I'd also put a little radar sensor in there, with the aim of having it detect when there was nobody around, so it could stop displaying to save power/noise.  Unfortunately, that meant that every time you entered the room, all 6 needles would suddenly move at the same time, making you jump out of your skin and spill your horlicks, so we just leave it 'on' all the time now.
    There's also a basic web UI, so you can see the same data on your phone or whatever, plus it's useful for troubleshooting:

     
    I had fun and learned loads making it - and now it's become a family game to try to cook dinner without making the red light come on. 🙂
     
    Libraries used are 'ESPUI' and 'servo', plus 'arduinoOTA'.  Code, FreeCad file for the gearbox & stl file for the arrow-head needle are all in the attached zip.
    Power_meters_v2..zip
  12. Like
    HedgeSlammer got a reaction from Hannesvz in Large 'Retro' Power System Display   
    Vital to being able to keep within the inverter output limits (and avoid importing expensive grid power unnecessarily) is having the means to display the relevant information in an immediate and accessible way.
    That's what I told my wife, anyway.  Really, I'd just scored a bunch of old RC servos on ebay for £5 and I wanted to play with them. 😉

     
    In context:

     
    It uses 6 servos, a Wemos d1 mini clone and a tri-colour LED.  Dial faces are 3D printed, with a filament change from white to black (which turned out much better than I imagined, TBH).
    The servos only had around 90° of sweep angle, so I 3D printed some little holder/gearbox things to get over 180° and provide a shaft for the needle to go on, plus some 'steampunk' needles.


     
    All run buy the obligatory D1 mini and held together using the very latest in 'twist and tape' technology.

     
    Yee-haw! 🤠
    It gets fed the data from 'node-red' running on a Victron CerboGX via UDP packets over WiFi, updating as often as the data changes (approx 3 second intervals).  The LED changes colour according to state, so 'All OK' is green, 'You're getting very close to/exceeding the inverter output limit, so if you don't want to pay for grid, don't turn anything else on' is red, then blue for 'dumping power into the hot water tank'.
    It's by no means silent in operation.  I originally made a single-servo version for just PV generation and coded it so that the meter movements were gradual (a kind of PID to get from one value to the next), but apparently it 'sounded like we have cockroaches' when it made it's ticky-scratchy transitions between values, so the big version just jumps between values with a 'zzziiiiiup!' sound.
    It's actually quite reassuring to have an audible indication when the sun comes out for 5 seconds, or it starts charging at night.
    I'd also put a little radar sensor in there, with the aim of having it detect when there was nobody around, so it could stop displaying to save power/noise.  Unfortunately, that meant that every time you entered the room, all 6 needles would suddenly move at the same time, making you jump out of your skin and spill your horlicks, so we just leave it 'on' all the time now.
    There's also a basic web UI, so you can see the same data on your phone or whatever, plus it's useful for troubleshooting:

     
    I had fun and learned loads making it - and now it's become a family game to try to cook dinner without making the red light come on. 🙂
     
    Libraries used are 'ESPUI' and 'servo', plus 'arduinoOTA'.  Code, FreeCad file for the gearbox & stl file for the arrow-head needle are all in the attached zip.
    Power_meters_v2..zip
  13. Like
    HedgeSlammer got a reaction from WannabeSolarSparky in Large 'Retro' Power System Display   
    Ah, yep... I had that problem, too.  I got away with a 2A PSU and a 3300uF cap, but also I think in the code I might have made each needle move in turn (rather than more than one at the same time) - although in the 'test' mode they do all move at once, seemingly without the ESP8266 going nuts. 🤔
    I've definitely found the ESP32 can be a bit more fussy (than the 8266) about voltage dips and noise.
  14. Thanks
    HedgeSlammer reacted to WannabeSolarSparky in Large 'Retro' Power System Display   
    Nice, the video shows nicely how your diffusers work, job well done Great job on how the levels show as well
  15. Like
    HedgeSlammer reacted to WannabeSolarSparky in Large 'Retro' Power System Display   
    This is as far as I got last week...
    Managed to get all 10 servo's running nicely after I upgraded to a bigger power supply, seems like those tiny servo's want plenty amps to work correctly 🤣
    I had a smaller 3amp converter and had the servo's jittering like crazy, now have a decent 6amp one and a nice beefy cap to smooth out everything.

  16. Like
    HedgeSlammer got a reaction from jumper in Large 'Retro' Power System Display   
    Vital to being able to keep within the inverter output limits (and avoid importing expensive grid power unnecessarily) is having the means to display the relevant information in an immediate and accessible way.
    That's what I told my wife, anyway.  Really, I'd just scored a bunch of old RC servos on ebay for £5 and I wanted to play with them. 😉

     
    In context:

     
    It uses 6 servos, a Wemos d1 mini clone and a tri-colour LED.  Dial faces are 3D printed, with a filament change from white to black (which turned out much better than I imagined, TBH).
    The servos only had around 90° of sweep angle, so I 3D printed some little holder/gearbox things to get over 180° and provide a shaft for the needle to go on, plus some 'steampunk' needles.


     
    All run buy the obligatory D1 mini and held together using the very latest in 'twist and tape' technology.

     
    Yee-haw! 🤠
    It gets fed the data from 'node-red' running on a Victron CerboGX via UDP packets over WiFi, updating as often as the data changes (approx 3 second intervals).  The LED changes colour according to state, so 'All OK' is green, 'You're getting very close to/exceeding the inverter output limit, so if you don't want to pay for grid, don't turn anything else on' is red, then blue for 'dumping power into the hot water tank'.
    It's by no means silent in operation.  I originally made a single-servo version for just PV generation and coded it so that the meter movements were gradual (a kind of PID to get from one value to the next), but apparently it 'sounded like we have cockroaches' when it made it's ticky-scratchy transitions between values, so the big version just jumps between values with a 'zzziiiiiup!' sound.
    It's actually quite reassuring to have an audible indication when the sun comes out for 5 seconds, or it starts charging at night.
    I'd also put a little radar sensor in there, with the aim of having it detect when there was nobody around, so it could stop displaying to save power/noise.  Unfortunately, that meant that every time you entered the room, all 6 needles would suddenly move at the same time, making you jump out of your skin and spill your horlicks, so we just leave it 'on' all the time now.
    There's also a basic web UI, so you can see the same data on your phone or whatever, plus it's useful for troubleshooting:

     
    I had fun and learned loads making it - and now it's become a family game to try to cook dinner without making the red light come on. 🙂
     
    Libraries used are 'ESPUI' and 'servo', plus 'arduinoOTA'.  Code, FreeCad file for the gearbox & stl file for the arrow-head needle are all in the attached zip.
    Power_meters_v2..zip
  17. Like
    HedgeSlammer got a reaction from WannabeSolarSparky in Large 'Retro' Power System Display   
    How's your one coming along, @WannabeSolarSparky?
    I've got mine up on the wall... 😎

    Here's a video (note the 'fake PV' data injection, then SOC plus inverter load to demonstrate - I'm fighting the real data as it comes in, so it jumps around a bit, but you get the idea).
    I used the '144 LEDs per metre' WS2813 strip for the legs, battery, inverter and house, with 60 lpm WS2812 for the sun and pylon.  I'd made the legs to take 10mm wide strip, but the 144 was 12mm wide so I had to trim a mil off the power tracks on each side - luckily they were generous with the tracks, so I got away with it for such short runs.
    Getting it to bend around in nice curves and stay flat was a right pain, as the LEDs are less than 2mm apart, but it worked out in the end.  Basically, by folding it back on itself, squeezing one side sharp and then flattening it back out whilst bending it into a curve with the sharp crease on the inside of the curve.  It's best to completely remove the stick tape first, though.
    I didn't fill any/everything with hot glue (as a diffuser) as originally planned as it looks OK without it, plus it's too easy to lose the shape of the parts when they're heated.
    The code still needs a bit of fine tuning, plus there are a few oddities with the FastLED lib that need addressing (like the LEDs in the 'arms' don't go completely off when they should).
    I'll post the code / stl files once it's sanitised. 🤪
  18. Like
    unrolled and laid out on the frame

     
  19. Like
    top view

  20. Like
    Some of the bits and pieces that will make the magic happen.

  21. Like
    HedgeSlammer got a reaction from WannabeSolarSparky in Large 'Retro' Power System Display   
    Good tip, thanks...
    I'd tried using this method before :
    #define DEBUG 0 #if DEBUG == 1 #define debug(x) Serial.print(x) #define debugln(x) Serial.println(x) #else #define debug(x) #define debugln(x) #endif .. but it all goes to hell when you're dealing with floats (i.e. more than one argument - the second defining the decimal places to be printed).  But your method seems to cope with that, no problem.  I'll be using that in the future. 👍
    I do try to only enable one 'print' at a time, though - especially when dealing with 'timing critical' stuff, like these microsecond LED dimming loops.
    There's still always the trusty 'Search: Serial.print >replace with> //Serial.print', too. 😆
  22. Like
    This is how I handle the serial print output

    Add to the top with all your other defines.
    #define DEBUG 1 // SET TO 0 TO Disable serial debugging info or 1 to show serial debugging info #if DEBUG #define D_SerialBegin(...) Serial.begin(__VA_ARGS__); #define D_print(...) Serial.print(__VA_ARGS__); #define D_write(...) Serial.write(__VA_ARGS__); #define D_println(...) Serial.println(__VA_ARGS__); #else #define D_SerialBegin(bauds); #define D_print(...); #define D_write(...); #define D_println(...); #endif then change all your
     
    Change Serial.print(); to D_print(); and Serial.println(); to D_println(); Works like a charm to switch the serial print on or off
    You can even add a button to do it for you if you are lazy like me 🤣
  23. Like
    HedgeSlammer got a reaction from WannabeSolarSparky in Large 'Retro' Power System Display   
    Here's the whole thing so far...

    I might have to re-do the sun, though.  It's supposed to be sized so that the 60-LED-per-metre strip lines up with the 'rays' inside, but I suspect it won't and needs to be about 15mm bigger diameter...  I tried it with the 30-per-metre, expecting it to be lining up with every other ray, but it's miles out. 😢
    Still, what's not to like about a bigger sun?  Making the 'rays' a bit bigger would certainly print a lot better, too. 🙂
  24. Like
    HedgeSlammer got a reaction from WannabeSolarSparky in Large 'Retro' Power System Display   
    Cheers for that. 🙂
    From the WS2812/13 datasheets, they suggest that the data level needs to be 0.7 x the supply voltage, which would mean 3.5v at 5v supply - a tad higher than the ~3.3v the ESP delivers.  Reading around, sometimes you can get away with it, sometimes not.  Depends on the particular LEDs.  One neat trick I came across was to split off the supply to the first LED and stick a small silicone diode inline there, which drops the supply voltage by 0.7v, meaning 4.3v x 0.7, so 3v data level, then the second LED takes it back up from there for the rest of the string.  It does mean that the first LED will be a bit dimmer, though.
    I'll stick with the level shifter, as I already have some, it fits in there nicely and I won't have to experiment too much when the LEDs finally arrive.

    I started with the 'cylon' code, but it doesn't give me that 'ramping up' or 'fade in' effect for the leading LED.  The 'blur' thing looked promising, but a bit clunky at lower speeds.  I've gone for one 'active' LED on, then the one in front of it is ramping up as the one behind is ramping down by the same amount and the one behind that is turned off.  Probably completely unnecessary, but I won't let that stop me! 😆
  25. Like
    Nice they should be with you soon then
    int FlowSensorValue = analogRead(FlowSensorSpeed_Pin); // A0 pin 36 flowSpeed = map(FlowSensorValue, 0, 1023, 1, 50); int LED_BsensorValue = analogRead(Brightness_Pin); // A3 pin 39 BRIGHTNESS = map(LED_BsensorValue, 0, 1023, 1, 50); Simply using two potentiometers and mapping them in to control the brightness and flow speeds.
    Currently the flow speeds are simple delays.
    Once I have done the physical mockup and know the exact number of LED's for each segment then I will recode everything into frames and palettes and eliminate all the delay code bits.
    I am using the cylon code which gives a nice trail effect to the flows.
    LED strip + connected to direct esp32 5v VIN
    LED strip data connected direct to pin 23 - no external level shifter required as the data line is independent of the + line.
    The 1st led acts as the levelshifter quite effectively. If your 1st led is far away from the eps32 pin then you may need a level shifter.
    The esp32 puts out more than enough power to drive the data line. Set the max amps to 500ma and max brightness to 50. With those settings I have tested the full strip of 300 led's without any external power and experienced no colour fading or bad data.
    I am using the Lolin32 WROOM, it's has pretty robust power handling stock standard.
    I am currently driving all the led's and 10 servo's without external power and have had zero issues with the servo's or the led's colours and sequences.
    On the final board I will however add an external 5v PS to drive the led's and servo's

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.