Skip to content

Commit

Permalink
Power off top screen backlight during FTP
Browse files Browse the repository at this point in the history
  • Loading branch information
joel16 committed Sep 8, 2018
1 parent 75686fe commit 0f84f20
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions source/menus/menu_ftp.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ void Menu_DisplayFTP(void)

ret = gethostname(hostname, sizeof(hostname));

if (R_SUCCEEDED(gspLcdInit()))
{
GSPLCD_PowerOffBacklight(GSPLCD_SCREEN_TOP);
gspLcdExit();
}

while(MENU_STATE == MENU_STATE_FTP)
{
ftp_loop();
Expand Down Expand Up @@ -91,6 +97,13 @@ void Menu_DisplayFTP(void)
memset(ftp_accepted_connection, 0, 20); // Empty accepted connection address
memset(ftp_file_transfer, 0, 50); // Empty transfer status
ftp_exit();

if (R_SUCCEEDED(gspLcdInit()))
{
GSPLCD_PowerOnBacklight(GSPLCD_SCREEN_TOP);
gspLcdExit();
}

MENU_STATE = MENU_STATE_HOME;
Dirbrowse_PopulateFiles(true);
}

0 comments on commit 0f84f20

Please sign in to comment.