Questions about Mode

@jody.albritton @erickv @nayelyz

Long time no see! It’s me who always bother you through some questions…
I’m always feel sorry about that but you know that I am always thankful.

Today my question is about mode/automation.

I have defined multiple modes (I said the mode requests the control commands of each capabilities together), and while testing, I have a question because I don’t understand something.

The normal concept as I understood is it’s work by tapping the play icon next to it.
after tapping it turns into a refresh icon and when the command is executed normally,
it changes to a check icon!

But it seemed a little ambiguous because the check icon was already changed in the APP UI
before my STSC even returned the result of the command. (What?)
Would you tell me why this happen?

Also, What is the exact condition the Icon ‘!’ to occur?

When I test my service, It happens with a really low frequency, but I don’t know this condition.
(The reason I want to know about this icon is that it shouldn’t happen after service already been published. So I’m trying to prevent it before publish.)

I thought it would be occur when my STSC return the commandResult lately.
However, it seems not because the check icon is already displayed before it receives my commandResult!
I want to know about specific condition about the icon ‘!’.

If you want for the accurate test , I can give you an account to test my service!.

Also I attached some image for your quick understanding.


1 Like

Hey, @Maxwell_Kim

It’s nice to know you’re still there!

I’ll replicate the workflow you mention with an ST Schema app to track the necessary evidence of the issue and as soon as I get some results, I’ll reach back to you.

As for, the “!” icon, it is generally used for unsuccessful actions due to unreachable devices on unavailable services, e.g. when a user needs to refresh their ST Schema authentication.

1 Like

Just to be in the same channel, are you using the ST Schema NodeJS SDK?

No I used Java Instead. (With spring framework + spring oauth)
But Instead, I referred to the javascript stsc in GitHub. GitHub - SmartThingsCommunity/st-schema-nodejs: ST Schema helper library for NodeJS

I wonder that “!” mark means unreachable device but what is the condition of unreachable device?

1 Like

Hey, @Maxwell_Kim

Following-up, I’ve been testing the workflow of Scenes based on the delay of command responses, and I’ve noticed the following:

  • By delaying success responses:

    • At the Scenes page, the refresh spinner can wait for a max of 5 seconds, and then the checkmark will appear.
    • At the Dashboard, the spinner will wait only 2 seconds, and the checkmark appears.
  • Using error responses:

    • Regardless of the delay set, the SmartThings app triggers the error pop-up along with the “!” icon immediately.

Based on these results, I recommend two approaches:

  • Implement the proper Error Responses if devices take too long to respond. This way, the users will be aware that something didn’t work.
  • Take advantage of refresh delay, but implement State Callbacks on your side, to guarantee that the new state has been applied, let’s say… If the device keeps me waiting for 2 seconds → trigger State Callback instead.

Please, let me know if you have any other questions.

How can you answer so clearly and kindly!
Thank you very much.
Now I can make the condition clearer when I test it!

Um… but can I ask you one more question? then what is the condition of the infinite spinner icon?
It seems to be a separate problem.

Thank you so much!

Thanks, @Maxwell_Kim , anytime! = )

As for an infinite spinner animation, I believe such a thing is not possible. Also, I pretty sure that the certainty of the Scenes animation relies mainly on the kind of Device Integration.

For example, ST Schema devices do not interact directly with the SmartThings App (nor the API), therefore, its communication relies on the Schema Connector, which in my opinion, must be able to address these communication details to enhance user experience.