Testing CI reset

git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@491 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
focus
2010-03-17 09:49:44 +00:00
parent 15766fde8c
commit 03066eab04
5 changed files with 21 additions and 11 deletions

View File

@@ -1361,6 +1361,7 @@ cam.removed CAM removed from slot
cam.init_ok CAM init complete cam.init_ok CAM init complete
cam.waiting Waiting for CI answer cam.waiting Waiting for CI answer
cam.timeout Timeout waiting CI menu ready cam.timeout Timeout waiting CI menu ready
cam.reset Reset
subtitles.head Subtitles subtitles.head Subtitles
subtitles.stop Stop subtitles subtitles.stop Stop subtitles
favorites.copy Copy bouquet to Favorites favorites.copy Copy bouquet to Favorites

View File

@@ -18,21 +18,20 @@ void CI_EnterMenu(unsigned char bSlotIndex);
typedef struct typedef struct
{ {
int slot; int slot;
int choice_nb; int choice_nb;
char title[MAX_MMI_TEXT_LEN]; char title[MAX_MMI_TEXT_LEN];
char subtitle[MAX_MMI_TEXT_LEN]; char subtitle[MAX_MMI_TEXT_LEN];
char bottom[MAX_MMI_TEXT_LEN]; char bottom[MAX_MMI_TEXT_LEN];
char choice_item[MAX_MMI_ITEMS][MAX_MMI_CHOICE_TEXT_LEN]; char choice_item[MAX_MMI_ITEMS][MAX_MMI_CHOICE_TEXT_LEN];
} MMI_MENU_LIST_INFO; } MMI_MENU_LIST_INFO;
typedef struct typedef struct
{ {
int slot; int slot;
int blind; int blind;
int answerlen; int answerlen;
char enguiryText[MAX_MMI_TEXT_LEN]; char enguiryText[MAX_MMI_TEXT_LEN];
} MMI_ENGUIRY_INFO; } MMI_ENGUIRY_INFO;
typedef void (*SEND_MSG_HOOK) (unsigned int msg, unsigned int data); typedef void (*SEND_MSG_HOOK) (unsigned int msg, unsigned int data);
@@ -57,6 +56,7 @@ class cDvbCi {
void SetHook(SEND_MSG_HOOK _SendMessage) { SendMessage = _SendMessage; }; void SetHook(SEND_MSG_HOOK _SendMessage) { SendMessage = _SendMessage; };
bool CamPresent(int slot); bool CamPresent(int slot);
bool GetName(int slot, char * name); bool GetName(int slot, char * name);
bool Reset(int slot);
}; };
#endif //__DVBCI_H #endif //__DVBCI_H

View File

@@ -80,6 +80,10 @@ printf("CCAMMenuHandler::exec: actionkey %s\n", actionkey.c_str());
return doMenu(0); return doMenu(0);
} else if(actionkey == "cam2") { } else if(actionkey == "cam2") {
return doMenu(1); return doMenu(1);
} else if(actionkey == "reset1") {
ci->Reset(0);
} else if(actionkey == "reset2") {
ci->Reset(1);
} }
return doMainMenu (); return doMainMenu ();
@@ -105,6 +109,8 @@ int CCAMMenuHandler::doMainMenu ()
ci->GetName(0, name1); ci->GetName(0, name1);
printf("CCAMMenuHandler::doMenu cam1 name %s\n", name1); printf("CCAMMenuHandler::doMenu cam1 name %s\n", name1);
cammenu->addItem(new CMenuForwarderNonLocalized(name1, true, NULL, this, "cam1", CRCInput::RC_1)); cammenu->addItem(new CMenuForwarderNonLocalized(name1, true, NULL, this, "cam1", CRCInput::RC_1));
cammenu->addItem(new CMenuForwarder(LOCALE_CAM_RESET, true, NULL, this, "reset1"));
cammenu->addItem( GenericMenuSeparatorLine );
} else { } else {
sprintf(str1, "%s 1", g_Locale->getText(LOCALE_CAM_EMPTY)); sprintf(str1, "%s 1", g_Locale->getText(LOCALE_CAM_EMPTY));
tempMenu = new CMenuWidget(str1, NEUTRINO_ICON_SETTINGS); tempMenu = new CMenuWidget(str1, NEUTRINO_ICON_SETTINGS);
@@ -115,6 +121,7 @@ printf("CCAMMenuHandler::doMenu cam1 name %s\n", name1);
ci->GetName(1, name2); ci->GetName(1, name2);
printf("CCAMMenuHandler::doMenu cam2 name %s\n", name2); printf("CCAMMenuHandler::doMenu cam2 name %s\n", name2);
cammenu->addItem(new CMenuForwarderNonLocalized(name2, true, NULL, this, "cam2", CRCInput::RC_2)); cammenu->addItem(new CMenuForwarderNonLocalized(name2, true, NULL, this, "cam2", CRCInput::RC_2));
cammenu->addItem(new CMenuForwarder(LOCALE_CAM_RESET, true, NULL, this, "reset2"));
} else { } else {
sprintf(str2, "%s 2", g_Locale->getText(LOCALE_CAM_EMPTY)); sprintf(str2, "%s 2", g_Locale->getText(LOCALE_CAM_EMPTY));
tempMenu = new CMenuWidget(str2, NEUTRINO_ICON_SETTINGS); tempMenu = new CMenuWidget(str2, NEUTRINO_ICON_SETTINGS);

View File

@@ -1377,6 +1377,7 @@ typedef enum {
LOCALE_CAM_INIT_OK, LOCALE_CAM_INIT_OK,
LOCALE_CAM_WAITING, LOCALE_CAM_WAITING,
LOCALE_CAM_TIMEOUT, LOCALE_CAM_TIMEOUT,
LOCALE_CAM_RESET,
LOCALE_SUBTITLES_HEAD, LOCALE_SUBTITLES_HEAD,
LOCALE_SUBTITLES_STOP, LOCALE_SUBTITLES_STOP,
LOCALE_FAN_SPEED, LOCALE_FAN_SPEED,

View File

@@ -1377,6 +1377,7 @@ const char *locale_real_names[] = {
"cam.init_ok", "cam.init_ok",
"cam.waiting", "cam.waiting",
"cam.timeout", "cam.timeout",
"cam.reset",
"subtitles.head", "subtitles.head",
"subtitles.stop", "subtitles.stop",
"fan_speed", "fan_speed",