LA1TV / Hyperdeck-JS-Lib

A javascript library for communication with the Blackmagic Hyperdeck.
MIT License
26 stars 8 forks source link

{Node-Red} is it possible to use this code within NodeRed? #78

Open MDAR opened 1 year ago

MDAR commented 1 year ago

Hello everyone

I'm not a coder in any sense of the word, so please forgive me if what I'm about to ask is impossible.

"Is there any way this JavaScript could be packaged to with as nodes within NodeRed?"

So that us lesser mortals can make use of it?

https://flows.nodered.org/flow/195773d3b493d81c9bf012f64da02ea3

https://nodered.org/docs/creating-nodes/

tjenkinson commented 1 year ago

Hey @MDAR,

I’ve never used node red before. Do you have an example if something you want to achieve?

E.g. do you have a set of nodes in node red and you want to have a node that when triggered would start recording on a hyperdeck?

If the js in a node is able to open sockets it sounds feasible

MDAR commented 1 year ago

Thank you so much for replying.

My use case is that I want to use a Shuttle HD (because of it's jog wheel) to be a master for a small bank of Hyperdecks

All record All Stop All Playback All Jog back and forth ect

So I'm looking for a way to mirror the events on the Shuttle to other decks.

(I know that HyperDeckPanel can present one software surface and sync multiple HyperDeck units, it's just the hardware surface that I'm trying to create)

Node-RED can easily open UDP and TCP ports.

I'm happy to explore options is you can point me the right direction.

tjenkinson commented 1 year ago

I've created a build in a single file here: https://github.com/LA1TV/Hyperdeck-JS-Lib/blob/bundled/bundled.js

So you might be able to paste that in at the top if your file and then use the HyperdeckJSLib variable.

It might fail though at the require of node core modules on the last line. They might need tweaking a bit to load in the modules in the way that node red does it if it does it in a different way

MDAR commented 1 year ago

Wow

Thanks

I'm not entirely sure what to do with this, I but will spend some time next week trying to learn.