• HugeNerd@lemmy.ca
    link
    fedilink
    English
    arrow-up
    112
    ·
    2 months ago

    “it was actually a PY32F002B, powered by a 24 MHz Arm Cortex M0+ processor. The chip also carried 24KB of flash storage and 3KB of static RAM”

    To process a single button.

    • Aceticon@lemmy.dbzer0.com
      link
      fedilink
      English
      arrow-up
      19
      ·
      edit-2
      2 months ago

      Well the PY32F002B (costing a few cents) even though it has a 32-bit (entry level) ARM core @ 24MHz is literally cheaper than older and less powerful microcontrollers.

      Granted, if you don’t do anything else than react to a push button it’s still cheaper to use discrete electronic components than a microcontroller, but given that this device has a LiPo battery (meaning there’s battery control involved) and judging by the picture a USB-C connector, there’s probably a bit more digital logic in it, by which point a 3 cent microcontroller plus a cheap SMD crystal and some caps is cheaper than using discrete components.

      The domain of embedded systems has evolved to the point that it’s the best option for almost everything in consumer electronics, mainly because at the lower end there are so many stupidly cheap and easy to use choices were you don’t run an OS in it but instead just a single block of single-threaded code directly on the bare metal accessing registers directly.

      • KairuByte@lemmy.dbzer0.com
        link
        fedilink
        English
        arrow-up
        11
        ·
        2 months ago

        Temperature control, likely something to keep track of how much is left in the device, and I’m betting I’m forgetting something.

        I doubt discreet electronics can cut it at that point.

        • Aceticon@lemmy.dbzer0.com
          link
          fedilink
          English
          arrow-up
          4
          ·
          2 months ago

          Yeah, as per the analysis I did in another post, even a 555 and a couple of transistors to just blink an LED is more expensive than putting a microcontroller like this one there.

      • merdaverse@lemmy.zip
        link
        fedilink
        English
        arrow-up
        7
        arrow-down
        1
        ·
        edit-2
        2 months ago

        It’s crazy to think that this is basically more powerful than the Apollo Guidance Computer that got people onto the moon. It costs 3 cents, and we use it for shit like this and then throw it away. What spectacular waste.

    • Lovable Sidekick@lemmy.world
      link
      fedilink
      English
      arrow-up
      3
      ·
      edit-2
      2 months ago

      Yes, where “process” means measuring instantaneous changes in airflow as the user inhales (or doesn’t), and regulating a heating coil accordingly by running actual program code - which requires a controller to run it and memory to store it in. I mean when you click “Reply” on this page all it has to do is process one button, but that involves a lot.

      • Corkyskog@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        1
        ·
        2 months ago

        Some of them have games like snake you can play in class on them. I mean that’s what I assume its for, any adult would use their phone.

      • kevinsky@feddit.nl
        link
        fedilink
        English
        arrow-up
        1
        ·
        edit-2
        2 months ago

        All that logic is still a choice though. You could also just instruct the user to not press the button unless they’re inhaling and just actually have it be an on and of button. That’s how vapes used to work. Worst thing that could happen there is that you burn the wick, which is only a problem because it’s not serviceable.

    • Melobol@lemmy.ml
      link
      fedilink
      English
      arrow-up
      2
      ·
      edit-2
      2 months ago

      There were couple series of: full lcd screen, bt connected to smartphone for notifications and a speaker versions. Plus the rechargeable battery and usb c charging port (obviously).
      It was selling about 35 bucks.
      Forgot the game one: had controller buttons and 3 games: pacman, tetris and a lying shooter inbuilt. With full lcd and speaker. (Thus wasnt bt connected tho) Price was similar.