Stepper.Setup syntax error

Here we can discuss about the problem found
Post Reply
User avatar
Electroguard
Posts: 857
Joined: Mon Feb 08, 2021 6:22 pm
Has thanked: 273 times
Been thanked: 321 times

Stepper.Setup syntax error

Post by Electroguard »

The pic shows a syntax error when trying to initialise a stepper motor... is minimal content just to show no interference from anything else.
Tried running an original prog on its original old device with its original firmware from last year, but started causing network problems again, so upgraded - but then kept getting the syntax error with 1.52.1, and also when reverting back to 1.51.9 and 1.59.8 (and is the same when using other pins)
stepper_syntax_error.jpg


Also noticed a couple of typo's have crept into the Digital I/O section of the Help by the way, the example for pin 5 has blue '1' in front of the 5 making it look like 15, and there is a red vertical bar in the line above.

pin.jpg
You do not have the required permissions to view the files attached to this post.
Zim
Posts: 286
Joined: Mon Feb 08, 2021 9:15 pm
Has thanked: 262 times
Been thanked: 128 times

Re: Stepper.Setup syntax error

Post by Zim »

just wondering if you have to pin.mode as an output first?
User avatar
Electroguard
Posts: 857
Joined: Mon Feb 08, 2021 6:22 pm
Has thanked: 273 times
Been thanked: 321 times

Re: Stepper.Setup syntax error

Post by Electroguard »

No Zim, in fact I would have configured them as digital outputs just to prove they were ok if it was possible to relinquish them after, but I didn't see any way to release them again (which is how come I noticed the digital I/O typo's)... and you can't have the cake and eat too - it is one or the other.


Francesco, It seems to be related to the multi-channel syntax, cos the original 1.51.3 single-channel implementation works fine, but simply omitting the channel number in the multi-channel versions still caused a syntax error.
orig.jpg
You do not have the required permissions to view the files attached to this post.
User avatar
cicciocb
Site Admin
Posts: 2041
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 436 times
Been thanked: 1340 times
Contact:

Re: Stepper.Setup syntax error

Post by cicciocb »

In the latest version you must always specify the channel but I need to check, maybe I removed the code from the final compilation by mistake :oops:
Post Reply