-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/display data from response #4
base: master
Are you sure you want to change the base?
Feature/display data from response #4
Conversation
052192a
to
f55f3cf
Compare
f55f3cf
to
64ca409
Compare
…data from the response
64ca409
to
e701ea9
Compare
… and cabling it correctly in the code to keep all PI elements perfectly distinct in name
Just realized while coming back to the PR today to properly add the unit in the config (as the screenshot code was hardcoded) that it is missing the polling capability. |
Note for myself: I noticed this morning after a fresh boot that the refresh timeout seems not-to-be honored as I had the warning sign about every 15s (as the DNS was not resolving yet) despite the fact my buttons were configured to refresh every 300 or 600s. |
Hi @mjbnz, sorry for the delayed update. I finally found some time to track the polling bug I mentioned earlier. The good news was that I missed one line to plugin the polling into to frequency calculation 😀 |
+1 to this feature. It would be great to see the functionality added. |
will this feature merged? |
Hi @killriam, I have been using it daily at work on 5 buttons and cannot get enough of it ;) (many thanks to @mjbnz for developing this very useful plugin !) |
i tried out this pull request as a plugin, but still i am not able to find the json path i think... |
Looking forward to see this merged! |
I did not find the release you mentioned here. Is it still available? Thanks! |
FYI, you can just download the source ZIP file from https://github.com/Commit-La-Grenouille/streamdeck-api-request and copy the contents within the Source folder into the "com.github.mjbnz.sd-api-request.sdPlugin" folder you already have (yes to overwrite). Restart the streamdeck app. You'll probably have to recreate any buttons using it though. That's all the "release" really is. Note it won't work unless you set a background image. And getting a different value to show from a different URL than what the button does is broken. (Which is changeable if you feel like editing.) At some point I might work on a text-only fork, as this does exactly what I need, with a secondary polling URL, but I only care about text from the response and want to use library images. |
Thanks @rgreer4 for sharing the deployment trick. As for the limitation, I would be interested by a simple reproducer using a public service to look into it and adjust this PR accordingly (the more useful the PR the better) ;) |
I am trying to install it on 6.5 but I am not able to... I couldn't even find the "com.github.mjbnz.sd-api-request.sdPlugin" folder so I can replace with @Commit-La-Grenouille code... is there a way to provide the sdPlugin package? Seems that @mjbnz is not maitaining it anymore... |
Hi,
as discussed in issue #3, here is a possible implementation of the display of data from the response on the button (latest stable on the right and this PR's code with the same API call on the left):

This implementation uses the setTitle() to display the data on the button. The good: the user can leverage the title config (color, location, font size...) from the config to control the look of the text. The bad: you cannot use the Title field (otherwise it will hide the data from setTitle()) and must use the name field instead.
I will give a look at an alternative implementation where the data from the response is rendered as bitmap instead (but not quite sure how good it will look and it will come with its limitations on text style if we want to keep the config reasonably compact).