FreeRTOS console and io devices support for compile
git-svn-id: svn://db.shs.com.ru/pip@688 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5
This commit is contained in:
@@ -62,10 +62,15 @@ PIScreen::SystemConsole::SystemConsole() {
|
||||
GetConsoleMode(PRIVATE->hOut, &PRIVATE->smode);
|
||||
GetConsoleCursorInfo(PRIVATE->hOut, &PRIVATE->curinfo);
|
||||
#else
|
||||
# ifdef FREERTOS
|
||||
w = 80;
|
||||
h = 24;
|
||||
# else
|
||||
winsize ws;
|
||||
ioctl(0, TIOCGWINSZ, &ws);
|
||||
w = ws.ws_col;
|
||||
h = ws.ws_row;
|
||||
# endif
|
||||
#endif
|
||||
resize(w, h);
|
||||
}
|
||||
@@ -109,10 +114,15 @@ void PIScreen::SystemConsole::prepare() {
|
||||
w = PRIVATE->csbi.srWindow.Right - PRIVATE->csbi.srWindow.Left + 1;
|
||||
h = PRIVATE->csbi.srWindow.Bottom - PRIVATE->csbi.srWindow.Top + 1;
|
||||
#else
|
||||
# ifdef FREERTOS
|
||||
w = 80;
|
||||
h = 24;
|
||||
# else
|
||||
winsize ws;
|
||||
ioctl(0, TIOCGWINSZ, &ws);
|
||||
w = ws.ws_col;
|
||||
h = ws.ws_row;
|
||||
# endif
|
||||
#endif
|
||||
resize(w, h);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user