out = '' if ( getValue('brillemaaler.mangler.odxt') == '' ) then out = out .. 'Egen brille, o.dxt: ' .. getValue('brillemaaler.sf.odxt') .. ' sf' if ( getValue('brillemaaler.cyl.odxt') ~= '' ) then out = out .. ', ' .. getValue('brillemaaler.cyl.odxt') .. ' cyl' end if ( getValue('brillemaaler.grader.odxt') ~= '' ) then out = out .. ', ' .. getValue('brillemaaler.grader.odxt') .. ' grader\n' else out = out .. '\n' end end if ( getValue('brillemaaler.mangler.osin') == '' ) then out = out .. 'Egen brille, o.sin: ' .. getValue('brillemaaler.sf.osin') .. ' sf' if ( getValue('brillemaaler.cyl.osin') ~= '' ) then out = out .. ', ' .. getValue('brillemaaler.cyl.osin') .. ' cyl' end if ( getValue('brillemaaler.grader.osin') ~= '' ) then out = out .. ', ' .. getValue('brillemaaler.grader.osin') .. ' grader\n' else out = out .. '\n' end end return out value = 0 timestamp = 0 source = '' if( missing_eye_odxt ) then if( missing_eye_odxt.value and missing_eye_odxt.value == '' ) then value = '' timestamp = missing_eye_odxt.timestamp source = missing_eye_odxt.source else value = 'mangler' timestamp = missing_eye_odxt.timestamp source = missing_eye_odxt.source end end return value, timestamp, source value = 0 timestamp = 0 source = '' if( missing_eye_osin ) then if( missing_eye_osin.value and missing_eye_osin.value == '' ) then value = '' timestamp = missing_eye_osin.timestamp source = missing_eye_osin.source else value = 'mangler' timestamp = missing_eye_osin.timestamp source = missing_eye_osin.source end end return value, timestamp, source -- Returning 0, 0 invalidates the result value = 0 timestamp = 0 source = 0 if(lensmeter and brillemaaler.osin and brillemaaler.sf.osin and brillemaaler.sf.value.osin and brillemaaler.sf.timestamp.osin) then value = brillemaaler.sf.value.osin -- convert . to , value = string.gsub(value, '[.]', ',') timestamp = brillemaaler.sf.timestamp.osin source = brillemaaler.sf.osin.source end return value, timestamp, source -- Returning 0, 0 invalidates the result value = 0 timestamp = 0 source = 0 if(lensmeter and brillemaaler.osin and brillemaaler.cyl.osin and brillemaaler.cyl.value.osin and brillemaaler.cyl.timestamp.osin) then value = brillemaaler.cyl.value.osin -- convert . to , value = string.gsub(value, '[.]', ',') timestamp = brillemaaler.cyl.timestamp.osin source = brillemaaler.cyl.osin.source end return value, timestamp, source -- Returning 0, 0 invalidates the result value = 0 timestamp = 0 source = 0 if(lensmeter and brillemaaler.odxt and brillemaaler.sf.odxt and brillemaaler.sf.value.odxt and brillemaaler.sf.timestamp.odxt) then value = brillemaaler.sf.value.odxt -- convert . to , value = string.gsub(value, '[.]', ',') timestamp = brillemaaler.sf.timestamp.odxt source = brillemaaler.sf.odxt.source end return value, timestamp, source -- Returning 0, 0 invalidates the result value = 0 timestamp = 0 source = 0 if(lensmeter and brillemaaler.odxt and brillemaaler.cyl.odxt and brillemaaler.cyl.value.odxt and brillemaaler.cyl.timestamp.odxt) then value = brillemaaler.cyl.value.odxt -- convert . to , value = string.gsub(value, '[.]', ',') timestamp = brillemaaler.cyl.timestamp.odxt source = brillemaaler.cyl.odxt.source end return value, timestamp, source