🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Problems with Vibrator Motor Unit in uiflow

    General
    4
    4
    6.1k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • drjakobD
      drjakob
      last edited by drjakob

      The Vibrator Motor Unit is still missing as a unit in uiFlow 1.2.3 and 1.4.5. The official sample code (https://docs.m5stack.com/#/en/unit/vibrator ) won't work with M5Stack fire. The program always crashes when I try to digitalWritePin 26. Any ideas how to get vibrator motor working?

      1 Reply Last reply Reply Quote 0
      • lukasmaximusL
        lukasmaximus
        last edited by

        you need to use the PWM blocks instead of digitalwrite, digital write is just for off and on but PWM can control the speed of the motor

        1 Reply Last reply Reply Quote 0
        • world101W
          world101
          last edited by world101

          Same thing for me on the Fan unit (which has the same N20 motor as the Vibrator motor unit). I tried PWM on Pin 26, but it just crashes after running the program.

          0_1588963069604_Screen Shot 2020-05-08 at 2.37.38 PM.png

          Even if I upload an empty flow with blank setup and loop functions, as soon as the M5Stack Fire boots, it tries to start the fan and crashes/reboots.

          I'm testing on Port B. If I switch to Port A, that port has power all the time and turns the motor on full blast and I'm not able to control it.

          1 Reply Last reply Reply Quote 0
          • ajb2k3A
            ajb2k3
            last edited by ajb2k3

            Don't use it on port A use it only on port B.
            Confirmed, the motor doesn't work properly.
            I am sure that the unit only works as on or off as it only has an on/off transistor not a PWMable transistor.

            UIFlow, so easy an adult can learn it!
            If I don't know it, be patient!
            I've ether not learned it or am too drunk to remember it!
            Author of the WIP UIFlow Handbook!
            M5Black, Go, Stick, Core2, and so much more it cant be fit in here!

            1 Reply Last reply Reply Quote 0
            • First post
              Last post