Compensate for S8R firmware bug

This fixes #5677
This commit is contained in:
3djc
2018-02-08 19:14:09 +01:00
parent 817f81ebb2
commit afb0ca384a
3 changed files with 3 additions and 0 deletions
+1
View File
@@ -196,6 +196,7 @@ local function refreshNext()
local field = fields[refreshIndex + 1]
if fieldId == field[3] then
local value = math.floor(value / 256)
value = bit32.band(value, 0xffff)
if field[3] >= 0x9E and field[3] <= 0xA0 then
local b1 = value % 256
local b2 = math.floor(value / 256)
@@ -145,6 +145,7 @@ local function refreshNext()
local field = fields[refreshIndex + 1]
if fieldId == field[3] then
local value = math.floor(value / 256)
value = bit32.band(value, 0xffff)
if field[3] >= 0x9E and field[3] <= 0xA0 then
local b1 = value % 256
local b2 = math.floor(value / 256)
@@ -143,6 +143,7 @@ local function refreshNext()
local field = fields[refreshIndex + 1]
if fieldId == field[3] then
local value = math.floor(value / 256)
value = bit32.band(value, 0xffff)
if field[3] >= 0x9E and field[3] <= 0xA0 then
local b1 = value % 256
local b2 = math.floor(value / 256)