Skip to content
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

Streamdeck as input device. #78

Open
WooterTheTroubleshooter opened this issue Jan 31, 2019 · 7 comments
Open

Streamdeck as input device. #78

WooterTheTroubleshooter opened this issue Jan 31, 2019 · 7 comments

Comments

@WooterTheTroubleshooter

Are there any plans to support/allow the Elgato Stream Deck as an input device?

They should have a developer api available.

@evilC
Copy link
Collaborator

evilC commented Jan 31, 2019

Yes, I bought an SD with the intention of working out how we might integrate it with UCR.
It's going to be relatively tough though with the way UCR works at the moment, especially if we wish to support setting arbitrary images on the buttons in response to input - the way UCR works at the moment, all sending is done by Indexes (numbers) rather than strings of text (eg a path to an image).
So either we need to make some concessions (Maybe have a config file that says "Image 1 is C:\somefile.jpg") or we need to extend UCR to support non-indexed inputs and outputs.
Either way, plugins in UCR do not currently support arbitrary GuiControls (eg something to display images, so you can select which image to assign to a button), so that's an additional hurdle.
Other features (eg support for Voice commands) would probably want similar changes, so I am leaning towards the latter.
In the meantime, I wrote a library for AutoHotkey called AutoHotStreamDeck, which gives you full programmatic control over the SD.

@WooterTheTroubleshooter
Copy link
Author

WooterTheTroubleshooter commented Jan 31, 2019

How about adding an action to the stream deck that calls an UCR api instead? I can now look for custom actions in Stream Deck through the "More actions" button?

Edit: Here is the url to the SDK to create custom actions. Which apperently also allows changing the icon and such. SDK
As a start I would be happy with just triggering UCR actions/chains by setting one button on the Stream Deck to that action.

@evilC
Copy link
Collaborator

evilC commented Jan 31, 2019

The SD SDK that you linked is fundamentally different to the API that I am using to interact with the SD hardware - they are totally unrelated.
My code just interacts with the device directly via HID.
The SDK is for building DLLs that plug in to the Elgato software, so I would need some way for that DLL to be able to interop with UCR.
Also, it seems that SDK is JS, C++ or Objective-C only, none of which I am proficient in.

@WooterTheTroubleshooter
Copy link
Author

Looking into it somewhat further. The 'plugin' is essentially a command-line executable that is expected to start a websocket.
Then communicate with the Stream Deck software through that websocket.

What is the current route/plugin/wrapper for custom UCR plugins, is that IOWrapper?

@evilC
Copy link
Collaborator

evilC commented Jan 31, 2019

Oh, that sounds interesting.
yeah, iowrapper is what actually handles the I/O

@evilC
Copy link
Collaborator

evilC commented Jan 31, 2019

Still not 100% sure how this would work. I have done a little reading of the SDK docs, still not quite seeing how to go about this.
It seems to me that UCR itself cannot be the plugin - the plugin would be a proxy between the SD app and UCR. I am guessing that we would maybe need to have UCR communicate with the plugin via WebSockets or something, then the plugin communicates with the Elgato app?
BTW, feel free to pick this conversation up on Discord

@fredemmott
Copy link

There's also third-party C# SDK at https://github.com/BarRaider/streamdeck-tools

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants