Skip to content

Commit 35ba3cf

Browse files
authored
Merge pull request #15 from VideoBSO/fix-fw261-messaging
Fix variables and breakage with latest pulse fw release `2.6.1`
2 parents e4d0164 + 66a2209 commit 35ba3cf

File tree

7 files changed

+71
-17
lines changed

7 files changed

+71
-17
lines changed

README.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,23 @@ See HELP.md and LICENSE
1515
* Added presets for new commands
1616

1717
**V1.1.4**
18-
* Added the ability to block Standby and Eco modes
18+
* Added the ability to block Standby and Eco modes
19+
20+
**V2.1.0**
21+
* Add command to set Illumination value and get back the current value as Variable
22+
23+
**V2.2.0**
24+
* Add Activation of Profiles
25+
26+
**V2.3.0**
27+
* Added variable `illumination_value` that returns percentage of current laser power
28+
* Generally fixed following variables:
29+
* `identification` for article number
30+
* `identifiction_family` for model name
31+
* `illumination_state` which returns power state of laser unit
32+
* `serial_number`
33+
* `firmware_version`
34+
* Fixed breakage through Pulse Firmware `V2.6.1`:
35+
* `power_state`
36+
* `illumination_value`
37+
* `shutter_postion`

companion/HELP.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
* **Power state** on/off
66
* **Ilumination** on/off
7+
* **Illumination Values** Integer Percentage (default = 100, min = 15, max = 100)
78
* **Input selection** Currently HDMI / Displayport **Not tested**
89
* **OSD** on/off
910
* **Shutter** open/close/toggle
@@ -17,4 +18,15 @@
1718
* **Factory Reset** Factory Reset the device
1819
* **Activate Profile** Run a profile/macro on the device
1920

20-
* **Presets availible for all included commands!**
21+
* **Presets availible for all included commands!**
22+
23+
## Currently supported variables:
24+
25+
* **Firmware Version** firmware_version
26+
* **Identification** identification
27+
* **Identification Family** identification_family
28+
* **Illumination State** illumination_state
29+
* **Illumination Value** illumination_value
30+
* **Power State** power_state
31+
* **Serial Number** serial_number
32+
* **Shutter State** shutter_position

companion/manifest.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"name": "barco-pulse",
44
"shortname": "pulse",
55
"description": "Barcos Pulse Platform",
6-
"version": "0.0.0",
6+
"version": "2.3.0",
77
"license": "MIT",
88
"repository": "git+https://github.com/bitfocus/companion-module-barco-pulse.git",
99
"bugs": "https://github.com/bitfocus/companion-module-barco-pulse/issues",
@@ -28,4 +28,4 @@
2828
"Projector",
2929
"Protocol"
3030
]
31-
}
31+
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "barco-pulse",
3-
"version": "2.2.0",
3+
"version": "2.2.1",
44
"main": "./index.js",
55
"scripts": {
66
"test": "echo \"Error: no test specified\" && exit 1"

src/feedbacks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ module.exports = {
8282
return false
8383
}
8484
}
85-
85+
8686
self.setFeedbackDefinitions(feedbacks);
8787
}
8888
}

src/utils.js

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -185,16 +185,39 @@ module.exports = {
185185
});
186186

187187
self.sendCommand("property.get", { "property": "illumination.state" }, function(err, res) {
188-
console.log("property.get():",err,"RES",res);
188+
self.INFO['illumination_state'] = res;
189189
self.checkVariables();
190190
self.checkFeedbacks();
191191
});
192-
192+
self.sendCommand("property.get", { "property": "firmware.firmwareversion" }, function(err, res) {
193+
self.INFO['firmware_version'] = res;
194+
self.checkVariables();
195+
self.checkFeedbacks();
196+
});
197+
198+
self.sendCommand("property.get", { "property": "system.serialnumber" }, function(err, res) {
199+
self.INFO['serial_number'] = res;
200+
self.checkVariables();
201+
self.checkFeedbacks();
202+
});
203+
204+
self.sendCommand("property.get", { "property": "system.modelname" }, function(err, res) {
205+
self.INFO['identification_family'] = res;
206+
self.checkVariables();
207+
self.checkFeedbacks();
208+
});
209+
210+
self.sendCommand("property.get", { "property": "system.articlenumber" }, function(err, res) {
211+
self.INFO['identification'] = res;
212+
self.checkVariables();
213+
self.checkFeedbacks();
214+
});
215+
193216
/* Laser Power */
194217
self.sendCommand("property.get", { "property": "illumination.sources.laser.power" }, function(err, res) {
195218
self.INFO['illumination_value'] = res;
196219
self.checkVariables();
197220
self.checkFeedbacks();
198221
});
199222
}
200-
}
223+
}

src/variables.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ module.exports = {
44
let variables = [];
55

66
variables.push({ variableId: 'power_state', name: 'Power State' });
7-
//variables.push({ variableId: 'illumination_state', name: 'Illumination State' });
7+
variables.push({ variableId: 'illumination_state', name: 'Illumination State' });
88
variables.push({ variableId: 'illumination_value', name: 'Illumination Value' });
99
variables.push({ variableId: 'shutter_position', name: 'Shutter State' });
1010

@@ -31,18 +31,18 @@ module.exports = {
3131
}
3232

3333
if ('illumination_state' in self.INFO) {
34-
//variableObj['illumination_state'] = self.INFO['illumination_state'];
35-
}
34+
variableObj['illumination_state'] = self.INFO['illumination_state'];
35+
}
3636

3737
if ('shutter_position' in self.INFO) {
3838
variableObj['shutter_position'] = self.INFO['shutter_position'];
3939
}
4040

4141
if ('identification' in self.INFO) {
42-
variableObj['identification_family'] = self.INFO['identification']['IdentificationFamily'];
43-
variableObj['identification'] = self.INFO['identification']['Identification'];
44-
variableObj['serial_number'] = self.INFO['identification']['SerialNumber'];
45-
variableObj['firmware_version'] = self.INFO['identification']['version'];
42+
variableObj['identification_family'] = self.INFO['identification_family'];
43+
variableObj['identification'] = self.INFO['identification'];
44+
variableObj['serial_number'] = self.INFO['serial_number'];
45+
variableObj['firmware_version'] = self.INFO['firmware_version'];
4646
}
4747

4848
self.setVariableValues(variableObj);
@@ -51,4 +51,4 @@ module.exports = {
5151
self.log('error', 'Error Processing Variables: ' + String(error));
5252
}
5353
}
54-
}
54+
}

0 commit comments

Comments
 (0)