@@ -4,13 +4,13 @@ local MSP_OSD_CONFIG = 84
44
55local MSP_RADIO_SETUP = 69
66
7- local BUILD_OPTION_VTX = bit32.lshift (1 , 0 )
8- local BUILD_OPTION_GPS = bit32.lshift (1 , 1 )
9- local BUILD_OPTION_OSD_SD = bit32.lshift (1 , 2 )
7+ local BUILD_OPTION_VTX = bit32.lshift (1 , 0 )
8+ local BUILD_OPTION_GPS = bit32.lshift (1 , 1 )
9+ local BUILD_OPTION_OSD = bit32.lshift (1 , 2 )
1010
1111local isVtxRead = false
1212local isGpsRead = false
13- local isOsdSDRead = false
13+ local isOsdRead = false
1414
1515local lastRunTS = 0
1616local INTERVAL = 100
@@ -24,11 +24,11 @@ local returnTable = {
2424local function processRadioSetupReply (payload )
2525 isVtxRead = true
2626 isGpsRead = true
27- isOsdSDRead = true
27+ isOsdRead = true
2828
2929 features .vtx = bit32.band (payload [1 ], BUILD_OPTION_VTX ) ~= 0
3030 features .gps = bit32.band (payload [1 ], BUILD_OPTION_GPS ) ~= 0
31- features .osdSD = bit32.band (payload [1 ], BUILD_OPTION_OSD_SD ) ~= 0
31+ features .osd = bit32.band (payload [1 ], BUILD_OPTION_OSD ) ~= 0
3232end
3333
3434local function processMspReply (cmd , payload , err )
@@ -47,9 +47,9 @@ local function processMspReply(cmd, payload, err)
4747 local providerSet = payload [1 ] ~= 0
4848 features .gps = isOkay and providerSet
4949 elseif cmd == MSP_OSD_CONFIG then
50- isOsdSDRead = true
51- local osdSDAvailable = payload [1 ] ~= 0
52- features .osdSD = isOkay and osdSDAvailable
50+ isOsdRead = true
51+ local osdAvailable = payload [1 ] ~= 0
52+ features .osd = isOkay and osdAvailable
5353 end
5454end
5555
@@ -66,9 +66,9 @@ local function updateFeatures()
6666 elseif not isGpsRead then
6767 cmd = MSP_GPS_CONFIG
6868 returnTable .t = " Checking GPS..."
69- elseif not isOsdSDRead then
69+ elseif not isOsdRead then
7070 cmd = MSP_OSD_CONFIG
71- returnTable .t = " Checking OSD (SD) ..."
71+ returnTable .t = " Checking OSD..."
7272 end
7373 if cmd and not isInFlight then
7474 protocol .mspRead (cmd )
@@ -77,7 +77,7 @@ local function updateFeatures()
7777 end
7878 mspProcessTxQ ()
7979 processMspReply (mspPollReply ())
80- return isVtxRead and isGpsRead and isOsdSDRead
80+ return isVtxRead and isGpsRead and isOsdRead
8181end
8282
8383returnTable .f = updateFeatures
0 commit comments