[LoTW] Creates a map_mode function for converting ADIF modes to lotw modes

LoTW has a weird habbit of using on standard modes this matches those to ADIF modes
pull/955/head
Peter Goodhall 2021-03-18 17:06:21 +00:00
rodzic eef45b0c9f
commit a33a094f3b
1 zmienionych plików z 16 dodań i 0 usunięć

Wyświetl plik

@ -910,4 +910,20 @@ class Lotw extends CI_Controller {
return array_search(strtoupper($satname),$arr,true);
}
/*
| Function: mode_map
| Requires: mode as $mode
|
| This converts ADIF modes to the mode that LoTW expects if its non standard
*/
function mode_map($mode) {
switch ($mode):
case "PKT":
return "PACKET"
break;
default:
return $mode
endswitch;
}
} // end class