diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2015-03-31 16:20:21 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2015-03-31 16:20:21 -0600 |
commit | 1aa554ab19210a162ab3ba7f8a635b1f11586aa2 (patch) | |
tree | 32eded82fe4e2e27796081de9c73f57613d1a322 /NxWidgets | |
parent | 89e6ac65fdaef533a95ad504bb18ec50c9cd977f (diff) | |
download | px4-nuttx-1aa554ab19210a162ab3ba7f8a635b1f11586aa2.tar.gz px4-nuttx-1aa554ab19210a162ab3ba7f8a635b1f11586aa2.tar.bz2 px4-nuttx-1aa554ab19210a162ab3ba7f8a635b1f11586aa2.zip |
Rename up_nxdrvinit() to board_graphics_setup(). Add CONFIG_BOARDCTL_GRAPHICS that will enabled calls to board_graphics_setup() from boardctrl(). In apps/ and NxWidgts/, replace all calls to up_nxdrvinit with calls to boardctl().
Diffstat (limited to 'NxWidgets')
-rw-r--r-- | NxWidgets/libnxwidgets/src/cnxserver.cxx | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/NxWidgets/libnxwidgets/src/cnxserver.cxx b/NxWidgets/libnxwidgets/src/cnxserver.cxx index d47fa74c1..1c28a6b4a 100644 --- a/NxWidgets/libnxwidgets/src/cnxserver.cxx +++ b/NxWidgets/libnxwidgets/src/cnxserver.cxx @@ -1,7 +1,7 @@ /**************************************************************************** * NxWidgets/libnxwidgets/src/cnxserver.cxx * - * Copyright (C) 2012, 2013 Gregory Nutt. All rights reserved. + * Copyright (C) 2012, 2013, 2015 Gregory Nutt. All rights reserved. * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without @@ -40,6 +40,7 @@ #include <nuttx/config.h> #include <sys/types.h> +#include <sys/boardctl.h> #include <stdint.h> #include <stdbool.h> #include <unistd.h> @@ -125,10 +126,10 @@ bool CNxServer::connect(void) #if defined(CONFIG_NXWIDGETS_EXTERNINIT) // Use external graphics driver initialization - m_hDevice = up_nxdrvinit(CONFIG_NXWIDGETS_DEVNO); + m_hDevice = boardctl(BOARDIOC_GRAPHICS_SETUP, CONFIG_NXWIDGETS_DEVNO); if (!m_hDevice) { - gdbg("up_nxdrvinit failed, devno=%d\n", CONFIG_NXWIDGETS_DEVNO); + gdbg("boardctl failed, devno=%d\n", CONFIG_NXWIDGETS_DEVNO); return false; } @@ -357,10 +358,10 @@ int CNxServer::server(int argc, char *argv[]) #if defined(CONFIG_NXWIDGETS_EXTERNINIT) // Use external graphics driver initialization - dev = up_nxdrvinit(CONFIG_NXWIDGETS_DEVNO); + dev = boardctl(BOARDIOC_GRAPHICS_SETUP, CONFIG_NXWIDGETS_DEVNO); if (!dev) { - gdbg("up_nxdrvinit failed, devno=%d\n", CONFIG_NXWIDGETS_DEVNO); + gdbg("boardctl failed, devno=%d\n", CONFIG_NXWIDGETS_DEVNO); return EXIT_FAILURE; } |