kopia lustrzana https://github.com/OpenRTX/OpenRTX
Moved constants for screen dimensions to platform-dependent hwconfig file
rodzic
160b23f1b7
commit
beb33ff244
|
@ -58,12 +58,12 @@ def = {'DONT_USE_CMSIS_INIT': ''}
|
|||
## Linux
|
||||
linux_src = src + ['tests/platform/x64_uC.c',
|
||||
'platform/drivers/display/display_libSDL.c',
|
||||
'openrtx/src/graphics/graphics_rgb565.c',
|
||||
'openrtx/src/graphics/graphics_bw.c',
|
||||
'rtos/uC-OS3/Ports/POSIX/os_cpu_c.c',
|
||||
'rtos/uC-CPU/Posix/cpu_c.c']
|
||||
|
||||
|
||||
linux_def = def + {'SCREEN_WIDTH': '160', 'SCREEN_HEIGHT': '128', 'PIX_FMT_RGB565': ''}
|
||||
linux_def = def + {'SCREEN_WIDTH': '160', 'SCREEN_HEIGHT': '128', 'PIX_FMT_BW': ''}
|
||||
|
||||
linux_inc = inc + ['rtos/uC-OS3/Ports/POSIX',
|
||||
'rtos/uC-CPU/Posix']
|
||||
|
@ -102,12 +102,13 @@ md380_src = src + ['openrtx/src/main.c',
|
|||
'rtos/uC-CPU/ARM-Cortex-M/ARMv7-M/cpu_c.c',
|
||||
'rtos/uC-CPU/ARM-Cortex-M/ARMv7-M/cpu_a.s']
|
||||
|
||||
md380_def = def + {'SCREEN_WIDTH': '160', 'SCREEN_HEIGHT': '128', 'STM32F40_41xxx': ''}
|
||||
md380_def = def + {'STM32F40_41xxx': ''}
|
||||
|
||||
md380_inc = inc + ['platform/mcu/CMSIS/Include',
|
||||
'platform/mcu/CMSIS/Device/ST/STM32F4xx/Include',
|
||||
'platform/mcu/STM32F4xx',
|
||||
'platform/mcu/STM32F4xx/drivers/usb',
|
||||
'platform/targets/MD380',
|
||||
'rtos/uC-OS3/Ports/ARM-Cortex-M/ARMv7-M',
|
||||
'rtos/uC-CPU/ARM-Cortex-M/ARMv7-M']
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include "gpio.h"
|
||||
#include "display.h"
|
||||
#include "delays.h"
|
||||
#include "hwconfig.h"
|
||||
|
||||
/* Defines for GPIO control, really ugly but useful. */
|
||||
#define D0 GPIOD,14
|
||||
|
@ -100,10 +101,6 @@
|
|||
#define LCD_FSMC_ADDR_COMMAND 0x60000000
|
||||
#define LCD_FSMC_ADDR_DATA 0x60040000
|
||||
|
||||
/* Screen dimensions */
|
||||
#define SCREEN_WIDTH 160
|
||||
#define SCREEN_HEIGHT 128
|
||||
|
||||
/*
|
||||
* LCD framebuffer, allocated on the heap by display_init().
|
||||
* Pixel format is RGB565, 16 bit per pixel
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
/***************************************************************************
|
||||
* Copyright (C) 2020 by Federico Amedeo Izzo IU2NUO, *
|
||||
* Niccolò Izzo IU2KIN *
|
||||
* Silvano Seva IU2KWO *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 3 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, see <http://www.gnu.org/licenses/> *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef HWCONFIG_H
|
||||
#define HWCONFIG_H
|
||||
|
||||
/* Screen dimensions */
|
||||
#define SCREEN_WIDTH 160
|
||||
#define SCREEN_HEIGHT 128
|
||||
|
||||
#endif
|
Ładowanie…
Reference in New Issue