#418

แชร์
ฝัง
  • เผยแพร่เมื่อ 16 พ.ค. 2024
  • Artificial Intelligence on the edge! Sounds modern and cool. Reading numbers or dials with an ESP32-CAM for a few dollars? Even cooler. But does it work? And how does it compare with the traditional “barefoot” approach? Let’s have a closer look.
    I am a proud Patreon of @GreatScott!, @ElectroBOOM , @Electronoobs , @EEVblog , and others.
    Links:
    ESP32-CAM: s.click.aliexpress.com/e/_Ap3E7l
    ESP32 with battery support: s.click.aliexpress.com/e/_AEEa8B
    CNY70: s.click.aliexpress.com/e/_A0k6fl
    AI water meter project: github.com/jomjol/AI-on-the-e...
    My Sketch: github.com/SensorsIot/AI-on-t...
    My second channel: / @hb9bla
    The links above usually are affiliate links that support the channel (no additional cost for you).
    Supporting Material and Blog Page: www.sensorsiot.org
    Github: www.github.com/sensorsiot
    My Patreon Page: / andreasspiess
    Discord: / discord
    If you want to support the channel, please use the links below to start your shopping. No additional charges for you, but I get a commission of your purchases to buy new stuff for the channel
    My Amazon.com shop: www.amazon.com/shop/andreassp...
    For Banggood bit.ly/2jAQEf4
    For AliExpress: bit.ly/2B0yTLL
    For Amazon.de: amzn.to/2r0ZCYI
    For Amazon UK: amzn.to/2mxBaJf
    For ebay.com: ebay.to/2DuYXBp
    profile.php?...
    / spiessa
    www.instructables.com/member/...
    Please do not try to email me. This communication channel is reserved for my primary job
    As an Amazon Associate, I earn from qualifying purchases
    #no#midroll#ads
  • วิทยาศาสตร์และเทคโนโลยี

ความคิดเห็น • 425

  • @matambale
    @matambale 2 ปีที่แล้ว +77

    This reminds me of my favorite remote sensing story: it was determined that the cheapest, quickest, and most accurate solution to remote greenhouse temperature sensing was a large dial thermometer and a pair of binoculars.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +4

      Cool!

    • @guatagel2454
      @guatagel2454 2 ปีที่แล้ว +7

      Nice! Now you can install an esp32-cam with a telescope! No cables, no long range wifi, no LoRa, just a telescope, one cheap esp32-cam+AI, and a local wifi.

    • @matambale
      @matambale 2 ปีที่แล้ว +1

      @@guatagel2454 Brilliant idea!

    • @danielforrest3871
      @danielforrest3871 2 ปีที่แล้ว +1

      Hilarious, because it is true.

    • @smartassist9700
      @smartassist9700 ปีที่แล้ว

      🤣

  • @josefmuller4714
    @josefmuller4714 ปีที่แล้ว +6

    Hi Andreas,
    great video! This is the developer of the AI-on-the-edge. The reason, why your analog counters are not detected correctly is indeed the inverted color (white on black). In contrast do the digits, this is not part of the training data yet.
    Have a look on the latest updates, now we can even detect the NaN values with then newest neural networks.
    Best regards,
    jomjol

    • @AndreasSpiess
      @AndreasSpiess  ปีที่แล้ว +1

      Cool that I have so important viewers on the channel! Even if it did not work for me, it still is a very good project!

  • @Pheatrix
    @Pheatrix 2 ปีที่แล้ว +64

    I work as a data scientist and one of the most important questions you always have to ask before using AI is:
    Can this be done without AI?
    If the answer is yes it is probably more reliable to do in a traditional way.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +6

      Thank you for the additional insight!

    • @AndreasDelleske
      @AndreasDelleske 2 ปีที่แล้ว

      Well then you might have to convince all other members of a co-owned housing compound to let you change just one water counter and why...

    • @planckstudios
      @planckstudios 2 ปีที่แล้ว

      @@AndreasDelleske generally speaking, using AI to bypass HOA restrictions could be popular in a lot of tech savvy pockets that have sprung up in old money communities

    • @Pheatrix
      @Pheatrix 2 ปีที่แล้ว

      @@AndreasDelleske
      That means you can't do it (or can't do it without a significant amount of effort).
      -> use case for AI

    • @AZ-vk7oe
      @AZ-vk7oe 2 ปีที่แล้ว +5

      the term "AI-washing" comes to mind, similar to greenwashing for environmental issues.

  • @ItsTristan1st
    @ItsTristan1st 2 ปีที่แล้ว +24

    Going the optical character recognition route, as was initially attempted would require a substantial amount of system training. You provide the images and supply the CORRECT digits in each case. Then after a while it will be able to do it reliably on it's own.

    • @StefanoBettega
      @StefanoBettega 2 ปีที่แล้ว +1

      This is also the best solution to have the project running only for small amounts of time. But AI surely requires a lot of CPU power, and you can end up with a project which drains batteries faster than a proximity sensor one. I was also thinking about proximity sensors for smartphones: are those all of the reflective kind?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +6

      The training and the execution are separate tasks in AI. Training is done on big CPUs. But the execution (inference) does not need a lot of power and can be done on smaller machines.

    • @StefanoBettega
      @StefanoBettega 2 ปีที่แล้ว

      @@AndreasSpiess that's true, but I assume that also the picture grabbing and processing, along with the energy needed to power up the LED would be high. In the meantime I was thinking about STM32's battery backup domain. This feature if I well remember should contain an event counter still working when the core is in deep sleep mode, which would be capable of turning on the system after some counting has reached a pre-programmed threshold. This could help, if you only need a rough value from time to time rather than a continuous monitoring.

    • @alexandrsoldiernetizen162
      @alexandrsoldiernetizen162 2 ปีที่แล้ว

      @@AndreasSpiess You could train that simple model on decent 16 core desktop server, probably in a matter of days. The problem would be getting all the training images together, which would require multiple permutations. Those half digit images especially.

    • @FuZZbaLLbee
      @FuZZbaLLbee ปีที่แล้ว

      Retaining the model is actually very doable, even on a slower machine. Since you could use a pre trained model and only retrain the head.
      The problem here is that you need images of all the numbers in every position to account for the led glare

  • @BG-dr3si
    @BG-dr3si 2 ปีที่แล้ว +39

    Hello, I also have the AI solution for Gas and Watermeter and it works fine. But it took me some hours to do the correct setup. It it important, that the image is horizontal aligned and the scan area for the digital digits are large enough (larger than you wouId expect) , in 3:21 you see the 039 even includes the frames around the digits. This reduces the NaN results a lot and even recognized switching numbers. Also you must setup the initial value and a threshold to only overtake reasonable values (Values to low or big are thereby ignored). I mounted an angle iron on the wall 10 cm above the meter and taped the ESP32 below it. By twisting, you can move the glare point of the internal led to an area, which is not scanned, With this easy solution your energy provider can still read the values manually, if needed. Hope that help's to give it another try.

    • @eyeontheworldfromabove4500
      @eyeontheworldfromabove4500 2 ปีที่แล้ว +2

      I agree with the above. I almost gave up on it as wel, but after adjusting and configuring for days it's been stable for weeks now. The documentation is very limited, but I can already see what you did wrong there (due to all my fails lol): 1. your camera is too far away or lens was not adjusted to have the best focus for the distance, 2. your rotation is slightly off (even 0.5 degrees makes a difference), 3. your reflection of the LED will hinder you a lot (experiment with different positions, angles, put a black sticker on the reflection point of your meter to limit the reflection, and if nothing else works, try soldering two small led's that you can position relative to the board) and then lastly, 4. your rectangles around your digits are too small. They need to be bigger (+-30% whitespace around each digit). If you do all of the above correct, I can almost guarantee that it will have it correct for 90% of the times and the rate limit should filter the other 10%. I can't speak for the analog ones as I didn't use those. The stability of the latest version was terrible, but the v9.2 was working fine. The camera drivers were changed in latest version and proved very buggy with my esp32 board type.

    • @jeanyluisa8483
      @jeanyluisa8483 ปีที่แล้ว +1

      Seems I'am lucky, for me the AI on the edge solution works quite reliable since about 6 weeks now. It's reading all the 5 digital and 4 analog values of my watermeter properly.
      Three or four times I noticed errors. But those were detected and shown as error by the integrated plausibility check. So the sensor did not send any values until the readings made sense againt .
      The big advantage of the AI on the edge solution is, that there it's directly reading the watermeter. So it always gets back to the proper values. When counting impulses and calculatimg the values little errors will add up and the real value of the watermeter and the calculated value of the sensor will drift further and further apart by time.

  • @gdvissch
    @gdvissch 2 ปีที่แล้ว +36

    Hahaha, let the MBAs do what already works… priceless! I’m sure your typical audience are mainly engineers so no one will take offence.
    Great video as always. Thanks!

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +11

      Anyway, as an owner of an MBA and a PhD in Business Administration I thought that this joke was ok ;-)

    • @c1ph3rpunk
      @c1ph3rpunk 2 ปีที่แล้ว +2

      That 3 letter degree provides more value than I can adequately communicate.
      But I cannot imagine a PhD in it. Oof. Though, having that in a concentration such as Operations could be fun. Sort of. ;-)

  • @jsepulveda7550
    @jsepulveda7550 8 หลายเดือนก่อน

    Thanks for video!!
    Good content, as usual.
    In my project, I used a coffee cup to mount the camera. I loved it, cheap and recycled.

  • @themoloch
    @themoloch 2 ปีที่แล้ว +3

    As always great video! The metal piece from the water meter is for inductive sensors like TI LDC0851, I have worked designing this kind of sensors for iot devices

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      Thanks for the info! Mine did not work with my hall sensor. So I thought it is not metal...

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      In the meantime I checked with the LJ18A3-8-Z/BX sensor and it works. So it must be metal, but not magnetic.

  • @wjn777
    @wjn777 2 ปีที่แล้ว

    Great, thanks for sharing. "We want more" is one of the main reasons I watch this channel

  • @avejst
    @avejst 2 ปีที่แล้ว

    Great video as always 👍😀
    Great tricks
    Thanks for sharing your experience with all of us 👍😀

  • @zukjeff
    @zukjeff 2 ปีที่แล้ว +4

    to eliminate the glare try polarizing film either over the meter face or on an angle below the LED. You can get the film from a damaged LCD screen/ display.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I agree, polarization could help. I will try it once.

  • @nicovosje
    @nicovosje 2 ปีที่แล้ว +3

    Thank you for the video.
    Getting interested in tensorflow now :)
    You can also use mqtt retain to store the counter value.
    Works great for me.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Cool. This was my first encounter...

  • @suchinthanawijesundara6464
    @suchinthanawijesundara6464 2 ปีที่แล้ว

    Excellent and attractive approaches ❤

  • @grzegorz3742
    @grzegorz3742 2 ปีที่แล้ว

    Lovely treasure boxes :) I'm affraid all we have similar number of goods at our workshops. Great idea with phototransistor. I've tried AI on the edge and after hours or experiments I have to chose another solution due to big difference between mine water counter and the example one. Great content! Appreciate your work very much.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I liked the project and was a little disappointed when I saw that my counter is hugely different... But now the problem is solved, and it works.

  • @JosepsGSX
    @JosepsGSX 2 ปีที่แล้ว +2

    A very interesting video. The way to approach the sine wave to process it is brilliant.
    My water metter is very similar to the one from the project, but has some kind of wireless communication as this is a flat with central hot water (same goes for the heating). I wish I had enough knowledge to work it with the SDR radio to get the numbers in the same way I get the 433 weather sensors.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      If these meters are more modern they often are encrypted :-(

    • @JosepsGSX
      @JosepsGSX 2 ปีที่แล้ว

      It is two years ago modern, so sure it will be. Too bad, but thank you for pointing it :)
      I could follow the AI path, as my model is very similar to the one from the project.
      Before that I´ll try asking the provider to get direct access to the API and feed Nodered with it, or even try to process the very unusable user website I have with poorly arranged information.

  • @miguelestrada2011
    @miguelestrada2011 2 ปีที่แล้ว

    "An engineer's work always start when something does not work"
    Nice adage, thank you.

  • @ed.puckett
    @ed.puckett 2 ปีที่แล้ว

    I just love your sense of humor! I cracked up when you mentioned an engineers work begins....

  • @rinokentie8653
    @rinokentie8653 2 ปีที่แล้ว

    Interesting project again!

  • @gregorymccoy6797
    @gregorymccoy6797 2 ปีที่แล้ว

    Really love all that amassed "treasure".

  • @c1ph3rpunk
    @c1ph3rpunk 2 ปีที่แล้ว

    Boy this sounds like fun, wish I had time to start another project.

  • @ManfredHa
    @ManfredHa 2 ปีที่แล้ว

    Straight to the point, as always!
    State machine rulez 😁👍

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Indeed, I like this concept!

  • @carltone
    @carltone 2 ปีที่แล้ว

    Andreas another great instruction video. I enjoyed the water usage analysis. I got thinking, you should add some control to the project and slowly reduce the available hot water after a certain time frame. The idea to minimize water consumption. Results could be water savings but …. 😉😉

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      We will see how this will work out. It is in operation now and I will do some analysis...

  • @voltlog
    @voltlog 2 ปีที่แล้ว +1

    Cool project, I have something similar in mind for several months now but my ESP32-CAM boards got lost on their way to me 😁 BTW, using the VoltLink USB to serial adapter, would not require pushing any buttons for programming the ESP devices as it handles that automatically 👍

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +5

      Good to know. I forgot to use it. I am an old man and have my habits :-(

  • @rklauco
    @rklauco 2 ปีที่แล้ว +4

    I like the more practical approach to the measurement - using pattern recognition is good idea for some events, but reliability is a big problem. So using something like you did is far better, I think.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +2

      For me, it was interesting in diving into the matter. What does the counter do if one number is between two numerics? What if 2 or three are in this position? Not easy to solve if the counter was not made to be read by a machine. Or if I cannot read one of the dials? How to solve that?

  • @TheOO23
    @TheOO23 ปีที่แล้ว +1

    I made a project like that, reading 8bit segment digits from an aquarium meter. Used ESPcam to take pictures, then a raspberry with OpenCV to locate the digits and tweak the image, then tesseract, trained version for digits. It works nice in the end, i still get some wrong numbers but im able to filter then out.

  • @valiza123
    @valiza123 2 ปีที่แล้ว

    The needle mechanisms are magnetically coupled to the turbine so you can for sure use hall effect sensor if you remove the lid and gears completely.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Good to know. But I did not want to destroy the top. I think the meter belongs to water supplier, not to me...

  • @bob2859
    @bob2859 2 ปีที่แล้ว

    7:49 - the dream!

  • @retroattic4647
    @retroattic4647 2 ปีที่แล้ว

    I've been working an AI agricultural system to read 24k analog meters. When trained with a custom dataset from our meters we've achieved excellent recognition and conversation at the edge. Using a priori information about the meters prior state we can deal with many other edge case issue since we know meters only increase over time.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Good to know. I assume you were able to invest a little more time for 24k meters than me with only one ;-)

  • @joostluyten_ON3JT
    @joostluyten_ON3JT 2 ปีที่แล้ว +1

    Just in time, been on my list for a few months now. Next : eBus from Vaillant 😉

  • @guatagel2454
    @guatagel2454 2 ปีที่แล้ว

    Both solutions have their set of problems on which they are useful. Thank you!
    Edit: I'm having a lot of fun reading the comments, so many clever ideas.

  • @PeetHobby
    @PeetHobby ปีที่แล้ว

    Just a little tip: If your microcontroller doesn't have an ADC pin or you can't spare another ADC for just a simple sensor, you can read it with a digital pin. We can accomplish that with example a PNP transistor on the output of the sensor and with a relative low base and collector resistor, that will make the output clip between gnd and 5v, like a digital signal.

  • @waltsteinchen
    @waltsteinchen 2 ปีที่แล้ว

    Engineering at it's best Andreas! ;-) I'm using a setup where I'm not really interested in the actual numbers but trying to detect water flow vs no water flow to react on broken pipes, hanging valves etc. My theory is that in 2 hours there should always be 10 minutes with absolute no water usage - at least in my household. If not I use a central valve to close the entire water flow for the house. Works great so far, f.e. detecting hanging toiletts or similar. Had just one false alarm in 5 years. I also have added a ESP32 CAM .. but basically to just allow me to get a "video" or static picture from the counter (that's what the default firmware of the ESP32 CAM does). My water supplier (10 years ago) offered a special device for ~60 euro that is able to put out a open collector contact for every liter water. Imho there is a spinning magnet inside the water meter itself which they plug on. Easy way to get the "real" numbers of water usage. And btw: The "central valve" just a pure mechanical construct which uses an old cordless drill to manually close the central valve ;-) Cheers!

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      My new decalcification system has this feature, too. You know how I discovered it? For the tests in this project, I had to let the water run constantly for some time. Suddenly it stopped :-(
      This device checks if the water flow is the same for a certain time and then cuts it...

  • @joinedupjon
    @joinedupjon 2 ปีที่แล้ว

    I guess that metal 'D' plate was designed for a specific optical sensor unit from the OEM with a shaped and focussed beam which probably made the electronic signal processing a bit easier.
    we've got portable label printers at work that use IR to count and align the label paper by black marks printed on the back of the paper and they do a really good job under a lot of conditions.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Well possible that they wanted more accuracy. Or wanted to save on BOM cost and only added a simple sensor and no MCU.

  • @pietermoelans9748
    @pietermoelans9748 2 ปีที่แล้ว

    Works like a charm!!Tested it on my water meter and worked on the first try! Makes me wonder what I did wrong...🙃

  • @MrEerwin
    @MrEerwin 2 ปีที่แล้ว +2

    Thank you for these excellent videos. I love the clear thinking and explanation you bring to them.
    So, as AI has transitioned from its early mechanistic approaches (e.g., expert systems, etc.) to the current models based on non-parametric statistics, there is also a subtle change in its successful application. The current models are more about being 'less wrong' than 'exactly right in the instance'. This is encouraged by its alignment with large number theory and other assumptions (e.g., Bayesian Analysis, etc.). Given this, we might best think of modern AI technique as most suitable as part of a 'problem-space reduction' tool that gets bolstered and completed by more traditional, deterministic kinds of algorithms, rather than as a central part of some core algorithm. AI's real mission, IMHO, is about abstracting 'the smart' from from everyday good engineering, and this will require a different kind application with different kinds of value produced. I like to think of AI as a kind 'context manager' for whatever problem(s) I am trying to understand and solve.
    Still, this was a bold and valuable attempt. Bravo to Andreas Spiess, The Guy with Swiss Accent.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      I only used AI for the TH-cam algorithm. Otherwise I call this use case "pattern recognition". I still think that, if we take out the sales speak, a lot of valuable "AI" is pattern recognition, sometimes on a high level.
      I also never know how much programmed "expert system" is in the applications. I use a spelling and grammar checker for my scripts and always wonder how good it is. But I fear there is a lot of standard programming behind it. Even if the leaflet calls it "AI"...

  • @temyraverdana6421
    @temyraverdana6421 2 ปีที่แล้ว +2

    Hi, thanks for amazing video, very instructive.
    I have a question: why don't use a Smith trigger to signal conformation to have a 0 and 1 digital signal?
    Thanks and see you next

    • @makers_lab
      @makers_lab 2 ปีที่แล้ว +1

      A hardware schmitt trigger would add complications but it could be done in software with an adaptive threshold detector that was largely immune to changing bias. Andreas's approach is neat though and has the potential benefit of being able to do some error handling or error correction.

    • @temyraverdana6421
      @temyraverdana6421 2 ปีที่แล้ว

      @@makers_labThanks for answer, you are right

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +2

      Exactly. I wanted the sensor to be able to adjust automatically. The curve is not as neat as I showed (a sine was easy to draw) and its middle is not at 1.6 volts (it also changed with slightly different adjustments). But you are right. I most probably could have done it a little simpler. But I also wanted to be a little educational for other cases.

    • @temyraverdana6421
      @temyraverdana6421 2 ปีที่แล้ว

      @@AndreasSpiess Thanks Andreas for answer. See you next

  • @Ed19601
    @Ed19601 2 ปีที่แล้ว +1

    Two interesting approaches. i am using an inductive proximity sensor placed above a rotating metal semidisc to pick up a signal

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      This seems another method if your counter does not have this reflective part. I only tried this part with the hall sensor. So I do not know if my counter would also have such a metallic part.

    • @Ed19601
      @Ed19601 2 ปีที่แล้ว

      @@AndreasSpiess Yours works. In the end that's what counts (no pun intended).
      I have considered the AI solution as well but found it unreliable/too error prone

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      In the meantime I checked the LJ18A3-8-Z/BX sensor and it worked. So it must be metal. Now I have the choice...

    • @Ed19601
      @Ed19601 2 ปีที่แล้ว

      @@AndreasSpiess great

  • @bobylapointe6559
    @bobylapointe6559 2 ปีที่แล้ว

    I have same counter in Vaud but the water supplier add the remote sensor by default. The M-Bus can be read on 868.625M from your favorite SDR gear and RTL soft. They do that so they don't have to ask you to check the counter. use Izar protocol and NOKEY param.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Cool! Here we are asked to read the counter once a year.

  • @Uncle-Duncan-Shack
    @Uncle-Duncan-Shack 2 ปีที่แล้ว

    Interesting video Andreas.
    Creativity for the win, by the time one has trained the AI for all the variables that exist in the application, a lot of time has been spent and functionality is still not guaranteed.
    The IR is a known workable solution.
    But, we would not have known all of this if you had not spent the time doing the research, and that is the value of doing these projects.
    It remains an investment in knowledge, and you kindly share it with us.
    I appreciate that, and it makes for a nice Sunday viewing.
    Kind regards,
    South Africa

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Indeed, I learned a lot (as with many of my projects). But this also takes a lot of time because sometimes I must prepare two or three different solutions till one works ;-)
      But I am glad if you like the result.

  • @triularity
    @triularity 2 ปีที่แล้ว

    @2:07 - That trigger button made me think of one of those vintage accordion plate cameras (on a tripod/stand) which has a cord and "button" to trigger the snapshot. Maybe as a project you should make a retro version of that style camera using an esp32-cam and cord. ;)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      You are right. And if I remember right, they were mechanically connected to the button on the cameras...

  • @meinsda5983
    @meinsda5983 2 ปีที่แล้ว

    Andreas nice video! Why do you need the analog input. You can also use a "flip-flop" or? Do you know there are different esp-cam modules are on the market?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      1. I wanted that the sensor adjusts its values automatically. The middle value is not at 1.6 volts and the curve is not a sine as I showed (for simplification). But implementing a threshold could have worked, too. I agree.

  • @peter.stimpel
    @peter.stimpel 2 ปีที่แล้ว +5

    I tried exactly the same with my heating central at the attic and my house power meter. I ended up kicking the pattern recognition in both cases. The fresh installed smartmeter (power) provides a blinkig LED, 5000 ticks per kWh. Easy enough to read using a lightsensor. For the central heating I just tried to find out how often the flame was ignited. I ended up using a lightsensor as well, using the "flame is on" LED of the heating central. I would love to read gas consumption and water consumption as well, but here my problems are more real life related: no power to drive anything around those installations. Seems, the guy that planned installation in this house did not have any digital stuff in mind at all. Still, I need to stick my head into that tensorflow pattern recognition. And many thanks for not calling pattern recognition AI. I hate that buzzword bingo that is happening nowadays.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +2

      You know: I am an engineer and like to name things correctly ;-)
      Using secondary things for measurements often needs some creativity but can lead to good solutions (as in your case).
      These counters need some power because they have to be always on and, in my case, also need an LED. So, 100mA is needed. I have electricity there so it will not be a problem.

    • @gregw1076
      @gregw1076 2 ปีที่แล้ว

      For power, if money was no object a power over Ethernet (PoE) setup sounds nice, or just run speaker wire with either 5v or 12v as supply

    • @peter.stimpel
      @peter.stimpel 2 ปีที่แล้ว +1

      @@gregw1076 sadly, not working there. No way to get a cable there, if it not look like a barbarian attack :)

  • @makers_lab
    @makers_lab 2 ปีที่แล้ว

    If the project supports training then based on your own images then it really should be possible to get perfect recognition of the main digits at least. Constructing and training on synthetic images of the digit transitions might well be reliable too. I always prefer the simple pulse counting and interval timing approaches though as they're perfect for smaller uC's such as PICs.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      They offer a training possibility. But only for one meter, the effort was too much for me...

  • @TomsRCScalers
    @TomsRCScalers ปีที่แล้ว

    Sali Andreas, ich feiere echt all deine Videos, genial - mach bitte immer weiter so! Zum ESP32-CAM mit AI on the edge watermeter Ansatz kann ich Dir berichten, dass dies bei mir erstaunlich gut funktioniert. Vielleicht wurde mittlerweile der Algorithmus auch weiterentwickelt. Mein Wasserzähler hat ebenfalls weisse rollierende Buchstaben auf schwarzem Grund, und die werden recht zuverlässig erkannt und interpretiert. Ebenso die analogen Zeigerchen. In Home Assistant sehe ich per MQTT präzise den Wasserverbrauch. Das Gefummel bis Kamerabild und Licht stimmten, war aber schon e chli en Murks.. :)

    • @AndreasSpiess
      @AndreasSpiess  ปีที่แล้ว

      Vielen Dank für deine Rückmeldung. Ich weiss nicht, ob sie etwas geändert haben.

  • @rgitzelify
    @rgitzelify 2 ปีที่แล้ว

    Fascinating! I hadn't thought of using a camera on an analog meter when I went this route.
    Like you I already had electrical monitoring into Influxdb (thanks Iotawatt!). So I started to wonder about water. I already had some cheap hall sensors on my outdoor water lines to verify that the irrigation system keeps our garden watered. But what about the house itself?
    Here in Canada (Vancouver) we don't pay for our water, so it's not metered, so I didn't have an analog meter to start with.
    Digital water meters were pricey, and usually meant for high-volume, so not very precise. Then about a year ago EKM Metering released a version of their pulse water meter that pulses every 0.283 litres. You can hardly turn a tap on without a pulse.
    Plug the pulse output into a Sonoff running Tasmota, and tada! A count published to MQTT every minute.
    The meters are cheap enough that I bought two: I still need to put the second one on my hot water line, but soon I'll know water the hot:cold ratio is for my shower. I have yet to convince my partner why this is useful. :-)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      Indeed, it is not easy to convince somebody of the usefulness of measuring a free good ;-) That is what I call a hobby. Useless, but fun!

  • @hitsov
    @hitsov 2 ปีที่แล้ว

    You can use induction sensor for reading the water meter, super easy and accurate!

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      You are right. But the Lj1234A does not work off 5V. It needs more :-(

    • @hitsov
      @hitsov 2 ปีที่แล้ว

      @@AndreasSpiess I tried 2 for my water meter and they both work although one was rated as low as 6V it still works reliably at 5V. And if you take the NPN version it will not hurt the micro because it only grounds the output. Being digital signal its much easier and reliable to work with. Costs as low as 3-4 euro from China

    • @hitsov
      @hitsov 2 ปีที่แล้ว

      I have LJ12A3-4-Z/BX and PL-08N, both work at 5v, the second one I've been using for almost 3 months now

  • @edgarvaneersel2
    @edgarvaneersel2 2 ปีที่แล้ว

    Still nice to experiment with AI.
    For the water meter, I have created one a year ago, using a hall sensor.
    A few hints for those who want to create one too:
    - as my meter has a metal spinning disc, a hall meter does work in my case
    - I created an MQTT message from which I can update the reading after a reboot. Also, I keep track if an update was done.
    - I had to use a condensor and a resistor to avoid false reading. They were rare, but completely eliminated with that small circuit added.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Thanks for the tips! Other viewers suggested avoiding the absolute count on the device and only keeping it on the Raspberry. That is what I will do. Only transfer the consumption.

  • @Gastell0
    @Gastell0 2 ปีที่แล้ว

    Some meters actually use magnet to trigger reed switch and the reader head either sends a pulse or it's smart enough to keep the count and report the current number

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I changed the concept now and only transfer the impulse. The rest is done in Node-Red...

  • @phillipneal8194
    @phillipneal8194 2 ปีที่แล้ว

    The "MBA" crack was great !! 8-)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I own one. So I'm allowed to make a joke ;-)

  • @matneu27
    @matneu27 2 ปีที่แล้ว

    Yup, if water meters where not leaded 😉 we could glue a tiny magnet on the dial arm. Anyway there are also sold water meters with built-in pulse output, but then you had to buy it self and let register and lead it again at the water supplier.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Ours is also owned by the water supplier and we must not change anything.

  • @enkrypt3d
    @enkrypt3d ปีที่แล้ว

    omg this is so much work.... impressive though!

    • @AndreasSpiess
      @AndreasSpiess  ปีที่แล้ว

      It really is! Work is good if you like the topic.

    • @enkrypt3d
      @enkrypt3d ปีที่แล้ว

      @@AndreasSpiess I ended up getting the flume 2 and it's been great so far

    • @AndreasSpiess
      @AndreasSpiess  ปีที่แล้ว

      @@enkrypt3d Not cheap, but with an additional function.

  • @kentvandervelden
    @kentvandervelden 2 ปีที่แล้ว

    I enjoyed the final solution. More investigation of the camera system would have been interesting, but can't disagree with simple, low power, and reliable solutions.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Training would have solved some of the problems. But just for one meter it was too much work for me.

  • @jonathanrodriguez8219
    @jonathanrodriguez8219 2 ปีที่แล้ว

    Nice!

  • @MisterkeTube
    @MisterkeTube 2 ปีที่แล้ว

    My meter has nothing like that and the digits don't align very well for image recognition, but most of these meters need to transfer the motion of some rotor inside the water to the measuring mechanism outside the area where water is, without allowing any water to escape. Almost all meters do this transfer of motion using magnetism, so that in turn means there is some changing magnetic field at the center of that mechanism when the rotor rotates. Sometimes that magnetic field might be sufficiently strong to measure with a Hall sensor, but with my meter - with metal housing - this didn't seem to work. But ... I then used a magnetic field / compass sensor glued to the meter body and from that get a vector that indicates the direction of the magnetic flux. When the meter turns, that vector also turns (in 3d) and by reading it out several times a second and tracking that movement (flattening out some jitter which will always be there with something like this), my esp8266 can measure the number of rotations the meter makes and convert that to actual cubic m of water gone through ... Within one rotation the accuracy is not perfect, but half rotations (so those inverting the vector) are detected fine.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Cool! I like that you did not give up!

  • @adityapatil3792
    @adityapatil3792 2 ปีที่แล้ว +1

    6:39 🔥🔥🔥

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      As an owner of such a paper I am allowed to make a joke ;-)

  • @ats89117
    @ats89117 2 ปีที่แล้ว +1

    Thanks for this video. You didn't talk about training the neural net for the failed image recognition phase of the project. Did you just use a generically trained NN? The training phase of NN development will almost certainly be a really important tool for future makers. Perhaps you should take a closer look at this...
    Note that training this type of numerical recognition system where the numbers always appear in the same location in a picture is one of the easiest to train because you can get immediate and unequivocal feedback on whether the NN output is correct or not. This is generally not the case, which makes training in the general case much more difficult and explains why it is such a hot current research area.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      This project was trained with the German counter (and seems to work ok). Training for only one counter was too much work for me. Therefore, I did not look at it. I just hoped it would work with my counter, too.

  • @cklamNL
    @cklamNL 2 ปีที่แล้ว +2

    Instead of changing magical number for the initial value, can also let ESP subscribe to a mqtt topic so you can adjust without needing to recompile/reupload

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Good point. Or, as other viewers suggested: Only transfer the consumption and store the absolute value on the Raspberry. That is what I will try.

  • @PhG1961
    @PhG1961 2 ปีที่แล้ว

    Great video. A technology which will become mandatory here in Belgium pretty soon !
    Btw, I like your vocabulary... a 'ESP32 treasure chest' ! ;-)
    This reminds me of some years ago when I had a visitor in my workshop at the office. He called it 'the cave of Ali Baba', which was a nice compliment. In my and his opioning, it was full of treasures !

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +2

      Hopefully you do not have the 40 thieves in your cave ;-)

    • @PhG1961
      @PhG1961 2 ปีที่แล้ว

      @@AndreasSpiess I had two of them, which caused me a lot of trouble. :-(

  • @xDR1TeK
    @xDR1TeK 2 ปีที่แล้ว

    Hello Andreas, regarding the photo transistor, how about a Schmidt trigger to take the sinewave and generate a pulse?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +2

      That would also work if it is truly a sine Here it is only a sinusoid. And I wanted to be sure and completely automatically.

  • @user-hk3ej4hk7m
    @user-hk3ej4hk7m 7 หลายเดือนก่อน

    Using a correlation filter would have been much simpler to implement and probably more reliable, considering that the setup has fixed lighting conditions

    • @AndreasSpiess
      @AndreasSpiess  7 หลายเดือนก่อน +1

      I do not know why the "inventor" used this way and if he tried others.

  • @Alex000113
    @Alex000113 2 ปีที่แล้ว

    Thanks again for a very interesting and informative video. So many valuable nuggets of valuable information from a seasoned engineer ! If your wife had so many stashes youd probably call her a hoarder :-), so its ok if she is cleaner than you. So the AI solution you found is quite brittle, it breaks when bent to a slightly different problem. I also thought it would be straightforward to take images of my oil tank level and automatically remind me when to reorder ... 3m later Im still going into the basement to read the guage directly. Yes the ESP32-CAM is an amazing device, but requires work to do real-world tasks different from any open source available. Introductory solutions can be found with only 50 lines of code, more featured ones are several thousand lines of rarely commented code.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I made a video about pressure meters where many viewers reported that they use such a sensor for their oil tanks...

  • @nrdesign1991
    @nrdesign1991 2 ปีที่แล้ว

    I attempted a similar project in the past, reading a water meter on a rotating dial. It was a spoked wheel with many more theeth on the outside. Reading it optically worked super well, to a theoretical accuracy of a few ml per tooth. Unfortunately the water meters were replaced with ones that have only the numbers visible. I was unable to find a rotating magnetic piece, or a detectable piece of metal inside.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      That is what the call "Innovation" ;-)

  • @dave_dennis
    @dave_dennis 2 ปีที่แล้ว

    Very interesting. I like your solution much better than the AI solution.
    I am curious why you chose to setup the reflective sensor in an emitter follower configuration. I am sure you had to tweak your LED current to come up with such a nice sine wave. Phototransistors are hard to keep in a linear region.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      You are right. The curve I showed was only symbolic.

  • @paulixus
    @paulixus 2 ปีที่แล้ว

    Hi, did you try a capacitive sensor? That semicircle looks metallic

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      No. It worked and I was happy ;-)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      In the meantime I checked the LJ18A3-8-Z/BX sensor and it worked, too. So I have the choice ;-)

  • @johnpomaro1731
    @johnpomaro1731 2 ปีที่แล้ว +1

    What about capacitively sensing the grey plate?
    Looking at the design of the grey plate, I am reminded of a tunable capacitor. Is it made of metal, plastic, or since other material?
    Capacitively sensing the plate might allow you to get more of an analog/positional reading, instead of a single pulse per revolution. It would also be significantly more reliable if the meter is exposed to sunlight (something that I believe the manufacturer may have anticipated).

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I do not know if this plate is metal or just painted plastic. Sunlight is rare at the place it is mounted (usually in the basements). But I do not know how they do the reading and if they use a different method. As you saw, I also get an analog signal and could do some mapping. But one turn is 1 liter. That is good enough for me.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      In the meantime I checked the LJ18A3-8-Z/BX sensor and it worked (one pulse/revolution). So it must be metal. Now I have the choice...

  • @likeadracula
    @likeadracula 2 ปีที่แล้ว

    To read the metal piece you need to use LC sensor. The Hal of course will not work. And the IR in the field will going to have problems because of the moisture and the water around the meter. Using LC sensor will eliminate that problems and is very robust. Use two LC sensor to find also the rotation direction of the disk. By the way very nice video!!! I'm waiting to see one using LC sensor, there is plenty of documentation out there from ST, IT and meany more.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      In the meantime I tried such a sensor and you are right, it works. Unfortunately, mine needed at least 6 volts. So I stick with IR. My place is clean and dry, so I do not expect problems. For now it is reliable.

  • @Cam2Art
    @Cam2Art 2 ปีที่แล้ว +1

    Sure could have used one of these a few months ago, my water bill went through the roof. The water department told me to check if my water meter's needle was spinning, it sure was, non-stop.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      The meter is now life and I wonder about some peaks, too. I will have to see where the water goes.

    • @Cam2Art
      @Cam2Art 2 ปีที่แล้ว

      @@AndreasSpiess Leaking toilet overflow valve did not turn off water flow, imperceptible leak that I was unaware of until I saw that meter needle spinning.

  • @eslenik
    @eslenik 2 ปีที่แล้ว

    what about placing a piezo sensor to the water pipe? when there is a flow it should create some vibration and with some calibration there may be good results :)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      These counters are precise (because they are part of a contract). So I would not want to invent what was already invented (and paid and installed) ;-)

  • @catalinalb1722
    @catalinalb1722 2 ปีที่แล้ว

    Hello Andreas, can this be included into Home Assistant, the raspberry pi project? And is the Peters Scargill solution better for home automation?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      I do not use HA. My home automation is based on MQTT and on IOTstack. MQTT can be integrated in HA.

  • @Realcryptotalk
    @Realcryptotalk 2 ปีที่แล้ว

    Hi I lived the solution implemented by you and am trying to buld one
    At 8.03 min I see you have suggested connecing 2 resistors
    330 ohm between vcc and emitter
    and 10K one between Gnd & Diode
    What power rating should I use for them?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      just small ones. Nearly no power should be dissipated if you chose the right one.

  • @jonathanpizaperez9217
    @jonathanpizaperez9217 2 ปีที่แล้ว

    "An engineer's work always starts when something does not work, the other things can be done by the MBA's". That hits harder than it should hahaha, preach!

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      I am an MBA, too. So I thought I can say this ;-)

  • @science4allworld587
    @science4allworld587 2 ปีที่แล้ว

    Hi Andreas.. as usual solution is generally simple..when sought out. AI is needed where normal I wont work ;).
    Btw.. i have been playing with this cam since quite a while. One way to reduce glare is 3D print diffuser.. other control intensity, lastly as you did rightly.. external LED.
    But my major challenge is... how do we get rid of that glue.. never managed to remove or losen that focusing lens... any thoughts?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I used one of my sharp knives and had no problems. Maybe I was willing to sacrifice one and used a little force ;-)

  • @markusmeier761
    @markusmeier761 2 ปีที่แล้ว +1

    Polarizing filters may help, but the angle of the reflectet should be in the neighborhood of the so called Brewster angle (the closer the better). If the angle of the reflected light is close to zero degrees (vertical incidence) a polarizing filter doesn't help. I such cases two polarizing filters may help: the 1st filter in front of the LED, the 2nd in front of the camera. The two filters must be 'crossed'.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      Good idea! Maybe I will give it a try (out of curiosity and to learn).

  • @dan-nutu
    @dan-nutu 2 ปีที่แล้ว

    Thank you for another interesting video, I had this particular ESP32-CAM "AI on the edge" project on my to-do list for some time now, I keep delaying it because I don't have a 3D printer to make the mounting support.
    At 11:45 I reckon your Y axis labels in Grafana are wrong, possibly by a factor of 1k or even 10k (depending on your showering preferences). I doubt that your wife is using only 4ml of water per minute for the evening shower! :)

    • @dan-nutu
      @dan-nutu 2 ปีที่แล้ว

      @marthale7 That could be an option, I agree, although I would be worried about leaving an old phone (with an equally old Li-Ion battery) permanently connected to a charger, especially when I'm not at home.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      @Dan: You are right. I did not look at the scale, just at the values :-(

  • @PjPtubification
    @PjPtubification 4 หลายเดือนก่อน

    In situations where water meter locations usually lack access to power, is there a viable option to adapt this project by implementing RF for low-power signal transmission using batteries? The goal would be to receive these signals on a gateway and subsequently publish the data to MQTT. Thank you for the great videos and the moments of humour.

    • @AndreasSpiess
      @AndreasSpiess  4 หลายเดือนก่อน +1

      You could use a LoRa module to transport data. They have a longer range than WiFi (they are also used by utility companies)

  • @Ekstrapolator
    @Ekstrapolator 2 ปีที่แล้ว +2

    I believe it would be better to send whole image to RPI and use openCV or similar to distinguish the numbers directly on RPI

    • @bob2859
      @bob2859 2 ปีที่แล้ว

      Easier to develop probably... but even more power used and additional complexity on top of what's already unnecessary complexity!

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Maybe. But I am not sure if it would solve the glare problems. And probably also would need some training.

  • @SurajGrewal
    @SurajGrewal 2 ปีที่แล้ว

    Well, if you're storing a single eeprom variable at a time, you can always store it's complementarity, alongside it, to check for writing errors

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      Also a good idea. I developed this way when I had more variables to store. And often, I do not know how many variables must be stored at the end of a project ;-)

  • @awesomedee5421
    @awesomedee5421 2 ปีที่แล้ว

    To get rid of the glare, best is to put the camera to read at 45 degrees to the surface, but anything will see improvement. That will take the LED and bounce the light away from the camera. I thought you had to train tensorflow. Would it have better results if ran much longer to train it?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      This project includes trained files. But not for my meter. Training it for only one meter would be too much effort for me.

  • @ch94086
    @ch94086 2 ปีที่แล้ว

    Wow, great project and test of "AI" (CNN) vs reflectance counter. I wonder how effective traditional image processing would work, e.g . bitmap matching and arrow angle analysis. Probably you could have retrained the NNs and tweaked the alignment to get it to work, but that's a lot of work.
    I have a friend who wants to monitor water heater status lights, and seems like an ESP-Cam would work well. I was thinking of using simple image analysis (AI seems harder). You could have written image analysis to detect the spinning disk, but you could have a low power solution (battery) with your reflectance sensor monitored by the ULP peripheral.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I could also have trained Tensor flow for my setup. But the effort was too big for me. But for other scenarios this setup could be good. Training for a few LEDs probably would be simple...

  • @aimanfaris9100
    @aimanfaris9100 11 หลายเดือนก่อน

    where did you get the power source for the esp32-cam, sir?

    • @AndreasSpiess
      @AndreasSpiess  11 หลายเดือนก่อน

      Usually from AliExpress

  • @rcpoisond
    @rcpoisond 2 ปีที่แล้ว

    You can use the ESP32 Preferences API which is much simpler, the EEPROM API is marked as deprecated anyway :)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      You are right. But only for one number, I did not think of it.

  • @RaadYacu
    @RaadYacu 2 ปีที่แล้ว +2

    using EEPROM is good but since you have connection via MQTT ( RPI ) and then to Influx DB, why not in startup get the last values from DB instead. Let the DB be your master source of data
    But awesome project for sure

    • @jenskaa4044
      @jenskaa4044 2 ปีที่แล้ว

      You could also publish with retain and subscribe to the same topic then you will be updated at startup. To be fully persistent remember to set the mqtt server to save the retain messages on disk

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Both are good ideas! Then I only would transfer the consumption. Thanks.

  • @SandeepSandhu
    @SandeepSandhu ปีที่แล้ว

    Is there any mechanism that we can measure AC voltage level, in my flat the voltage fluctuations are common and the AC stops working and gives 88 error which is during high or low voltages. Please make a video if feasible. Thanks

    • @AndreasSpiess
      @AndreasSpiess  ปีที่แล้ว

      You can use any AC meter to measure the voltage. If you want to read it via Wi-Fi you get power meters with built-in Wi-Fi (e.g. Sonoff). They measure voltage, too.
      I already made a similar video.

    • @SandeepSandhu
      @SandeepSandhu ปีที่แล้ว

      @@AndreasSpiess Danke

  • @yekutielbenheshel354
    @yekutielbenheshel354 2 ปีที่แล้ว +1

    This is an excellent video! As usual, you do an excellent job of explaining how to properly engineer solutions. Also, thank you for making another ESP32 video!
    Arduino have done a splendid job of popularizing microcontrollers for students and hobbyists. But generally-speaking-at least for this channel-I suppose using ESP32 for projects is better because it's more powerful than Arduino.
    AI is a buzzword (well, buzz-phrase to be more precise) that I've always hated. Not only does it confuse more than it clarifies, worse still by anthropomorphising machines the term AI wanders out of the realm of science and into the world of witchcraft, magic, and astrology. Machines cannot be intelligent, nor can they experience emotions, nor can they die; but people can.
    When machines perform sophisticated pattern recognition they are not being intelligent nor is there anything artificial about the process.
    Similarly, the term "cryptocurrency" is also a falsehood. An accurate term would be "cryptocollectible." People collect Bitcoin, Ethereum, Dogecoin etc just like people collect stamps, paintings, antiques, etc. Currencies are issued by governments.
    As you know, charlatans, shills, and, well, many ordinary devious marketers perniciously employ puffery to manipulate those who are unsophisticated. Thank you for taking the time to lampoon popular malevolent falsehoods that are often mistaken for "The Truth."
    There is nothing inherently wrong with purchasing collectibles nor with employing sophisticated pattern recognition. However, just as the term "artificial intelligence" sounds more impressive than the phrase "sophisticated pattern recognition" the term "cryptocurrency" sounds more impressive than the term "cryptocollectible". In reality, the terms "artificial intelligence" and "cryptocurrency" are lies which have duped many millions of people.
    As is the case with most people who purchase stocks and bonds, most people who purchase Bitcoin, Ethereum, Dogecoin, etc are not actually investors but rather merely speculators. Similarly, people who buy into the notion that artificial intelligence actually exists-and can actually exist-aren't real engineers; instead they are people who explicitly or implicitly engage in things like witchcraft, magic, and astrology.
    These days, many people seek to become wealthy as either investors or as engineers. In reality, for the average person it is very difficult to earn a significant return on investment (ROI) as either an investor or an engineer because most of the profits-the so-called "lion's share" or disproportionate portion-go to a relatively small number of people.
    Nonetheless, the "lure of easy money" (which is a phrase that comes from Glen Frey's song Smuggler's Blues th-cam.com/video/LSXKyHM133c/w-d-xo.html) or a "gold rush mentality" has led millions of people to "check their brains at the door" (that is, act foolishly).

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I like the ESP32 because it has Wi-Fi. Most of my projects are somehow connected.

    • @yekutielbenheshel354
      @yekutielbenheshel354 2 ปีที่แล้ว

      ​@@AndreasSpiess Wi-Fi seems to be the initial reason most makers move from the Arduino the the ESP32. You seem to be at that stage.
      But if you were to ever move decide to move past "toy projects" (which is what you build for this channel) to more complex projects (which are actually useful to ordinary people in real life), you would likely find that MicroPython very significantly reduces development times.
      An ESP32 project that might take, for example, 200 hours to 300 hours to write and debug in C/C++, might be able to be completed in, say, 25 to 50 hours with MicroPython. In other words, the time difference is huge.
      For toy projects developing and debugging in C/C++ isn't much slower than MicroPython. And sure, if you were to build a robot or a guided missile, MicroPython would be a bad choice. But for most projects that makers tend to build the speed and precision of C/C++ is unnecessary.
      Bad engineers tend to myopically focus on avoiding failure at all costs. Therefore, they habitually over-engineer solutions. For most projects ESP32 projects C/C++ is over-engineering.
      Good engineers properly balance effectiveness against efficiency. It's oftentimes a difficult task. But, in the case of C/C++ vs MicroPython on the ESP32, it is easy to for a good engineer to determine that MicroPython is usually a vastly superior choice.
      The world is full of bad engineers. It is often difficult to avoid upsetting them. Nonetheless, good engineers are willing to endure the wrath of irate bad engineers.

  • @dibyojyotibhattacherjee897
    @dibyojyotibhattacherjee897 2 ปีที่แล้ว

    Hello Andreas, why don't you use visual micro or platformio, I am sure it would be really fun.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      For the channel I use the Arduino IDE because everybody has one. I made videos on both other possibilities.

  • @Chupacabras222
    @Chupacabras222 2 ปีที่แล้ว

    What kind of Hall sensor did you use? Linear or digital one? That plate is plastic or some metal?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Now I checked again. It is metallic but not magnetic.

    • @Chupacabras222
      @Chupacabras222 2 ปีที่แล้ว

      @@AndreasSpiess Linear Hall sensor (like EG49A) could potentially detect it. Digital Hall sensor (like GH1248) is useless for this.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      The LJ123A works, but needs at least 6 volts...

  • @KlausMusch2
    @KlausMusch2 2 ปีที่แล้ว +1

    I think for having better results from the AI, it would be necessary to train it with pictures from the watermeter which is actually used. In German magazine "Make" there is currently a series of articles on how to do this ("AI for ESP32" or "KI für den ESP32" in German, unfortunately behind a paywall). The AI is trained on a PC with python, only the result is transferred to the ESP32. Didn't do it myself, but I would except much better results.

    • @MakerMeik
      @MakerMeik 2 ปีที่แล้ว

      The articles in the German Make are actually by the same author as the water meter project. By the way, this runs extremely reliably for me. But it's true: You should reduce complexity wherever possible if you want reliability.
      However, I bet that 99% of the viewers here don't do that, because in that case we would have to do without our ESPs and Raspis and switch the light on and off at the switch instead ;-)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +2

      Glad the installation works with you. Your counters are much more "clean" than ours. Only one level and nothing covered.
      Fortunately, I get the "Make" every month. But training my project would have been too much time consuming. And the main problems still would be there (glare, 2 dials covered, number between two numerics). So I learned a lot and wait for the next shot.

  • @GlennHamblin
    @GlennHamblin 2 ปีที่แล้ว +1

    I wonder if a circular polarizing lens over the camera lens would knock out the glare?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      Plus a polarizer on the LED. At least this is what others suggested. Mybe I will give it a try.

    • @GlennHamblin
      @GlennHamblin 2 ปีที่แล้ว +1

      @@AndreasSpiess
      I just know that photographers use circular polarizing lens adapters on their lenses to reduce glare.

  • @martingaete8098
    @martingaete8098 8 หลายเดือนก่อน

    "The other things can be made by the MBA's" 🤣🤣🤣🤣🤣 Savage

    • @AndreasSpiess
      @AndreasSpiess  8 หลายเดือนก่อน +1

      I can say that because I also own one ;-)

  • @GordieGii
    @GordieGii 2 ปีที่แล้ว

    They could also be using a metal detector. i.e. An inductive proximity sensor. Alternatively, a hall sensor and a biasing magnet. Inductive proxies are good for any metal, foil if non-ferrous, while hall and magnet is only good for ferrous targets.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      I am even not sure if it is metal or only colored plastic :-(

    • @GordieGii
      @GordieGii 2 ปีที่แล้ว

      @@AndreasSpiess Even if it is metalized film an inductive prox sensor can pick it up. It just needs to be conductive.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      In the meantime I checked the LJ18A3-8-Z/BX sensor and it worked. So it must be metal. Now I have the choice...

  • @chuxxsss
    @chuxxsss 2 ปีที่แล้ว

    Andreas, could I look at the node red flow please 🙏. I am on the edge to about power.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      You find some videos about my flows and AFAIK I added the flows there to copy.

    • @chuxxsss
      @chuxxsss 2 ปีที่แล้ว

      @@AndreasSpiess So in your older vlog mate.

  • @lucapesce3335
    @lucapesce3335 2 ปีที่แล้ว

    You compared pears with apples. In the traditional approach you were able to choose the right tools and write a program to make them work. The equivalent process with such a focused AI tool is training it with your images and your labels (e.g. black background, rotating reflector, ...) After that and maybe some lighting adjustment, the camera-powered solution can be far more reliable than the traditional one (e.g. being able to recover from outage/disaster and being able to store some pictures for periodic manual verification)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Of course I compared apples with pears! And I liked apples more in the end. Comparing apples with apples often does not provide good solutions because your search is too narrow.
      I know that the system can be trained. But for one meter?

    • @lucapesce3335
      @lucapesce3335 2 ปีที่แล้ว

      @@AndreasSpiess you are right, the answer is not obvious, in the economy of such a model it is probably more appropriate to train for a class of objects, let's say the black background meters. I'm saying that a data scientist will find easier to train for your specific meter while sticking to "simple" camera hardware like an old smartphone, compared to developing a dedicated module with opto-things etc. Same things applies to your "traditional" solution if you compare it to a 40 years ago flip-flop based counter, the trend is the same, always more powerful hardware and always more easy to write software for it

  • @phillipneal8194
    @phillipneal8194 2 ปีที่แล้ว

    I agree with your "Barefoot" first idea.

  • @KlausMusch2
    @KlausMusch2 2 ปีที่แล้ว

    How did you do the aggregating in Grafana at position 0:42? I tried "field(value) last() difference()" and "group by time(1h)". But a) this does not work for months and b) fill(previous) doesn't work, so I always have spikes like in fill(linear)

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Grafana does not show the aggregations if the data is not here for the whole period.
      I did not use fill(previous). It would not make a lot of sense for consumption. But I also have to try till it looks good.

  • @SarahKchannel
    @SarahKchannel 2 ปีที่แล้ว

    pretty much all out water and EL meters here, have an IR LED under the clear cover, so that the 'meter man' can simply place a reader on top to take the reading, eliminating human errors. Well that was until recently, now the wast majority of our meters have been replaced by IoT meters and read online anyway.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      We are old-fashioned here. I as the owner has to read the meter once a year and send this info to the community. Water here still comes from them.

    • @SarahKchannel
      @SarahKchannel 2 ปีที่แล้ว

      @@AndreasSpiess Funny enough our meters in the middle east are Landis+Gyr :)

  • @michaelbolling8747
    @michaelbolling8747 2 ปีที่แล้ว

    In the past I heard hair spray may help to avoid reflections.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว +1

      I would not want to try it because I do not know what it would do with the plastic and if it could be removed later. And I need the counter for the next few years ;-)
      I use hairspray for my 3D printer, BTW. But on a metal plate.

  • @Embeded_Geek
    @Embeded_Geek 9 หลายเดือนก่อน

    6:36 other things can be done by MBA. Got me laughing 🤣

    • @AndreasSpiess
      @AndreasSpiess  9 หลายเดือนก่อน

      I can say that because I have a Ph.D. in Business Administration, too ;-)

  • @lemd49
    @lemd49 2 ปีที่แล้ว

    Very interesting experiments, and they seems to concur with recent articles on AI in our monthly IEEE Spectrum magazine

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      Glad others got similar results...

  • @science4allworld587
    @science4allworld587 2 ปีที่แล้ว

    How is current consumption of the ESP version with battery support ?

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      The battery only will be for backup. It consumes around 100mA.

  • @romancharak3675
    @romancharak3675 2 ปีที่แล้ว

    Can you get the ESP32 to send you a low-res photo? Then you can read the numbers yourself? Interesting video, Andreas, Thank you.

    • @AndreasSpiess
      @AndreasSpiess  2 ปีที่แล้ว

      It could send pictures. But I have to do other things than readding numbers all the time ;-)