I set up a webOS TV project in my local system, how to identify which webOS version I am installed or using.
How to know about LG WebOS TV version?
881 Views Asked by Karthikeyan S At
2
There are 2 best solutions below
0
On
You can use https://webostv.developer.lge.com/api/webostvjs/webos/?wos_flag=deviceInfo#deviceInfo
webOS.deviceInfo(function (device) {
var version = device.version.split('.');
if (Number(version[0]) > 3 || Number(device.versionMajor) > 3) {
// do something
if (Number(version[1]) > 2 || Number(device.versionMinor) > 2) {
// do something
if (Number(version[2]) > 13 || Number(device.versionDot) > 13) {
// do something
}
}
}
var sdkVersion = device.sdkVersion.split('.');
if (sdkVersion[0] === '3') {
// do something
}
});
You can use this Luna Service API to get device information, which will contain the webOS version in its response.
luna://com.webos.service.tv.systempropertyFrom the docs:
The
sdkVersionparameter contains the webOS version - Example: "1.3.0", "2.0.0"Refer: