Free Text Editing


#1

1) Give a description of the problem
Is there a way to enter custom text rather than the dropdowns?

2) What is the expected behaviour?
See above

3) What is happening/not happening?
See above

4) Post a Green Snapshot of the pistonimage
(UPLOAD YOUR IMAGE HERE)

5) Attach logs after turning logging level to Full
(PASTE YOUR LOGS HERE THEN HIGHLIGHT ALL OF THE LOGS AND CLICK ON THE </> ICON TO FORMAT THEM CORRECTLY)

REMOVE BELOW AFTER READING
If a solution is found for your question then please mark the post as the solution.


#2

Yes. Simply change “Value” to an “Expression”…

temp

It acts like a mini-editor, and shows the response in the grey box right then and there…


#3

I think that would work if I could choose Expression when adding a Task, but I don’t see that as an option. I’ve attached screenshots. I’d like to be able to type home() like you can see away() in the previous if command.



#4

I believe what is available in the drop down menus are entirely dependent on the code in the Device Handler.


#5

Makes sense, so I went and looked at the Custom DTH on the ST IDE. I can see ‘off’ and ‘home’ as options in addition to ‘away,’ but that doesn’t seem to make it available in webCoRE.


#6

I am sure those three would be listed somewhere in the DH code… but not sure if that is the right section of code for the dropdown.

Maybe try searching the code for the phrase:
"Pan camera to the Home"
or
"Strobe and Siren"
as seen in your earlier screenshot.


#7

Oh wait a minute… I just noticed that your screenshot says “Commands available to all devices”. This means that those listed above are not coming from the DH, but instead from the built-in (generic) handler from SmartThings.

Do you know how to change Device Handlers for a device?
It might be worth double checking.

Changing the Handler changes the available options in the dropdown…
(I always hard refresh my browser after changing, and before editing anything)


Then again, (I won’t mention any names, but) I have seen more than once where it was as simple as needing to scroll down farther in the drop down to see more options.


#8

It’s a Custom DTH making Ring Alarm and its sensors available in ST, so there are not other DTH options.

I’m positive the other options aren’t available and although it’s listed under ‘All Devices,’ the away() command works in the webCoRE piston.

There doesn’t appear to be a device-specific section of the dropdown either.


#9

Here’s the section that I think is relevant from the DTH:

def off() {log.info “Setting Ring Alarm mode to ‘Off’”
callApiAndUpdateEvents(‘off’)}

def home() {log.info “Setting Ring Alarm mode to ‘Home’”
callApiAndUpdateEvents(‘home’)}

def away() {log.info “Setting Ring Alarm mode to ‘Away’”
callApiAndUpdateEvents(‘away’)}

I think “Commands available to all devices” actually does make sense since I’m only trying to assign this task to the one device (Ring Alarm with Sensors)


#10

This usually means that either:

  • You are trying to push code to a device that sends data, but does not receive any.
    (For example, with a magnetic door contact, there is no command allowed to “Close” it, since SmartThings cannot actually force the door shut)

  • …or you are using the default (generic) Handler for that device
    (which means some basic commands like “away” may work, but very few of the advanced commands will)


With everything you have said above, I am leaning towards the latter. I suspect that you are not using the desired “Custom DTH”. You can verify/change which Handler you are using by:

  • Use a web browser to log into the IDE
  • Click on “My Devices” up top
  • Click on the offending device (Ring Alarm With Sensors)
  • Click on “Edit” at the bottom of the page
  • The dropdown next to “Type”, select your “Custom DTH” or an alternative
  • Click on “Update” when done

(Note: Sometimes I have to be in an Private/Incognito window to do these steps)


I usually wait a couple of minutes after a change… Then hard refresh my web browser (Ctrl-F5)… Then open webCoRE’s Dashboard, and create a new, single line piston for testing.

You should know right away, because there will be more available choices in the device’s dropdown menu. Of course, not every device/command works with every Device Handler, so you may have to repeat the steps to try out another.


Side Note:

When talking about Custom Device Handlers, I usually direct specific questions on the forum where I found the DH. That is where the real experts (and those most familiar with the specifics) will hang out…


#11

I figured it out. More here (https://github.com/asishrs/smartthings-ringalarm/issues/25)

Thanks for your help!