Adafruit Shield Motor V2 problems

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
pw444
Normal user
Posts: 155
Joined: 23 Apr 2019, 15:34
Location: rio de janeiro

Adafruit Shield Motor V2 problems

#1 Post by pw444 » 20 Mar 2021, 15:03

Hya,

tried the following rule with plugin P048

Code: Select all

On System#Boot do    //When the ESP boots, do
  let,1,0
  let,2,0
  logentry, "start"
endon


on OPEN#status do
   if %eventvalue%=1
      logentry,"forward"
      let,1,1
      MotorShieldCMD,DCMotor,4,Forward,100
    else
      logentry,"backward"
      let,1,0
     MotorShieldCMD,DCMotor,4,Backward,100
   endif
endon
problem: event OPEN#status NEVER reaches.

User avatar
Ath
Normal user
Posts: 3418
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Adafruit Shield Motor V2 problems

#2 Post by Ath » 20 Mar 2021, 15:16

How do you expect that event to be triggered? By a button, external command, other...?
/Ton (PayPal.me)

pw444
Normal user
Posts: 155
Joined: 23 Apr 2019, 15:34
Location: rio de janeiro

Re: Adafruit Shield Motor V2 problems

#3 Post by pw444 » 20 Mar 2021, 15:18

button, OPEN ;-)

seams that

Code: Select all

MotorShieldCMD,DCMotor,4,Forward,100
takes over and nothing else works.
Attachments
Screenshot_20210320_112058.png
Screenshot_20210320_112058.png (98.6 KiB) Viewed 7464 times
Last edited by pw444 on 20 Mar 2021, 15:23, edited 1 time in total.

User avatar
Ath
Normal user
Posts: 3418
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Adafruit Shield Motor V2 problems

#4 Post by Ath » 20 Mar 2021, 15:22

By default the Value for a Switch device is named State, you have used status, could that be a typo/mistake?
Edit: Aha, now I see the names on the screenshot. So no typo.

Do you have a serial log of the unit?
/Ton (PayPal.me)

pw444
Normal user
Posts: 155
Joined: 23 Apr 2019, 15:34
Location: rio de janeiro

Re: Adafruit Shield Motor V2 problems

#5 Post by pw444 » 20 Mar 2021, 15:23

no. see the screen print.

pw444
Normal user
Posts: 155
Joined: 23 Apr 2019, 15:34
Location: rio de janeiro

Re: Adafruit Shield Motor V2 problems

#6 Post by pw444 » 20 Mar 2021, 16:46

Got it working. A bad cable caused the mess.

Thx!

User avatar
Ath
Normal user
Posts: 3418
Joined: 10 Jun 2018, 12:06
Location: NL

Re: Adafruit Shield Motor V2 problems

#7 Post by Ath » 20 Mar 2021, 18:37

pw444 wrote: 20 Mar 2021, 16:46 Got it working. A bad cable caused the mess.
That was the next question I had in mind.

Great it is fixed.
/Ton (PayPal.me)

Post Reply

Who is online

Users browsing this forum: No registered users and 28 guests