sofie-core icon indicating copy to clipboard operation
sofie-core copied to clipboard

feat: Input gateway support

Open jstarpl opened this issue 3 years ago • 1 comments

  • What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)

This is a feature

  • What is the current behavior? (You can also link to an open issue here)

  • What is the new behavior (if this is a feature change)?

This PR aims at implementing an API for trigger gateway (input gateway) peripheral devices. This will allow for such things as native Stream Deck plugin integration, HTTP, MIDI, GPI, Serial triggers, etc.

The plan for this implementation is as follows:

  • Add a Mounted Triggers publications for peripheralDevices, so that devices can know what they will trigger
  • Add core peripheralDevice API methods for sending triggers into Core. The trigger payload will be a key-value object.
  • Add a Last Trigger publication so that the UI can pick that up when assigning triggers to actions

This will allow us to listen for triggers in very much the same way we do for hotkeys, i.e., the Input Gateway will not need to present a manifest of possible triggers, but we should be able to expand on this API later, if needed (say, have an X-Y-Z joystick control into a DVE AdLib Action?)

  • Other information:

Status

  • [ ] Code documentation for the relevant parts in the code have been added/updated by the PR author
  • [ ] The functionality has been tested by the PR author
  • [ ] The functionality has been tested by NRK

jstarpl avatar Aug 30 '22 09:08 jstarpl

Codecov Report

Base: 73.75% // Head: 70.97% // Decreases project coverage by -2.77% :warning:

Coverage data is based on head (6716400) compared to base (5ee78a7). Patch coverage: 28.03% of modified lines in pull request are covered.

Additional details and impacted files
@@              Coverage Diff              @@
##           release49     #756      +/-   ##
=============================================
- Coverage      73.75%   70.97%   -2.78%     
=============================================
  Files            292      317      +25     
  Lines          34349    36106    +1757     
  Branches        3521     3909     +388     
=============================================
+ Hits           25333    25626     +293     
- Misses          8777    10184    +1407     
- Partials         239      296      +57     
Impacted Files Coverage Δ
...teor/client/lib/reactiveData/reactiveDataHelper.ts 60.97% <ø> (ø)
meteor/lib/api/client.ts 100.00% <ø> (ø)
meteor/lib/api/triggers/RundownViewEventBus.ts 88.88% <ø> (ø)
meteor/lib/collections/TriggeredActions.ts 100.00% <ø> (ø)
meteor/lib/collections/lib.ts 46.35% <ø> (ø)
meteor/server/api/client.ts 55.40% <ø> (ø)
meteor/server/lib/customPublication/publish.ts 23.33% <ø> (ø)
meteor/server/publications/lib/observerChain.ts 2.17% <0.00%> (ø)
...rver/api/deviceTriggers/ReactiveCacheCollection.ts 9.43% <9.43%> (ø)
...r/api/deviceTriggers/StudioDeviceTriggerManager.ts 9.43% <9.43%> (ø)
... and 36 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

codecov-commenter avatar Aug 30 '22 09:08 codecov-commenter

⚡ Published prerelease version server-core-integration@1.49.0-nightly-feat-triggerGateways-20230109-123747-3c71f04.0 to NPM

github-actions[bot] avatar Jan 04 '23 15:01 github-actions[bot]