zapit/src/transponder.cpp: add static ::pol to get polarization letter

Origin commit data
------------------
Commit: d1801782a3
Author: [CST] Focus <focus.cst@gmail.com>
Date: 2012-04-16 (Mon, 16 Apr 2012)
This commit is contained in:
[CST] Focus
2012-04-16 16:42:27 +04:00
parent 50f4b9d1dc
commit a86d4f4158
2 changed files with 18 additions and 5 deletions

View File

@@ -47,6 +47,7 @@ public:
void dumpServiceXml(FILE * fd);
void dump(std::string label = "tp");
void ddump(std::string label = "tp");
static char pol(unsigned char pol);
};
typedef std::map <transponder_id_t, transponder> transponder_list_t;

View File

@@ -108,3 +108,15 @@ void transponder::ddump(std::string label)
if (zapit_debug)
dump(label);
}
char transponder::pol(unsigned char p)
{
if (p == 0)
return 'H';
else if (p == 1)
return 'V';
else if (p == 2)
return 'L';
else
return 'R';
}