I thought it might have been you I had helped out in the old forum, but I couldn’t find the post to check. Hope everything (aside from this feedback issue) has been working well in the meantime!
I took a look at the docs and your plugin code. It’s not 100% clear to me from the docs, but if you look at pg. 48, where it is describing the Inquiry commands and the Basic format, I think what may be happening is that the projector responds in the same command format that you send commands in. Otherwise, it doesn’t really make sense to list the “parameters” for the various inquiry commands, because it would be very inefficient to have to query each option to find out which one is correct. So, for example, if you send:
I think what you would get back is:
\x02QPW:000\x03 (if off)
\x02QPW:001\x03 (if on)
If so, the trick is to parse that before going into your switch statement. As you can see in the Runco Projector plugin code, I had to do something similar on that projector with the:
responseVal = response.split(" = ");
In that case, you would send the command then get back the command followed by
" = <value>".
Here, you could do something similar with
.split(":"), which would give you everything to the right of the colon (
000\x03). The only trick at that point is to strip the \x03, which is probably a non-visible character. I don’t know whether the
.trim() call that is already there will strip that or not; it’s typically used for stripping whitespace and I’m not sure how it would work on the
split() and the existing
trim() to see if that does the trick. Another thing to try, although very clunky, would be to invoke
split() a second time like:
split("\x03"), which would give you everything to the left of the
Hopefully some of that is useful–happy to keep spitballing, but some more details on what exactly is coming back from the projector would be very helpful.