2021-01-01 17:32:05 +00:00
|
|
|
/***************************************************************************
|
2025-04-04 17:06:57 +00:00
|
|
|
* Copyright (C) 2021 - 2025 by Federico Amedeo Izzo IU2NUO, *
|
2022-06-02 07:56:05 +00:00
|
|
|
* Niccolò Izzo IU2KIN, *
|
|
|
|
* Frederik Saraci IU2NRO, *
|
|
|
|
* Silvano Seva IU2KWO *
|
2021-01-01 17:32:05 +00:00
|
|
|
* *
|
|
|
|
* 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
|
|
|
|
|
|
|
|
#include <stm32f4xx.h>
|
2023-12-26 09:20:14 +00:00
|
|
|
#include "pinmap.h"
|
2021-01-01 17:32:05 +00:00
|
|
|
|
2022-01-20 11:54:34 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2024-11-10 11:11:25 +00:00
|
|
|
enum adcChannel
|
|
|
|
{
|
|
|
|
ADC_VOL_CH = 0,
|
|
|
|
ADC_VBAT_CH = 1,
|
|
|
|
ADC_VOX_CH = 3,
|
|
|
|
ADC_RSSI_CH = 8,
|
|
|
|
ADC_SW1_CH = 7,
|
|
|
|
ADC_SW2_CH = 6,
|
|
|
|
ADC_RSSI2_CH = 9,
|
|
|
|
ADC_HTEMP_CH = 15
|
|
|
|
};
|
|
|
|
|
2025-08-15 17:44:45 +00:00
|
|
|
extern const struct gpsDevice gps;
|
2024-10-08 17:19:59 +00:00
|
|
|
extern const struct spiDevice spi2;
|
2024-11-10 11:11:25 +00:00
|
|
|
extern const struct Adc adc1;
|
2024-10-08 17:19:59 +00:00
|
|
|
|
2021-01-01 17:58:35 +00:00
|
|
|
/* Device has a working real time clock */
|
2023-12-26 09:50:01 +00:00
|
|
|
#define CONFIG_RTC
|
2021-01-01 17:58:35 +00:00
|
|
|
|
2021-02-14 16:49:23 +00:00
|
|
|
/* Device supports an optional GPS chip */
|
2023-12-26 09:50:01 +00:00
|
|
|
#define CONFIG_GPS
|
2025-08-15 17:44:45 +00:00
|
|
|
#define CONFIG_GPS_STM32_USART1
|
|
|
|
#define CONFIG_NMEA_RBUF_SIZE 128
|
2021-02-14 16:49:23 +00:00
|
|
|
|
2021-01-01 17:32:05 +00:00
|
|
|
/* Screen dimensions */
|
2023-12-26 09:40:34 +00:00
|
|
|
#define CONFIG_SCREEN_WIDTH 128
|
|
|
|
#define CONFIG_SCREEN_HEIGHT 64
|
2021-01-01 17:32:05 +00:00
|
|
|
|
2021-01-29 22:11:11 +00:00
|
|
|
/* Screen has adjustable contrast */
|
2023-12-26 09:40:34 +00:00
|
|
|
#define CONFIG_SCREEN_CONTRAST
|
|
|
|
#define CONFIG_DEFAULT_CONTRAST 91
|
2021-01-29 22:11:11 +00:00
|
|
|
|
2024-12-27 21:26:05 +00:00
|
|
|
/* Screen has adjustable brightness */
|
|
|
|
#define CONFIG_SCREEN_BRIGHTNESS
|
|
|
|
|
2021-01-01 17:32:05 +00:00
|
|
|
/* Screen pixel format */
|
2023-12-26 09:40:34 +00:00
|
|
|
#define CONFIG_PIX_FMT_BW
|
2021-01-01 17:32:05 +00:00
|
|
|
|
|
|
|
/* Battery type */
|
2023-12-26 09:43:51 +00:00
|
|
|
#define CONFIG_BAT_NONE
|
2021-01-01 17:32:05 +00:00
|
|
|
|
2022-01-20 11:54:34 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
2021-01-01 17:32:05 +00:00
|
|
|
#endif
|
2022-01-20 11:54:34 +00:00
|
|
|
|
|
|
|
#endif /* HWCONFIG_H */
|