Ez Script Control Button Keeps Showing "stopping"

 
#1

Hi all,

I have several EZ Scripts written that are triggered and stopped by other scripts. Every once and a while when one is stopped it will show "stopping" on the Start/Stop button. Not sure but I think it only happens on scripts where loops are running. Once the "Stopping" message appears on the button I cant operate it. Any ideas? Here's a pic:

User-inserted image

I still need to migrate all my scripts into a Script Manager. Don't know if this will help once I do that.

#2

Mine has done that on occasion, I'm yet to pinpoint the cause though.Usually its fine but every now and then, for no real reason it'll do that.

#3

Good to know I'm not alone. Misery loves company. Winky

It's not a big issue to my (yet) but it does make me restart EZ Builder sometimes so I can get control of that script again.

#4

Stopping is when it's stopping. You've asked the script to stop using a ControlCommand(). If the script you asked to stop is doing something, it will be in stopping state until it stops.

Imagine driving toward an intersection and the light turns red. When you press the brake, you don't stop to a halt - instead you begin stopping... Eventually you stop. Smile

#5

I'm guessing Dave has the same issue as me on this but it will say stopping for what seems like forever (well, until I close EZ-Builder), I've left it for a good 20-30 minutes before and it's never stopped. I haven't found the cause and when I try to force the issue to happen it doesn't... When I figure out how to replicate the error I'll give more details but as of now all I know is that sometimes it will be forever "stopping" but no idea why.

It happens with ControlCommand and manually clicking stop in my experiences. I guess it's when it's in the middle of doing something like a loop or moving a servo or something but honestly I have no idea.

#6

If you can replicate or provide your project then I can take a look

#7

Rich is correct. Just to clearly it more; the actions the script are running when the stop command is issued (from whereever) will stop. However the Start/Stop button on the control window where that script resides will show "Stopping" and stay that way till I restart EZ Builder. While "Stopping" is showing on the Start/Stop button I cannot operate it. However I can get into the control through it's settings button and change things.

In my project this will happen every time to the "Radar Rutine 1" control after the Init Script runs and it cant connect to my 3 EZB's because they are off or out of Bluetooth range. Not sure why that "Radar Rutine 1" control is effected at start up as the only thing that calls it is a script in the Speech Recognition control (I think).

It does happen to other controls sometimes also and other then the example given above seems random to me. Cant find the common event that causes it.

Here's my project (sorry, it's a little messy. I need to clean it up a bit and start using the Script Manager):

B9RobotControl.EZB

Thanks for offering to look into this,
Dave Schulpius

#8

Have you used the Flow control under Scripting to view where "Radar Rutine 1" is being controlled from?

#9

OK, after looking at my Script Flow chart I see that "Radar Rutine 1" is called by the "Kill" script with a command:
ControlCommand("Radar Rutine 1", ScriptStop)
That "Kill" script is called by the Init Script at EZ Builder start up and stays running as a loop looking and waiting for a switch to close.

Could it be that if a control is not running and a stop command is sent to that control it will keep showing "Stopping" on the Start/Stop button. would it also hold that button hostage trying to stop a script that is already stopped?

Just thinking it through here.
Dave Schulpius

#10

If this is happening mostly due to Bluetooth not connecting, then use the IsConnected() function after the connection attempt.

Now, just to make sure... Does your version have an IsConnected() EZ-Script command? To be honest, my brain is quite a mess right now and i'm not sure how recent that command is. It might just be in my beta version lol