Compare commits
18 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a787a2bb6c | ||
|
|
9166723b29 | ||
|
|
fe1b50f658 | ||
|
|
beb6b59889 | ||
|
|
c0614e7bd6 | ||
|
|
db17385947 | ||
|
|
90c0bf9683 | ||
|
|
1bc62adc6c | ||
|
|
d9b65701c8 | ||
|
|
f01a2d3505 | ||
|
|
549c5aa6b9 | ||
|
|
538a741912 | ||
|
|
4c0ba72542 | ||
|
|
b2f97933fd | ||
|
|
c618cd0665 | ||
|
|
9f581cb28e | ||
|
|
bc7558bdd9 | ||
|
|
2d90f218dc |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -42,3 +42,4 @@ Logo GUI/TS100 Logo Editor/TS100 Logo Editor/obj/
|
|||||||
Logo GUI/TS100 Logo Editor/TS100 Logo Editor/bin/
|
Logo GUI/TS100 Logo Editor/TS100 Logo Editor/bin/
|
||||||
workspace/ts100/ts100.xml
|
workspace/ts100/ts100.xml
|
||||||
workspace/ts100_old/*
|
workspace/ts100_old/*
|
||||||
|
*.cache
|
||||||
|
|||||||
@@ -148,7 +148,7 @@ namespace TS100_Logo_Editor
|
|||||||
data[i] = data[i + 1];
|
data[i] = data[i + 1];
|
||||||
data[i + 1] = temp;
|
data[i + 1] = temp;
|
||||||
}
|
}
|
||||||
string outputHexFile = IntelHex.IntelHex.encode(data, 0x0800B800, 16, true, true);//16 bytes is the only format the DFU seems to support //0x0800B800
|
string outputHexFile = IntelHex.IntelHex.encode(data, 0x0800F800, 16, true, true);//16 bytes is the only format the DFU seems to support //0x0800B800
|
||||||
//^ This string now just needs to be written out to a text file :)
|
//^ This string now just needs to be written out to a text file :)
|
||||||
SaveFileDialog dlg = new SaveFileDialog();
|
SaveFileDialog dlg = new SaveFileDialog();
|
||||||
dlg.Title = "Save DFU File";
|
dlg.Title = "Save DFU File";
|
||||||
|
|||||||
@@ -158,7 +158,7 @@ def img2hex(input_filename,
|
|||||||
# store in endian-reversed byte order
|
# store in endian-reversed byte order
|
||||||
data[4 + ndx + (1 if ndx % 2 == 0 else -1)] = byte
|
data[4 + ndx + (1 if ndx % 2 == 0 else -1)] = byte
|
||||||
|
|
||||||
intel_hex(output_file, data, 0x0800B800)
|
intel_hex(output_file, data, 0x0800F800)
|
||||||
|
|
||||||
|
|
||||||
def parse_commandline():
|
def parse_commandline():
|
||||||
|
|||||||
5
workspace/TS100/.gitignore
vendored
Normal file
5
workspace/TS100/.gitignore
vendored
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
/Debug/
|
||||||
|
/Release/
|
||||||
|
/Hexfile/
|
||||||
|
/Objects/
|
||||||
|
|
||||||
27
workspace/TS100/.settings/language.settings.xml
Normal file
27
workspace/TS100/.settings/language.settings.xml
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<project>
|
||||||
|
<configuration id="fr.ac6.managedbuild.config.gnu.cross.exe.debug.1352500998" name="Debug">
|
||||||
|
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
|
||||||
|
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
|
||||||
|
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
|
||||||
|
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
|
||||||
|
<provider copy-of="extension" id="org.eclipse.cdt.managedbuilder.core.GCCBuildCommandParser"/>
|
||||||
|
<provider class="fr.ac6.mcu.ide.build.CrossBuiltinSpecsDetector" console="false" env-hash="-1512662983927490956" id="fr.ac6.mcu.ide.build.CrossBuiltinSpecsDetector" keep-relative-paths="false" name="Ac6 SW4 STM32 MCU Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||||
|
<language-scope id="org.eclipse.cdt.core.gcc"/>
|
||||||
|
<language-scope id="org.eclipse.cdt.core.g++"/>
|
||||||
|
</provider>
|
||||||
|
</extension>
|
||||||
|
</configuration>
|
||||||
|
<configuration id="fr.ac6.managedbuild.config.gnu.cross.exe.release.723264573" name="Release">
|
||||||
|
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
|
||||||
|
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
|
||||||
|
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
|
||||||
|
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
|
||||||
|
<provider copy-of="extension" id="org.eclipse.cdt.managedbuilder.core.GCCBuildCommandParser"/>
|
||||||
|
<provider class="fr.ac6.mcu.ide.build.CrossBuiltinSpecsDetector" console="false" env-hash="-1512662983927490956" id="fr.ac6.mcu.ide.build.CrossBuiltinSpecsDetector" keep-relative-paths="false" name="Ac6 SW4 STM32 MCU Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||||
|
<language-scope id="org.eclipse.cdt.core.gcc"/>
|
||||||
|
<language-scope id="org.eclipse.cdt.core.g++"/>
|
||||||
|
</provider>
|
||||||
|
</extension>
|
||||||
|
</configuration>
|
||||||
|
</project>
|
||||||
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1,307 +0,0 @@
|
|||||||
/**
|
|
||||||
******************************************************************************
|
|
||||||
* @file stm32f1xx_hal_timebase_rtc_alarm_template.c
|
|
||||||
* @author MCD Application Team
|
|
||||||
* @version V1.1.1
|
|
||||||
* @date 12-May-2017
|
|
||||||
* @brief HAL time base based on the hardware RTC_ALARM.
|
|
||||||
*
|
|
||||||
* This file override the native HAL time base functions (defined as weak)
|
|
||||||
* to use the RTC ALARM for time base generation:
|
|
||||||
* + Intializes the RTC peripheral to increment the seconds registers each 1ms
|
|
||||||
* + The alarm is configured to assert an interrupt when the RTC reaches 1ms
|
|
||||||
* + HAL_IncTick is called at each Alarm event and the time is reset to 00:00:00
|
|
||||||
* + HSE (default), LSE or LSI can be selected as RTC clock source
|
|
||||||
@verbatim
|
|
||||||
==============================================================================
|
|
||||||
##### How to use this driver #####
|
|
||||||
==============================================================================
|
|
||||||
[..]
|
|
||||||
This file must be copied to the application folder and modified as follows:
|
|
||||||
(#) Rename it to 'stm32f1xx_hal_timebase_rtc_alarm.c'
|
|
||||||
(#) Add this file and the RTC HAL drivers to your project and uncomment
|
|
||||||
HAL_RTC_MODULE_ENABLED define in stm32f1xx_hal_conf.h
|
|
||||||
|
|
||||||
[..]
|
|
||||||
(@) HAL RTC alarm and HAL RTC wakeup drivers can<61>t be used with low power modes:
|
|
||||||
The wake up capability of the RTC may be intrusive in case of prior low power mode
|
|
||||||
configuration requiring different wake up sources.
|
|
||||||
Application/Example behavior is no more guaranteed
|
|
||||||
(@) The stm32f1xx_hal_timebase_tim use is recommended for the Applications/Examples
|
|
||||||
requiring low power modes
|
|
||||||
|
|
||||||
@endverbatim
|
|
||||||
******************************************************************************
|
|
||||||
* @attention
|
|
||||||
*
|
|
||||||
* <h2><center>© COPYRIGHT(c) 2017 STMicroelectronics</center></h2>
|
|
||||||
*
|
|
||||||
* Redistribution and use in source and binary forms, with or without modification,
|
|
||||||
* are permitted provided that the following conditions are met:
|
|
||||||
* 1. Redistributions of source code must retain the above copyright notice,
|
|
||||||
* this list of conditions and the following disclaimer.
|
|
||||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
|
||||||
* this list of conditions and the following disclaimer in the documentation
|
|
||||||
* and/or other materials provided with the distribution.
|
|
||||||
* 3. Neither the name of STMicroelectronics nor the names of its contributors
|
|
||||||
* may be used to endorse or promote products derived from this software
|
|
||||||
* without specific prior written permission.
|
|
||||||
*
|
|
||||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
||||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
||||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
|
||||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
||||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
||||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
|
||||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
||||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
||||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
*
|
|
||||||
******************************************************************************
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Includes ------------------------------------------------------------------*/
|
|
||||||
#include "stm32f1xx_hal.h"
|
|
||||||
/** @addtogroup STM32F1xx_HAL_Driver
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @defgroup HAL_TimeBase_RTC_Alarm_Template HAL TimeBase RTC Alarm Template
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Private typedef -----------------------------------------------------------*/
|
|
||||||
/* Private define ------------------------------------------------------------*/
|
|
||||||
|
|
||||||
/* Uncomment the line below to select the appropriate RTC Clock source for your application:
|
|
||||||
+ RTC_CLOCK_SOURCE_HSE: can be selected for applications requiring timing precision.
|
|
||||||
+ RTC_CLOCK_SOURCE_LSE: can be selected for applications with low constraint on timing
|
|
||||||
precision.
|
|
||||||
+ RTC_CLOCK_SOURCE_LSI: can be selected for applications with low constraint on timing
|
|
||||||
precision.
|
|
||||||
*/
|
|
||||||
#define RTC_CLOCK_SOURCE_HSE
|
|
||||||
/* #define RTC_CLOCK_SOURCE_LSE */
|
|
||||||
/* #define RTC_CLOCK_SOURCE_LSI */
|
|
||||||
|
|
||||||
/* Private macro -------------------------------------------------------------*/
|
|
||||||
/* Private variables ---------------------------------------------------------*/
|
|
||||||
RTC_HandleTypeDef hRTC_Handle;
|
|
||||||
/* Private function prototypes -----------------------------------------------*/
|
|
||||||
void RTC_Alarm_IRQHandler(void);
|
|
||||||
/* Private functions ---------------------------------------------------------*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief This function configures the RTC_ALARMA as a time base source.
|
|
||||||
* The time source is configured to have 1ms time base with a dedicated
|
|
||||||
* Tick interrupt priority.
|
|
||||||
* @note This function is called automatically at the beginning of program after
|
|
||||||
* reset by HAL_Init() or at any time when clock is configured, by HAL_RCC_ClockConfig().
|
|
||||||
* @param TickPriority: Tick interrupt priority.
|
|
||||||
* @retval HAL status
|
|
||||||
*/
|
|
||||||
HAL_StatusTypeDef HAL_InitTick (uint32_t TickPriority)
|
|
||||||
{
|
|
||||||
__IO uint32_t counter = 0U;
|
|
||||||
|
|
||||||
RCC_OscInitTypeDef RCC_OscInitStruct;
|
|
||||||
RCC_PeriphCLKInitTypeDef PeriphClkInitStruct;
|
|
||||||
|
|
||||||
#ifdef RTC_CLOCK_SOURCE_LSE
|
|
||||||
/* Configue LSE as RTC clock soucre */
|
|
||||||
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_LSE;
|
|
||||||
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_NONE;
|
|
||||||
RCC_OscInitStruct.LSEState = RCC_LSE_ON;
|
|
||||||
PeriphClkInitStruct.RTCClockSelection = RCC_RTCCLKSOURCE_LSE;
|
|
||||||
#elif defined (RTC_CLOCK_SOURCE_LSI)
|
|
||||||
/* Configue LSI as RTC clock soucre */
|
|
||||||
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_LSI;
|
|
||||||
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_NONE;
|
|
||||||
RCC_OscInitStruct.LSIState = RCC_LSI_ON;
|
|
||||||
PeriphClkInitStruct.RTCClockSelection = RCC_RTCCLKSOURCE_LSI;
|
|
||||||
#elif defined (RTC_CLOCK_SOURCE_HSE)
|
|
||||||
/* Configue HSE as RTC clock soucre */
|
|
||||||
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSE;
|
|
||||||
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_NONE;
|
|
||||||
RCC_OscInitStruct.HSEState = RCC_HSE_ON;
|
|
||||||
PeriphClkInitStruct.RTCClockSelection = RCC_RTCCLKSOURCE_HSE_DIV128;
|
|
||||||
#else
|
|
||||||
#error Please select the RTC Clock source
|
|
||||||
#endif /* RTC_CLOCK_SOURCE_LSE */
|
|
||||||
|
|
||||||
if(HAL_RCC_OscConfig(&RCC_OscInitStruct) == HAL_OK)
|
|
||||||
{
|
|
||||||
PeriphClkInitStruct.PeriphClockSelection = RCC_PERIPHCLK_RTC;
|
|
||||||
if(HAL_RCCEx_PeriphCLKConfig(&PeriphClkInitStruct) == HAL_OK)
|
|
||||||
{
|
|
||||||
/* Enable RTC Clock */
|
|
||||||
__HAL_RCC_RTC_ENABLE();
|
|
||||||
|
|
||||||
hRTC_Handle.Instance = RTC;
|
|
||||||
/* Configure RTC time base to 10Khz */
|
|
||||||
hRTC_Handle.Init.AsynchPrediv = (HAL_RCCEx_GetPeriphCLKFreq(RCC_PERIPHCLK_RTC) / 10000) - 1;
|
|
||||||
hRTC_Handle.Init.OutPut = RTC_OUTPUTSOURCE_NONE;
|
|
||||||
HAL_RTC_Init(&hRTC_Handle);
|
|
||||||
|
|
||||||
/* Disable the write protection for RTC registers */
|
|
||||||
__HAL_RTC_WRITEPROTECTION_DISABLE(&hRTC_Handle);
|
|
||||||
|
|
||||||
/* Clear flag alarm A */
|
|
||||||
__HAL_RTC_ALARM_CLEAR_FLAG(&hRTC_Handle, RTC_FLAG_ALRAF);
|
|
||||||
|
|
||||||
counter = 0U;
|
|
||||||
/* Wait till RTC ALRAF flag is set and if Time out is reached exit */
|
|
||||||
while(__HAL_RTC_ALARM_GET_FLAG(&hRTC_Handle, RTC_FLAG_ALRAF) != RESET)
|
|
||||||
{
|
|
||||||
if(counter++ == SystemCoreClock /48U) /* Timeout = ~ 1s */
|
|
||||||
{
|
|
||||||
return HAL_ERROR;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Set RTC COUNTER MSB word */
|
|
||||||
hRTC_Handle.Instance->ALRH = 0x00U;
|
|
||||||
/* Set RTC COUNTER LSB word */
|
|
||||||
hRTC_Handle.Instance->ALRL = 0x09U;
|
|
||||||
|
|
||||||
/* RTC Alarm Interrupt Configuration: EXTI configuration */
|
|
||||||
__HAL_RTC_ALARM_EXTI_ENABLE_IT();
|
|
||||||
__HAL_RTC_ALARM_EXTI_ENABLE_RISING_EDGE();
|
|
||||||
|
|
||||||
/* Clear Second and overflow flags */
|
|
||||||
CLEAR_BIT(hRTC_Handle.Instance->CRL, (RTC_FLAG_SEC | RTC_FLAG_OW));
|
|
||||||
|
|
||||||
/* Set RTC COUNTER MSB word */
|
|
||||||
hRTC_Handle.Instance->CNTH = 0x00U;
|
|
||||||
/* Set RTC COUNTER LSB word */
|
|
||||||
hRTC_Handle.Instance->CNTL = 0x00U;
|
|
||||||
|
|
||||||
/* Configure the Alarm interrupt */
|
|
||||||
__HAL_RTC_ALARM_ENABLE_IT(&hRTC_Handle, RTC_IT_ALRA);
|
|
||||||
|
|
||||||
/* Enable the write protection for RTC registers */
|
|
||||||
__HAL_RTC_WRITEPROTECTION_ENABLE(&hRTC_Handle);
|
|
||||||
|
|
||||||
/* Wait till RTC is in INIT state and if Time out is reached exit */
|
|
||||||
counter = 0U;
|
|
||||||
while((hRTC_Handle.Instance->CRL & RTC_CRL_RTOFF) == (uint32_t)RESET)
|
|
||||||
{
|
|
||||||
if(counter++ == SystemCoreClock /48U) /* Timeout = ~ 1s */
|
|
||||||
{
|
|
||||||
return HAL_ERROR;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
HAL_NVIC_SetPriority(RTC_Alarm_IRQn, TickPriority, 0U);
|
|
||||||
HAL_NVIC_EnableIRQ(RTC_Alarm_IRQn);
|
|
||||||
return HAL_OK;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return HAL_ERROR;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief Suspend Tick increment.
|
|
||||||
* @note Disable the tick increment by disabling RTC ALARM interrupt.
|
|
||||||
* @param None
|
|
||||||
* @retval None
|
|
||||||
*/
|
|
||||||
void HAL_SuspendTick(void)
|
|
||||||
{
|
|
||||||
/* Disable RTC ALARM update Interrupt */
|
|
||||||
__HAL_RTC_ALARM_DISABLE_IT(&hRTC_Handle, RTC_IT_ALRA);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief Resume Tick increment.
|
|
||||||
* @note Enable the tick increment by Enabling RTC ALARM interrupt.
|
|
||||||
* @param None
|
|
||||||
* @retval None
|
|
||||||
*/
|
|
||||||
void HAL_ResumeTick(void)
|
|
||||||
{
|
|
||||||
__IO uint32_t counter = 0U;
|
|
||||||
|
|
||||||
/* Disable the write protection for RTC registers */
|
|
||||||
__HAL_RTC_WRITEPROTECTION_DISABLE(&hRTC_Handle);
|
|
||||||
|
|
||||||
/* Set RTC COUNTER MSB word */
|
|
||||||
hRTC_Handle.Instance->CNTH = 0x00U;
|
|
||||||
/* Set RTC COUNTER LSB word */
|
|
||||||
hRTC_Handle.Instance->CNTL = 0x00U;
|
|
||||||
|
|
||||||
/* Clear Second and overflow flags */
|
|
||||||
CLEAR_BIT(hRTC_Handle.Instance->CRL, (RTC_FLAG_SEC | RTC_FLAG_OW | RTC_FLAG_ALRAF));
|
|
||||||
|
|
||||||
/* Enable RTC ALARM Update interrupt */
|
|
||||||
__HAL_RTC_ALARM_ENABLE_IT(&hRTC_Handle, RTC_IT_ALRA);
|
|
||||||
|
|
||||||
/* Enable the write protection for RTC registers */
|
|
||||||
__HAL_RTC_WRITEPROTECTION_ENABLE(&hRTC_Handle);
|
|
||||||
|
|
||||||
/* Wait till RTC is in INIT state and if Time out is reached exit */
|
|
||||||
while((hRTC_Handle.Instance->CRL & RTC_CRL_RTOFF) == (uint32_t)RESET)
|
|
||||||
{
|
|
||||||
if(counter++ == SystemCoreClock /48U) /* Timeout = ~ 1s */
|
|
||||||
{
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief ALARM A Event Callback in non blocking mode
|
|
||||||
* @note This function is called when RTC_ALARM interrupt took place, inside
|
|
||||||
* RTC_ALARM_IRQHandler(). It makes a direct call to HAL_IncTick() to increment
|
|
||||||
* a global variable "uwTick" used as application time base.
|
|
||||||
* @param hrtc : RTC handle
|
|
||||||
* @retval None
|
|
||||||
*/
|
|
||||||
void HAL_RTC_AlarmAEventCallback(RTC_HandleTypeDef *hrtc)
|
|
||||||
{
|
|
||||||
__IO uint32_t counter = 0U;
|
|
||||||
|
|
||||||
HAL_IncTick();
|
|
||||||
|
|
||||||
__HAL_RTC_WRITEPROTECTION_DISABLE(hrtc);
|
|
||||||
|
|
||||||
/* Set RTC COUNTER MSB word */
|
|
||||||
WRITE_REG(hrtc->Instance->CNTH, 0x00U);
|
|
||||||
/* Set RTC COUNTER LSB word */
|
|
||||||
WRITE_REG(hrtc->Instance->CNTL, 0x00U);
|
|
||||||
|
|
||||||
/* Clear Second and overflow flags */
|
|
||||||
CLEAR_BIT(hrtc->Instance->CRL, (RTC_FLAG_SEC | RTC_FLAG_OW));
|
|
||||||
|
|
||||||
/* Enable the write protection for RTC registers */
|
|
||||||
__HAL_RTC_WRITEPROTECTION_ENABLE(hrtc);
|
|
||||||
|
|
||||||
/* Wait till RTC is in INIT state and if Time out is reached exit */
|
|
||||||
while((hrtc->Instance->CRL & RTC_CRL_RTOFF) == (uint32_t)RESET)
|
|
||||||
{
|
|
||||||
if(counter++ == SystemCoreClock /48U) /* Timeout = ~ 1s */
|
|
||||||
{
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief This function handles RTC ALARM interrupt request.
|
|
||||||
* @retval None
|
|
||||||
*/
|
|
||||||
void RTC_Alarm_IRQHandler(void)
|
|
||||||
{
|
|
||||||
HAL_RTC_AlarmIRQHandler(&hRTC_Handle);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @}
|
|
||||||
*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @}
|
|
||||||
*/
|
|
||||||
|
|
||||||
/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
|
|
||||||
@@ -1,184 +0,0 @@
|
|||||||
/**
|
|
||||||
******************************************************************************
|
|
||||||
* @file stm32f1xx_hal_timebase_tim_template.c
|
|
||||||
* @author MCD Application Team
|
|
||||||
* @version V1.1.1
|
|
||||||
* @date 12-May-2017
|
|
||||||
* @brief HAL time base based on the hardware TIM Template.
|
|
||||||
*
|
|
||||||
* This file overrides the native HAL time base functions (defined as weak)
|
|
||||||
* the TIM time base:
|
|
||||||
* + Intializes the TIM peripheral generate a Period elapsed Event each 1ms
|
|
||||||
* + HAL_IncTick is called inside HAL_TIM_PeriodElapsedCallback ie each 1ms
|
|
||||||
*
|
|
||||||
******************************************************************************
|
|
||||||
* @attention
|
|
||||||
*
|
|
||||||
* <h2><center>© COPYRIGHT(c) 2017 STMicroelectronics</center></h2>
|
|
||||||
*
|
|
||||||
* Redistribution and use in source and binary forms, with or without modification,
|
|
||||||
* are permitted provided that the following conditions are met:
|
|
||||||
* 1. Redistributions of source code must retain the above copyright notice,
|
|
||||||
* this list of conditions and the following disclaimer.
|
|
||||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
|
||||||
* this list of conditions and the following disclaimer in the documentation
|
|
||||||
* and/or other materials provided with the distribution.
|
|
||||||
* 3. Neither the name of STMicroelectronics nor the names of its contributors
|
|
||||||
* may be used to endorse or promote products derived from this software
|
|
||||||
* without specific prior written permission.
|
|
||||||
*
|
|
||||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
||||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
||||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
|
||||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
||||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
||||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
|
||||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
||||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
||||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
*
|
|
||||||
******************************************************************************
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Includes ------------------------------------------------------------------*/
|
|
||||||
#include "stm32f1xx_hal.h"
|
|
||||||
|
|
||||||
/** @addtogroup STM32F1xx_HAL_Driver
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @addtogroup HAL_TimeBase_TIM
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Private typedef -----------------------------------------------------------*/
|
|
||||||
/* Private define ------------------------------------------------------------*/
|
|
||||||
/* Private macro -------------------------------------------------------------*/
|
|
||||||
/* Private variables ---------------------------------------------------------*/
|
|
||||||
TIM_HandleTypeDef TimHandle;
|
|
||||||
/* Private function prototypes -----------------------------------------------*/
|
|
||||||
void TIM2_IRQHandler(void);
|
|
||||||
/* Private functions ---------------------------------------------------------*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief This function configures the TIM2 as a time base source.
|
|
||||||
* The time source is configured to have 1ms time base with a dedicated
|
|
||||||
* Tick interrupt priority.
|
|
||||||
* @note This function is called automatically at the beginning of program after
|
|
||||||
* reset by HAL_Init() or at any time when clock is configured, by HAL_RCC_ClockConfig().
|
|
||||||
* @param TickPriority: Tick interrupt priority.
|
|
||||||
* @retval HAL status
|
|
||||||
*/
|
|
||||||
HAL_StatusTypeDef HAL_InitTick (uint32_t TickPriority)
|
|
||||||
{
|
|
||||||
RCC_ClkInitTypeDef clkconfig;
|
|
||||||
uint32_t uwTimclock, uwAPB1Prescaler = 0U;
|
|
||||||
uint32_t uwPrescalerValue = 0U;
|
|
||||||
uint32_t pFLatency;
|
|
||||||
|
|
||||||
/*Configure the TIM2 IRQ priority */
|
|
||||||
HAL_NVIC_SetPriority(TIM2_IRQn, TickPriority ,0U);
|
|
||||||
|
|
||||||
/* Enable the TIM2 global Interrupt */
|
|
||||||
HAL_NVIC_EnableIRQ(TIM2_IRQn);
|
|
||||||
|
|
||||||
/* Enable TIM2 clock */
|
|
||||||
__HAL_RCC_TIM2_CLK_ENABLE();
|
|
||||||
|
|
||||||
/* Get clock configuration */
|
|
||||||
HAL_RCC_GetClockConfig(&clkconfig, &pFLatency);
|
|
||||||
|
|
||||||
/* Get APB1 prescaler */
|
|
||||||
uwAPB1Prescaler = clkconfig.APB1CLKDivider;
|
|
||||||
|
|
||||||
/* Compute TIM2 clock */
|
|
||||||
if (uwAPB1Prescaler == RCC_HCLK_DIV1)
|
|
||||||
{
|
|
||||||
uwTimclock = HAL_RCC_GetPCLK1Freq();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
uwTimclock = 2*HAL_RCC_GetPCLK1Freq();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Compute the prescaler value to have TIM2 counter clock equal to 1MHz */
|
|
||||||
uwPrescalerValue = (uint32_t) ((uwTimclock / 1000000U) - 1U);
|
|
||||||
|
|
||||||
/* Initialize TIM2 */
|
|
||||||
TimHandle.Instance = TIM2;
|
|
||||||
|
|
||||||
/* Initialize TIMx peripheral as follow:
|
|
||||||
+ Period = [(TIM2CLK/1000) - 1]. to have a (1/1000) s time base.
|
|
||||||
+ Prescaler = (uwTimclock/1000000 - 1) to have a 1MHz counter clock.
|
|
||||||
+ ClockDivision = 0
|
|
||||||
+ Counter direction = Up
|
|
||||||
*/
|
|
||||||
TimHandle.Init.Period = (1000000U / 1000U) - 1U;
|
|
||||||
TimHandle.Init.Prescaler = uwPrescalerValue;
|
|
||||||
TimHandle.Init.ClockDivision = 0U;
|
|
||||||
TimHandle.Init.CounterMode = TIM_COUNTERMODE_UP;
|
|
||||||
TimHandle.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE;
|
|
||||||
if(HAL_TIM_Base_Init(&TimHandle) == HAL_OK)
|
|
||||||
{
|
|
||||||
/* Start the TIM time Base generation in interrupt mode */
|
|
||||||
return HAL_TIM_Base_Start_IT(&TimHandle);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Return function status */
|
|
||||||
return HAL_ERROR;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief Suspend Tick increment.
|
|
||||||
* @note Disable the tick increment by disabling TIM2 update interrupt.
|
|
||||||
* @retval None
|
|
||||||
*/
|
|
||||||
void HAL_SuspendTick(void)
|
|
||||||
{
|
|
||||||
/* Disable TIM2 update Interrupt */
|
|
||||||
__HAL_TIM_DISABLE_IT(&TimHandle, TIM_IT_UPDATE);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief Resume Tick increment.
|
|
||||||
* @note Enable the tick increment by Enabling TIM2 update interrupt.
|
|
||||||
* @retval None
|
|
||||||
*/
|
|
||||||
void HAL_ResumeTick(void)
|
|
||||||
{
|
|
||||||
/* Enable TIM2 Update interrupt */
|
|
||||||
__HAL_TIM_ENABLE_IT(&TimHandle, TIM_IT_UPDATE);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief Period elapsed callback in non blocking mode
|
|
||||||
* @note This function is called when TIM2 interrupt took place, inside
|
|
||||||
* HAL_TIM_IRQHandler(). It makes a direct call to HAL_IncTick() to increment
|
|
||||||
* a global variable "uwTick" used as application time base.
|
|
||||||
* @param htim : TIM handle
|
|
||||||
* @retval None
|
|
||||||
*/
|
|
||||||
void HAL_TIM_PeriodElapsedCallback(TIM_HandleTypeDef *htim)
|
|
||||||
{
|
|
||||||
HAL_IncTick();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief This function handles TIM interrupt request.
|
|
||||||
* @retval None
|
|
||||||
*/
|
|
||||||
void TIM2_IRQHandler(void)
|
|
||||||
{
|
|
||||||
HAL_TIM_IRQHandler(&TimHandle);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @}
|
|
||||||
*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @}
|
|
||||||
*/
|
|
||||||
|
|
||||||
/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
|
|
||||||
220
workspace/TS100/Makefile
Normal file
220
workspace/TS100/Makefile
Normal file
@@ -0,0 +1,220 @@
|
|||||||
|
|
||||||
|
OUTPUT_EXE=TS100_$(lang)
|
||||||
|
ifndef lang
|
||||||
|
lang:= EN
|
||||||
|
endif
|
||||||
|
|
||||||
|
# Discover the source files to build
|
||||||
|
SOURCE := $(shell find . -type f -name '*.c')
|
||||||
|
SOURCE_CPP := $(shell find . -type f -name '*.cpp')
|
||||||
|
S_SRCS := $(shell find . -type f -name '*.s')
|
||||||
|
|
||||||
|
APP_INC_DIR = ./inc
|
||||||
|
CMSIS_DEVICE_INC_DIR = ./CMSIS/device
|
||||||
|
CMSIS_CORE_INC_DIR = ./CMSIS/core
|
||||||
|
HAL_INC_DIR = ./HAL_Driver/Inc
|
||||||
|
FRTOS_CMIS_INC_DIR = ./Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS
|
||||||
|
FRTOS_INC_DIR = ./Middlewares/Third_Party/FreeRTOS/Source/include
|
||||||
|
FRTOS_GCC_INC_DIR = ./Middlewares/Third_Party/FreeRTOS/Source/portable/GCC/ARM_CM3
|
||||||
|
|
||||||
|
INCLUDES = -I$(APP_INC_DIR) \
|
||||||
|
-I$(CMSIS_DEVICE_INC_DIR)\
|
||||||
|
-I$(CMSIS_CORE_INC_DIR) \
|
||||||
|
-I$(HAL_INC_DIR) \
|
||||||
|
-I$(FRTOS_CMIS_INC_DIR) \
|
||||||
|
-I$(FRTOS_INC_DIR) \
|
||||||
|
-I$(FRTOS_GCC_INC_DIR)
|
||||||
|
# output folder
|
||||||
|
HEXFILE_DIR=Hexfile
|
||||||
|
|
||||||
|
# temporary objects folder
|
||||||
|
OUTPUT_DIR=Objects
|
||||||
|
|
||||||
|
# code optimisation ------------------------------------------------------------
|
||||||
|
OPTIM=-O2 -finline-small-functions -findirect-inlining -fdiagnostics-color
|
||||||
|
|
||||||
|
|
||||||
|
# global defines ---------------------------------------------------------------
|
||||||
|
GLOBAL_DEFINES += -D STM32F103T8Ux -D STM32F1 -D STM32 -D USE_HAL_DRIVER -D STM32F103xB -D USE_RTOS_SYSTICK -D LANG_$(lang)
|
||||||
|
|
||||||
|
# Enable debug code generation
|
||||||
|
DEBUG=-g
|
||||||
|
# Without debug code
|
||||||
|
#DEBUG=
|
||||||
|
|
||||||
|
|
||||||
|
# libs -------------------------------------------------------------------------
|
||||||
|
LIBS=
|
||||||
|
|
||||||
|
# linker script ----------------------------------------------------------------
|
||||||
|
LDSCRIPT=LinkerScript.ld
|
||||||
|
|
||||||
|
# ------------------------------------------------------------------------------
|
||||||
|
COMPILER=gcc
|
||||||
|
# programs ---------------------------------------------------------------------
|
||||||
|
CC=arm-none-eabi-gcc
|
||||||
|
CPP=arm-none-eabi-g++
|
||||||
|
AS=arm-none-eabi-as
|
||||||
|
GCOV=arm-none-eabi-gcov
|
||||||
|
OBJCOPY=arm-none-eabi-objcopy
|
||||||
|
OBJDUMP=arm-none-eabi-objdump
|
||||||
|
SIZE=arm-none-eabi-size
|
||||||
|
SREC=srec_cat
|
||||||
|
SREC_INFO=srec_info
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# linker flags -----------------------------------------------------------------
|
||||||
|
LINKER_FLAGS=-Wl,--gc-sections \
|
||||||
|
-o$(OUT_HEXFILE).elf \
|
||||||
|
-Wl,-Map=$(OUT_HEXFILE).map \
|
||||||
|
-mcpu=cortex-m3 \
|
||||||
|
-mthumb \
|
||||||
|
-mfloat-abi=soft \
|
||||||
|
-lm
|
||||||
|
|
||||||
|
# compiler flags ---------------------------------------------------------------
|
||||||
|
CPUFLAGS=-D GCC_ARMCM3 \
|
||||||
|
-D ARM_MATH_CM3 \
|
||||||
|
-D STM32F10X_MD \
|
||||||
|
-mthumb \
|
||||||
|
-mcpu=cortex-m3 \
|
||||||
|
-mfloat-abi=soft
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
CHECKOPTIONS= -Wall \
|
||||||
|
-Wextra \
|
||||||
|
-Wunused \
|
||||||
|
-Wcomment \
|
||||||
|
-Wtrigraphs \
|
||||||
|
-Wuninitialized \
|
||||||
|
-Wmissing-braces \
|
||||||
|
-Wfloat-equal \
|
||||||
|
-Wunreachable-code \
|
||||||
|
-Wswitch-default \
|
||||||
|
-Wreturn-type \
|
||||||
|
-Wundef \
|
||||||
|
-Wparentheses \
|
||||||
|
-Wnonnull \
|
||||||
|
-Winit-self \
|
||||||
|
-Wmissing-include-dirs \
|
||||||
|
-Wsequence-point \
|
||||||
|
-Wswitch \
|
||||||
|
-Wformat \
|
||||||
|
-Wsign-compare \
|
||||||
|
-Waddress \
|
||||||
|
-Waggregate-return \
|
||||||
|
-Wmissing-field-initializers \
|
||||||
|
-Winline \
|
||||||
|
-Wshadow \
|
||||||
|
-Wno-unused-parameter \
|
||||||
|
-Wdouble-promotion
|
||||||
|
|
||||||
|
|
||||||
|
CHECKOPTIONS_C= -Wbad-function-cast
|
||||||
|
|
||||||
|
|
||||||
|
CXXFLAGS=$(CPUFLAGS) \
|
||||||
|
$(DEBUG) \
|
||||||
|
$(INCLUDES) \
|
||||||
|
$(GLOBAL_DEFINES) \
|
||||||
|
-D${COMPILER} \
|
||||||
|
-MMD \
|
||||||
|
$(CHECKOPTIONS) \
|
||||||
|
-std=c++11 \
|
||||||
|
$(OPTIM) \
|
||||||
|
-fno-common \
|
||||||
|
-ffreestanding \
|
||||||
|
-fno-rtti \
|
||||||
|
-fno-exceptions \
|
||||||
|
-fno-non-call-exceptions \
|
||||||
|
-fno-use-cxa-atexit \
|
||||||
|
-T$(LDSCRIPT)
|
||||||
|
|
||||||
|
|
||||||
|
CFLAGS=$(CPUFLAGS) \
|
||||||
|
$(DEBUG) \
|
||||||
|
$(INCLUDES) \
|
||||||
|
$(CHECKOPTIONS_C) \
|
||||||
|
$(GLOBAL_DEFINES) \
|
||||||
|
-D${COMPILER} \
|
||||||
|
-MMD \
|
||||||
|
-std=gnu99 \
|
||||||
|
$(OPTIM) \
|
||||||
|
-fno-common \
|
||||||
|
-ffreestanding \
|
||||||
|
-T$(LDSCRIPT) \
|
||||||
|
-c
|
||||||
|
|
||||||
|
|
||||||
|
AFLAGS=$(CPUFLAGS) \
|
||||||
|
$(DEBUG) \
|
||||||
|
$(INCLUDES)
|
||||||
|
|
||||||
|
|
||||||
|
ifeq (${COMPILER}, gcc)
|
||||||
|
AFLAGS += -ffunction-sections -fdata-sections
|
||||||
|
CFLAGS += -ffunction-sections -fdata-sections
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
OBJS = $(SOURCE:.c=.o)
|
||||||
|
OBJS_CPP = $(SOURCE_CPP:.cpp=.o)
|
||||||
|
OBJS_S = $(S_SRCS:.s=.o)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
OUT_OBJS=$(addprefix $(OUTPUT_DIR)/,$(OBJS))
|
||||||
|
OUT_OBJS_CPP=$(addprefix $(OUTPUT_DIR)/,$(OBJS_CPP))
|
||||||
|
OUT_OBJS_S=$(addprefix $(OUTPUT_DIR)/,$(OBJS_S))
|
||||||
|
OUT_HEXFILE=$(addprefix $(HEXFILE_DIR)/,$(OUTPUT_EXE))
|
||||||
|
|
||||||
|
all: $(OUT_HEXFILE).hex
|
||||||
|
|
||||||
|
#
|
||||||
|
# The rule to create the target directory
|
||||||
|
#
|
||||||
|
|
||||||
|
# Create hexfile
|
||||||
|
%.hex : %.elf
|
||||||
|
$(SIZE) -x $^
|
||||||
|
$(OBJCOPY) $^ -O ihex $@
|
||||||
|
|
||||||
|
$(OUT_HEXFILE).elf : $(OUT_OBJS) $(OUT_OBJS_CPP) $(OUT_OBJS_S) Makefile $(LDSCRIPT)
|
||||||
|
@test -d $(@D) || mkdir -p $(@D)
|
||||||
|
@echo Linking $(OUTPUT_EXE).elf
|
||||||
|
@$(CPP) $(CXXFLAGS) $(OUT_OBJS) $(OUT_OBJS_CPP) $(OUT_OBJS_S) $(LIBS) $(LINKER_FLAGS)
|
||||||
|
|
||||||
|
$(OUT_OBJS): $(OUTPUT_DIR)/%.o : %.c Makefile
|
||||||
|
@test -d $(@D) || mkdir -p $(@D)
|
||||||
|
@echo Compiling ${<}
|
||||||
|
# @echo $(CFLAGS)
|
||||||
|
@$(CC) -c $(CFLAGS) $< -o $@
|
||||||
|
@$(OBJDUMP) -d -S $@ > $@.lst
|
||||||
|
|
||||||
|
$(OUT_OBJS_CPP): $(OUTPUT_DIR)/%.o : %.cpp Makefile
|
||||||
|
@test -d $(@D) || mkdir -p $(@D)
|
||||||
|
@echo Compiling ${<}
|
||||||
|
@$(CPP) -c $(CXXFLAGS) $< -o $@
|
||||||
|
@$(OBJDUMP) -d -S $@ > $@.lst
|
||||||
|
|
||||||
|
$(OUT_OBJS_S): $(OUTPUT_DIR)/%.o: %.s Makefile
|
||||||
|
@test -d $(@D) || mkdir -p $(@D)
|
||||||
|
@echo 'Building file: $<'
|
||||||
|
@echo 'Invoking: MCU GCC Assembler'
|
||||||
|
@$(AS) -mcpu=cortex-m3 -mthumb -mfloat-abi=soft $(INCLUDES) -g $< -o $@
|
||||||
|
@echo 'Finished building: $<'
|
||||||
|
@echo ' '
|
||||||
|
|
||||||
|
|
||||||
|
clean :
|
||||||
|
rm -Rf $(OUTPUT_DIR)
|
||||||
|
rm -Rf $(HEXFILE_DIR)
|
||||||
|
|
||||||
|
# pull in dependency info for *existing* .o files
|
||||||
|
-include $(OUT_OBJS:.o=.d)
|
||||||
|
-include $(OUT_OBJS_CPP:.o=.d)
|
||||||
|
|
||||||
@@ -1,188 +0,0 @@
|
|||||||
/*
|
|
||||||
FreeRTOS V9.0.0 - Copyright (C) 2016 Real Time Engineers Ltd.
|
|
||||||
All rights reserved
|
|
||||||
|
|
||||||
VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION.
|
|
||||||
|
|
||||||
This file is part of the FreeRTOS distribution.
|
|
||||||
|
|
||||||
FreeRTOS is free software; you can redistribute it and/or modify it under
|
|
||||||
the terms of the GNU General Public License (version 2) as published by the
|
|
||||||
Free Software Foundation >>>> AND MODIFIED BY <<<< the FreeRTOS exception.
|
|
||||||
|
|
||||||
***************************************************************************
|
|
||||||
>>! NOTE: The modification to the GPL is included to allow you to !<<
|
|
||||||
>>! distribute a combined work that includes FreeRTOS without being !<<
|
|
||||||
>>! obliged to provide the source code for proprietary components !<<
|
|
||||||
>>! outside of the FreeRTOS kernel. !<<
|
|
||||||
***************************************************************************
|
|
||||||
|
|
||||||
FreeRTOS 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. Full license text is available on the following
|
|
||||||
link: http://www.freertos.org/a00114.html
|
|
||||||
|
|
||||||
***************************************************************************
|
|
||||||
* *
|
|
||||||
* FreeRTOS provides completely free yet professionally developed, *
|
|
||||||
* robust, strictly quality controlled, supported, and cross *
|
|
||||||
* platform software that is more than just the market leader, it *
|
|
||||||
* is the industry's de facto standard. *
|
|
||||||
* *
|
|
||||||
* Help yourself get started quickly while simultaneously helping *
|
|
||||||
* to support the FreeRTOS project by purchasing a FreeRTOS *
|
|
||||||
* tutorial book, reference manual, or both: *
|
|
||||||
* http://www.FreeRTOS.org/Documentation *
|
|
||||||
* *
|
|
||||||
***************************************************************************
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/FAQHelp.html - Having a problem? Start by reading
|
|
||||||
the FAQ page "My application does not run, what could be wrong?". Have you
|
|
||||||
defined configASSERT()?
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/support - In return for receiving this top quality
|
|
||||||
embedded software for free we request you assist our global community by
|
|
||||||
participating in the support forum.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/training - Investing in training allows your team to
|
|
||||||
be as productive as possible as early as possible. Now you can receive
|
|
||||||
FreeRTOS training directly from Richard Barry, CEO of Real Time Engineers
|
|
||||||
Ltd, and the world's leading authority on the world's leading RTOS.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/plus - A selection of FreeRTOS ecosystem products,
|
|
||||||
including FreeRTOS+Trace - an indispensable productivity tool, a DOS
|
|
||||||
compatible FAT file system, and our tiny thread aware UDP/IP stack.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/labs - Where new FreeRTOS products go to incubate.
|
|
||||||
Come and try FreeRTOS+TCP, our new open source TCP/IP stack for FreeRTOS.
|
|
||||||
|
|
||||||
http://www.OpenRTOS.com - Real Time Engineers ltd. license FreeRTOS to High
|
|
||||||
Integrity Systems ltd. to sell under the OpenRTOS brand. Low cost OpenRTOS
|
|
||||||
licenses offer ticketed support, indemnification and commercial middleware.
|
|
||||||
|
|
||||||
http://www.SafeRTOS.com - High Integrity Systems also provide a safety
|
|
||||||
engineered and independently SIL3 certified version for use in safety and
|
|
||||||
mission critical applications that require provable dependability.
|
|
||||||
|
|
||||||
1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* The simplest possible implementation of pvPortMalloc(). Note that this
|
|
||||||
* implementation does NOT allow allocated memory to be freed again.
|
|
||||||
*
|
|
||||||
* See heap_2.c, heap_3.c and heap_4.c for alternative implementations, and the
|
|
||||||
* memory management pages of http://www.FreeRTOS.org for more information.
|
|
||||||
*/
|
|
||||||
#include <stdlib.h>
|
|
||||||
|
|
||||||
/* Defining MPU_WRAPPERS_INCLUDED_FROM_API_FILE prevents task.h from redefining
|
|
||||||
all the API functions to use the MPU wrappers. That should only be done when
|
|
||||||
task.h is included from an application file. */
|
|
||||||
#define MPU_WRAPPERS_INCLUDED_FROM_API_FILE
|
|
||||||
|
|
||||||
#include "FreeRTOS.h"
|
|
||||||
#include "task.h"
|
|
||||||
|
|
||||||
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE
|
|
||||||
|
|
||||||
#if( configSUPPORT_DYNAMIC_ALLOCATION == 0 )
|
|
||||||
#error This file must not be used if configSUPPORT_DYNAMIC_ALLOCATION is 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* A few bytes might be lost to byte aligning the heap start address. */
|
|
||||||
#define configADJUSTED_HEAP_SIZE ( configTOTAL_HEAP_SIZE - portBYTE_ALIGNMENT )
|
|
||||||
|
|
||||||
/* Allocate the memory for the heap. */
|
|
||||||
/* Allocate the memory for the heap. */
|
|
||||||
#if( configAPPLICATION_ALLOCATED_HEAP == 1 )
|
|
||||||
/* The application writer has already defined the array used for the RTOS
|
|
||||||
heap - probably so it can be placed in a special segment or address. */
|
|
||||||
extern uint8_t ucHeap[ configTOTAL_HEAP_SIZE ];
|
|
||||||
#else
|
|
||||||
static uint8_t ucHeap[ configTOTAL_HEAP_SIZE ];
|
|
||||||
#endif /* configAPPLICATION_ALLOCATED_HEAP */
|
|
||||||
|
|
||||||
static size_t xNextFreeByte = ( size_t ) 0;
|
|
||||||
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void *pvPortMalloc( size_t xWantedSize )
|
|
||||||
{
|
|
||||||
void *pvReturn = NULL;
|
|
||||||
static uint8_t *pucAlignedHeap = NULL;
|
|
||||||
|
|
||||||
/* Ensure that blocks are always aligned to the required number of bytes. */
|
|
||||||
#if( portBYTE_ALIGNMENT != 1 )
|
|
||||||
{
|
|
||||||
if( xWantedSize & portBYTE_ALIGNMENT_MASK )
|
|
||||||
{
|
|
||||||
/* Byte alignment required. */
|
|
||||||
xWantedSize += ( portBYTE_ALIGNMENT - ( xWantedSize & portBYTE_ALIGNMENT_MASK ) );
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
vTaskSuspendAll();
|
|
||||||
{
|
|
||||||
if( pucAlignedHeap == NULL )
|
|
||||||
{
|
|
||||||
/* Ensure the heap starts on a correctly aligned boundary. */
|
|
||||||
pucAlignedHeap = ( uint8_t * ) ( ( ( portPOINTER_SIZE_TYPE ) &ucHeap[ portBYTE_ALIGNMENT ] ) & ( ~( ( portPOINTER_SIZE_TYPE ) portBYTE_ALIGNMENT_MASK ) ) );
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Check there is enough room left for the allocation. */
|
|
||||||
if( ( ( xNextFreeByte + xWantedSize ) < configADJUSTED_HEAP_SIZE ) &&
|
|
||||||
( ( xNextFreeByte + xWantedSize ) > xNextFreeByte ) )/* Check for overflow. */
|
|
||||||
{
|
|
||||||
/* Return the next free byte then increment the index past this
|
|
||||||
block. */
|
|
||||||
pvReturn = pucAlignedHeap + xNextFreeByte;
|
|
||||||
xNextFreeByte += xWantedSize;
|
|
||||||
}
|
|
||||||
|
|
||||||
traceMALLOC( pvReturn, xWantedSize );
|
|
||||||
}
|
|
||||||
( void ) xTaskResumeAll();
|
|
||||||
|
|
||||||
#if( configUSE_MALLOC_FAILED_HOOK == 1 )
|
|
||||||
{
|
|
||||||
if( pvReturn == NULL )
|
|
||||||
{
|
|
||||||
extern void vApplicationMallocFailedHook( void );
|
|
||||||
vApplicationMallocFailedHook();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return pvReturn;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vPortFree( void *pv )
|
|
||||||
{
|
|
||||||
/* Memory cannot be freed using this scheme. See heap_2.c, heap_3.c and
|
|
||||||
heap_4.c for alternative implementations, and the memory management pages of
|
|
||||||
http://www.FreeRTOS.org for more information. */
|
|
||||||
( void ) pv;
|
|
||||||
|
|
||||||
/* Force an assert as it is invalid to call this function. */
|
|
||||||
configASSERT( pv == NULL );
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vPortInitialiseBlocks( void )
|
|
||||||
{
|
|
||||||
/* Only required when static memory is not cleared. */
|
|
||||||
xNextFreeByte = ( size_t ) 0;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
size_t xPortGetFreeHeapSize( void )
|
|
||||||
{
|
|
||||||
return ( configADJUSTED_HEAP_SIZE - xNextFreeByte );
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,314 +0,0 @@
|
|||||||
/*
|
|
||||||
FreeRTOS V9.0.0 - Copyright (C) 2016 Real Time Engineers Ltd.
|
|
||||||
All rights reserved
|
|
||||||
|
|
||||||
VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION.
|
|
||||||
|
|
||||||
This file is part of the FreeRTOS distribution.
|
|
||||||
|
|
||||||
FreeRTOS is free software; you can redistribute it and/or modify it under
|
|
||||||
the terms of the GNU General Public License (version 2) as published by the
|
|
||||||
Free Software Foundation >>>> AND MODIFIED BY <<<< the FreeRTOS exception.
|
|
||||||
|
|
||||||
***************************************************************************
|
|
||||||
>>! NOTE: The modification to the GPL is included to allow you to !<<
|
|
||||||
>>! distribute a combined work that includes FreeRTOS without being !<<
|
|
||||||
>>! obliged to provide the source code for proprietary components !<<
|
|
||||||
>>! outside of the FreeRTOS kernel. !<<
|
|
||||||
***************************************************************************
|
|
||||||
|
|
||||||
FreeRTOS 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. Full license text is available on the following
|
|
||||||
link: http://www.freertos.org/a00114.html
|
|
||||||
|
|
||||||
***************************************************************************
|
|
||||||
* *
|
|
||||||
* FreeRTOS provides completely free yet professionally developed, *
|
|
||||||
* robust, strictly quality controlled, supported, and cross *
|
|
||||||
* platform software that is more than just the market leader, it *
|
|
||||||
* is the industry's de facto standard. *
|
|
||||||
* *
|
|
||||||
* Help yourself get started quickly while simultaneously helping *
|
|
||||||
* to support the FreeRTOS project by purchasing a FreeRTOS *
|
|
||||||
* tutorial book, reference manual, or both: *
|
|
||||||
* http://www.FreeRTOS.org/Documentation *
|
|
||||||
* *
|
|
||||||
***************************************************************************
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/FAQHelp.html - Having a problem? Start by reading
|
|
||||||
the FAQ page "My application does not run, what could be wrong?". Have you
|
|
||||||
defined configASSERT()?
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/support - In return for receiving this top quality
|
|
||||||
embedded software for free we request you assist our global community by
|
|
||||||
participating in the support forum.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/training - Investing in training allows your team to
|
|
||||||
be as productive as possible as early as possible. Now you can receive
|
|
||||||
FreeRTOS training directly from Richard Barry, CEO of Real Time Engineers
|
|
||||||
Ltd, and the world's leading authority on the world's leading RTOS.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/plus - A selection of FreeRTOS ecosystem products,
|
|
||||||
including FreeRTOS+Trace - an indispensable productivity tool, a DOS
|
|
||||||
compatible FAT file system, and our tiny thread aware UDP/IP stack.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/labs - Where new FreeRTOS products go to incubate.
|
|
||||||
Come and try FreeRTOS+TCP, our new open source TCP/IP stack for FreeRTOS.
|
|
||||||
|
|
||||||
http://www.OpenRTOS.com - Real Time Engineers ltd. license FreeRTOS to High
|
|
||||||
Integrity Systems ltd. to sell under the OpenRTOS brand. Low cost OpenRTOS
|
|
||||||
licenses offer ticketed support, indemnification and commercial middleware.
|
|
||||||
|
|
||||||
http://www.SafeRTOS.com - High Integrity Systems also provide a safety
|
|
||||||
engineered and independently SIL3 certified version for use in safety and
|
|
||||||
mission critical applications that require provable dependability.
|
|
||||||
|
|
||||||
1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* A sample implementation of pvPortMalloc() and vPortFree() that permits
|
|
||||||
* allocated blocks to be freed, but does not combine adjacent free blocks
|
|
||||||
* into a single larger block (and so will fragment memory). See heap_4.c for
|
|
||||||
* an equivalent that does combine adjacent blocks into single larger blocks.
|
|
||||||
*
|
|
||||||
* See heap_1.c, heap_3.c and heap_4.c for alternative implementations, and the
|
|
||||||
* memory management pages of http://www.FreeRTOS.org for more information.
|
|
||||||
*/
|
|
||||||
#include <stdlib.h>
|
|
||||||
|
|
||||||
/* Defining MPU_WRAPPERS_INCLUDED_FROM_API_FILE prevents task.h from redefining
|
|
||||||
all the API functions to use the MPU wrappers. That should only be done when
|
|
||||||
task.h is included from an application file. */
|
|
||||||
#define MPU_WRAPPERS_INCLUDED_FROM_API_FILE
|
|
||||||
|
|
||||||
#include "FreeRTOS.h"
|
|
||||||
#include "task.h"
|
|
||||||
|
|
||||||
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE
|
|
||||||
|
|
||||||
#if( configSUPPORT_DYNAMIC_ALLOCATION == 0 )
|
|
||||||
#error This file must not be used if configSUPPORT_DYNAMIC_ALLOCATION is 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* A few bytes might be lost to byte aligning the heap start address. */
|
|
||||||
#define configADJUSTED_HEAP_SIZE ( configTOTAL_HEAP_SIZE - portBYTE_ALIGNMENT )
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Initialises the heap structures before their first use.
|
|
||||||
*/
|
|
||||||
static void prvHeapInit( void );
|
|
||||||
|
|
||||||
/* Allocate the memory for the heap. */
|
|
||||||
#if( configAPPLICATION_ALLOCATED_HEAP == 1 )
|
|
||||||
/* The application writer has already defined the array used for the RTOS
|
|
||||||
heap - probably so it can be placed in a special segment or address. */
|
|
||||||
extern uint8_t ucHeap[ configTOTAL_HEAP_SIZE ];
|
|
||||||
#else
|
|
||||||
static uint8_t ucHeap[ configTOTAL_HEAP_SIZE ];
|
|
||||||
#endif /* configAPPLICATION_ALLOCATED_HEAP */
|
|
||||||
|
|
||||||
|
|
||||||
/* Define the linked list structure. This is used to link free blocks in order
|
|
||||||
of their size. */
|
|
||||||
typedef struct A_BLOCK_LINK
|
|
||||||
{
|
|
||||||
struct A_BLOCK_LINK *pxNextFreeBlock; /*<< The next free block in the list. */
|
|
||||||
size_t xBlockSize; /*<< The size of the free block. */
|
|
||||||
} BlockLink_t;
|
|
||||||
|
|
||||||
|
|
||||||
static const uint16_t heapSTRUCT_SIZE = ( ( sizeof ( BlockLink_t ) + ( portBYTE_ALIGNMENT - 1 ) ) & ~portBYTE_ALIGNMENT_MASK );
|
|
||||||
#define heapMINIMUM_BLOCK_SIZE ( ( size_t ) ( heapSTRUCT_SIZE * 2 ) )
|
|
||||||
|
|
||||||
/* Create a couple of list links to mark the start and end of the list. */
|
|
||||||
static BlockLink_t xStart, xEnd;
|
|
||||||
|
|
||||||
/* Keeps track of the number of free bytes remaining, but says nothing about
|
|
||||||
fragmentation. */
|
|
||||||
static size_t xFreeBytesRemaining = configADJUSTED_HEAP_SIZE;
|
|
||||||
|
|
||||||
/* STATIC FUNCTIONS ARE DEFINED AS MACROS TO MINIMIZE THE FUNCTION CALL DEPTH. */
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Insert a block into the list of free blocks - which is ordered by size of
|
|
||||||
* the block. Small blocks at the start of the list and large blocks at the end
|
|
||||||
* of the list.
|
|
||||||
*/
|
|
||||||
#define prvInsertBlockIntoFreeList( pxBlockToInsert ) \
|
|
||||||
{ \
|
|
||||||
BlockLink_t *pxIterator; \
|
|
||||||
size_t xBlockSize; \
|
|
||||||
\
|
|
||||||
xBlockSize = pxBlockToInsert->xBlockSize; \
|
|
||||||
\
|
|
||||||
/* Iterate through the list until a block is found that has a larger size */ \
|
|
||||||
/* than the block we are inserting. */ \
|
|
||||||
for( pxIterator = &xStart; pxIterator->pxNextFreeBlock->xBlockSize < xBlockSize; pxIterator = pxIterator->pxNextFreeBlock ) \
|
|
||||||
{ \
|
|
||||||
/* There is nothing to do here - just iterate to the correct position. */ \
|
|
||||||
} \
|
|
||||||
\
|
|
||||||
/* Update the list to include the block being inserted in the correct */ \
|
|
||||||
/* position. */ \
|
|
||||||
pxBlockToInsert->pxNextFreeBlock = pxIterator->pxNextFreeBlock; \
|
|
||||||
pxIterator->pxNextFreeBlock = pxBlockToInsert; \
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void *pvPortMalloc( size_t xWantedSize )
|
|
||||||
{
|
|
||||||
BlockLink_t *pxBlock, *pxPreviousBlock, *pxNewBlockLink;
|
|
||||||
static BaseType_t xHeapHasBeenInitialised = pdFALSE;
|
|
||||||
void *pvReturn = NULL;
|
|
||||||
|
|
||||||
vTaskSuspendAll();
|
|
||||||
{
|
|
||||||
/* If this is the first call to malloc then the heap will require
|
|
||||||
initialisation to setup the list of free blocks. */
|
|
||||||
if( xHeapHasBeenInitialised == pdFALSE )
|
|
||||||
{
|
|
||||||
prvHeapInit();
|
|
||||||
xHeapHasBeenInitialised = pdTRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* The wanted size is increased so it can contain a BlockLink_t
|
|
||||||
structure in addition to the requested amount of bytes. */
|
|
||||||
if( xWantedSize > 0 )
|
|
||||||
{
|
|
||||||
xWantedSize += heapSTRUCT_SIZE;
|
|
||||||
|
|
||||||
/* Ensure that blocks are always aligned to the required number of bytes. */
|
|
||||||
if( ( xWantedSize & portBYTE_ALIGNMENT_MASK ) != 0 )
|
|
||||||
{
|
|
||||||
/* Byte alignment required. */
|
|
||||||
xWantedSize += ( portBYTE_ALIGNMENT - ( xWantedSize & portBYTE_ALIGNMENT_MASK ) );
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if( ( xWantedSize > 0 ) && ( xWantedSize < configADJUSTED_HEAP_SIZE ) )
|
|
||||||
{
|
|
||||||
/* Blocks are stored in byte order - traverse the list from the start
|
|
||||||
(smallest) block until one of adequate size is found. */
|
|
||||||
pxPreviousBlock = &xStart;
|
|
||||||
pxBlock = xStart.pxNextFreeBlock;
|
|
||||||
while( ( pxBlock->xBlockSize < xWantedSize ) && ( pxBlock->pxNextFreeBlock != NULL ) )
|
|
||||||
{
|
|
||||||
pxPreviousBlock = pxBlock;
|
|
||||||
pxBlock = pxBlock->pxNextFreeBlock;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* If we found the end marker then a block of adequate size was not found. */
|
|
||||||
if( pxBlock != &xEnd )
|
|
||||||
{
|
|
||||||
/* Return the memory space - jumping over the BlockLink_t structure
|
|
||||||
at its start. */
|
|
||||||
pvReturn = ( void * ) ( ( ( uint8_t * ) pxPreviousBlock->pxNextFreeBlock ) + heapSTRUCT_SIZE );
|
|
||||||
|
|
||||||
/* This block is being returned for use so must be taken out of the
|
|
||||||
list of free blocks. */
|
|
||||||
pxPreviousBlock->pxNextFreeBlock = pxBlock->pxNextFreeBlock;
|
|
||||||
|
|
||||||
/* If the block is larger than required it can be split into two. */
|
|
||||||
if( ( pxBlock->xBlockSize - xWantedSize ) > heapMINIMUM_BLOCK_SIZE )
|
|
||||||
{
|
|
||||||
/* This block is to be split into two. Create a new block
|
|
||||||
following the number of bytes requested. The void cast is
|
|
||||||
used to prevent byte alignment warnings from the compiler. */
|
|
||||||
pxNewBlockLink = ( void * ) ( ( ( uint8_t * ) pxBlock ) + xWantedSize );
|
|
||||||
|
|
||||||
/* Calculate the sizes of two blocks split from the single
|
|
||||||
block. */
|
|
||||||
pxNewBlockLink->xBlockSize = pxBlock->xBlockSize - xWantedSize;
|
|
||||||
pxBlock->xBlockSize = xWantedSize;
|
|
||||||
|
|
||||||
/* Insert the new block into the list of free blocks. */
|
|
||||||
prvInsertBlockIntoFreeList( ( pxNewBlockLink ) );
|
|
||||||
}
|
|
||||||
|
|
||||||
xFreeBytesRemaining -= pxBlock->xBlockSize;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
traceMALLOC( pvReturn, xWantedSize );
|
|
||||||
}
|
|
||||||
( void ) xTaskResumeAll();
|
|
||||||
|
|
||||||
#if( configUSE_MALLOC_FAILED_HOOK == 1 )
|
|
||||||
{
|
|
||||||
if( pvReturn == NULL )
|
|
||||||
{
|
|
||||||
extern void vApplicationMallocFailedHook( void );
|
|
||||||
vApplicationMallocFailedHook();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return pvReturn;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vPortFree( void *pv )
|
|
||||||
{
|
|
||||||
uint8_t *puc = ( uint8_t * ) pv;
|
|
||||||
BlockLink_t *pxLink;
|
|
||||||
|
|
||||||
if( pv != NULL )
|
|
||||||
{
|
|
||||||
/* The memory being freed will have an BlockLink_t structure immediately
|
|
||||||
before it. */
|
|
||||||
puc -= heapSTRUCT_SIZE;
|
|
||||||
|
|
||||||
/* This unexpected casting is to keep some compilers from issuing
|
|
||||||
byte alignment warnings. */
|
|
||||||
pxLink = ( void * ) puc;
|
|
||||||
|
|
||||||
vTaskSuspendAll();
|
|
||||||
{
|
|
||||||
/* Add this block to the list of free blocks. */
|
|
||||||
prvInsertBlockIntoFreeList( ( ( BlockLink_t * ) pxLink ) );
|
|
||||||
xFreeBytesRemaining += pxLink->xBlockSize;
|
|
||||||
traceFREE( pv, pxLink->xBlockSize );
|
|
||||||
}
|
|
||||||
( void ) xTaskResumeAll();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
size_t xPortGetFreeHeapSize( void )
|
|
||||||
{
|
|
||||||
return xFreeBytesRemaining;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vPortInitialiseBlocks( void )
|
|
||||||
{
|
|
||||||
/* This just exists to keep the linker quiet. */
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
static void prvHeapInit( void )
|
|
||||||
{
|
|
||||||
BlockLink_t *pxFirstFreeBlock;
|
|
||||||
uint8_t *pucAlignedHeap;
|
|
||||||
|
|
||||||
/* Ensure the heap starts on a correctly aligned boundary. */
|
|
||||||
pucAlignedHeap = ( uint8_t * ) ( ( ( portPOINTER_SIZE_TYPE ) &ucHeap[ portBYTE_ALIGNMENT ] ) & ( ~( ( portPOINTER_SIZE_TYPE ) portBYTE_ALIGNMENT_MASK ) ) );
|
|
||||||
|
|
||||||
/* xStart is used to hold a pointer to the first item in the list of free
|
|
||||||
blocks. The void cast is used to prevent compiler warnings. */
|
|
||||||
xStart.pxNextFreeBlock = ( void * ) pucAlignedHeap;
|
|
||||||
xStart.xBlockSize = ( size_t ) 0;
|
|
||||||
|
|
||||||
/* xEnd is used to mark the end of the list of free blocks. */
|
|
||||||
xEnd.xBlockSize = configADJUSTED_HEAP_SIZE;
|
|
||||||
xEnd.pxNextFreeBlock = NULL;
|
|
||||||
|
|
||||||
/* To start with there is a single free block that is sized to take up the
|
|
||||||
entire heap space. */
|
|
||||||
pxFirstFreeBlock = ( void * ) pucAlignedHeap;
|
|
||||||
pxFirstFreeBlock->xBlockSize = configADJUSTED_HEAP_SIZE;
|
|
||||||
pxFirstFreeBlock->pxNextFreeBlock = &xEnd;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
@@ -1,139 +0,0 @@
|
|||||||
/*
|
|
||||||
FreeRTOS V9.0.0 - Copyright (C) 2016 Real Time Engineers Ltd.
|
|
||||||
All rights reserved
|
|
||||||
|
|
||||||
VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION.
|
|
||||||
|
|
||||||
This file is part of the FreeRTOS distribution.
|
|
||||||
|
|
||||||
FreeRTOS is free software; you can redistribute it and/or modify it under
|
|
||||||
the terms of the GNU General Public License (version 2) as published by the
|
|
||||||
Free Software Foundation >>>> AND MODIFIED BY <<<< the FreeRTOS exception.
|
|
||||||
|
|
||||||
***************************************************************************
|
|
||||||
>>! NOTE: The modification to the GPL is included to allow you to !<<
|
|
||||||
>>! distribute a combined work that includes FreeRTOS without being !<<
|
|
||||||
>>! obliged to provide the source code for proprietary components !<<
|
|
||||||
>>! outside of the FreeRTOS kernel. !<<
|
|
||||||
***************************************************************************
|
|
||||||
|
|
||||||
FreeRTOS 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. Full license text is available on the following
|
|
||||||
link: http://www.freertos.org/a00114.html
|
|
||||||
|
|
||||||
***************************************************************************
|
|
||||||
* *
|
|
||||||
* FreeRTOS provides completely free yet professionally developed, *
|
|
||||||
* robust, strictly quality controlled, supported, and cross *
|
|
||||||
* platform software that is more than just the market leader, it *
|
|
||||||
* is the industry's de facto standard. *
|
|
||||||
* *
|
|
||||||
* Help yourself get started quickly while simultaneously helping *
|
|
||||||
* to support the FreeRTOS project by purchasing a FreeRTOS *
|
|
||||||
* tutorial book, reference manual, or both: *
|
|
||||||
* http://www.FreeRTOS.org/Documentation *
|
|
||||||
* *
|
|
||||||
***************************************************************************
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/FAQHelp.html - Having a problem? Start by reading
|
|
||||||
the FAQ page "My application does not run, what could be wrong?". Have you
|
|
||||||
defined configASSERT()?
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/support - In return for receiving this top quality
|
|
||||||
embedded software for free we request you assist our global community by
|
|
||||||
participating in the support forum.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/training - Investing in training allows your team to
|
|
||||||
be as productive as possible as early as possible. Now you can receive
|
|
||||||
FreeRTOS training directly from Richard Barry, CEO of Real Time Engineers
|
|
||||||
Ltd, and the world's leading authority on the world's leading RTOS.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/plus - A selection of FreeRTOS ecosystem products,
|
|
||||||
including FreeRTOS+Trace - an indispensable productivity tool, a DOS
|
|
||||||
compatible FAT file system, and our tiny thread aware UDP/IP stack.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/labs - Where new FreeRTOS products go to incubate.
|
|
||||||
Come and try FreeRTOS+TCP, our new open source TCP/IP stack for FreeRTOS.
|
|
||||||
|
|
||||||
http://www.OpenRTOS.com - Real Time Engineers ltd. license FreeRTOS to High
|
|
||||||
Integrity Systems ltd. to sell under the OpenRTOS brand. Low cost OpenRTOS
|
|
||||||
licenses offer ticketed support, indemnification and commercial middleware.
|
|
||||||
|
|
||||||
http://www.SafeRTOS.com - High Integrity Systems also provide a safety
|
|
||||||
engineered and independently SIL3 certified version for use in safety and
|
|
||||||
mission critical applications that require provable dependability.
|
|
||||||
|
|
||||||
1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Implementation of pvPortMalloc() and vPortFree() that relies on the
|
|
||||||
* compilers own malloc() and free() implementations.
|
|
||||||
*
|
|
||||||
* This file can only be used if the linker is configured to to generate
|
|
||||||
* a heap memory area.
|
|
||||||
*
|
|
||||||
* See heap_1.c, heap_2.c and heap_4.c for alternative implementations, and the
|
|
||||||
* memory management pages of http://www.FreeRTOS.org for more information.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <stdlib.h>
|
|
||||||
|
|
||||||
/* Defining MPU_WRAPPERS_INCLUDED_FROM_API_FILE prevents task.h from redefining
|
|
||||||
all the API functions to use the MPU wrappers. That should only be done when
|
|
||||||
task.h is included from an application file. */
|
|
||||||
#define MPU_WRAPPERS_INCLUDED_FROM_API_FILE
|
|
||||||
|
|
||||||
#include "FreeRTOS.h"
|
|
||||||
#include "task.h"
|
|
||||||
|
|
||||||
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE
|
|
||||||
|
|
||||||
#if( configSUPPORT_DYNAMIC_ALLOCATION == 0 )
|
|
||||||
#error This file must not be used if configSUPPORT_DYNAMIC_ALLOCATION is 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void *pvPortMalloc( size_t xWantedSize )
|
|
||||||
{
|
|
||||||
void *pvReturn;
|
|
||||||
|
|
||||||
vTaskSuspendAll();
|
|
||||||
{
|
|
||||||
pvReturn = malloc( xWantedSize );
|
|
||||||
traceMALLOC( pvReturn, xWantedSize );
|
|
||||||
}
|
|
||||||
( void ) xTaskResumeAll();
|
|
||||||
|
|
||||||
#if( configUSE_MALLOC_FAILED_HOOK == 1 )
|
|
||||||
{
|
|
||||||
if( pvReturn == NULL )
|
|
||||||
{
|
|
||||||
extern void vApplicationMallocFailedHook( void );
|
|
||||||
vApplicationMallocFailedHook();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return pvReturn;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vPortFree( void *pv )
|
|
||||||
{
|
|
||||||
if( pv )
|
|
||||||
{
|
|
||||||
vTaskSuspendAll();
|
|
||||||
{
|
|
||||||
free( pv );
|
|
||||||
traceFREE( pv, 0 );
|
|
||||||
}
|
|
||||||
( void ) xTaskResumeAll();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,527 +0,0 @@
|
|||||||
/*
|
|
||||||
FreeRTOS V9.0.0 - Copyright (C) 2016 Real Time Engineers Ltd.
|
|
||||||
All rights reserved
|
|
||||||
|
|
||||||
VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION.
|
|
||||||
|
|
||||||
This file is part of the FreeRTOS distribution.
|
|
||||||
|
|
||||||
FreeRTOS is free software; you can redistribute it and/or modify it under
|
|
||||||
the terms of the GNU General Public License (version 2) as published by the
|
|
||||||
Free Software Foundation >>>> AND MODIFIED BY <<<< the FreeRTOS exception.
|
|
||||||
|
|
||||||
***************************************************************************
|
|
||||||
>>! NOTE: The modification to the GPL is included to allow you to !<<
|
|
||||||
>>! distribute a combined work that includes FreeRTOS without being !<<
|
|
||||||
>>! obliged to provide the source code for proprietary components !<<
|
|
||||||
>>! outside of the FreeRTOS kernel. !<<
|
|
||||||
***************************************************************************
|
|
||||||
|
|
||||||
FreeRTOS 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. Full license text is available on the following
|
|
||||||
link: http://www.freertos.org/a00114.html
|
|
||||||
|
|
||||||
***************************************************************************
|
|
||||||
* *
|
|
||||||
* FreeRTOS provides completely free yet professionally developed, *
|
|
||||||
* robust, strictly quality controlled, supported, and cross *
|
|
||||||
* platform software that is more than just the market leader, it *
|
|
||||||
* is the industry's de facto standard. *
|
|
||||||
* *
|
|
||||||
* Help yourself get started quickly while simultaneously helping *
|
|
||||||
* to support the FreeRTOS project by purchasing a FreeRTOS *
|
|
||||||
* tutorial book, reference manual, or both: *
|
|
||||||
* http://www.FreeRTOS.org/Documentation *
|
|
||||||
* *
|
|
||||||
***************************************************************************
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/FAQHelp.html - Having a problem? Start by reading
|
|
||||||
the FAQ page "My application does not run, what could be wrong?". Have you
|
|
||||||
defined configASSERT()?
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/support - In return for receiving this top quality
|
|
||||||
embedded software for free we request you assist our global community by
|
|
||||||
participating in the support forum.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/training - Investing in training allows your team to
|
|
||||||
be as productive as possible as early as possible. Now you can receive
|
|
||||||
FreeRTOS training directly from Richard Barry, CEO of Real Time Engineers
|
|
||||||
Ltd, and the world's leading authority on the world's leading RTOS.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/plus - A selection of FreeRTOS ecosystem products,
|
|
||||||
including FreeRTOS+Trace - an indispensable productivity tool, a DOS
|
|
||||||
compatible FAT file system, and our tiny thread aware UDP/IP stack.
|
|
||||||
|
|
||||||
http://www.FreeRTOS.org/labs - Where new FreeRTOS products go to incubate.
|
|
||||||
Come and try FreeRTOS+TCP, our new open source TCP/IP stack for FreeRTOS.
|
|
||||||
|
|
||||||
http://www.OpenRTOS.com - Real Time Engineers ltd. license FreeRTOS to High
|
|
||||||
Integrity Systems ltd. to sell under the OpenRTOS brand. Low cost OpenRTOS
|
|
||||||
licenses offer ticketed support, indemnification and commercial middleware.
|
|
||||||
|
|
||||||
http://www.SafeRTOS.com - High Integrity Systems also provide a safety
|
|
||||||
engineered and independently SIL3 certified version for use in safety and
|
|
||||||
mission critical applications that require provable dependability.
|
|
||||||
|
|
||||||
1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* A sample implementation of pvPortMalloc() that allows the heap to be defined
|
|
||||||
* across multiple non-contigous blocks and combines (coalescences) adjacent
|
|
||||||
* memory blocks as they are freed.
|
|
||||||
*
|
|
||||||
* See heap_1.c, heap_2.c, heap_3.c and heap_4.c for alternative
|
|
||||||
* implementations, and the memory management pages of http://www.FreeRTOS.org
|
|
||||||
* for more information.
|
|
||||||
*
|
|
||||||
* Usage notes:
|
|
||||||
*
|
|
||||||
* vPortDefineHeapRegions() ***must*** be called before pvPortMalloc().
|
|
||||||
* pvPortMalloc() will be called if any task objects (tasks, queues, event
|
|
||||||
* groups, etc.) are created, therefore vPortDefineHeapRegions() ***must*** be
|
|
||||||
* called before any other objects are defined.
|
|
||||||
*
|
|
||||||
* vPortDefineHeapRegions() takes a single parameter. The parameter is an array
|
|
||||||
* of HeapRegion_t structures. HeapRegion_t is defined in portable.h as
|
|
||||||
*
|
|
||||||
* typedef struct HeapRegion
|
|
||||||
* {
|
|
||||||
* uint8_t *pucStartAddress; << Start address of a block of memory that will be part of the heap.
|
|
||||||
* size_t xSizeInBytes; << Size of the block of memory.
|
|
||||||
* } HeapRegion_t;
|
|
||||||
*
|
|
||||||
* The array is terminated using a NULL zero sized region definition, and the
|
|
||||||
* memory regions defined in the array ***must*** appear in address order from
|
|
||||||
* low address to high address. So the following is a valid example of how
|
|
||||||
* to use the function.
|
|
||||||
*
|
|
||||||
* HeapRegion_t xHeapRegions[] =
|
|
||||||
* {
|
|
||||||
* { ( uint8_t * ) 0x80000000UL, 0x10000 }, << Defines a block of 0x10000 bytes starting at address 0x80000000
|
|
||||||
* { ( uint8_t * ) 0x90000000UL, 0xa0000 }, << Defines a block of 0xa0000 bytes starting at address of 0x90000000
|
|
||||||
* { NULL, 0 } << Terminates the array.
|
|
||||||
* };
|
|
||||||
*
|
|
||||||
* vPortDefineHeapRegions( xHeapRegions ); << Pass the array into vPortDefineHeapRegions().
|
|
||||||
*
|
|
||||||
* Note 0x80000000 is the lower address so appears in the array first.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
#include <stdlib.h>
|
|
||||||
|
|
||||||
/* Defining MPU_WRAPPERS_INCLUDED_FROM_API_FILE prevents task.h from redefining
|
|
||||||
all the API functions to use the MPU wrappers. That should only be done when
|
|
||||||
task.h is included from an application file. */
|
|
||||||
#define MPU_WRAPPERS_INCLUDED_FROM_API_FILE
|
|
||||||
|
|
||||||
#include "FreeRTOS.h"
|
|
||||||
#include "task.h"
|
|
||||||
|
|
||||||
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE
|
|
||||||
|
|
||||||
#if( configSUPPORT_DYNAMIC_ALLOCATION == 0 )
|
|
||||||
#error This file must not be used if configSUPPORT_DYNAMIC_ALLOCATION is 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Block sizes must not get too small. */
|
|
||||||
#define heapMINIMUM_BLOCK_SIZE ( ( size_t ) ( xHeapStructSize << 1 ) )
|
|
||||||
|
|
||||||
/* Assumes 8bit bytes! */
|
|
||||||
#define heapBITS_PER_BYTE ( ( size_t ) 8 )
|
|
||||||
|
|
||||||
/* Define the linked list structure. This is used to link free blocks in order
|
|
||||||
of their memory address. */
|
|
||||||
typedef struct A_BLOCK_LINK
|
|
||||||
{
|
|
||||||
struct A_BLOCK_LINK *pxNextFreeBlock; /*<< The next free block in the list. */
|
|
||||||
size_t xBlockSize; /*<< The size of the free block. */
|
|
||||||
} BlockLink_t;
|
|
||||||
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Inserts a block of memory that is being freed into the correct position in
|
|
||||||
* the list of free memory blocks. The block being freed will be merged with
|
|
||||||
* the block in front it and/or the block behind it if the memory blocks are
|
|
||||||
* adjacent to each other.
|
|
||||||
*/
|
|
||||||
static void prvInsertBlockIntoFreeList( BlockLink_t *pxBlockToInsert );
|
|
||||||
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
/* The size of the structure placed at the beginning of each allocated memory
|
|
||||||
block must by correctly byte aligned. */
|
|
||||||
static const size_t xHeapStructSize = ( sizeof( BlockLink_t ) + ( ( size_t ) ( portBYTE_ALIGNMENT - 1 ) ) ) & ~( ( size_t ) portBYTE_ALIGNMENT_MASK );
|
|
||||||
|
|
||||||
/* Create a couple of list links to mark the start and end of the list. */
|
|
||||||
static BlockLink_t xStart, *pxEnd = NULL;
|
|
||||||
|
|
||||||
/* Keeps track of the number of free bytes remaining, but says nothing about
|
|
||||||
fragmentation. */
|
|
||||||
static size_t xFreeBytesRemaining = 0U;
|
|
||||||
static size_t xMinimumEverFreeBytesRemaining = 0U;
|
|
||||||
|
|
||||||
/* Gets set to the top bit of an size_t type. When this bit in the xBlockSize
|
|
||||||
member of an BlockLink_t structure is set then the block belongs to the
|
|
||||||
application. When the bit is free the block is still part of the free heap
|
|
||||||
space. */
|
|
||||||
static size_t xBlockAllocatedBit = 0;
|
|
||||||
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void *pvPortMalloc( size_t xWantedSize )
|
|
||||||
{
|
|
||||||
BlockLink_t *pxBlock, *pxPreviousBlock, *pxNewBlockLink;
|
|
||||||
void *pvReturn = NULL;
|
|
||||||
|
|
||||||
/* The heap must be initialised before the first call to
|
|
||||||
prvPortMalloc(). */
|
|
||||||
configASSERT( pxEnd );
|
|
||||||
|
|
||||||
vTaskSuspendAll();
|
|
||||||
{
|
|
||||||
/* Check the requested block size is not so large that the top bit is
|
|
||||||
set. The top bit of the block size member of the BlockLink_t structure
|
|
||||||
is used to determine who owns the block - the application or the
|
|
||||||
kernel, so it must be free. */
|
|
||||||
if( ( xWantedSize & xBlockAllocatedBit ) == 0 )
|
|
||||||
{
|
|
||||||
/* The wanted size is increased so it can contain a BlockLink_t
|
|
||||||
structure in addition to the requested amount of bytes. */
|
|
||||||
if( xWantedSize > 0 )
|
|
||||||
{
|
|
||||||
xWantedSize += xHeapStructSize;
|
|
||||||
|
|
||||||
/* Ensure that blocks are always aligned to the required number
|
|
||||||
of bytes. */
|
|
||||||
if( ( xWantedSize & portBYTE_ALIGNMENT_MASK ) != 0x00 )
|
|
||||||
{
|
|
||||||
/* Byte alignment required. */
|
|
||||||
xWantedSize += ( portBYTE_ALIGNMENT - ( xWantedSize & portBYTE_ALIGNMENT_MASK ) );
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
|
|
||||||
if( ( xWantedSize > 0 ) && ( xWantedSize <= xFreeBytesRemaining ) )
|
|
||||||
{
|
|
||||||
/* Traverse the list from the start (lowest address) block until
|
|
||||||
one of adequate size is found. */
|
|
||||||
pxPreviousBlock = &xStart;
|
|
||||||
pxBlock = xStart.pxNextFreeBlock;
|
|
||||||
while( ( pxBlock->xBlockSize < xWantedSize ) && ( pxBlock->pxNextFreeBlock != NULL ) )
|
|
||||||
{
|
|
||||||
pxPreviousBlock = pxBlock;
|
|
||||||
pxBlock = pxBlock->pxNextFreeBlock;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* If the end marker was reached then a block of adequate size
|
|
||||||
was not found. */
|
|
||||||
if( pxBlock != pxEnd )
|
|
||||||
{
|
|
||||||
/* Return the memory space pointed to - jumping over the
|
|
||||||
BlockLink_t structure at its start. */
|
|
||||||
pvReturn = ( void * ) ( ( ( uint8_t * ) pxPreviousBlock->pxNextFreeBlock ) + xHeapStructSize );
|
|
||||||
|
|
||||||
/* This block is being returned for use so must be taken out
|
|
||||||
of the list of free blocks. */
|
|
||||||
pxPreviousBlock->pxNextFreeBlock = pxBlock->pxNextFreeBlock;
|
|
||||||
|
|
||||||
/* If the block is larger than required it can be split into
|
|
||||||
two. */
|
|
||||||
if( ( pxBlock->xBlockSize - xWantedSize ) > heapMINIMUM_BLOCK_SIZE )
|
|
||||||
{
|
|
||||||
/* This block is to be split into two. Create a new
|
|
||||||
block following the number of bytes requested. The void
|
|
||||||
cast is used to prevent byte alignment warnings from the
|
|
||||||
compiler. */
|
|
||||||
pxNewBlockLink = ( void * ) ( ( ( uint8_t * ) pxBlock ) + xWantedSize );
|
|
||||||
|
|
||||||
/* Calculate the sizes of two blocks split from the
|
|
||||||
single block. */
|
|
||||||
pxNewBlockLink->xBlockSize = pxBlock->xBlockSize - xWantedSize;
|
|
||||||
pxBlock->xBlockSize = xWantedSize;
|
|
||||||
|
|
||||||
/* Insert the new block into the list of free blocks. */
|
|
||||||
prvInsertBlockIntoFreeList( ( pxNewBlockLink ) );
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
|
|
||||||
xFreeBytesRemaining -= pxBlock->xBlockSize;
|
|
||||||
|
|
||||||
if( xFreeBytesRemaining < xMinimumEverFreeBytesRemaining )
|
|
||||||
{
|
|
||||||
xMinimumEverFreeBytesRemaining = xFreeBytesRemaining;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* The block is being returned - it is allocated and owned
|
|
||||||
by the application and has no "next" block. */
|
|
||||||
pxBlock->xBlockSize |= xBlockAllocatedBit;
|
|
||||||
pxBlock->pxNextFreeBlock = NULL;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
|
|
||||||
traceMALLOC( pvReturn, xWantedSize );
|
|
||||||
}
|
|
||||||
( void ) xTaskResumeAll();
|
|
||||||
|
|
||||||
#if( configUSE_MALLOC_FAILED_HOOK == 1 )
|
|
||||||
{
|
|
||||||
if( pvReturn == NULL )
|
|
||||||
{
|
|
||||||
extern void vApplicationMallocFailedHook( void );
|
|
||||||
vApplicationMallocFailedHook();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return pvReturn;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vPortFree( void *pv )
|
|
||||||
{
|
|
||||||
uint8_t *puc = ( uint8_t * ) pv;
|
|
||||||
BlockLink_t *pxLink;
|
|
||||||
|
|
||||||
if( pv != NULL )
|
|
||||||
{
|
|
||||||
/* The memory being freed will have an BlockLink_t structure immediately
|
|
||||||
before it. */
|
|
||||||
puc -= xHeapStructSize;
|
|
||||||
|
|
||||||
/* This casting is to keep the compiler from issuing warnings. */
|
|
||||||
pxLink = ( void * ) puc;
|
|
||||||
|
|
||||||
/* Check the block is actually allocated. */
|
|
||||||
configASSERT( ( pxLink->xBlockSize & xBlockAllocatedBit ) != 0 );
|
|
||||||
configASSERT( pxLink->pxNextFreeBlock == NULL );
|
|
||||||
|
|
||||||
if( ( pxLink->xBlockSize & xBlockAllocatedBit ) != 0 )
|
|
||||||
{
|
|
||||||
if( pxLink->pxNextFreeBlock == NULL )
|
|
||||||
{
|
|
||||||
/* The block is being returned to the heap - it is no longer
|
|
||||||
allocated. */
|
|
||||||
pxLink->xBlockSize &= ~xBlockAllocatedBit;
|
|
||||||
|
|
||||||
vTaskSuspendAll();
|
|
||||||
{
|
|
||||||
/* Add this block to the list of free blocks. */
|
|
||||||
xFreeBytesRemaining += pxLink->xBlockSize;
|
|
||||||
traceFREE( pv, pxLink->xBlockSize );
|
|
||||||
prvInsertBlockIntoFreeList( ( ( BlockLink_t * ) pxLink ) );
|
|
||||||
}
|
|
||||||
( void ) xTaskResumeAll();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
size_t xPortGetFreeHeapSize( void )
|
|
||||||
{
|
|
||||||
return xFreeBytesRemaining;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
size_t xPortGetMinimumEverFreeHeapSize( void )
|
|
||||||
{
|
|
||||||
return xMinimumEverFreeBytesRemaining;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
static void prvInsertBlockIntoFreeList( BlockLink_t *pxBlockToInsert )
|
|
||||||
{
|
|
||||||
BlockLink_t *pxIterator;
|
|
||||||
uint8_t *puc;
|
|
||||||
|
|
||||||
/* Iterate through the list until a block is found that has a higher address
|
|
||||||
than the block being inserted. */
|
|
||||||
for( pxIterator = &xStart; pxIterator->pxNextFreeBlock < pxBlockToInsert; pxIterator = pxIterator->pxNextFreeBlock )
|
|
||||||
{
|
|
||||||
/* Nothing to do here, just iterate to the right position. */
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Do the block being inserted, and the block it is being inserted after
|
|
||||||
make a contiguous block of memory? */
|
|
||||||
puc = ( uint8_t * ) pxIterator;
|
|
||||||
if( ( puc + pxIterator->xBlockSize ) == ( uint8_t * ) pxBlockToInsert )
|
|
||||||
{
|
|
||||||
pxIterator->xBlockSize += pxBlockToInsert->xBlockSize;
|
|
||||||
pxBlockToInsert = pxIterator;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Do the block being inserted, and the block it is being inserted before
|
|
||||||
make a contiguous block of memory? */
|
|
||||||
puc = ( uint8_t * ) pxBlockToInsert;
|
|
||||||
if( ( puc + pxBlockToInsert->xBlockSize ) == ( uint8_t * ) pxIterator->pxNextFreeBlock )
|
|
||||||
{
|
|
||||||
if( pxIterator->pxNextFreeBlock != pxEnd )
|
|
||||||
{
|
|
||||||
/* Form one big block from the two blocks. */
|
|
||||||
pxBlockToInsert->xBlockSize += pxIterator->pxNextFreeBlock->xBlockSize;
|
|
||||||
pxBlockToInsert->pxNextFreeBlock = pxIterator->pxNextFreeBlock->pxNextFreeBlock;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
pxBlockToInsert->pxNextFreeBlock = pxEnd;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
pxBlockToInsert->pxNextFreeBlock = pxIterator->pxNextFreeBlock;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* If the block being inserted plugged a gab, so was merged with the block
|
|
||||||
before and the block after, then it's pxNextFreeBlock pointer will have
|
|
||||||
already been set, and should not be set here as that would make it point
|
|
||||||
to itself. */
|
|
||||||
if( pxIterator != pxBlockToInsert )
|
|
||||||
{
|
|
||||||
pxIterator->pxNextFreeBlock = pxBlockToInsert;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mtCOVERAGE_TEST_MARKER();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vPortDefineHeapRegions( const HeapRegion_t * const pxHeapRegions )
|
|
||||||
{
|
|
||||||
BlockLink_t *pxFirstFreeBlockInRegion = NULL, *pxPreviousFreeBlock;
|
|
||||||
size_t xAlignedHeap;
|
|
||||||
size_t xTotalRegionSize, xTotalHeapSize = 0;
|
|
||||||
BaseType_t xDefinedRegions = 0;
|
|
||||||
size_t xAddress;
|
|
||||||
const HeapRegion_t *pxHeapRegion;
|
|
||||||
|
|
||||||
/* Can only call once! */
|
|
||||||
configASSERT( pxEnd == NULL );
|
|
||||||
|
|
||||||
pxHeapRegion = &( pxHeapRegions[ xDefinedRegions ] );
|
|
||||||
|
|
||||||
while( pxHeapRegion->xSizeInBytes > 0 )
|
|
||||||
{
|
|
||||||
xTotalRegionSize = pxHeapRegion->xSizeInBytes;
|
|
||||||
|
|
||||||
/* Ensure the heap region starts on a correctly aligned boundary. */
|
|
||||||
xAddress = ( size_t ) pxHeapRegion->pucStartAddress;
|
|
||||||
if( ( xAddress & portBYTE_ALIGNMENT_MASK ) != 0 )
|
|
||||||
{
|
|
||||||
xAddress += ( portBYTE_ALIGNMENT - 1 );
|
|
||||||
xAddress &= ~portBYTE_ALIGNMENT_MASK;
|
|
||||||
|
|
||||||
/* Adjust the size for the bytes lost to alignment. */
|
|
||||||
xTotalRegionSize -= xAddress - ( size_t ) pxHeapRegion->pucStartAddress;
|
|
||||||
}
|
|
||||||
|
|
||||||
xAlignedHeap = xAddress;
|
|
||||||
|
|
||||||
/* Set xStart if it has not already been set. */
|
|
||||||
if( xDefinedRegions == 0 )
|
|
||||||
{
|
|
||||||
/* xStart is used to hold a pointer to the first item in the list of
|
|
||||||
free blocks. The void cast is used to prevent compiler warnings. */
|
|
||||||
xStart.pxNextFreeBlock = ( BlockLink_t * ) xAlignedHeap;
|
|
||||||
xStart.xBlockSize = ( size_t ) 0;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
/* Should only get here if one region has already been added to the
|
|
||||||
heap. */
|
|
||||||
configASSERT( pxEnd != NULL );
|
|
||||||
|
|
||||||
/* Check blocks are passed in with increasing start addresses. */
|
|
||||||
configASSERT( xAddress > ( size_t ) pxEnd );
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Remember the location of the end marker in the previous region, if
|
|
||||||
any. */
|
|
||||||
pxPreviousFreeBlock = pxEnd;
|
|
||||||
|
|
||||||
/* pxEnd is used to mark the end of the list of free blocks and is
|
|
||||||
inserted at the end of the region space. */
|
|
||||||
xAddress = xAlignedHeap + xTotalRegionSize;
|
|
||||||
xAddress -= xHeapStructSize;
|
|
||||||
xAddress &= ~portBYTE_ALIGNMENT_MASK;
|
|
||||||
pxEnd = ( BlockLink_t * ) xAddress;
|
|
||||||
pxEnd->xBlockSize = 0;
|
|
||||||
pxEnd->pxNextFreeBlock = NULL;
|
|
||||||
|
|
||||||
/* To start with there is a single free block in this region that is
|
|
||||||
sized to take up the entire heap region minus the space taken by the
|
|
||||||
free block structure. */
|
|
||||||
pxFirstFreeBlockInRegion = ( BlockLink_t * ) xAlignedHeap;
|
|
||||||
pxFirstFreeBlockInRegion->xBlockSize = xAddress - ( size_t ) pxFirstFreeBlockInRegion;
|
|
||||||
pxFirstFreeBlockInRegion->pxNextFreeBlock = pxEnd;
|
|
||||||
|
|
||||||
/* If this is not the first region that makes up the entire heap space
|
|
||||||
then link the previous region to this region. */
|
|
||||||
if( pxPreviousFreeBlock != NULL )
|
|
||||||
{
|
|
||||||
pxPreviousFreeBlock->pxNextFreeBlock = pxFirstFreeBlockInRegion;
|
|
||||||
}
|
|
||||||
|
|
||||||
xTotalHeapSize += pxFirstFreeBlockInRegion->xBlockSize;
|
|
||||||
|
|
||||||
/* Move onto the next HeapRegion_t structure. */
|
|
||||||
xDefinedRegions++;
|
|
||||||
pxHeapRegion = &( pxHeapRegions[ xDefinedRegions ] );
|
|
||||||
}
|
|
||||||
|
|
||||||
xMinimumEverFreeBytesRemaining = xTotalHeapSize;
|
|
||||||
xFreeBytesRemaining = xTotalHeapSize;
|
|
||||||
|
|
||||||
/* Check something was actually defined before it is accessed. */
|
|
||||||
configASSERT( xTotalHeapSize );
|
|
||||||
|
|
||||||
/* Work out the position of the top bit in a size_t variable. */
|
|
||||||
xBlockAllocatedBit = ( ( size_t ) 1 ) << ( ( sizeof( size_t ) * heapBITS_PER_BYTE ) - 1 );
|
|
||||||
}
|
|
||||||
|
|
||||||
25
workspace/TS100/build.sh
Executable file
25
workspace/TS100/build.sh
Executable file
@@ -0,0 +1,25 @@
|
|||||||
|
make clean
|
||||||
|
make -j16 lang=EN
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=CS_CZ
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=DE
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=DK
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=ES
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=FR
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=HR
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=IT
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=PL
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=RU
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=SE
|
||||||
|
rm -rf Objects/src
|
||||||
|
make -j16 lang=TR
|
||||||
|
rm -rf Objects/src
|
||||||
@@ -30,7 +30,7 @@ const uint8_t FONT_12[]={
|
|||||||
0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x00,0x00, // -
|
0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x00,0x00, // -
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x38,0x38,0x00,0x00,0x00,0x00,0x00, // .
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x38,0x38,0x00,0x00,0x00,0x00,0x00, // .
|
||||||
0x00,0x00,0x00,0x00,0x00,0x80,0xC0,0xE0,0x70,0x38,0x1C,0x0E,0x00,0x18,0x1C,0x0E,0x07,0x03,0x01,0x00,0x00,0x00,0x00,0x00, // /
|
0x00,0x00,0x00,0x00,0x00,0x80,0xC0,0xE0,0x70,0x38,0x1C,0x0E,0x00,0x18,0x1C,0x0E,0x07,0x03,0x01,0x00,0x00,0x00,0x00,0x00, // /
|
||||||
|
//V16
|
||||||
0x00,0xF8,0xFE,0x06,0x03,0x83,0xC3,0x63,0x33,0x1E,0xFE,0xF8,0x00,0x07,0x1F,0x1E,0x33,0x31,0x30,0x30,0x30,0x18,0x1F,0x07, // 0
|
0x00,0xF8,0xFE,0x06,0x03,0x83,0xC3,0x63,0x33,0x1E,0xFE,0xF8,0x00,0x07,0x1F,0x1E,0x33,0x31,0x30,0x30,0x30,0x18,0x1F,0x07, // 0
|
||||||
0x00,0x00,0x00,0x0C,0x0C,0x0E,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x3F,0x3F,0x30,0x30,0x30,0x00, // 1
|
0x00,0x00,0x00,0x0C,0x0C,0x0E,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x3F,0x3F,0x30,0x30,0x30,0x00, // 1
|
||||||
0x00,0x1C,0x1E,0x07,0x03,0x03,0x83,0xC3,0xE3,0x77,0x3E,0x1C,0x00,0x30,0x38,0x3C,0x3E,0x37,0x33,0x31,0x30,0x30,0x30,0x30, // 2
|
0x00,0x1C,0x1E,0x07,0x03,0x03,0x83,0xC3,0xE3,0x77,0x3E,0x1C,0x00,0x30,0x38,0x3C,0x3E,0x37,0x33,0x31,0x30,0x30,0x30,0x30, // 2
|
||||||
@@ -214,12 +214,12 @@ const uint8_t FONT_12[]={
|
|||||||
0x00,0x00,0x80,0x80,0x80,0xB0,0xB0,0x80,0x80,0x80,0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x0D,0x0D,0x01,0x01,0x01,0x00,0x00, // ÷ c3 b7
|
0x00,0x00,0x80,0x80,0x80,0xB0,0xB0,0x80,0x80,0x80,0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x0D,0x0D,0x01,0x01,0x01,0x00,0x00, // ÷ c3 b7
|
||||||
0x00,0x80,0xC0,0xE0,0x60,0x60,0x60,0xE0,0xC0,0xE0,0xA0,0x00,0x00,0x2F,0x3F,0x18,0x3C,0x36,0x33,0x31,0x38,0x1F,0x0F,0x00, // ø c3 b8
|
0x00,0x80,0xC0,0xE0,0x60,0x60,0x60,0xE0,0xC0,0xE0,0xA0,0x00,0x00,0x2F,0x3F,0x18,0x3C,0x36,0x33,0x31,0x38,0x1F,0x0F,0x00, // ø c3 b8
|
||||||
0x00,0xE0,0xE0,0x00,0x02,0x06,0x0C,0x08,0x00,0xE0,0xE0,0x00,0x00,0x0F,0x1F,0x38,0x30,0x30,0x30,0x30,0x18,0x3F,0x3F,0x00, // ù c3 b9
|
0x00,0xE0,0xE0,0x00,0x02,0x06,0x0C,0x08,0x00,0xE0,0xE0,0x00,0x00,0x0F,0x1F,0x38,0x30,0x30,0x30,0x30,0x18,0x3F,0x3F,0x00, // ù c3 b9
|
||||||
0x00,0xE0,0xE0,0x00,0x08,0x0C,0x06,0x02,0x00,0xE0,0xE0,0x00,0x00,0x0F,0x1F,0x38,0x30,0x30,0x30,0x30,0x18,0x3F,0x3F,0x00, // ú c3 bA
|
0x00,0xE0,0xE0,0x00,0x08,0x0C,0x06,0x02,0x00,0xE0,0xE0,0x00,0x00,0x0F,0x1F,0x38,0x30,0x30,0x30,0x30,0x18,0x3F,0x3F,0x00, // ú c3 ba
|
||||||
0x00,0xE0,0xE0,0x08,0x0C,0x06,0x06,0x0C,0x08,0xE0,0xE0,0x00,0x00,0x0F,0x1F,0x38,0x30,0x30,0x30,0x30,0x18,0x3F,0x3F,0x00, // û c3 bB
|
0x00,0xE0,0xE0,0x08,0x0C,0x06,0x06,0x0C,0x08,0xE0,0xE0,0x00,0x00,0x0F,0x1F,0x38,0x30,0x30,0x30,0x30,0x18,0x3F,0x3F,0x00, // û c3 bb
|
||||||
0x00,0xE0,0xE0,0x0C,0x0C,0x00,0x00,0x0C,0x0C,0xE0,0xE0,0x00,0x00,0x0F,0x1F,0x38,0x30,0x30,0x30,0x30,0x18,0x3F,0x3F,0x00, // ü c3 bC
|
0x00,0xE0,0xE0,0x0C,0x0C,0x00,0x00,0x0C,0x0C,0xE0,0xE0,0x00,0x00,0x0F,0x1F,0x38,0x30,0x30,0x30,0x30,0x18,0x3F,0x3F,0x00, // ü c3 bc
|
||||||
0x00,0x00,0x60,0xE0,0x80,0x10,0x18,0x8C,0xE4,0x60,0x00,0x00,0x00,0x00,0x00,0x81,0xE7,0x7E,0x1E,0x07,0x01,0x00,0x00,0x00, // ý c3 bD
|
0x00,0x00,0x60,0xE0,0x80,0x10,0x18,0x8C,0xE4,0x60,0x00,0x00,0x00,0x00,0x00,0x81,0xE7,0x7E,0x1E,0x07,0x01,0x00,0x00,0x00, // ý c3 bd
|
||||||
0x00,0x00,0x03,0xFF,0xFF,0x1B,0x18,0x18,0xF8,0xF0,0x00,0x00,0x00,0x00,0x30,0x3F,0x3F,0x36,0x06,0x06,0x07,0x03,0x00,0x00, // þ c3 bE
|
0x00,0x00,0x03,0xFF,0xFF,0x1B,0x18,0x18,0xF8,0xF0,0x00,0x00,0x00,0x00,0x30,0x3F,0x3F,0x36,0x06,0x06,0x07,0x03,0x00,0x00, // þ c3 be
|
||||||
0x00,0x00,0x60,0xEC,0x8C,0x00,0x00,0x8C,0xEC,0x60,0x00,0x00,0x00,0x00,0x00,0x81,0xE7,0x7E,0x1E,0x07,0x01,0x00,0x00,0x00, // ÿ c3 bF
|
0x00,0x00,0x60,0xEC,0x8C,0x00,0x00,0x8C,0xEC,0x60,0x00,0x00,0x00,0x00,0x00,0x81,0xE7,0x7E,0x1E,0x07,0x01,0x00,0x00,0x00, // ÿ c3 bf
|
||||||
#ifdef LANG_RU
|
#ifdef LANG_RU
|
||||||
/* Cyrillic Glyphs */
|
/* Cyrillic Glyphs */
|
||||||
//V192 ---- PAGE U+0400-U+043F (UTF 0xD080-0xD0BF) ----
|
//V192 ---- PAGE U+0400-U+043F (UTF 0xD080-0xD0BF) ----
|
||||||
@@ -463,33 +463,35 @@ const uint8_t FONT_12[]={
|
|||||||
0x00,0x60,0x60,0x60,0x60,0x68,0xE0,0xE0,0x60,0x20,0x00,0x00,0x00,0x30,0x38,0x3C,0x36,0x33,0x31,0x30,0x30,0x30,0x00,0x00, // ż c5 bc
|
0x00,0x60,0x60,0x60,0x60,0x68,0xE0,0xE0,0x60,0x20,0x00,0x00,0x00,0x30,0x38,0x3C,0x36,0x33,0x31,0x30,0x30,0x30,0x00,0x00, // ż c5 bc
|
||||||
0x00,0x18,0x18,0x18,0x19,0x1B,0x9A,0xDB,0xF9,0x78,0x38,0x00,0x00,0x30,0x38,0x3C,0x3E,0x37,0x33,0x31,0x30,0x30,0x30,0x00, // Ž c5 bd
|
0x00,0x18,0x18,0x18,0x19,0x1B,0x9A,0xDB,0xF9,0x78,0x38,0x00,0x00,0x30,0x38,0x3C,0x3E,0x37,0x33,0x31,0x30,0x30,0x30,0x00, // Ž c5 bd
|
||||||
0x00,0x60,0x60,0x64,0x6C,0x68,0xEC,0xE4,0x60,0x20,0x00,0x00,0x00,0x30,0x38,0x3C,0x36,0x33,0x31,0x30,0x30,0x30,0x00,0x00, // ž c5 be
|
0x00,0x60,0x60,0x64,0x6C,0x68,0xEC,0xE4,0x60,0x20,0x00,0x00,0x00,0x30,0x38,0x3C,0x36,0x33,0x31,0x30,0x30,0x30,0x00,0x00, // ž c5 be
|
||||||
0x00,0x00,0x00,0x00,0xFC,0xFE,0x06,0x06,0x0E,0x0C,0x00,0x00,0x00,0x00,0x30,0x30,0x3F,0x3F,0x30,0x00,0x00,0x00,0x00,0x00, // ſ c5 bf
|
0x00,0x00,0x00,0x00,0xFC,0xFE,0x06,0x06,0x0E,0x0C,0x00,0x00,0x00,0x00,0x30,0x30,0x3F,0x3F,0x30,0x00,0x00,0x00,0x00,0x00 // ſ c5 bf
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
const uint8_t ExtraFontChars[] = {
|
const uint8_t ExtraFontChars[] = {
|
||||||
|
//width = 12
|
||||||
|
//height = 16
|
||||||
0x00,0x18,0x24,0x24,0x18,0xC0,0x40,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x02,0x02,0x02,0x00,0x00,0x00, // Degrees F
|
0x00,0x18,0x24,0x24,0x18,0xC0,0x40,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x02,0x02,0x02,0x00,0x00,0x00, // Degrees F
|
||||||
0x00,0x18,0x24,0x24,0x18,0x80,0x40,0x20,0x20,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x08,0x10,0x10,0x10,0x00,0x00, // Degrees C
|
0x00,0x18,0x24,0x24,0x18,0x80,0x40,0x20,0x20,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x08,0x10,0x10,0x10,0x00,0x00, // Degrees C
|
||||||
0x00,0x00,0x20,0x30,0x38,0xFC,0xFE,0xFC,0x38,0x30,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x7F,0x7F,0x00,0x00,0x00,0x00, // UP arrow
|
0x00,0x00,0x20,0x30,0x38,0xFC,0xFE,0xFC,0x38,0x30,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x7F,0x7F,0x00,0x00,0x00,0x00, // UP arrow
|
||||||
|
|
||||||
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x3F,0x00,/*Battery Empty*/
|
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x3F,0x00, // Battery Empty
|
||||||
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x50,0x50,0x50,0x50,0x50,0x50,0x40,0x3F,0x00,/*Battery 1*/
|
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x50,0x50,0x50,0x50,0x50,0x50,0x40,0x3F,0x00, // Battery 1*/
|
||||||
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x58,0x58,0x58,0x58,0x58,0x58,0x40,0x3F,0x00,/*Battery 2*/
|
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x58,0x58,0x58,0x58,0x58,0x58,0x40,0x3F,0x00, // Battery 2*/
|
||||||
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5C,0x5C,0x5C,0x5C,0x5C,0x5C,0x40,0x3F,0x00,/*Battery 3*/
|
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5C,0x5C,0x5C,0x5C,0x5C,0x5C,0x40,0x3F,0x00, // Battery 3*/
|
||||||
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5E,0x5E,0x5E,0x5E,0x5E,0x5E,0x40,0x3F,0x00,/*Battery 4*/
|
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5E,0x5E,0x5E,0x5E,0x5E,0x5E,0x40,0x3F,0x00, // Battery 4*/
|
||||||
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00,/*Battery 5*/
|
0x00,0xF0,0x08,0x0E,0x02,0x02,0x02,0x02,0x0E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00, // Battery 5*/
|
||||||
0x00,0xF0,0x08,0x8E,0x82,0x82,0x82,0x82,0x8E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00,/*Battery 6*/
|
0x00,0xF0,0x08,0x8E,0x82,0x82,0x82,0x82,0x8E,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00, // Battery 6*/
|
||||||
0x00,0xF0,0x08,0xCE,0xC2,0xC2,0xC2,0xC2,0xCE,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00,/*Battery 7*/
|
0x00,0xF0,0x08,0xCE,0xC2,0xC2,0xC2,0xC2,0xCE,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00, // Battery 7*/
|
||||||
0x00,0xF0,0x08,0xEE,0xE2,0xE2,0xE2,0xE2,0xEE,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00,/*Battery 8*/
|
0x00,0xF0,0x08,0xEE,0xE2,0xE2,0xE2,0xE2,0xEE,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00, // Battery 8*/
|
||||||
0x00,0xF0,0x08,0xEE,0xE2,0xF2,0xF2,0xE2,0xEE,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00,/*Battery 9*/
|
0x00,0xF0,0x08,0xEE,0xE2,0xF2,0xF2,0xE2,0xEE,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00, // Battery 9*/
|
||||||
0x00,0xF0,0x08,0xEE,0xE2,0xFA,0xFA,0xE2,0xEE,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00,/*Battery 10*/
|
0x00,0xF0,0x08,0xEE,0xE2,0xFA,0xFA,0xE2,0xEE,0x08,0xF0,0x00,0x00,0x3F,0x40,0x5F,0x5F,0x5F,0x5F,0x5F,0x5F,0x40,0x3F,0x00, // Battery 10*/
|
||||||
|
|
||||||
0x00,0x00,0x38,0xC4,0x00,0x38,0xC4,0x00,0x38,0xC4,0x00,0x00,0x00,0x38,0x3A,0x39,0x38,0x3A,0x39,0x38,0x3A,0x39,0x10,0x10, // heating
|
0x00,0x00,0x38,0xC4,0x00,0x38,0xC4,0x00,0x38,0xC4,0x00,0x00,0x00,0x38,0x3A,0x39,0x38,0x3A,0x39,0x38,0x3A,0x39,0x10,0x10, // heating
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x38,0x38,0x38,0x38,0x38,0x38,0x38,0x38,0x10,0x10, // cooling
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x38,0x38,0x38,0x38,0x38,0x38,0x38,0x38,0x10,0x10, // cooling
|
||||||
//width = 12
|
0x00,0x60,0xE0,0xFE,0xE0,0xE0,0xE0,0xE0,0xFE,0xE0,0x60,0x00,0x00,0x00,0x00,0x01,0x03,0xFF,0xFF,0x03,0x01,0x00,0x00,0x00, // AC
|
||||||
//height = 16
|
|
||||||
0x00,0x60,0xE0,0xFE,0xE0,0xE0,0xE0,0xE0,0xFE,0xE0,0x60,0x00,0x00,0x00,0x00,0x01,0x03,0xFF,0xFF,0x03,0x01,0x00,0x00,0x00,
|
|
||||||
|
|
||||||
|
0xE0,0xF0,0x98,0x18,0x18,0x18,0x18,0xD8,0x78,0x38,0xFC,0xE6,0x1F,0x3F,0x61,0x63,0x66,0x6C,0x67,0x61,0x60,0x60,0x3F,0x1F, // checkbox on
|
||||||
|
0xE0,0xF0,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0xF0,0xE0,0x1F,0x3F,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x3F,0x1F // checkbox off
|
||||||
|
|
||||||
/*
|
/*
|
||||||
0x00,0x00,0x00,0x80,0x80,0xFE,0xFF,0x83,0x87,0x06,0x00,0x00,0x00,0x00,0x30,0x70,0x60,0x7F,0x3F,0x00,0x00,0x00,0x00,0x00, // Function?
|
0x00,0x00,0x00,0x80,0x80,0xFE,0xFF,0x83,0x87,0x06,0x00,0x00,0x00,0x00,0x30,0x70,0x60,0x7F,0x3F,0x00,0x00,0x00,0x00,0x00, // Function?
|
||||||
@@ -539,7 +541,6 @@ const uint8_t ExtraFontChars[] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const uint8_t FontSymbols[] = {
|
const uint8_t FontSymbols[] = {
|
||||||
|
|
||||||
0x00,0x00,0x00,0xFC,0xF8,0xF0,0xE0,0xC0,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x0F,0x07,0x03,0x01,0x00,0x00,0x00,0x00, // Right block
|
0x00,0x00,0x00,0xFC,0xF8,0xF0,0xE0,0xC0,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x0F,0x07,0x03,0x01,0x00,0x00,0x00,0x00, // Right block
|
||||||
0x00,0x00,0x00,0x80,0xC0,0xE0,0xF0,0xF8,0xFC,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x03,0x07,0x0F,0x1F,0x00,0x00,0x00, // left block
|
0x00,0x00,0x00,0x80,0xC0,0xE0,0xF0,0xF8,0xFC,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x03,0x07,0x0F,0x1F,0x00,0x00,0x00, // left block
|
||||||
0x00,0x00,0x00,0x10,0x18,0x1C,0xFE,0x1C,0x18,0x10,0x00,0x00,0x00,0x00,0x00,0x04,0x0C,0x1C,0x3F,0x1C,0x0C,0x04,0x00,0x00, // UD arrow
|
0x00,0x00,0x00,0x10,0x18,0x1C,0xFE,0x1C,0x18,0x10,0x00,0x00,0x00,0x00,0x00,0x04,0x0C,0x1C,0x3F,0x1C,0x0C,0x04,0x00,0x00, // UD arrow
|
||||||
@@ -555,16 +556,17 @@ const uint8_t FontSymbols[] = {
|
|||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,
|
||||||
0x00,0x80,0xC0,0xE0,0xF0,0x80,0x80,0x80,0xF0,0xE0,0xC0,0x80,0x00,0x00,0x01,0x03,0x07,0x00,0x00,0x00,0x07,0x03,0x01,0x00, // LR arrow
|
0x00,0x80,0xC0,0xE0,0xF0,0x80,0x80,0x80,0xF0,0xE0,0xC0,0x80,0x00,0x00,0x01,0x03,0x07,0x00,0x00,0x00,0x07,0x03,0x01,0x00, // LR arrow
|
||||||
0x00,0x00,0x00,0x00,0x80,0xC0,0xE0,0xC0,0x80,0x00,0x00,0x00,0x00,0x04,0x06,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x06,0x04, // UP block
|
0x00,0x00,0x00,0x00,0x80,0xC0,0xE0,0xC0,0x80,0x00,0x00,0x00,0x00,0x04,0x06,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x06,0x04, // UP block
|
||||||
0x00,0x20,0x60,0xE0,0xE0,0xE0,0xE0,0xE0,0xE0,0xE0,0x60,0x20,0x00,0x00,0x00,0x00,0x01,0x03,0x07,0x03,0x01,0x00,0x00,0x00,//Down block
|
0x00,0x20,0x60,0xE0,0xE0,0xE0,0xE0,0xE0,0xE0,0xE0,0x60,0x20,0x00,0x00,0x00,0x00,0x01,0x03,0x07,0x03,0x01,0x00,0x00,0x00 // Down block
|
||||||
};
|
};
|
||||||
|
|
||||||
const uint8_t WarningBlock24[] = {
|
const uint8_t WarningBlock24[] = {
|
||||||
//width = 24
|
//width = 24
|
||||||
//height = 16
|
//height = 16
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0x30,0x0C,0x02,0xF1,0xF1,0xF1,0x02,0x0C,0x30,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0x30,0x0C,0x02,0xF1,0xF1,0xF1,0x02,0x0C,0x30,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,
|
||||||
0x00,0x00,0x00,0xC0,0xB0,0x8C,0x83,0x80,0x80,0x80,0x80,0xB3,0xB3,0xB3,0x80,0x80,0x80,0x80,0x83,0x8C,0xB0,0xC0,0x00,0x00,
|
0x00,0x00,0x00,0xC0,0xB0,0x8C,0x83,0x80,0x80,0x80,0x80,0xB3,0xB3,0xB3,0x80,0x80,0x80,0x80,0x83,0x8C,0xB0,0xC0,0x00,0x00
|
||||||
};
|
};
|
||||||
const uint8_t idleScreenBG[] = {
|
|
||||||
|
|
||||||
|
const uint8_t idleScreenBG[] = {
|
||||||
//width = 84
|
//width = 84
|
||||||
//height = 16
|
//height = 16
|
||||||
0x00,0xE0,0x18,0x04,0x02,0x02,0x01,0x41,0x61,0x61,0x61,0xE1,0xC1,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,
|
0x00,0xE0,0x18,0x04,0x02,0x02,0x01,0x41,0x61,0x61,0x61,0xE1,0xC1,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,
|
||||||
@@ -574,7 +576,7 @@ const uint8_t idleScreenBG[] = {
|
|||||||
0x00,0x07,0x18,0x20,0x40,0x40,0x80,0x82,0x86,0x86,0x86,0x87,0x83,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,
|
0x00,0x07,0x18,0x20,0x40,0x40,0x80,0x82,0x86,0x86,0x86,0x87,0x83,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,
|
||||||
0x81,0x81,0x81,0x81,0x83,0x87,0x86,0x86,0x86,0x82,0x80,0x80,0x40,0x40,0x20,0x18,0x07,0x00,0x00,0x07,0x18,0x20,0x40,0x40,
|
0x81,0x81,0x81,0x81,0x83,0x87,0x86,0x86,0x86,0x82,0x80,0x80,0x40,0x40,0x20,0x18,0x07,0x00,0x00,0x07,0x18,0x20,0x40,0x40,
|
||||||
0x80,0x82,0x87,0x85,0x85,0x85,0x85,0x87,0x87,0x85,0x87,0x85,0x87,0x87,0x82,0x82,0x82,0x80,0x82,0x80,0x82,0x82,0x82,0x92,
|
0x80,0x82,0x87,0x85,0x85,0x85,0x85,0x87,0x87,0x85,0x87,0x85,0x87,0x87,0x82,0x82,0x82,0x80,0x82,0x80,0x82,0x82,0x82,0x92,
|
||||||
0x8A,0x84,0x82,0x81,0x80,0x80,0x80,0x40,0x40,0x20,0x18,0x07,
|
0x8A,0x84,0x82,0x81,0x80,0x80,0x80,0x40,0x40,0x20,0x18,0x07
|
||||||
};
|
};
|
||||||
|
|
||||||
const uint8_t idleScreenBGF[] = {
|
const uint8_t idleScreenBGF[] = {
|
||||||
@@ -587,102 +589,442 @@ const uint8_t idleScreenBGF[] = {
|
|||||||
0x07,0x18,0x20,0x40,0x40,0x80,0x80,0x80,0x81,0x82,0x84,0x8A,0x92,0x82,0x82,0x82,0x80,0x82,0x80,0x82,0x82,0x82,0x87,0x87,
|
0x07,0x18,0x20,0x40,0x40,0x80,0x80,0x80,0x81,0x82,0x84,0x8A,0x92,0x82,0x82,0x82,0x80,0x82,0x80,0x82,0x82,0x82,0x87,0x87,
|
||||||
0x85,0x87,0x85,0x87,0x87,0x85,0x85,0x85,0x85,0x87,0x82,0x80,0x40,0x40,0x20,0x18,0x07,0x00,0x00,0x07,0x18,0x20,0x40,0x40,
|
0x85,0x87,0x85,0x87,0x87,0x85,0x85,0x85,0x85,0x87,0x82,0x80,0x40,0x40,0x20,0x18,0x07,0x00,0x00,0x07,0x18,0x20,0x40,0x40,
|
||||||
0x80,0x80,0x82,0x86,0x86,0x86,0x87,0x83,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x83,
|
0x80,0x80,0x82,0x86,0x86,0x86,0x87,0x83,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x81,0x83,
|
||||||
0x87,0x86,0x86,0x86,0x82,0x80,0x40,0x40,0x20,0x18,0x07,0x00,
|
0x87,0x86,0x86,0x86,0x82,0x80,0x40,0x40,0x20,0x18,0x07,0x00
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const uint8_t FONT_6x8[] = {
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 000: ' ' U+0020 (utf-8: 20)
|
||||||
|
0x00, 0x00, 0x4f, 0x00, 0x00, 0x00, // 001: '!' U+0021 (utf-8: 21)
|
||||||
|
0x00, 0x07, 0x00, 0x07, 0x00, 0x00, // 002: '"' U+0022 (utf-8: 22)
|
||||||
|
0x14, 0x7f, 0x14, 0x7f, 0x14, 0x00, // 003: '#' U+0023 (utf-8: 23)
|
||||||
|
0x24, 0x2a, 0x7f, 0x2a, 0x12, 0x00, // 004: '$' U+0024 (utf-8: 24)
|
||||||
|
0x23, 0x13, 0x08, 0x64, 0x62, 0x00, // 005: '%' U+0025 (utf-8: 25)
|
||||||
|
0x36, 0x49, 0x56, 0x20, 0x58, 0x00, // 006: '&' U+0026 (utf-8: 26)
|
||||||
|
0x00, 0x05, 0x03, 0x00, 0x00, 0x00, // 007: ''' U+0027 (utf-8: 27)
|
||||||
|
0x00, 0x1c, 0x22, 0x41, 0x00, 0x00, // 008: '(' U+0028 (utf-8: 28)
|
||||||
|
0x00, 0x41, 0x22, 0x1c, 0x00, 0x00, // 009: ')' U+0029 (utf-8: 29)
|
||||||
|
0x14, 0x08, 0x3e, 0x08, 0x14, 0x00, // 010: '*' U+002a (utf-8: 2a)
|
||||||
|
0x08, 0x08, 0x3e, 0x08, 0x08, 0x00, // 011: '+' U+002b (utf-8: 2b)
|
||||||
|
0x00, 0x50, 0x30, 0x00, 0x00, 0x00, // 012: ',' U+002c (utf-8: 2c)
|
||||||
|
0x08, 0x08, 0x08, 0x08, 0x08, 0x00, // 013: '-' U+002d (utf-8: 2d)
|
||||||
|
0x00, 0x60, 0x60, 0x00, 0x00, 0x00, // 014: '.' U+002e (utf-8: 2e)
|
||||||
|
0x20, 0x10, 0x08, 0x04, 0x02, 0x00, // 015: '/' U+002f (utf-8: 2f)
|
||||||
|
0x3e, 0x51, 0x49, 0x45, 0x3e, 0x00, // 016: '0' U+0030 (utf-8: 30)
|
||||||
|
0x00, 0x42, 0x7f, 0x40, 0x00, 0x00, // 017: '1' U+0031 (utf-8: 31)
|
||||||
|
0x42, 0x61, 0x51, 0x49, 0x46, 0x00, // 018: '2' U+0032 (utf-8: 32)
|
||||||
|
0x21, 0x41, 0x45, 0x4b, 0x31, 0x00, // 019: '3' U+0033 (utf-8: 33)
|
||||||
|
0x18, 0x14, 0x12, 0x7f, 0x10, 0x00, // 020: '4' U+0034 (utf-8: 34)
|
||||||
|
0x27, 0x45, 0x45, 0x45, 0x39, 0x00, // 021: '5' U+0035 (utf-8: 35)
|
||||||
|
0x3c, 0x4a, 0x49, 0x49, 0x30, 0x00, // 022: '6' U+0036 (utf-8: 36)
|
||||||
|
0x01, 0x71, 0x09, 0x05, 0x03, 0x00, // 023: '7' U+0037 (utf-8: 37)
|
||||||
|
0x36, 0x49, 0x49, 0x49, 0x36, 0x00, // 024: '8' U+0038 (utf-8: 38)
|
||||||
|
0x06, 0x49, 0x49, 0x29, 0x1e, 0x00, // 025: '9' U+0039 (utf-8: 39)
|
||||||
|
0x00, 0x36, 0x36, 0x00, 0x00, 0x00, // 026: ':' U+003a (utf-8: 3a)
|
||||||
|
0x00, 0x56, 0x36, 0x00, 0x00, 0x00, // 027: ';' U+003b (utf-8: 3b)
|
||||||
|
0x08, 0x14, 0x22, 0x41, 0x00, 0x00, // 028: '<' U+003c (utf-8: 3c)
|
||||||
|
0x14, 0x14, 0x14, 0x14, 0x14, 0x00, // 029: '=' U+003d (utf-8: 3d)
|
||||||
|
0x00, 0x41, 0x22, 0x14, 0x08, 0x00, // 030: '>' U+003e (utf-8: 3e)
|
||||||
|
0x02, 0x01, 0x51, 0x09, 0x06, 0x00, // 031: '?' U+003f (utf-8: 3f)
|
||||||
|
0x32, 0x49, 0x79, 0x41, 0x3e, 0x00, // 032: '@' U+0040 (utf-8: 40)
|
||||||
|
0x7e, 0x09, 0x09, 0x09, 0x7e, 0x00, // 033: 'A' U+0041 (utf-8: 41)
|
||||||
|
0x7f, 0x49, 0x49, 0x49, 0x36, 0x00, // 034: 'B' U+0042 (utf-8: 42)
|
||||||
|
0x3e, 0x41, 0x41, 0x41, 0x22, 0x00, // 035: 'C' U+0043 (utf-8: 43)
|
||||||
|
0x7f, 0x41, 0x41, 0x22, 0x1c, 0x00, // 036: 'D' U+0044 (utf-8: 44)
|
||||||
|
0x7f, 0x49, 0x49, 0x49, 0x41, 0x00, // 037: 'E' U+0045 (utf-8: 45)
|
||||||
|
0x7f, 0x09, 0x09, 0x09, 0x01, 0x00, // 038: 'F' U+0046 (utf-8: 46)
|
||||||
|
0x3e, 0x41, 0x41, 0x49, 0x7a, 0x00, // 039: 'G' U+0047 (utf-8: 47)
|
||||||
|
0x7f, 0x08, 0x08, 0x08, 0x7f, 0x00, // 040: 'H' U+0048 (utf-8: 48)
|
||||||
|
0x00, 0x41, 0x7f, 0x41, 0x00, 0x00, // 041: 'I' U+0049 (utf-8: 49)
|
||||||
|
0x20, 0x40, 0x41, 0x3f, 0x01, 0x00, // 042: 'J' U+004a (utf-8: 4a)
|
||||||
|
0x7f, 0x08, 0x14, 0x22, 0x41, 0x00, // 043: 'K' U+004b (utf-8: 4b)
|
||||||
|
0x7f, 0x40, 0x40, 0x40, 0x40, 0x00, // 044: 'L' U+004c (utf-8: 4c)
|
||||||
|
0x7f, 0x02, 0x0c, 0x02, 0x7f, 0x00, // 045: 'M' U+004d (utf-8: 4d)
|
||||||
|
0x7f, 0x04, 0x08, 0x10, 0x7f, 0x00, // 046: 'N' U+004e (utf-8: 4e)
|
||||||
|
0x3e, 0x41, 0x41, 0x41, 0x3e, 0x00, // 047: 'O' U+004f (utf-8: 4f)
|
||||||
|
0x7f, 0x09, 0x09, 0x09, 0x06, 0x00, // 048: 'P' U+0050 (utf-8: 50)
|
||||||
|
0x3e, 0x41, 0x51, 0x21, 0x5e, 0x00, // 049: 'Q' U+0051 (utf-8: 51)
|
||||||
|
0x7f, 0x09, 0x19, 0x29, 0x46, 0x00, // 050: 'R' U+0052 (utf-8: 52)
|
||||||
|
0x26, 0x49, 0x49, 0x49, 0x32, 0x00, // 051: 'S' U+0053 (utf-8: 53)
|
||||||
|
0x01, 0x01, 0x7f, 0x01, 0x01, 0x00, // 052: 'T' U+0054 (utf-8: 54)
|
||||||
|
0x3f, 0x40, 0x40, 0x40, 0x3f, 0x00, // 053: 'U' U+0055 (utf-8: 55)
|
||||||
|
0x1f, 0x20, 0x40, 0x20, 0x1f, 0x00, // 054: 'V' U+0056 (utf-8: 56)
|
||||||
|
0x3f, 0x40, 0x38, 0x40, 0x3f, 0x00, // 055: 'W' U+0057 (utf-8: 57)
|
||||||
|
0x63, 0x14, 0x08, 0x14, 0x63, 0x00, // 056: 'X' U+0058 (utf-8: 58)
|
||||||
|
0x07, 0x08, 0x70, 0x08, 0x07, 0x00, // 057: 'Y' U+0059 (utf-8: 59)
|
||||||
|
0x61, 0x51, 0x49, 0x45, 0x43, 0x00, // 058: 'Z' U+005a (utf-8: 5a)
|
||||||
|
0x00, 0x7f, 0x41, 0x41, 0x00, 0x00, // 059: '[' U+005b (utf-8: 5b)
|
||||||
|
0x02, 0x04, 0x08, 0x10, 0x20, 0x00, // 060: '\' U+005c (utf-8: 5c)
|
||||||
|
0x00, 0x41, 0x41, 0x7f, 0x00, 0x00, // 061: ']' U+005d (utf-8: 5d)
|
||||||
|
0x04, 0x02, 0x01, 0x02, 0x04, 0x00, // 062: '^' U+005e (utf-8: 5e)
|
||||||
|
0x40, 0x40, 0x40, 0x40, 0x40, 0x00, // 063: '_' U+005f (utf-8: 5f)
|
||||||
|
0x00, 0x03, 0x05, 0x00, 0x00, 0x00, // 064: '`' U+0060 (utf-8: 60)
|
||||||
|
0x20, 0x54, 0x54, 0x54, 0x78, 0x00, // 065: 'a' U+0061 (utf-8: 61)
|
||||||
|
0x7f, 0x48, 0x44, 0x44, 0x38, 0x00, // 066: 'b' U+0062 (utf-8: 62)
|
||||||
|
0x38, 0x44, 0x44, 0x44, 0x20, 0x00, // 067: 'c' U+0063 (utf-8: 63)
|
||||||
|
0x38, 0x44, 0x44, 0x48, 0x7f, 0x00, // 068: 'd' U+0064 (utf-8: 64)
|
||||||
|
0x38, 0x54, 0x54, 0x54, 0x18, 0x00, // 069: 'e' U+0065 (utf-8: 65)
|
||||||
|
0x00, 0x04, 0x7e, 0x05, 0x01, 0x00, // 070: 'f' U+0066 (utf-8: 66)
|
||||||
|
0x08, 0x54, 0x54, 0x54, 0x3c, 0x00, // 071: 'g' U+0067 (utf-8: 67)
|
||||||
|
0x7f, 0x08, 0x04, 0x04, 0x78, 0x00, // 072: 'h' U+0068 (utf-8: 68)
|
||||||
|
0x00, 0x44, 0x7d, 0x40, 0x00, 0x00, // 073: 'i' U+0069 (utf-8: 69)
|
||||||
|
0x20, 0x40, 0x44, 0x3d, 0x00, 0x00, // 074: 'j' U+006a (utf-8: 6a)
|
||||||
|
0x00, 0x7f, 0x10, 0x28, 0x44, 0x00, // 075: 'k' U+006b (utf-8: 6b)
|
||||||
|
0x00, 0x41, 0x7f, 0x40, 0x00, 0x00, // 076: 'l' U+006c (utf-8: 6c)
|
||||||
|
0x7c, 0x04, 0x78, 0x04, 0x78, 0x00, // 077: 'm' U+006d (utf-8: 6d)
|
||||||
|
0x7c, 0x08, 0x04, 0x04, 0x78, 0x00, // 078: 'n' U+006e (utf-8: 6e)
|
||||||
|
0x38, 0x44, 0x44, 0x44, 0x38, 0x00, // 079: 'o' U+006f (utf-8: 6f)
|
||||||
|
0x7c, 0x14, 0x14, 0x14, 0x08, 0x00, // 080: 'p' U+0070 (utf-8: 70)
|
||||||
|
0x08, 0x14, 0x14, 0x14, 0x7c, 0x00, // 081: 'q' U+0071 (utf-8: 71)
|
||||||
|
0x7c, 0x08, 0x04, 0x04, 0x08, 0x00, // 082: 'r' U+0072 (utf-8: 72)
|
||||||
|
0x48, 0x54, 0x54, 0x54, 0x24, 0x00, // 083: 's' U+0073 (utf-8: 73)
|
||||||
|
0x04, 0x3e, 0x44, 0x40, 0x20, 0x00, // 084: 't' U+0074 (utf-8: 74)
|
||||||
|
0x3c, 0x40, 0x40, 0x20, 0x7c, 0x00, // 085: 'u' U+0075 (utf-8: 75)
|
||||||
|
0x0c, 0x30, 0x40, 0x30, 0x0c, 0x00, // 086: 'v' U+0076 (utf-8: 76)
|
||||||
|
0x3c, 0x40, 0x30, 0x40, 0x3c, 0x00, // 087: 'w' U+0077 (utf-8: 77)
|
||||||
|
0x44, 0x24, 0x38, 0x48, 0x44, 0x00, // 088: 'x' U+0078 (utf-8: 78)
|
||||||
|
0x44, 0x48, 0x30, 0x10, 0x0c, 0x00, // 089: 'y' U+0079 (utf-8: 79)
|
||||||
|
0x44, 0x64, 0x54, 0x4c, 0x44, 0x00, // 090: 'z' U+007a (utf-8: 7a)
|
||||||
|
0x08, 0x36, 0x41, 0x00, 0x00, 0x00, // 091: '{' U+007b (utf-8: 7b)
|
||||||
|
0x00, 0x00, 0x77, 0x00, 0x00, 0x00, // 092: '|' U+007c (utf-8: 7c)
|
||||||
|
0x00, 0x00, 0x41, 0x36, 0x08, 0x00, // 093: '}' U+007d (utf-8: 7d)
|
||||||
|
0x02, 0x01, 0x02, 0x04, 0x02, 0x00, // 094: '~' U+007e (utf-8: 7e)
|
||||||
|
0x04, 0x02, 0x01, 0x02, 0x04, 0x00, // 095: '^' U+005e (utf-8: 5e)
|
||||||
|
|
||||||
const unsigned char ASCII6x8[] = {
|
/* Latin-1 Supplement */
|
||||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // sp
|
// ---- HALF-PAGE U+00A0-U+00BF (UTF 0xC2A0-0xC2BF) ----
|
||||||
0x00, 0x00, 0x00, 0x2f, 0x00, 0x00, // !
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 096: ' ' U+00a0 (utf-8: c2 a0)
|
||||||
0x00, 0x00, 0x07, 0x00, 0x07, 0x00, // "
|
0x00, 0x00, 0x79, 0x00, 0x00, 0x00, // 097: '¡' U+00a1 (utf-8: c2 a1)
|
||||||
0x00, 0x14, 0x7f, 0x14, 0x7f, 0x14, // #
|
0x1c, 0x22, 0x7f, 0x22, 0x10, 0x00, // 098: '¢' U+00a2 (utf-8: c2 a2)
|
||||||
0x00, 0x24, 0x2a, 0x7f, 0x2a, 0x12, // $
|
0x50, 0x7e, 0x51, 0x41, 0x42, 0x00, // 099: '£' U+00a3 (utf-8: c2 a3)
|
||||||
0x00, 0x62, 0x64, 0x08, 0x13, 0x23, // %
|
0x22, 0x1c, 0x14, 0x1c, 0x22, 0x00, // 100: '¤' U+00a4 (utf-8: c2 a4)
|
||||||
0x00, 0x36, 0x49, 0x55, 0x22, 0x50, // &
|
0x15, 0x16, 0x7c, 0x16, 0x15, 0x00, // 101: '¥' U+00a5 (utf-8: c2 a5)
|
||||||
0x00, 0x00, 0x05, 0x03, 0x00, 0x00, // '
|
0x00, 0x00, 0x77, 0x00, 0x00, 0x00, // 102: '¦' U+00a6 (utf-8: c2 a6)
|
||||||
0x00, 0x00, 0x1c, 0x22, 0x41, 0x00, // (
|
0x4a, 0x55, 0x55, 0x55, 0x29, 0x00, // 103: '§' U+00a7 (utf-8: c2 a7)
|
||||||
0x00, 0x00, 0x41, 0x22, 0x1c, 0x00, // )
|
0x00, 0x01, 0x00, 0x01, 0x00, 0x00, // 104: '¨' U+00a8 (utf-8: c2 a8)
|
||||||
0x00, 0x14, 0x08, 0x3E, 0x08, 0x14, // *
|
0x00, 0x18, 0x24, 0x24, 0x00, 0x00, // 105: '©' U+00a9 (utf-8: c2 a9)
|
||||||
0x00, 0x08, 0x08, 0x3E, 0x08, 0x08, // +
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 106: 'ª' U+00aa (utf-8: c2 aa)
|
||||||
0x00, 0x00, 0x00, 0xA0, 0x60, 0x00, // ,
|
0x08, 0x14, 0x00, 0x08, 0x14, 0x00, // 107: '«' U+00ab (utf-8: c2 ab)
|
||||||
0x00, 0x08, 0x08, 0x08, 0x08, 0x08, // -
|
0x08, 0x08, 0x08, 0x08, 0x38, 0x00, // 108: '¬' U+00ac (utf-8: c2 ac)
|
||||||
0x00, 0x00, 0x60, 0x60, 0x00, 0x00, // .
|
0x08, 0x08, 0x08, 0x08, 0x08, 0x00, // 109: '' U+00ad (utf-8: c2 ad)
|
||||||
0x00, 0x20, 0x10, 0x08, 0x04, 0x02, // /
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 110: '®' U+00ae (utf-8: c2 ae)
|
||||||
0x00, 0x3E, 0x51, 0x49, 0x45, 0x3E, // 0
|
0x00, 0x01, 0x01, 0x01, 0x00, 0x00, // 111: '¯' U+00af (utf-8: c2 af)
|
||||||
0x00, 0x00, 0x42, 0x7F, 0x40, 0x00, // 1
|
0x00, 0x00, 0x07, 0x05, 0x07, 0x00, // 112: '°' U+00b0 (utf-8: c2 b0)
|
||||||
0x00, 0x42, 0x61, 0x51, 0x49, 0x46, // 2
|
0x44, 0x44, 0x5f, 0x44, 0x44, 0x00, // 113: '±' U+00b1 (utf-8: c2 b1)
|
||||||
0x00, 0x21, 0x41, 0x45, 0x4B, 0x31, // 3
|
0x1d, 0x15, 0x17, 0x00, 0x00, 0x00, // 114: '²' U+00b2 (utf-8: c2 b2)
|
||||||
0x00, 0x18, 0x14, 0x12, 0x7F, 0x10, // 4
|
0x15, 0x15, 0x1f, 0x00, 0x00, 0x00, // 115: '³' U+00b3 (utf-8: c2 b3)
|
||||||
0x00, 0x27, 0x45, 0x45, 0x45, 0x39, // 5
|
0x00, 0x04, 0x02, 0x01, 0x00, 0x00, // 116: '´' U+00b4 (utf-8: c2 b4)
|
||||||
0x00, 0x3C, 0x4A, 0x49, 0x49, 0x30, // 6
|
0x7c, 0x10, 0x10, 0x0c, 0x10, 0x00, // 117: 'µ' U+00b5 (utf-8: c2 b5)
|
||||||
0x00, 0x01, 0x71, 0x09, 0x05, 0x03, // 7
|
0x02, 0x07, 0x7f, 0x01, 0x7f, 0x00, // 118: '¶' U+00b6 (utf-8: c2 b6)
|
||||||
0x00, 0x36, 0x49, 0x49, 0x49, 0x36, // 8
|
0x00, 0x00, 0x08, 0x00, 0x00, 0x00, // 119: '·' U+00b7 (utf-8: c2 b7)
|
||||||
0x00, 0x06, 0x49, 0x49, 0x29, 0x1E, // 9
|
0x00, 0x40, 0x60, 0x00, 0x00, 0x00, // 120: '¸' U+00b8 (utf-8: c2 b8)
|
||||||
0x00, 0x00, 0x36, 0x36, 0x00, 0x00, // :
|
0x12, 0x1f, 0x10, 0x00, 0x00, 0x00, // 121: '¹' U+00b9 (utf-8: c2 b9)
|
||||||
0x00, 0x00, 0x56, 0x36, 0x00, 0x00, // ;
|
0x07, 0x05, 0x07, 0x00, 0x00, 0x00, // 122: 'º' U+00ba (utf-8: c2 ba)
|
||||||
0x00, 0x08, 0x14, 0x22, 0x41, 0x00, // <
|
0x14, 0x08, 0x00, 0x14, 0x08, 0x00, // 123: '»' U+00bb (utf-8: c2 bb)
|
||||||
0x00, 0x14, 0x14, 0x14, 0x14, 0x14, // =
|
0x21, 0x17, 0x38, 0x24, 0x72, 0x00, // 124: '¼' U+00bc (utf-8: c2 bc)
|
||||||
0x00, 0x00, 0x41, 0x22, 0x14, 0x08, // >
|
0x21, 0x17, 0x78, 0x54, 0x5e, 0x00, // 125: '½' U+00bd (utf-8: c2 bd)
|
||||||
0x00, 0x02, 0x01, 0x51, 0x09, 0x06, // ?
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 126: '¾' U+00be (utf-8: c2 be)
|
||||||
0x00, 0x32, 0x49, 0x59, 0x51, 0x3E, // @
|
0x30, 0x48, 0x45, 0x40, 0x20, 0x00, // 127: '¿' U+00bf (utf-8: c2 bf)
|
||||||
0x00, 0x7C, 0x12, 0x11, 0x12, 0x7C, // A
|
|
||||||
0x00, 0x7F, 0x49, 0x49, 0x49, 0x36, // B
|
// ---- PAGE U+00C0-U+00FF (UTF 0xC380-0xC3BF) ----
|
||||||
0x00, 0x3E, 0x41, 0x41, 0x41, 0x22, // C
|
0x78, 0x15, 0x16, 0x14, 0x78, 0x00, // 128: 'À' U+00c0 (utf-8: c3 80)
|
||||||
0x00, 0x7F, 0x41, 0x41, 0x22, 0x1C, // D
|
0x78, 0x14, 0x16, 0x15, 0x78, 0x00, // 129: 'Á' U+00c1 (utf-8: c3 81)
|
||||||
0x00, 0x7F, 0x49, 0x49, 0x49, 0x41, // E
|
0x78, 0x16, 0x15, 0x16, 0x78, 0x00, // 130: 'Â' U+00c2 (utf-8: c3 82)
|
||||||
0x00, 0x7F, 0x09, 0x09, 0x09, 0x01, // F
|
0x7a, 0x29, 0x2a, 0x79, 0x00, 0x00, // 131: 'Ã' U+00c3 (utf-8: c3 83)
|
||||||
0x00, 0x3E, 0x41, 0x49, 0x49, 0x7A, // G
|
0x78, 0x15, 0x14, 0x15, 0x78, 0x00, // 132: 'Ä' U+00c4 (utf-8: c3 84)
|
||||||
0x00, 0x7F, 0x08, 0x08, 0x08, 0x7F, // H
|
0x78, 0x14, 0x15, 0x14, 0x78, 0x00, // 133: 'Å' U+00c5 (utf-8: c3 85)
|
||||||
0x00, 0x00, 0x41, 0x7F, 0x41, 0x00, // I
|
0x7e, 0x09, 0x7f, 0x49, 0x49, 0x00, // 134: 'Æ' U+00c6 (utf-8: c3 86)
|
||||||
0x00, 0x20, 0x40, 0x41, 0x3F, 0x01, // J
|
0x0e, 0x51, 0x71, 0x11, 0x08, 0x00, // 135: 'Ç' U+00c7 (utf-8: c3 87)
|
||||||
0x00, 0x7F, 0x08, 0x14, 0x22, 0x41, // K
|
0x7c, 0x55, 0x56, 0x44, 0x44, 0x00, // 136: 'È' U+00c8 (utf-8: c3 88)
|
||||||
0x00, 0x7F, 0x40, 0x40, 0x40, 0x40, // L
|
0x7c, 0x54, 0x56, 0x45, 0x44, 0x00, // 137: 'É' U+00c9 (utf-8: c3 89)
|
||||||
0x00, 0x7F, 0x02, 0x0C, 0x02, 0x7F, // M
|
0x7c, 0x56, 0x55, 0x46, 0x44, 0x00, // 138: 'Ê' U+00ca (utf-8: c3 8a)
|
||||||
0x00, 0x7F, 0x04, 0x08, 0x10, 0x7F, // N
|
0x7c, 0x55, 0x54, 0x45, 0x44, 0x00, // 139: 'Ë' U+00cb (utf-8: c3 8b)
|
||||||
0x00, 0x3E, 0x41, 0x41, 0x41, 0x3E, // O
|
0x00, 0x49, 0x7a, 0x48, 0x00, 0x00, // 140: 'Ì' U+00cc (utf-8: c3 8c)
|
||||||
0x00, 0x7F, 0x09, 0x09, 0x09, 0x06, // P
|
0x00, 0x48, 0x7a, 0x49, 0x00, 0x00, // 141: 'Í' U+00cd (utf-8: c3 8d)
|
||||||
0x00, 0x3E, 0x41, 0x51, 0x21, 0x5E, // Q
|
0x00, 0x4a, 0x79, 0x4a, 0x00, 0x00, // 142: 'Î' U+00ce (utf-8: c3 8e)
|
||||||
0x00, 0x7F, 0x09, 0x19, 0x29, 0x46, // R
|
0x44, 0x45, 0x7c, 0x45, 0x44, 0x00, // 143: 'Ï' U+00cf (utf-8: c3 8f)
|
||||||
0x00, 0x46, 0x49, 0x49, 0x49, 0x31, // S
|
0x08, 0x7f, 0x49, 0x22, 0x1c, 0x00, // 144: 'Ð' U+00d0 (utf-8: c3 90)
|
||||||
0x00, 0x01, 0x01, 0x7F, 0x01, 0x01, // T
|
0x7a, 0x11, 0x22, 0x79, 0x00, 0x00, // 145: 'Ñ' U+00d1 (utf-8: c3 91)
|
||||||
0x00, 0x3F, 0x40, 0x40, 0x40, 0x3F, // U
|
0x38, 0x45, 0x46, 0x44, 0x38, 0x00, // 146: 'Ò' U+00d2 (utf-8: c3 92)
|
||||||
0x00, 0x1F, 0x20, 0x40, 0x20, 0x1F, // V
|
0x38, 0x44, 0x46, 0x45, 0x38, 0x00, // 147: 'Ó' U+00d3 (utf-8: c3 93)
|
||||||
0x00, 0x3F, 0x40, 0x38, 0x40, 0x3F, // W
|
0x38, 0x46, 0x45, 0x46, 0x38, 0x00, // 148: 'Ô' U+00d4 (utf-8: c3 94)
|
||||||
0x00, 0x63, 0x14, 0x08, 0x14, 0x63, // X
|
0x32, 0x49, 0x4a, 0x31, 0x00, 0x00, // 149: 'Õ' U+00d5 (utf-8: c3 95)
|
||||||
0x00, 0x07, 0x08, 0x70, 0x08, 0x07, // Y
|
0x38, 0x45, 0x44, 0x45, 0x38, 0x00, // 150: 'Ö' U+00d6 (utf-8: c3 96)
|
||||||
0x00, 0x61, 0x51, 0x49, 0x45, 0x43, // Z
|
0x22, 0x14, 0x08, 0x14, 0x22, 0x00, // 151: '×' U+00d7 (utf-8: c3 97)
|
||||||
0x00, 0x00, 0x7F, 0x41, 0x41, 0x00, // [
|
0x58, 0x24, 0x54, 0x48, 0x34, 0x00, // 152: 'Ø' U+00d8 (utf-8: c3 98)
|
||||||
0x00, 0x55, 0x2A, 0x55, 0x2A, 0x55, // '\'
|
0x38, 0x41, 0x42, 0x40, 0x38, 0x00, // 153: 'Ù' U+00d9 (utf-8: c3 99)
|
||||||
0x00, 0x00, 0x41, 0x41, 0x7F, 0x00, // ]
|
0x38, 0x40, 0x42, 0x41, 0x38, 0x00, // 154: 'Ú' U+00da (utf-8: c3 9a)
|
||||||
0x00, 0x04, 0x02, 0x01, 0x02, 0x04, // ^
|
0x38, 0x42, 0x41, 0x42, 0x38, 0x00, // 155: 'Û' U+00db (utf-8: c3 9b)
|
||||||
0x00, 0x40, 0x40, 0x40, 0x40, 0x40, // _
|
0x3c, 0x41, 0x40, 0x41, 0x3c, 0x00, // 156: 'Ü' U+00dc (utf-8: c3 9c)
|
||||||
0x00, 0x00, 0x01, 0x02, 0x04, 0x00, // '
|
0x04, 0x08, 0x72, 0x09, 0x04, 0x00, // 157: 'Ý' U+00dd (utf-8: c3 9d)
|
||||||
0x00, 0x20, 0x54, 0x54, 0x54, 0x78, // a
|
0x7f, 0x22, 0x22, 0x22, 0x1c, 0x00, // 158: 'Þ' U+00de (utf-8: c3 9e)
|
||||||
0x00, 0x7F, 0x48, 0x44, 0x44, 0x38, // b
|
0x7e, 0x11, 0x25, 0x25, 0x1a, 0x00, // 159: 'ß' U+00df (utf-8: c3 9f)
|
||||||
0x00, 0x38, 0x44, 0x44, 0x44, 0x20, // c
|
0x20, 0x55, 0x56, 0x54, 0x78, 0x00, // 160: 'à' U+00e0 (utf-8: c3 a0)
|
||||||
0x00, 0x38, 0x44, 0x44, 0x48, 0x7F, // d
|
0x20, 0x54, 0x56, 0x55, 0x78, 0x00, // 161: 'á' U+00e1 (utf-8: c3 a1)
|
||||||
0x00, 0x38, 0x54, 0x54, 0x54, 0x18, // e
|
0x20, 0x56, 0x55, 0x56, 0x78, 0x00, // 162: 'â' U+00e2 (utf-8: c3 a2)
|
||||||
0x00, 0x08, 0x7E, 0x09, 0x01, 0x02, // f
|
0x22, 0x55, 0x56, 0x55, 0x78, 0x00, // 163: 'ã' U+00e3 (utf-8: c3 a3)
|
||||||
0x00, 0x18, 0xA4, 0xA4, 0xA4, 0x7C, // g
|
0x20, 0x55, 0x54, 0x55, 0x78, 0x00, // 164: 'ä' U+00e4 (utf-8: c3 a4)
|
||||||
0x00, 0x7F, 0x08, 0x04, 0x04, 0x78, // h
|
0x20, 0x54, 0x55, 0x54, 0x78, 0x00, // 165: 'å' U+00e5 (utf-8: c3 a5)
|
||||||
0x00, 0x00, 0x44, 0x7D, 0x40, 0x00, // i
|
0x24, 0x54, 0x7c, 0x54, 0x48, 0x00, // 166: 'æ' U+00e6 (utf-8: c3 a6)
|
||||||
0x00, 0x40, 0x80, 0x84, 0x7D, 0x00, // j
|
0x1c, 0x22, 0x62, 0x22, 0x10, 0x00, // 167: 'ç' U+00e7 (utf-8: c3 a7)
|
||||||
0x00, 0x7F, 0x10, 0x28, 0x44, 0x00, // k
|
0x38, 0x55, 0x56, 0x54, 0x08, 0x00, // 168: 'è' U+00e8 (utf-8: c3 a8)
|
||||||
0x00, 0x00, 0x41, 0x7F, 0x40, 0x00, // l
|
0x38, 0x54, 0x56, 0x55, 0x08, 0x00, // 169: 'é' U+00e9 (utf-8: c3 a9)
|
||||||
0x00, 0x7C, 0x04, 0x18, 0x04, 0x78, // m
|
0x38, 0x56, 0x55, 0x56, 0x08, 0x00, // 170: 'ê' U+00ea (utf-8: c3 aa)
|
||||||
0x00, 0x7C, 0x08, 0x04, 0x04, 0x78, // n
|
0x38, 0x55, 0x54, 0x55, 0x08, 0x00, // 171: 'ë' U+00eb (utf-8: c3 ab)
|
||||||
0x00, 0x38, 0x44, 0x44, 0x44, 0x38, // o
|
0x00, 0x45, 0x7e, 0x40, 0x00, 0x00, // 172: 'ì' U+00ec (utf-8: c3 ac)
|
||||||
0x00, 0xFC, 0x24, 0x24, 0x24, 0x18, // p
|
0x00, 0x44, 0x7e, 0x41, 0x00, 0x00, // 173: 'í' U+00ed (utf-8: c3 ad)
|
||||||
0x00, 0x18, 0x24, 0x24, 0x18, 0xFC, // q
|
0x00, 0x46, 0x7d, 0x42, 0x00, 0x00, // 174: 'î' U+00ee (utf-8: c3 ae)
|
||||||
0x00, 0x7C, 0x08, 0x04, 0x04, 0x08, // r
|
0x00, 0x45, 0x7c, 0x41, 0x00, 0x00, // 175: 'ï' U+00ef (utf-8: c3 af)
|
||||||
0x00, 0x48, 0x54, 0x54, 0x54, 0x20, // s
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 176: 'ð' U+00f0 (utf-8: c3 b0)
|
||||||
0x00, 0x04, 0x3F, 0x44, 0x40, 0x20, // t
|
0x78, 0x12, 0x09, 0x0a, 0x71, 0x00, // 177: 'ñ' U+00f1 (utf-8: c3 b1)
|
||||||
0x00, 0x3C, 0x40, 0x40, 0x20, 0x7C, // u
|
0x38, 0x45, 0x46, 0x44, 0x38, 0x00, // 178: 'ò' U+00f2 (utf-8: c3 b2)
|
||||||
0x00, 0x1C, 0x20, 0x40, 0x20, 0x1C, // v
|
0x38, 0x44, 0x46, 0x45, 0x38, 0x00, // 179: 'ó' U+00f3 (utf-8: c3 b3)
|
||||||
0x00, 0x3C, 0x40, 0x30, 0x40, 0x3C, // w
|
0x38, 0x46, 0x45, 0x46, 0x38, 0x00, // 180: 'ô' U+00f4 (utf-8: c3 b4)
|
||||||
0x00, 0x44, 0x28, 0x10, 0x28, 0x44, // x
|
0x32, 0x49, 0x4a, 0x31, 0x00, 0x00, // 181: 'õ' U+00f5 (utf-8: c3 b5)
|
||||||
0x00, 0x1C, 0xA0, 0xA0, 0xA0, 0x7C, // y
|
0x38, 0x45, 0x44, 0x45, 0x38, 0x00, // 182: 'ö' U+00f6 (utf-8: c3 b6)
|
||||||
0x00, 0x44, 0x64, 0x54, 0x4C, 0x44, // z
|
0x08, 0x08, 0x2a, 0x08, 0x08, 0x00, // 183: '÷' U+00f7 (utf-8: c3 b7)
|
||||||
|
0x58, 0x24, 0x54, 0x48, 0x34, 0x00, // 184: 'ø' U+00f8 (utf-8: c3 b8)
|
||||||
|
0x3c, 0x41, 0x42, 0x20, 0x7c, 0x00, // 185: 'ù' U+00f9 (utf-8: c3 b9)
|
||||||
|
0x3c, 0x40, 0x42, 0x21, 0x7c, 0x00, // 186: 'ú' U+00fa (utf-8: c3 ba)
|
||||||
|
0x3c, 0x42, 0x41, 0x22, 0x7c, 0x00, // 187: 'û' U+00fb (utf-8: c3 bb)
|
||||||
|
0x3c, 0x41, 0x40, 0x21, 0x5c, 0x00, // 188: 'ü' U+00fc (utf-8: c3 bc)
|
||||||
|
0x44, 0x48, 0x32, 0x11, 0x0c, 0x00, // 189: 'ý' U+00fd (utf-8: c3 bd)
|
||||||
|
0x7c, 0x28, 0x28, 0x10, 0x00, 0x00, // 190: 'þ' U+00fe (utf-8: c3 be)
|
||||||
|
0x44, 0x49, 0x30, 0x11, 0x0c, 0x00, // 191: 'ÿ' U+00ff (utf-8: c3 bf)
|
||||||
|
#ifdef LANG_RU
|
||||||
|
/* Cyrillic */
|
||||||
|
// ---- PAGE U+0400-U+043F (UTF 0xD080-0xD0BF) ----
|
||||||
|
0x7c, 0x55, 0x56, 0x44, 0x44, 0x00, // 192: 'Ѐ' U+0400 (utf-8: d0 80)
|
||||||
|
0x7c, 0x55, 0x54, 0x45, 0x44, 0x00, // 193: 'Ё' U+0401 (utf-8: d0 81)
|
||||||
|
0x01, 0x7f, 0x09, 0x49, 0x31, 0x00, // 194: 'Ђ' U+0402 (utf-8: d0 82)
|
||||||
|
0x7c, 0x04, 0x06, 0x05, 0x04, 0x00, // 195: 'Ѓ' U+0403 (utf-8: d0 83)
|
||||||
|
0x3e, 0x49, 0x49, 0x41, 0x00, 0x00, // 196: 'Є' U+0404 (utf-8: d0 84)
|
||||||
|
0x06, 0x49, 0x49, 0x49, 0x30, 0x00, // 197: 'Ѕ' U+0405 (utf-8: d0 85)
|
||||||
|
0x41, 0x41, 0x7f, 0x41, 0x41, 0x00, // 198: 'І' U+0406 (utf-8: d0 86)
|
||||||
|
0x44, 0x45, 0x7c, 0x45, 0x44, 0x00, // 199: 'Ї' U+0407 (utf-8: d0 87)
|
||||||
|
0x20, 0x40, 0x41, 0x3f, 0x01, 0x00, // 200: 'Ј' U+0408 (utf-8: d0 88)
|
||||||
|
0x7f, 0x01, 0x7f, 0x48, 0x30, 0x00, // 201: 'Љ' U+0409 (utf-8: d0 89)
|
||||||
|
0x7f, 0x08, 0x7f, 0x48, 0x30, 0x00, // 202: 'Њ' U+040a (utf-8: d0 8a)
|
||||||
|
0x01, 0x01, 0x7f, 0x09, 0x71, 0x00, // 203: 'Ћ' U+040b (utf-8: d0 8b)
|
||||||
|
0x7c, 0x12, 0x29, 0x44, 0x00, 0x00, // 204: 'Ќ' U+040c (utf-8: d0 8c)
|
||||||
|
0x7c, 0x21, 0x12, 0x08, 0x7c, 0x00, // 205: 'Ѝ' U+040d (utf-8: d0 8d)
|
||||||
|
0x44, 0x49, 0x32, 0x09, 0x04, 0x00, // 206: 'Ў' U+040e (utf-8: d0 8e)
|
||||||
|
0x3f, 0x20, 0x60, 0x20, 0x3f, 0x00, // 207: 'Џ' U+040f (utf-8: d0 8f)
|
||||||
|
0x7e, 0x09, 0x09, 0x09, 0x7e, 0x00, // 208: 'А' U+0410 (utf-8: d0 90)
|
||||||
|
0x7f, 0x49, 0x49, 0x49, 0x31, 0x00, // 209: 'Б' U+0411 (utf-8: d0 91)
|
||||||
|
0x7f, 0x49, 0x49, 0x49, 0x36, 0x00, // 210: 'В' U+0412 (utf-8: d0 92)
|
||||||
|
0x7f, 0x01, 0x01, 0x01, 0x01, 0x00, // 211: 'Г' U+0413 (utf-8: d0 93)
|
||||||
|
0x60, 0x3f, 0x21, 0x3f, 0x60, 0x00, // 212: 'Д' U+0414 (utf-8: d0 94)
|
||||||
|
0x7f, 0x49, 0x49, 0x49, 0x41, 0x00, // 213: 'Е' U+0415 (utf-8: d0 95)
|
||||||
|
0x77, 0x08, 0x7f, 0x08, 0x77, 0x00, // 214: 'Ж' U+0416 (utf-8: d0 96)
|
||||||
|
0x00, 0x41, 0x49, 0x49, 0x36, 0x00, // 215: 'З' U+0417 (utf-8: d0 97)
|
||||||
|
0x7f, 0x10, 0x08, 0x04, 0x7f, 0x00, // 216: 'И' U+0418 (utf-8: d0 98)
|
||||||
|
0x7c, 0x21, 0x12, 0x09, 0x7c, 0x00, // 217: 'Й' U+0419 (utf-8: d0 99)
|
||||||
|
0x7f, 0x08, 0x14, 0x22, 0x41, 0x00, // 218: 'К' U+041a (utf-8: d0 9a)
|
||||||
|
0x40, 0x3f, 0x01, 0x01, 0x7f, 0x00, // 219: 'Л' U+041b (utf-8: d0 9b)
|
||||||
|
0x7f, 0x02, 0x04, 0x02, 0x7f, 0x00, // 220: 'М' U+041c (utf-8: d0 9c)
|
||||||
|
0x7f, 0x08, 0x08, 0x08, 0x7f, 0x00, // 221: 'Н' U+041d (utf-8: d0 9d)
|
||||||
|
0x3e, 0x41, 0x41, 0x41, 0x3e, 0x00, // 222: 'О' U+041e (utf-8: d0 9e)
|
||||||
|
0x7f, 0x01, 0x01, 0x01, 0x7f, 0x00, // 223: 'П' U+041f (utf-8: d0 9f)
|
||||||
|
0x7f, 0x09, 0x09, 0x09, 0x06, 0x00, // 224: 'Р' U+0420 (utf-8: d0 a0)
|
||||||
|
0x3e, 0x41, 0x41, 0x41, 0x22, 0x00, // 225: 'С' U+0421 (utf-8: d0 a1)
|
||||||
|
0x01, 0x01, 0x7f, 0x01, 0x01, 0x00, // 226: 'Т' U+0422 (utf-8: d0 a2)
|
||||||
|
0x47, 0x48, 0x30, 0x08, 0x07, 0x00, // 227: 'У' U+0423 (utf-8: d0 a3)
|
||||||
|
0x0c, 0x12, 0x7f, 0x12, 0x0c, 0x00, // 228: 'Ф' U+0424 (utf-8: d0 a4)
|
||||||
|
0x63, 0x14, 0x08, 0x14, 0x63, 0x00, // 229: 'Х' U+0425 (utf-8: d0 a5)
|
||||||
|
0x3f, 0x20, 0x20, 0x3f, 0x60, 0x00, // 230: 'Ц' U+0426 (utf-8: d0 a6)
|
||||||
|
0x07, 0x08, 0x08, 0x08, 0x7f, 0x00, // 231: 'Ч' U+0427 (utf-8: d0 a7)
|
||||||
|
0x3f, 0x20, 0x3f, 0x20, 0x3f, 0x00, // 232: 'Ш' U+0428 (utf-8: d0 a8)
|
||||||
|
0x3f, 0x20, 0x3f, 0x20, 0x3f, 0x60, // 233: 'Щ' U+0429 (utf-8: d0 a9)
|
||||||
|
0x01, 0x7f, 0x48, 0x48, 0x30, 0x00, // 234: 'Ъ' U+042a (utf-8: d0 aa)
|
||||||
|
0x7f, 0x48, 0x30, 0x00, 0x7f, 0x00, // 235: 'Ы' U+042b (utf-8: d0 ab)
|
||||||
|
0x00, 0x7f, 0x48, 0x48, 0x30, 0x00, // 236: 'Ь' U+042c (utf-8: d0 ac)
|
||||||
|
0x22, 0x49, 0x49, 0x2a, 0x1c, 0x00, // 237: 'Э' U+042d (utf-8: d0 ad)
|
||||||
|
0x7f, 0x08, 0x3e, 0x41, 0x3e, 0x00, // 238: 'Ю' U+042e (utf-8: d0 ae)
|
||||||
|
0x46, 0x29, 0x19, 0x09, 0x7f, 0x00, // 239: 'Я' U+042f (utf-8: d0 af)
|
||||||
|
0x20, 0x54, 0x54, 0x54, 0x78, 0x00, // 240: 'а' U+0430 (utf-8: d0 b0)
|
||||||
|
0x3c, 0x4a, 0x4a, 0x4a, 0x30, 0x00, // 241: 'б' U+0431 (utf-8: d0 b1)
|
||||||
|
0x7c, 0x54, 0x54, 0x54, 0x28, 0x00, // 242: 'в' U+0432 (utf-8: d0 b2)
|
||||||
|
0x7c, 0x04, 0x04, 0x04, 0x04, 0x00, // 243: 'г' U+0433 (utf-8: d0 b3)
|
||||||
|
0x40, 0x3c, 0x24, 0x3c, 0x60, 0x00, // 244: 'д' U+0434 (utf-8: d0 b4)
|
||||||
|
0x38, 0x54, 0x54, 0x54, 0x18, 0x00, // 245: 'е' U+0435 (utf-8: d0 b5)
|
||||||
|
0x6c, 0x10, 0x7c, 0x10, 0x6c, 0x00, // 246: 'ж' U+0436 (utf-8: d0 b6)
|
||||||
|
0x28, 0x44, 0x54, 0x54, 0x28, 0x00, // 247: 'з' U+0437 (utf-8: d0 b7)
|
||||||
|
0x7c, 0x20, 0x10, 0x08, 0x7c, 0x00, // 248: 'и' U+0438 (utf-8: d0 b8)
|
||||||
|
0x7c, 0x21, 0x12, 0x09, 0x7c, 0x00, // 249: 'й' U+0439 (utf-8: d0 b9)
|
||||||
|
0x7c, 0x10, 0x28, 0x44, 0x00, 0x00, // 250: 'к' U+043a (utf-8: d0 ba)
|
||||||
|
0x40, 0x3c, 0x04, 0x04, 0x7c, 0x00, // 251: 'л' U+043b (utf-8: d0 bb)
|
||||||
|
0x7c, 0x08, 0x10, 0x08, 0x7c, 0x00, // 252: 'м' U+043c (utf-8: d0 bc)
|
||||||
|
0x7c, 0x10, 0x10, 0x10, 0x7c, 0x00, // 253: 'н' U+043d (utf-8: d0 bd)
|
||||||
|
0x38, 0x44, 0x44, 0x44, 0x38, 0x00, // 254: 'о' U+043e (utf-8: d0 be)
|
||||||
|
0x7c, 0x04, 0x04, 0x04, 0x7c, 0x00, // 255: 'п' U+043f (utf-8: d0 bf)
|
||||||
|
|
||||||
|
// ---- HALF-PAGE U+0440-U+045F (UTF 0xD180-0xD1BF) ----
|
||||||
|
0x7c, 0x14, 0x14, 0x14, 0x08, 0x00, // 256: 'р' U+0440 (utf-8: d1 80)
|
||||||
|
0x38, 0x44, 0x44, 0x44, 0x20, 0x00, // 257: 'с' U+0441 (utf-8: d1 81)
|
||||||
|
0x04, 0x04, 0x7c, 0x04, 0x04, 0x00, // 258: 'т' U+0442 (utf-8: d1 82)
|
||||||
|
0x4c, 0x50, 0x20, 0x10, 0x0c, 0x00, // 259: 'у' U+0443 (utf-8: d1 83)
|
||||||
|
0x18, 0x24, 0x7e, 0x24, 0x18, 0x00, // 260: 'ф' U+0444 (utf-8: d1 84)
|
||||||
|
0x44, 0x28, 0x10, 0x28, 0x44, 0x00, // 261: 'х' U+0445 (utf-8: d1 85)
|
||||||
|
0x3c, 0x20, 0x20, 0x3c, 0x60, 0x00, // 262: 'ц' U+0446 (utf-8: d1 86)
|
||||||
|
0x0c, 0x10, 0x10, 0x10, 0x7c, 0x00, // 263: 'ч' U+0447 (utf-8: d1 87)
|
||||||
|
0x3c, 0x20, 0x3c, 0x20, 0x3c, 0x00, // 264: 'ш' U+0448 (utf-8: d1 88)
|
||||||
|
0x3c, 0x20, 0x3c, 0x20, 0x7c, 0x00, // 265: 'щ' U+0449 (utf-8: d1 89)
|
||||||
|
0x04, 0x7c, 0x50, 0x20, 0x00, 0x00, // 266: 'ъ' U+044a (utf-8: d1 8a)
|
||||||
|
0x7c, 0x50, 0x20, 0x00, 0x7c, 0x00, // 267: 'ы' U+044b (utf-8: d1 8b)
|
||||||
|
0x00, 0x7c, 0x50, 0x20, 0x00, 0x00, // 268: 'ь' U+044c (utf-8: d1 8c)
|
||||||
|
0x28, 0x44, 0x54, 0x54, 0x28, 0x00, // 269: 'э' U+044d (utf-8: d1 8d)
|
||||||
|
0x7c, 0x10, 0x38, 0x44, 0x38, 0x00, // 270: 'ю' U+044e (utf-8: d1 8e)
|
||||||
|
0x48, 0x34, 0x14, 0x14, 0x7c, 0x00, // 271: 'я' U+044f (utf-8: d1 8f)
|
||||||
|
0x38, 0x55, 0x56, 0x54, 0x08, 0x00, // 272: 'ѐ' U+0450 (utf-8: d1 90)
|
||||||
|
0x38, 0x55, 0x54, 0x55, 0x08, 0x00, // 273: 'ё' U+0451 (utf-8: d1 91)
|
||||||
|
0x02, 0x3f, 0x12, 0x48, 0x30, 0x00, // 274: 'ђ' U+0452 (utf-8: d1 92)
|
||||||
|
0x7c, 0x04, 0x06, 0x05, 0x04, 0x00, // 275: 'ѓ' U+0453 (utf-8: d1 93)
|
||||||
|
0x38, 0x54, 0x54, 0x44, 0x28, 0x00, // 276: 'є' U+0454 (utf-8: d1 94)
|
||||||
|
0x08, 0x54, 0x54, 0x54, 0x20, 0x00, // 277: 'ѕ' U+0455 (utf-8: d1 95)
|
||||||
|
0x00, 0x44, 0x7d, 0x40, 0x00, 0x00, // 278: 'і' U+0456 (utf-8: d1 96)
|
||||||
|
0x00, 0x45, 0x7c, 0x41, 0x00, 0x00, // 279: 'ї' U+0457 (utf-8: d1 97)
|
||||||
|
0x20, 0x40, 0x44, 0x3d, 0x00, 0x00, // 280: 'ј' U+0458 (utf-8: d1 98)
|
||||||
|
0x7c, 0x04, 0x7c, 0x50, 0x20, 0x00, // 281: 'љ' U+0459 (utf-8: d1 99)
|
||||||
|
0x7c, 0x10, 0x7c, 0x50, 0x20, 0x00, // 282: 'њ' U+045a (utf-8: d1 9a)
|
||||||
|
0x04, 0x7e, 0x14, 0x10, 0x60, 0x00, // 283: 'ћ' U+045b (utf-8: d1 9b)
|
||||||
|
0x7c, 0x12, 0x29, 0x44, 0x00, 0x00, // 284: 'ќ' U+045c (utf-8: d1 9c)
|
||||||
|
0x7c, 0x21, 0x12, 0x08, 0x7c, 0x00, // 285: 'ѝ' U+045d (utf-8: d1 9d)
|
||||||
|
0x4c, 0x51, 0x22, 0x11, 0x0c, 0x00, // 286: 'ў' U+045e (utf-8: d1 9e)
|
||||||
|
0x3c, 0x20, 0x60, 0x20, 0x3c, 0x00, // 287: 'џ' U+045f (utf-8: d1 9f)
|
||||||
|
#else
|
||||||
|
/* Latin Extended-A */
|
||||||
|
// ---- PAGE U+0100-U+013F (UTF 0xC480-0xC4BF) ----
|
||||||
|
0x78, 0x15, 0x15, 0x15, 0x78, 0x00, // 192: 'Ā' U+0100 (utf-8: c4 80)
|
||||||
|
0x20, 0x55, 0x55, 0x55, 0x78, 0x00, // 193: 'ā' U+0101 (utf-8: c4 81)
|
||||||
|
0x78, 0x15, 0x16, 0x15, 0x78, 0x00, // 194: 'Ă' U+0102 (utf-8: c4 82)
|
||||||
|
0x20, 0x55, 0x56, 0x55, 0x78, 0x00, // 195: 'ă' U+0103 (utf-8: c4 83)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 196: 'Ą' U+0104 (utf-8: c4 84)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 197: 'ą' U+0105 (utf-8: c4 85)
|
||||||
|
0x38, 0x44, 0x46, 0x45, 0x28, 0x00, // 198: 'Ć' U+0106 (utf-8: c4 86)
|
||||||
|
0x38, 0x44, 0x46, 0x45, 0x20, 0x00, // 199: 'ć' U+0107 (utf-8: c4 87)
|
||||||
|
0x38, 0x46, 0x45, 0x46, 0x28, 0x00, // 200: 'Ĉ' U+0108 (utf-8: c4 88)
|
||||||
|
0x38, 0x46, 0x45, 0x46, 0x20, 0x00, // 201: 'ĉ' U+0109 (utf-8: c4 89)
|
||||||
|
0x38, 0x44, 0x45, 0x44, 0x28, 0x00, // 202: 'Ċ' U+010a (utf-8: c4 8a)
|
||||||
|
0x38, 0x44, 0x45, 0x44, 0x20, 0x00, // 203: 'ċ' U+010b (utf-8: c4 8b)
|
||||||
|
0x38, 0x45, 0x46, 0x45, 0x28, 0x00, // 204: 'Č' U+010c (utf-8: c4 8c)
|
||||||
|
0x38, 0x45, 0x46, 0x45, 0x20, 0x00, // 205: 'č' U+010d (utf-8: c4 8d)
|
||||||
|
0x7c, 0x45, 0x46, 0x29, 0x10, 0x00, // 206: 'Ď' U+010e (utf-8: c4 8e)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 207: 'ď' U+010f (utf-8: c4 8f)
|
||||||
|
0x08, 0x7f, 0x49, 0x22, 0x1c, 0x00, // 208: 'Đ' U+0110 (utf-8: c4 90)
|
||||||
|
0x38, 0x44, 0x44, 0x4A, 0x7F, 0x00, // 209: 'đ' U+0111 (utf-8: c4 91)
|
||||||
|
0x7c, 0x55, 0x55, 0x55, 0x44, 0x00, // 210: 'Ē' U+0112 (utf-8: c4 92)
|
||||||
|
0x38, 0x55, 0x55, 0x55, 0x08, 0x00, // 211: 'ē' U+0113 (utf-8: c4 93)
|
||||||
|
0x7c, 0x55, 0x56, 0x55, 0x44, 0x00, // 212: 'Ĕ' U+0114 (utf-8: c4 94)
|
||||||
|
0x38, 0x55, 0x56, 0x55, 0x08, 0x00, // 213: 'ĕ' U+0115 (utf-8: c4 95)
|
||||||
|
0x7c, 0x54, 0x55, 0x54, 0x44, 0x00, // 214: 'Ė' U+0116 (utf-8: c4 96)
|
||||||
|
0x38, 0x54, 0x55, 0x54, 0x08, 0x00, // 215: 'ė' U+0117 (utf-8: c4 97)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 216: 'Ę' U+0118 (utf-8: c4 98)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 217: 'ę' U+0119 (utf-8: c4 99)
|
||||||
|
0x7c, 0x55, 0x56, 0x55, 0x44, 0x00, // 218: 'Ě' U+011a (utf-8: c4 9a)
|
||||||
|
0x38, 0x55, 0x56, 0x55, 0x08, 0x00, // 219: 'ě' U+011b (utf-8: c4 9b)
|
||||||
|
0x38, 0x46, 0x55, 0x56, 0x70, 0x00, // 220: 'Ĝ' U+011c (utf-8: c4 9c)
|
||||||
|
0x08, 0x56, 0x55, 0x56, 0x3c, 0x00, // 221: 'ĝ' U+011d (utf-8: c4 9d)
|
||||||
|
0x38, 0x45, 0x56, 0x55, 0x30, 0x00, // 222: 'Ğ' U+011e (utf-8: c4 9e)
|
||||||
|
0x08, 0x55, 0x56, 0x55, 0x3c, 0x00, // 223: 'ğ' U+011f (utf-8: c4 9f)
|
||||||
|
0x38, 0x44, 0x55, 0x54, 0x30, 0x00, // 224: 'Ġ' U+0120 (utf-8: c4 a0)
|
||||||
|
0x08, 0x54, 0x55, 0x54, 0x3c, 0x00, // 225: 'ġ' U+0121 (utf-8: c4 a1)
|
||||||
|
0x0e, 0x51, 0x35, 0x15, 0x1c, 0x00, // 226: 'Ģ' U+0122 (utf-8: c4 a2)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 227: 'ģ' U+0123 (utf-8: c4 a3)
|
||||||
|
0x7c, 0x12, 0x11, 0x12, 0x7c, 0x00, // 228: 'Ĥ' U+0124 (utf-8: c4 a4)
|
||||||
|
0x02, 0x79, 0x22, 0x10, 0x60, 0x00, // 229: 'ĥ' U+0125 (utf-8: c4 a5)
|
||||||
|
0x02, 0x7f, 0x0a, 0x7f, 0x02, 0x00, // 230: 'Ħ' U+0126 (utf-8: c4 a6)
|
||||||
|
0x02, 0x7f, 0x12, 0x08, 0x70, 0x00, // 231: 'ħ' U+0127 (utf-8: c4 a7)
|
||||||
|
0x4a, 0x49, 0x7a, 0x49, 0x48, 0x00, // 232: 'Ĩ' U+0128 (utf-8: c4 a8)
|
||||||
|
0x02, 0x49, 0x7a, 0x41, 0x00, 0x00, // 233: 'ĩ' U+0129 (utf-8: c4 a9)
|
||||||
|
0x44, 0x45, 0x7d, 0x45, 0x44, 0x00, // 234: 'Ī' U+012a (utf-8: c4 aa)
|
||||||
|
0x00, 0x45, 0x7d, 0x41, 0x00, 0x00, // 235: 'ī' U+012b (utf-8: c4 ab)
|
||||||
|
0x44, 0x45, 0x7e, 0x45, 0x44, 0x00, // 236: 'Ĭ' U+012c (utf-8: c4 ac)
|
||||||
|
0x00, 0x45, 0x7e, 0x41, 0x00, 0x00, // 237: 'ĭ' U+012d (utf-8: c4 ad)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 238: 'Į' U+012e (utf-8: c4 ae)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 239: 'į' U+012f (utf-8: c4 af)
|
||||||
|
0x44, 0x44, 0x7d, 0x44, 0x44, 0x00, // 240: 'İ' U+0130 (utf-8: c4 b0)
|
||||||
|
0x00, 0x44, 0x7c, 0x40, 0x00, 0x00, // 241: 'ı' U+0131 (utf-8: c4 b1)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 242: 'IJ' U+0132 (utf-8: c4 b2)
|
||||||
|
0x44, 0x7d, 0x40, 0x44, 0x3d, 0x00, // 243: 'ij' U+0133 (utf-8: c4 b3)
|
||||||
|
0x20, 0x40, 0x46, 0x3d, 0x06, 0x00, // 244: 'Ĵ' U+0134 (utf-8: c4 b4)
|
||||||
|
0x00, 0x20, 0x46, 0x3d, 0x02, 0x00, // 245: 'ĵ' U+0135 (utf-8: c4 b5)
|
||||||
|
0x1f, 0x44, 0x2a, 0x11, 0x00, 0x00, // 246: 'Ķ' U+0136 (utf-8: c4 b6)
|
||||||
|
0x1f, 0x44, 0x2a, 0x11, 0x00, 0x00, // 247: 'ķ' U+0137 (utf-8: c4 b7)
|
||||||
|
0x7c, 0x10, 0x28, 0x44, 0x00, 0x00, // 248: 'ĸ' U+0138 (utf-8: c4 b8)
|
||||||
|
0x7c, 0x40, 0x42, 0x41, 0x40, 0x00, // 249: 'Ĺ' U+0139 (utf-8: c4 b9)
|
||||||
|
0x00, 0x44, 0x7e, 0x41, 0x00, 0x00, // 250: 'ĺ' U+013a (utf-8: c4 ba)
|
||||||
|
0x1f, 0x50, 0x30, 0x10, 0x10, 0x00, // 251: 'Ļ' U+013b (utf-8: c4 bb)
|
||||||
|
0x00, 0x51, 0x3f, 0x10, 0x00, 0x00, // 252: 'ļ' U+013c (utf-8: c4 bc)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 253: 'Ľ' U+013d (utf-8: c4 bd)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 254: 'ľ' U+013e (utf-8: c4 be)
|
||||||
|
0x7f, 0x40, 0x40, 0x48, 0x40, 0x00, // 255: 'Ŀ' U+013f (utf-8: c4 bf)
|
||||||
|
|
||||||
|
// ---- PAGE U+0140-U+017F (UTF 0xC580-0xC5BF) ----
|
||||||
|
0x00, 0x41, 0x7f, 0x40, 0x08, 0x00, // 256: 'ŀ' U+0140 (utf-8: c5 80)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 257: 'Ł' U+0141 (utf-8: c5 81)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 258: 'ł' U+0142 (utf-8: c5 82)
|
||||||
|
0x7c, 0x08, 0x12, 0x21, 0x7c, 0x00, // 259: 'Ń' U+0143 (utf-8: c5 83)
|
||||||
|
0x7c, 0x08, 0x06, 0x05, 0x78, 0x00, // 260: 'ń' U+0144 (utf-8: c5 84)
|
||||||
|
0x1f, 0x42, 0x24, 0x08, 0x1f, 0x00, // 261: 'Ņ' U+0145 (utf-8: c5 85)
|
||||||
|
0x1f, 0x42, 0x21, 0x01, 0x1e, 0x00, // 262: 'ņ' U+0146 (utf-8: c5 86)
|
||||||
|
0x7c, 0x09, 0x12, 0x21, 0x7c, 0x00, // 263: 'Ň' U+0147 (utf-8: c5 87)
|
||||||
|
0x7c, 0x09, 0x06, 0x05, 0x78, 0x00, // 264: 'ň' U+0148 (utf-8: c5 88)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 265: 'ʼn' U+0149 (utf-8: c5 89)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 266: 'Ŋ' U+014a (utf-8: c5 8a)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 267: 'ŋ' U+014b (utf-8: c5 8b)
|
||||||
|
0x38, 0x45, 0x45, 0x45, 0x38, 0x00, // 268: 'Ō' U+014c (utf-8: c5 8c)
|
||||||
|
0x38, 0x45, 0x45, 0x45, 0x38, 0x00, // 269: 'ō' U+014d (utf-8: c5 8d)
|
||||||
|
0x38, 0x45, 0x46, 0x45, 0x38, 0x00, // 270: 'Ŏ' U+014e (utf-8: c5 8e)
|
||||||
|
0x38, 0x45, 0x46, 0x45, 0x38, 0x00, // 271: 'ŏ' U+014f (utf-8: c5 8f)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 272: 'Ő' U+0150 (utf-8: c5 90)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 273: 'ő' U+0151 (utf-8: c5 91)
|
||||||
|
0x3e, 0x41, 0x7f, 0x49, 0x49, 0x00, // 274: 'Œ' U+0152 (utf-8: c5 92)
|
||||||
|
0x38, 0x44, 0x7c, 0x54, 0x58, 0x00, // 275: 'œ' U+0153 (utf-8: c5 93)
|
||||||
|
0x7c, 0x14, 0x16, 0x15, 0x68, 0x00, // 276: 'Ŕ' U+0154 (utf-8: c5 94)
|
||||||
|
0x7c, 0x08, 0x06, 0x05, 0x08, 0x00, // 277: 'ŕ' U+0155 (utf-8: c5 95)
|
||||||
|
0x1f, 0x45, 0x25, 0x05, 0x1a, 0x00, // 278: 'Ŗ' U+0156 (utf-8: c5 96)
|
||||||
|
0x1f, 0x42, 0x21, 0x01, 0x02, 0x00, // 279: 'ŗ' U+0157 (utf-8: c5 97)
|
||||||
|
0x7c, 0x15, 0x16, 0x15, 0x68, 0x00, // 280: 'Ř' U+0158 (utf-8: c5 98)
|
||||||
|
0x7c, 0x09, 0x06, 0x05, 0x08, 0x00, // 281: 'ř' U+0159 (utf-8: c5 99)
|
||||||
|
0x08, 0x54, 0x56, 0x55, 0x20, 0x00, // 282: 'Ś' U+015a (utf-8: c5 9a)
|
||||||
|
0x48, 0x54, 0x56, 0x55, 0x24, 0x00, // 283: 'ś' U+015b (utf-8: c5 9b)
|
||||||
|
0x08, 0x56, 0x55, 0x56, 0x20, 0x00, // 284: 'Ŝ' U+015c (utf-8: c5 9c)
|
||||||
|
0x48, 0x56, 0x55, 0x56, 0x24, 0x00, // 285: 'ŝ' U+015d (utf-8: c5 9d)
|
||||||
|
0x02, 0x55, 0x35, 0x15, 0x08, 0x00, // 286: 'Ş' U+015e (utf-8: c5 9e)
|
||||||
|
0x12, 0x55, 0x35, 0x15, 0x09, 0x00, // 287: 'ş' U+015f (utf-8: c5 9f)
|
||||||
|
0x08, 0x55, 0x56, 0x55, 0x20, 0x00, // 288: 'Š' U+0160 (utf-8: c5 a0)
|
||||||
|
0x48, 0x55, 0x56, 0x55, 0x24, 0x00, // 289: 'š' U+0161 (utf-8: c5 a1)
|
||||||
|
0x01, 0x41, 0x3f, 0x01, 0x01, 0x00, // 290: 'Ţ' U+0162 (utf-8: c5 a2)
|
||||||
|
0x02, 0x4f, 0x32, 0x10, 0x08, 0x00, // 291: 'ţ' U+0163 (utf-8: c5 a3)
|
||||||
|
0x04, 0x05, 0x7e, 0x05, 0x04, 0x00, // 292: 'Ť' U+0164 (utf-8: c5 a4)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 293: 'ť' U+0165 (utf-8: c5 a5)
|
||||||
|
0x01, 0x09, 0x7f, 0x09, 0x01, 0x00, // 294: 'Ŧ' U+0166 (utf-8: c5 a6)
|
||||||
|
0x14, 0x3e, 0x54, 0x40, 0x20, 0x00, // 295: 'ŧ' U+0167 (utf-8: c5 a7)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 296: 'Ũ' U+0168 (utf-8: c5 a8)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 297: 'ũ' U+0169 (utf-8: c5 a9)
|
||||||
|
0x3c, 0x41, 0x41, 0x41, 0x3c, 0x00, // 298: 'Ū' U+016a (utf-8: c5 aa)
|
||||||
|
0x3c, 0x41, 0x41, 0x21, 0x7c, 0x00, // 299: 'ū' U+016b (utf-8: c5 ab)
|
||||||
|
0x3c, 0x41, 0x42, 0x41, 0x3c, 0x00, // 300: 'Ŭ' U+016c (utf-8: c5 ac)
|
||||||
|
0x3c, 0x41, 0x41, 0x21, 0x7c, 0x00, // 301: 'ŭ' U+016d (utf-8: c5 ad)
|
||||||
|
0x3c, 0x40, 0x41, 0x40, 0x3c, 0x00, // 302: 'Ů' U+016e (utf-8: c5 ae)
|
||||||
|
0x3c, 0x41, 0x41, 0x21, 0x7c, 0x00, // 303: 'ů' U+016f (utf-8: c5 af)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 304: 'Ű' U+0170 (utf-8: c5 b0)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 305: 'ű' U+0171 (utf-8: c5 b1)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 306: 'Ų' U+0172 (utf-8: c5 b2)
|
||||||
|
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 307: 'ų' U+0173 (utf-8: c5 b3)
|
||||||
|
0x3c, 0x42, 0x39, 0x42, 0x3c, 0x00, // 308: 'Ŵ' U+0174 (utf-8: c5 b4)
|
||||||
|
0x3c, 0x42, 0x31, 0x42, 0x3c, 0x00, // 309: 'ŵ' U+0175 (utf-8: c5 b5)
|
||||||
|
0x04, 0x0a, 0x71, 0x0a, 0x04, 0x00, // 310: 'Ŷ' U+0176 (utf-8: c5 b6)
|
||||||
|
0x04, 0x4a, 0x31, 0x12, 0x0c, 0x00, // 311: 'ŷ' U+0177 (utf-8: c5 b7)
|
||||||
|
0x04, 0x09, 0x70, 0x09, 0x04, 0x00, // 312: 'Ÿ' U+0178 (utf-8: c5 b8)
|
||||||
|
0x44, 0x64, 0x56, 0x4d, 0x44, 0x00, // 313: 'Ź' U+0179 (utf-8: c5 b9)
|
||||||
|
0x44, 0x64, 0x56, 0x4d, 0x44, 0x00, // 314: 'ź' U+017a (utf-8: c5 ba)
|
||||||
|
0x44, 0x64, 0x55, 0x4c, 0x44, 0x00, // 315: 'Ż' U+017b (utf-8: c5 bb)
|
||||||
|
0x44, 0x64, 0x55, 0x4c, 0x44, 0x00, // 316: 'ż' U+017c (utf-8: c5 bc)
|
||||||
|
0x44, 0x65, 0x56, 0x4d, 0x44, 0x00, // 317: 'Ž' U+017d (utf-8: c5 bd)
|
||||||
|
0x44, 0x65, 0x56, 0x4d, 0x44, 0x00, // 318: 'ž' U+017e (utf-8: c5 be)
|
||||||
|
0x00, 0x04, 0x7e, 0x01, 0x01, 0x00 // 319: 'ſ' U+017f (utf-8: c5 bf)
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* FONT_H_ */
|
#endif /* FONT_H_ */
|
||||||
@@ -41,6 +41,7 @@ public:
|
|||||||
// Draws a number at the current cursor location
|
// Draws a number at the current cursor location
|
||||||
void clearScreen(); // Clears the buffer
|
void clearScreen(); // Clears the buffer
|
||||||
void drawBattery(uint8_t state); // Draws the battery level symbol
|
void drawBattery(uint8_t state); // Draws the battery level symbol
|
||||||
|
void drawCheckbox(bool state); // Draws a checkbox
|
||||||
void drawSymbol(uint8_t symbolID);//Used for drawing symbols of a predictable width
|
void drawSymbol(uint8_t symbolID);//Used for drawing symbols of a predictable width
|
||||||
void drawArea(int16_t x, int8_t y, uint8_t wide, uint8_t height,
|
void drawArea(int16_t x, int8_t y, uint8_t wide, uint8_t height,
|
||||||
const uint8_t* ptr);
|
const uint8_t* ptr);
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ extern const enum ShortNameType SettingsShortNameType;
|
|||||||
extern const char* SettingsShortNames[16][2];
|
extern const char* SettingsShortNames[16][2];
|
||||||
extern const char* SettingsLongNames[16];
|
extern const char* SettingsLongNames[16];
|
||||||
extern const char* SettingsCalibrationWarning;
|
extern const char* SettingsCalibrationWarning;
|
||||||
|
extern const char* SettingsResetWarning;
|
||||||
extern const char* UVLOWarningString;
|
extern const char* UVLOWarningString;
|
||||||
extern const char* SleepingSimpleString;
|
extern const char* SleepingSimpleString;
|
||||||
extern const char* SleepingAdvancedString;
|
extern const char* SleepingAdvancedString;
|
||||||
@@ -33,16 +34,5 @@ extern const char SettingLeftChar;
|
|||||||
extern const char SettingAutoChar;
|
extern const char SettingAutoChar;
|
||||||
|
|
||||||
#define LANG_EN
|
#define LANG_EN
|
||||||
//#define LANG_RU
|
|
||||||
//#define LANG_ES
|
|
||||||
//#define LANG_SE
|
|
||||||
//#define LANG_IT
|
|
||||||
//#define LANG_FR
|
|
||||||
//#define LANG_DE
|
|
||||||
//#define LANG_CS_CZ
|
|
||||||
//#define LANG_TR
|
|
||||||
//#define LANG_HR
|
|
||||||
//#define LANG_PL
|
|
||||||
//#define LANG_DK
|
|
||||||
|
|
||||||
#endif /* TRANSLATION_H_ */
|
#endif /* TRANSLATION_H_ */
|
||||||
|
|||||||
@@ -28,6 +28,6 @@ typedef struct {
|
|||||||
const state_func draw;
|
const state_func draw;
|
||||||
} menuitem;
|
} menuitem;
|
||||||
|
|
||||||
extern bool settingsResetRequest;
|
|
||||||
extern const menuitem settingsMenu[];
|
extern const menuitem settingsMenu[];
|
||||||
|
|
||||||
#endif /* GUI_H_ */
|
#endif /* GUI_H_ */
|
||||||
|
|||||||
@@ -1,11 +1,13 @@
|
|||||||
#ifndef __MAIN_H
|
#ifndef __MAIN_H
|
||||||
#define __MAIN_H
|
#define __MAIN_H
|
||||||
|
|
||||||
#include <MMA8652FC.hpp>
|
#include <MMA8652FC.hpp>
|
||||||
#include "Setup.h"
|
#include "Setup.h"
|
||||||
#include "OLED.hpp"
|
#include "OLED.hpp"
|
||||||
|
|
||||||
extern OLED lcd;
|
extern OLED lcd;
|
||||||
extern MMA8652FC accel;
|
extern MMA8652FC accel;
|
||||||
|
|
||||||
enum ButtonState {
|
enum ButtonState {
|
||||||
BUTTON_NONE = 0, /* No buttons pressed / < filter time*/
|
BUTTON_NONE = 0, /* No buttons pressed / < filter time*/
|
||||||
BUTTON_F_SHORT = 1, /* User has pressed the front button*/
|
BUTTON_F_SHORT = 1, /* User has pressed the front button*/
|
||||||
@@ -20,6 +22,8 @@ enum ButtonState {
|
|||||||
* holding means it has gone low, and been low for longer than filter time
|
* holding means it has gone low, and been low for longer than filter time
|
||||||
*/
|
*/
|
||||||
};
|
};
|
||||||
|
|
||||||
ButtonState getButtonState();
|
ButtonState getButtonState();
|
||||||
|
void waitForButtonPressOrTimeout(uint32_t timeout);
|
||||||
|
|
||||||
#endif /* __MAIN_H */
|
#endif /* __MAIN_H */
|
||||||
|
|||||||
@@ -120,7 +120,7 @@ void OLED::drawChar(char c, char PrecursorCommand) {
|
|||||||
index = (96 - 32) + (c);
|
index = (96 - 32) + (c);
|
||||||
break; //-32 compensate for chars excluded from font C2 section
|
break; //-32 compensate for chars excluded from font C2 section
|
||||||
case 0xC3:
|
case 0xC3:
|
||||||
index = (128-32) + (c);
|
index = (128) + (c);
|
||||||
break;
|
break;
|
||||||
#if defined(LANG_RU) || defined(LANG_UK) || defined(LANG_SR) || defined(LANG_BG) || defined(LANG_MK)
|
#if defined(LANG_RU) || defined(LANG_UK) || defined(LANG_SR) || defined(LANG_BG) || defined(LANG_MK)
|
||||||
case 0xD0:
|
case 0xD0:
|
||||||
@@ -209,7 +209,7 @@ void OLED::setCharCursor(int16_t x, int16_t y) {
|
|||||||
void OLED::setFont(uint8_t fontNumber) {
|
void OLED::setFont(uint8_t fontNumber) {
|
||||||
if (fontNumber == 1) {
|
if (fontNumber == 1) {
|
||||||
//small font
|
//small font
|
||||||
currentFont = ASCII6x8;
|
currentFont = FONT_6x8;
|
||||||
fontHeight = 8;
|
fontHeight = 8;
|
||||||
fontWidth = 6;
|
fontWidth = 6;
|
||||||
} else if (fontNumber == 2) {
|
} else if (fontNumber == 2) {
|
||||||
@@ -272,6 +272,9 @@ void OLED::drawBattery(uint8_t state) {
|
|||||||
state = 10;
|
state = 10;
|
||||||
drawSymbol(3 + state);
|
drawSymbol(3 + state);
|
||||||
}
|
}
|
||||||
|
void OLED::drawCheckbox(bool state) {
|
||||||
|
drawSymbol((state) ? 17 : 18);
|
||||||
|
}
|
||||||
void OLED::drawSymbol(uint8_t symbolID) {
|
void OLED::drawSymbol(uint8_t symbolID) {
|
||||||
//draw a symbol to the current cursor location
|
//draw a symbol to the current cursor location
|
||||||
setFont(2);
|
setFont(2);
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
#include "Settings.h"
|
#include "Settings.h"
|
||||||
#include "Setup.h"
|
#include "Setup.h"
|
||||||
#define FLASH_ADDR (0x8000000|0xBC00)/*Flash start OR'ed with the maximum amount of flash - 1024 bytes*/
|
#define FLASH_ADDR (0x8000000|0xFC00)/*Flash start OR'ed with the maximum amount of flash - 1024 bytes*/
|
||||||
#include "string.h"
|
#include "string.h"
|
||||||
systemSettingsType systemSettings;
|
systemSettingsType systemSettings;
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,8 @@
|
|||||||
*/
|
*/
|
||||||
#include "Translation.h"
|
#include "Translation.h"
|
||||||
|
|
||||||
// TEMPLATES for short names - choose one and use it as base for your translation:
|
// TEMPLATES for short names - choose one and use it as base for your
|
||||||
|
// translation:
|
||||||
|
|
||||||
//const enum ShortNameType SettingsShortNameType = SHORT_NAME_SINGLE_LINE;
|
//const enum ShortNameType SettingsShortNameType = SHORT_NAME_SINGLE_LINE;
|
||||||
//const char* SettingsShortNames[16][2] = {
|
//const char* SettingsShortNames[16][2] = {
|
||||||
@@ -49,8 +50,7 @@
|
|||||||
//};
|
//};
|
||||||
|
|
||||||
#ifdef LANG_EN
|
#ifdef LANG_EN
|
||||||
const char* SettingsLongNames[16] =
|
const char* SettingsLongNames[16] = {
|
||||||
{
|
|
||||||
// These are all the help text for all the settings.
|
// These are all the help text for all the settings.
|
||||||
// No requirements on spacing or length.
|
// No requirements on spacing or length.
|
||||||
/* Power source (DC or batt) */ "Power source. Sets cutoff voltage. <DC 10V> <S 3.3V per cell>",
|
/* Power source (DC or batt) */ "Power source. Sets cutoff voltage. <DC 10V> <S 3.3V per cell>",
|
||||||
@@ -68,18 +68,17 @@ const char* SettingsLongNames[16] =
|
|||||||
/* Temperature calibration enter menu */ "Calibrate tip offset.",
|
/* Temperature calibration enter menu */ "Calibrate tip offset.",
|
||||||
/* Settings reset command */ "Reset all settings",
|
/* Settings reset command */ "Reset all settings",
|
||||||
/* Calibrate input voltage */ "VIN Calibration. Buttons adjust, long press to exit",
|
/* Calibrate input voltage */ "VIN Calibration. Buttons adjust, long press to exit",
|
||||||
/* Advanced soldering screen enabled */"Display detailed information while soldering", };
|
/* Advanced soldering screen enabled */ "Display detailed information while soldering",
|
||||||
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning =
|
const char* SettingsCalibrationWarning = "Please ensure the tip is at room temperature before continuing!";
|
||||||
"Please ensure the tip is at room temperature before continuing!";
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Sleeping..."; // <=17 chars
|
const char* SleepingAdvancedString = "Sleeping..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "WARNING! TIP HOT!";
|
const char* WarningAdvancedString = "WARNING! TIP HOT!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'F';
|
|
||||||
const char SettingRightChar = 'R';
|
const char SettingRightChar = 'R';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -100,10 +99,9 @@ const char* SettingsShortNames[16][2] = {
|
|||||||
/* (<= 13) Cooldown blink */ {"Cooldown", "blink"},
|
/* (<= 13) Cooldown blink */ {"Cooldown", "blink"},
|
||||||
/* (<= 16) Temperature calibration enter menu */ {"Calibrate", "temperature?"},
|
/* (<= 16) Temperature calibration enter menu */ {"Calibrate", "temperature?"},
|
||||||
/* (<= 16) Settings reset command */ {"Factory", "Reset?"},
|
/* (<= 16) Settings reset command */ {"Factory", "Reset?"},
|
||||||
/* (<= 16) Calibrate input voltage */{ "Calibrate",
|
/* (<= 16) Calibrate input voltage */ {"Calibrate", "input voltage?"},
|
||||||
"input voltage?" },
|
/* (<= 13) Advanced soldering screen enabled */ {"Detailed", "solder screen"},
|
||||||
/* (<= 13) Advanced soldering screen enabled */{ "Detailed",
|
};
|
||||||
"solder screen" }, };
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef LANG_RU
|
#ifdef LANG_RU
|
||||||
@@ -129,14 +127,13 @@ const char* SettingsLongNames[16] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Убедитесь, что жало остыло до комнатной температуры, прежде чем продолжать!";
|
const char* SettingsCalibrationWarning = "Убедитесь, что жало остыло до комнатной температуры, прежде чем продолжать!";
|
||||||
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "БАТ РАЗР"; // Fixed width 8 chars
|
const char* UVLOWarningString = "БАТ РАЗР"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Хррр"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Хррр"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Ожидание..."; // <=17 chars
|
const char* SleepingAdvancedString = "Ожидание..."; // <=17 chars
|
||||||
const char* WarningSimpleString = " АЙ!"; // Must be <= 4 chars
|
const char* WarningSimpleString = " АЙ!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "ОСТОРОЖНО! ГОРЯЧО";
|
const char* WarningAdvancedString = "ОСТОРОЖНО! ГОРЯЧО";
|
||||||
|
|
||||||
const char SettingTrueChar = '+';
|
|
||||||
const char SettingFalseChar = '-';
|
|
||||||
/*
|
/*
|
||||||
* #TODO change support for multibyte constants here
|
* #TODO change support for multibyte constants here
|
||||||
const char SettingRightChar = 'П';
|
const char SettingRightChar = 'П';
|
||||||
@@ -183,7 +180,7 @@ const char* SettingsLongNames[16] = {
|
|||||||
/* Boost enabled */ "Activar el botón \"Boost\" en modo soldadura.",
|
/* Boost enabled */ "Activar el botón \"Boost\" en modo soldadura.",
|
||||||
/* Boost temperature */ "Temperatura en modo \"Boost\". <C>",
|
/* Boost temperature */ "Temperatura en modo \"Boost\". <C>",
|
||||||
/* Automatic start mode */ "Iniciar modo soldadura en el encendido. <V=Sí S=Modo reposo F=No>",
|
/* Automatic start mode */ "Iniciar modo soldadura en el encendido. <V=Sí S=Modo reposo F=No>",
|
||||||
/* Cooldown blink */"Parpadea la temperatura en el enfriamiento si la punta sigue caliente."
|
/* Cooldown blink */ "Parpadea la temperatura en el enfriamiento si la punta sigue caliente.",
|
||||||
/* Temperature calibration enter menu */ "Calibrate tip offset.",
|
/* Temperature calibration enter menu */ "Calibrate tip offset.",
|
||||||
/* Settings reset command */ "Reset all settings",
|
/* Settings reset command */ "Reset all settings",
|
||||||
/* Calibrate input voltage */ "VIN Calibration. Buttons adjust, long press to exit",
|
/* Calibrate input voltage */ "VIN Calibration. Buttons adjust, long press to exit",
|
||||||
@@ -191,14 +188,13 @@ const char* SettingsLongNames[16] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Please ensure the tip is at room temperature before continuing!";
|
const char* SettingsCalibrationWarning = "Please ensure the tip is at room temperature before continuing!";
|
||||||
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Sleeping..."; // <=17 chars
|
const char* SleepingAdvancedString = "Sleeping..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "WARNING! TIP HOT!";
|
const char* WarningAdvancedString = "WARNING! TIP HOT!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'F';
|
|
||||||
const char SettingRightChar = 'R';
|
const char SettingRightChar = 'R';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -239,7 +235,7 @@ const char* SettingsLongNames[16] = {
|
|||||||
/* Boost enabled */ "Активация кнопки A для Турбо режима до 450С при пайке ",
|
/* Boost enabled */ "Активация кнопки A для Турбо режима до 450С при пайке ",
|
||||||
/* Boost temperature */ "Установка температуры для Турбо режима",
|
/* Boost temperature */ "Установка температуры для Турбо режима",
|
||||||
/* Automatic start mode */ "Автоматический запуск паяльника при включении питания. T=Нагрев, S= Режим Сна,F=Выкл.",
|
/* Automatic start mode */ "Автоматический запуск паяльника при включении питания. T=Нагрев, S= Режим Сна,F=Выкл.",
|
||||||
/* Cooldown blink */"Мигает температура на экране охлаждения, пока жало остается горячим."
|
/* Cooldown blink */ "Мигает температура на экране охлаждения, пока жало остается горячим.",
|
||||||
/* Temperature calibration enter menu */ "Calibrate tip offset.",
|
/* Temperature calibration enter menu */ "Calibrate tip offset.",
|
||||||
/* Settings reset command */ "Reset all settings",
|
/* Settings reset command */ "Reset all settings",
|
||||||
/* Calibrate input voltage */ "VIN Calibration. Buttons adjust, long press to exit",
|
/* Calibrate input voltage */ "VIN Calibration. Buttons adjust, long press to exit",
|
||||||
@@ -247,14 +243,13 @@ const char* SettingsLongNames[16] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Please ensure the tip is at room temperature before continuing!";
|
const char* SettingsCalibrationWarning = "Please ensure the tip is at room temperature before continuing!";
|
||||||
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Sleeping..."; // <=17 chars
|
const char* SleepingAdvancedString = "Sleeping..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "WARNING! TIP HOT!";
|
const char* WarningAdvancedString = "WARNING! TIP HOT!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'F';
|
|
||||||
const char SettingRightChar = 'R';
|
const char SettingRightChar = 'R';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -284,55 +279,54 @@ const char* SettingsShortNames[16][2] = {
|
|||||||
const char* SettingsLongNames[16] = {
|
const char* SettingsLongNames[16] = {
|
||||||
// These are all the help text for all the settings.
|
// These are all the help text for all the settings.
|
||||||
// No requirements on spacing or length.
|
// No requirements on spacing or length.
|
||||||
/* Power source (DC or batt) */"Sorgente di alimentazione; imposta il limite minimo di tensione <DC: 10V; S: 3.3V per cella>",
|
/* Power source (DC or batt) */"Scegli la sorgente di alimentazione; imposta la soglia di scaricamento per alimentazione Li-Po <DC: 10V; S: 3.3V per cella>",
|
||||||
/* Sleep temperature */"Temperatura standby <°C>",
|
/* Sleep temperature */"Imposta temperatura in modalità standby <°C>",
|
||||||
/* Sleep timeout */"Timeout standby <minuti/secondi>",
|
/* Sleep timeout */"Imposta timer per entrare in modalità standby <minuti/secondi>",
|
||||||
/* Shutdown timeout */"Timeout spegnimento <minuti>",
|
/* Shutdown timeout */"Imposta timer per lo spegnimento <minuti>",
|
||||||
/* Motion sensitivity level */"Sensibilità al movimento <0: nessuna; 1: minima; 9: massima>",
|
/* Motion sensitivity level */"Imposta sensibilità al movimento per uscire dalla modalità standby <0: nessuna; 1: minima; 9: massima>",
|
||||||
/* Temperature in F and C */"Unità di misura della temperatura <C: Celsius; F: Farenheit>",
|
/* Temperature in F and C */"Scegli l'unità di misura per la temperatura <C: Celsius; F: Farenheit>",
|
||||||
/* Advanced idle display mode enabled */"Mostra informazioni dettagliate con un carattere più piccolo sulla schermata di inattività",
|
/* Advanced idle display mode enabled */"Mostra informazioni dettagliate con un carattere più piccolo nella schermata principale",
|
||||||
/* Display rotation mode */"Orientamento del display <A: automatico; S: mano sinistra; D: mano destra>",
|
/* Display rotation mode */"Imposta orientamento del display <A: automatico; S: mano sinistra; D: mano destra>",
|
||||||
/* Boost enabled */"Il tasto anteriore attiva la modalità \"boost\" durante la saldatura",
|
/* Boost enabled */"Il tasto anteriore attiva la funzione \"boost\" durante la saldatura",
|
||||||
/* Boost temperature */"Temperatura in modalità \"boost\"",
|
/* Boost temperature */"Imposta la temperatura in funzione \"boost\"",
|
||||||
/* Automatic start mode */"Attiva automaticamente il saldatore quando viene alimentato <A: saldatura; S: standby; D: disattiva>",
|
/* Automatic start mode */"Attiva automaticamente il saldatore quando viene alimentato <A: saldatura; S: standby; D: disattiva>",
|
||||||
/* Cooldown blink */"Durante il raffreddamento mostra la temperatura sul display se la punta è ancora calda"
|
/* Cooldown blink */"Mostra la temperatura durante il raffreddamento se la punta è ancora calda",
|
||||||
/* Temperature calibration enter menu */"Calibra l'offset della punta",
|
/* Temperature calibration enter menu */"Calibra la differenza di temperatura rilevata da quella presente sulla punta",
|
||||||
/* Settings reset command */"Ripristina tutte le impostazioni",
|
/* Settings reset command */"Ripristina tutte le impostazioni",
|
||||||
/* Calibrate input voltage */"Calibra la tensione in entrata; regola con i bottoni, tieni permuto per uscire",
|
/* Calibrate input voltage */"Calibra la tensione in ingresso; regola con i bottoni, tieni premuto per uscire",
|
||||||
/* Advanced soldering screen enabled */"Mostra informazioni dettagliate mentre stai saldando",
|
/* Advanced soldering screen enabled */"Mostra informazioni dettagliate in modalità saldatura",
|
||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Assicurati che la punta si trovi a temperatura ambiente prima di continuare!";
|
const char* SettingsCalibrationWarning = "Assicurati che la punta si trovi a temperatura ambiente prima di continuare!";
|
||||||
|
const char* SettingsResetWarning = "Ripristinare le impostazioni iniziali?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Standby"; // <=17 chars
|
const char* SleepingAdvancedString = "Standby"; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "ATTENZIONE! PUNTA CALDA!";
|
const char* WarningAdvancedString = "ATTENZIONE! PUNTA CALDA!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'A';
|
|
||||||
const char SettingFalseChar = 'D';
|
|
||||||
const char SettingRightChar = 'D';
|
const char SettingRightChar = 'D';
|
||||||
const char SettingLeftChar = 'S';
|
const char SettingLeftChar = 'S';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
|
|
||||||
const enum ShortNameType SettingsShortNameType = SHORT_NAME_SINGLE_LINE;
|
const enum ShortNameType SettingsShortNameType = SHORT_NAME_DOUBLE_LINE;
|
||||||
const char* SettingsShortNames[16][2] = {
|
const char* SettingsShortNames[16][2] = {
|
||||||
/* (<= 5) Power source (DC or batt) */{"PWRSC"},
|
/* (<= 11) Power source (DC or batt) */ {"Sorgente", "alimentaz"},
|
||||||
/* (<= 4) Sleep temperature */{"STMP"},
|
/* (<= 9) Sleep temperature */ {"Temp", "standby"},
|
||||||
/* (<= 4) Sleep timeout */{"STME"},
|
/* (<= 9) Sleep timeout */ {"Timer", "standby"},
|
||||||
/* (<= 5) Shutdown timeout */{"SHTME"},
|
/* (<= 11) Shutdown timeout */ {"Timer", "spegnimento"},
|
||||||
/* (<= 6) Motion sensitivity level */{"MSENSE"},
|
/* (<= 13) Motion sensitivity level */ {"Sensibilità", "al movimento"},
|
||||||
/* (<= 6) Temperature in F and C */{"TMPUNT"},
|
/* (<= 13) Temperature in F and C */ {"Unità di", "temperatura"},
|
||||||
/* (<= 6) Advanced idle display mode enabled */{"ADVIDL"},
|
/* (<= 13) Advanced idle display mode enabled */ {"Mostra", "dettagli"},
|
||||||
/* (<= 6) Display rotation mode */{"DSPROT"},
|
/* (<= 13) Display rotation mode */ {"Orientamento", "display"},
|
||||||
/* (<= 6) Boost enabled */{"BOOST"},
|
/* (<= 13) Boost enabled */ {"Funzione", "\"boost\""},
|
||||||
/* (<= 4) Boost temperature */{"BTMP"},
|
/* (<= 9) Boost temperature */ {"Temp", "\"boost\""},
|
||||||
/* (<= 6) Automatic start mode */{"ASTART"},
|
/* (<= 13) Automatic start mode */ {"Avvio", "automatico"},
|
||||||
/* (<= 6) Cooldown blink */{"CLBLNK"},
|
/* (<= 13) Cooldown blink */ {"Avviso", "punta calda"},
|
||||||
/* (<= 8) Temperature calibration enter menu */{"TMP CAL?"},
|
/* (<= 16) Temperature calibration enter menu */ {"Calibrazione", "temperatura"},
|
||||||
/* (<= 8) Settings reset command */{"RESET?"},
|
/* (<= 16) Settings reset command */ {"Ripristino", "impostazioni"},
|
||||||
/* (<= 8) Calibrate input voltage */{"CAL VIN?"},
|
/* (<= 16) Calibrate input voltage */ {"Calibrazione", "tensione"},
|
||||||
/* (<= 6) Advanced soldering screen enabled */{"ADVSLD"},
|
/* (<= 13) Advanced soldering screen enabled */ {"Dettagli", "saldatura"},
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -340,55 +334,54 @@ const char* SettingsShortNames[16][2] = {
|
|||||||
const char* SettingsLongNames[16] = {
|
const char* SettingsLongNames[16] = {
|
||||||
// These are all the help text for all the settings.
|
// These are all the help text for all the settings.
|
||||||
// No requirements on spacing or length.
|
// No requirements on spacing or length.
|
||||||
/* Power source (DC or batt) */"Type d\'alimentation. Regle la tension de coupure. <DC=10V S=3.3V par cellules>",
|
/* Power source (DC or batt) */ "Source d'alimentation. Règle la tension de coupure <DC=10V S=3.3V par cellules>",
|
||||||
/* Sleep temperature */"Temperature en veille. <C>",
|
/* Sleep temperature */ "Température en veille <C>",
|
||||||
/* Sleep timeout */"Temps avant mise en veille. <Minutes>",
|
/* Sleep timeout */ "Délai avant mise en veille <Minutes>",
|
||||||
/* Shutdown timeout */"Temps avant extinction. <Minutes>",
|
/* Shutdown timeout */ "Délai avant extinction <Minutes>",
|
||||||
/* Motion sensitivity level */"Sensibilitee du capteur de mouvement. <0=Inactif 1=Peu sensible 9=Tres sensible>",
|
/* Motion sensitivity level */ "Sensibilité du capteur de mouvement <0=Inactif 1=Peu sensible 9=Tres sensible>",
|
||||||
/* Temperature in F and C */"Unitee de temperature.",
|
/* Temperature in F and C */ "Unité de température <C=Celsius F=Fahrenheit>",
|
||||||
/* Advanced idle display mode enabled */"Afficher des informations detaillees en petit lors de la veille",
|
/* Advanced idle display mode enabled */ "Afficher des informations détaillées lors de la veille",
|
||||||
/* Display rotation mode */"Orientation de l\'affichage. <A=Automatique G=Gaucher D=Droitier>",
|
/* Display rotation mode */ "Orientation de l'affichage <A=Automatique G=Gaucher D=Droitier>",
|
||||||
/* Boost enabled */"Active le mode \"Boost\" 450C sur le bouton de devant pendant la soudure.",
|
/* Boost enabled */ "Activer le mode \"Boost\" en maintenant le bouton de devant pendant la soudure",
|
||||||
/* Boost temperature */"Temperature du mode \"Boost\". <C>",
|
/* Boost temperature */ "Température du mode \"Boost\" <C>",
|
||||||
/* Automatic start mode */"Demarre automatiquement la soudure a l\'allumage. <A=Active, V=Mode Veille, D=Desactive>",
|
/* Automatic start mode */ "Démarrer automatiquement la soudure à l'allumage",
|
||||||
/* Cooldown blink */"Fait clignotter la temperature lors du refroidissement pendant que la panne est chaude."
|
/* Cooldown blink */ "Faire clignoter la température lors du refroidissement tant que la panne est chaude",
|
||||||
/* Temperature calibration enter menu */"Compenser l\'erreur de la panne",
|
/* Temperature calibration enter menu */ "Étalonner la température de la panne",
|
||||||
/* Settings reset command */"Reinitialiser tout les reglages",
|
/* Settings reset command */ "Réinitialiser tous les réglages",
|
||||||
/* Calibrate input voltage */"Calibration VIN. Boutons pour ajuster, appui long pour quitter",
|
/* Calibrate input voltage */ "Étalonner la tension d'entrée. Boutons pour ajuster, appui long pour quitter",
|
||||||
/* Advanced soldering screen enabled */"Afficher des informations detaillees pendant la soudure",
|
/* Advanced soldering screen enabled */ "Afficher des informations détaillées pendant la soudure",
|
||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Please ensure the tip is at room temperature before continuing!";
|
const char* SettingsCalibrationWarning = "Assurez-vous que la panne soit à température ambiante avant de continuer!";
|
||||||
|
const char* SettingsResetWarning = "Voulez-vous vraiment réinitialiser les paramètres aux valeurs d'usine?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Sleeping...";// <=17 chars
|
const char* SleepingAdvancedString = "En veille..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "WARNING! TIP HOT!";
|
const char* WarningAdvancedString = "ATTENTION! CHAUD"; // Must be <= 16 chars
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
const char SettingRightChar = 'D';
|
||||||
const char SettingFalseChar = 'F';
|
const char SettingLeftChar = 'G';
|
||||||
const char SettingRightChar = 'R';
|
|
||||||
const char SettingLeftChar = 'L';
|
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
|
|
||||||
const enum ShortNameType SettingsShortNameType = SHORT_NAME_SINGLE_LINE;
|
const enum ShortNameType SettingsShortNameType = SHORT_NAME_DOUBLE_LINE;
|
||||||
const char* SettingsShortNames[16][2] = {
|
const char* SettingsShortNames[16][2] = {
|
||||||
/* (<= 5) Power source (DC or batt) */{"PWRSC"},
|
/* (<= 11) Power source (DC or batt) */ {"Source", "d'alim"},
|
||||||
/* (<= 4) Sleep temperature */{"STMP"},
|
/* (<= 9) Sleep temperature */ {"Temp.", "veille"},
|
||||||
/* (<= 4) Sleep timeout */{"STME"},
|
/* (<= 9) Sleep timeout */ {"Délai", "veille"},
|
||||||
/* (<= 5) Shutdown timeout */{"SHTME"},
|
/* (<= 11) Shutdown timeout */ {"Délai", "extinction"},
|
||||||
/* (<= 6) Motion sensitivity level */{"MSENSE"},
|
/* (<= 13) Motion sensitivity level */ {"Sensibilité", "au mouvement"},
|
||||||
/* (<= 6) Temperature in F and C */{"TMPUNT"},
|
/* (<= 13) Temperature in F and C */ {"Unité de", "température"},
|
||||||
/* (<= 6) Advanced idle display mode enabled */{"ADVIDL"},
|
/* (<= 13) Advanced idle display mode enabled */ {"Écran veille", "détaillé"},
|
||||||
/* (<= 6) Display rotation mode */{"DSPROT"},
|
/* (<= 13) Display rotation mode */ {"Orientation", "de l'écran"},
|
||||||
/* (<= 6) Boost enabled */{"BOOST"},
|
/* (<= 13) Boost enabled */ {"Activation du", "mode Boost"},
|
||||||
/* (<= 4) Boost temperature */{"BTMP"},
|
/* (<= 9) Boost temperature */ {"Temp.", "Boost"},
|
||||||
/* (<= 6) Automatic start mode */{"ASTART"},
|
/* (<= 13) Automatic start mode */ {"Démarrage", "automatique"},
|
||||||
/* (<= 6) Cooldown blink */{"CLBLNK"},
|
/* (<= 13) Cooldown blink */ {"Refroidir en", "clignottant"},
|
||||||
/* (<= 8) Temperature calibration enter menu */{"TMP CAL?"},
|
/* (<= 16) Temperature calibration enter menu */ {"Étalonner", "température"},
|
||||||
/* (<= 8) Settings reset command */{"RESET?"},
|
/* (<= 16) Settings reset command */ {"Réinitialisation", "d'usine"},
|
||||||
/* (<= 8) Calibrate input voltage */{"CAL VIN?"},
|
/* (<= 16) Calibrate input voltage */ {"Étalonner", "tension d'entrée"},
|
||||||
/* (<= 6) Advanced soldering screen enabled */{"ADVSLD"},
|
/* (<= 13) Advanced soldering screen enabled */ {"Écran soudure", "détaillé"},
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -402,49 +395,48 @@ const char* SettingsLongNames[16] = {
|
|||||||
/* Shutdown timeout */ "Abschaltzeit <Minuten>",
|
/* Shutdown timeout */ "Abschaltzeit <Minuten>",
|
||||||
/* Motion sensitivity level */ "Bewegungsempfindlichkeit <0=Aus, 1=Minimal ... 9=Maximal>",
|
/* Motion sensitivity level */ "Bewegungsempfindlichkeit <0=Aus, 1=Minimal ... 9=Maximal>",
|
||||||
/* Temperature in F and C */ "Temperatureinheit <C=Celsius, F=Fahrenheit>",
|
/* Temperature in F and C */ "Temperatureinheit <C=Celsius, F=Fahrenheit>",
|
||||||
/* Advanced idle display mode enabled */"Detaillierte Anzeige im Ruhemodus <T=An, F=Aus>",
|
/* Advanced idle display mode enabled */ "Detaillierte Anzeige im Ruhemodus <J=An, N=Aus>",
|
||||||
/* Display rotation mode */"Ausrichtung der Anzeige <A=Auto, L=Linkshändig, R=Rechtshändig>",
|
/* Display rotation mode */ "Ausrichtung der Anzeige <A=Automatisch, L=Linkshändig, R=Rechtshändig>",
|
||||||
/* Boost enabled */"Vordere Taste für Temperaturboost verwenden <T=An, F=Aus>",
|
/* Boost enabled */ "Vordere Taste für Temperaturboost verwenden <J=An, N=Aus>",
|
||||||
/* Boost temperature */ "Temperatur im Boostmodus (In der eingestellten Einheit)",
|
/* Boost temperature */ "Temperatur im Boostmodus (In der eingestellten Einheit)",
|
||||||
/* Automatic start mode */"Automatischer Start des Lötmodus beim Einschalten der Spannungsversorgung. <T=An, F=Aus>",
|
/* Automatic start mode */ "Automatischer Start des Lötmodus beim Einschalten der Spannungsversorgung. <J=An, N=Aus>",
|
||||||
/* Cooldown blink */"Blinkende Temperaturanzeige beim Abkühlen, solange heiß. <T=An, F=Aus>"
|
/* Cooldown blink */ "Blinkende Temperaturanzeige beim Abkühlen, solange heiß. <J=An, N=Aus>",
|
||||||
/* Temperature calibration enter menu */ "Kalibrierung der Lötspitzentemperatur",
|
/* Temperature calibration enter menu */ "Kalibrierung der Lötspitzentemperatur",
|
||||||
/* Settings reset command */ "Alle Einstellungen zurücksetzen",
|
/* Settings reset command */ "Alle Einstellungen zurücksetzen",
|
||||||
/* Calibrate input voltage */ "Kalibrierung der Eingangsspannung. Kurzer Tastendruck zum Einstellen, langer Tastendruck zum Verlassen.",
|
/* Calibrate input voltage */ "Kalibrierung der Eingangsspannung. Kurzer Tastendruck zum Einstellen, langer Tastendruck zum Verlassen.",
|
||||||
/* Advanced soldering screen enabled */"Detaillierte Anzeige im Lötmodus <T=An, F=Aus>",
|
/* Advanced soldering screen enabled */ "Detaillierte Anzeige im Lötmodus <J=An, N=Aus>",
|
||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Vor dem Fortfahren muss die Lötspitze vollständig abgekühlt sein!";
|
const char* SettingsCalibrationWarning = "Vor dem Fortfahren muss die Lötspitze vollständig abgekühlt sein!";
|
||||||
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzz "; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzz "; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Ruhemodus..."; // <=17 chars
|
const char* SleepingAdvancedString = "Ruhemodus..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HEIß"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HEIß"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "Achtung! Spitze Heiß!";
|
const char* WarningAdvancedString = "Achtung! Spitze Heiß!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'F';
|
|
||||||
const char SettingRightChar = 'R';
|
const char SettingRightChar = 'R';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
|
|
||||||
const enum ShortNameType SettingsShortNameType = SHORT_NAME_SINGLE_LINE;
|
const enum ShortNameType SettingsShortNameType = SHORT_NAME_DOUBLE_LINE;
|
||||||
const char* SettingsShortNames[16][2] = {
|
const char* SettingsShortNames[16][2] = {
|
||||||
/* (<= 5) Power source (DC or batt) */{"PWRSC"},
|
/* (<= 11) Power source (DC or batt) */ {"Spannungs-", "quelle"},
|
||||||
/* (<= 4) Sleep temperature */{"STMP"},
|
/* (<= 9) Sleep temperature */ {"Ruhetemp-", "eratur"},
|
||||||
/* (<= 4) Sleep timeout */{"STME"},
|
/* (<= 9) Sleep timeout */ {"Ruhever-", "zoegerung"},
|
||||||
/* (<= 5) Shutdown timeout */{"SHTME"},
|
/* (<= 11) Shutdown timeout */ {"Abschalt-", "zeit"},
|
||||||
/* (<= 6) Motion sensitivity level */{"MSENSE"},
|
/* (<= 13) Motion sensitivity level */ {"Bewegungs-", "empfindlichk."},
|
||||||
/* (<= 6) Temperature in F and C */{"TMPUNT"},
|
/* (<= 13) Temperature in F and C */ {"Temperatur-", "einheit"},
|
||||||
/* (<= 6) Advanced idle display mode enabled */{"ADVIDL"},
|
/* (<= 13) Advanced idle display mode enabled */ {"Detaillierte", "Ruheansicht"},
|
||||||
/* (<= 6) Display rotation mode */{"DSPROT"},
|
/* (<= 13) Display rotation mode */ {"Anzeige-", "ausrichtung"},
|
||||||
/* (<= 6) Boost enabled */{"BOOST"},
|
/* (<= 13) Boost enabled */ {"Boosttaste", "aktiv?"},
|
||||||
/* (<= 4) Boost temperature */{"BTMP"},
|
/* (<= 9) Boost temperature */ {"Boosttemp-", "eratur"},
|
||||||
/* (<= 6) Automatic start mode */{"ASTART"},
|
/* (<= 13) Automatic start mode */ {"Start im", "Loetmodus?"},
|
||||||
/* (<= 6) Cooldown blink */{"CLBLNK"},
|
/* (<= 13) Cooldown blink */ {"Abkuehl-", "blinken?"},
|
||||||
/* (<= 8) Temperature calibration enter menu */{"TMP CAL?"},
|
/* (<= 16) Temperature calibration enter menu */ {"Temperatur", "kalibrieren?"},
|
||||||
/* (<= 8) Settings reset command */{"RESET?"},
|
/* (<= 16) Settings reset command */ {"Einstellungen", "zuruecksetzen?"},
|
||||||
/* (<= 8) Calibrate input voltage */{"CAL VIN?"},
|
/* (<= 16) Calibrate input voltage */ {"Eingangsspannung", "kalibrieren?"},
|
||||||
/* (<= 6) Advanced soldering screen enabled */{"ADVSLD"},
|
/* (<= 13) Advanced soldering screen enabled */ {"Detaillierte", "Loetansicht"},
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -463,7 +455,7 @@ const char* SettingsLongNames[16] = {
|
|||||||
/* Boost enabled */ "Povolit tlacidlo pre prudky nahrev <T=Zap, F=Vyp>",
|
/* Boost enabled */ "Povolit tlacidlo pre prudky nahrev <T=Zap, F=Vyp>",
|
||||||
/* Boost temperature */ "Cielova teplota pre prudky nahrev (v nastavenych jednotkach)",
|
/* Boost temperature */ "Cielova teplota pre prudky nahrev (v nastavenych jednotkach)",
|
||||||
/* Automatic start mode */ "Pri starte spustit rezim spajkovania <T=Zap, F=Vyp, S=Spanok>",
|
/* Automatic start mode */ "Pri starte spustit rezim spajkovania <T=Zap, F=Vyp, S=Spanok>",
|
||||||
/* Cooldown blink */"Blikanie ukazovatela teploty pocas chladnutia hrotu <T=Zap, F=Vyp>"
|
/* Cooldown blink */ "Blikanie ukazovatela teploty pocas chladnutia hrotu <T=Zap, F=Vyp>",
|
||||||
/* Temperature calibration enter menu */ "Kalibracia posunu hrotu",
|
/* Temperature calibration enter menu */ "Kalibracia posunu hrotu",
|
||||||
/* Settings reset command */ "Tovarenske nastavenia",
|
/* Settings reset command */ "Tovarenske nastavenia",
|
||||||
/* Calibrate input voltage */ "Kalibracia VIN. Kratke stlacenie meni nastavenie, dlhe stlacenie pre navrat",
|
/* Calibrate input voltage */ "Kalibracia VIN. Kratke stlacenie meni nastavenie, dlhe stlacenie pre navrat",
|
||||||
@@ -471,14 +463,13 @@ const char* SettingsLongNames[16] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Najprv sa prosim uistite, ze hrot ma izbovu teplotu!";
|
const char* SettingsCalibrationWarning = "Najprv sa prosim uistite, ze hrot ma izbovu teplotu!";
|
||||||
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Chrr"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Chrr"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Kludovy rezim..."; // <=17 chars
|
const char* SleepingAdvancedString = "Kludovy rezim..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "Pozor! Hrot je horuci!";
|
const char* WarningAdvancedString = "Pozor! Hrot je horuci!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'F';
|
|
||||||
const char SettingRightChar = 'R';
|
const char SettingRightChar = 'R';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -527,14 +518,13 @@ const char* SettingsLongNames[16] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Lütfen devam etmeden önce ucun oda sıcaklığında olduğunu garantiye alın!";
|
const char* SettingsCalibrationWarning = "Lütfen devam etmeden önce ucun oda sıcaklığında olduğunu garantiye alın!";
|
||||||
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Uyuyor..."; // <=17 chars
|
const char* SleepingAdvancedString = "Uyuyor..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "UYARI! UÇ SICAK!";
|
const char* WarningAdvancedString = "UYARI! UÇ SICAK!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'F';
|
|
||||||
const char SettingRightChar = 'R';
|
const char SettingRightChar = 'R';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -583,14 +573,13 @@ const char* SettingsLongNames[16] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Provjerite da je vršak ohlađen na sobnu temperaturu prije nego što nastavite!";
|
const char* SettingsCalibrationWarning = "Provjerite da je vršak ohlađen na sobnu temperaturu prije nego što nastavite!";
|
||||||
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "NAPON!!!"; // Fixed width 8 chars
|
const char* UVLOWarningString = "NAPON!!!"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Spavanje..."; // <=17 chars
|
const char* SleepingAdvancedString = "Spavanje..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "VRUĆ"; // Must be <= 4 chars
|
const char* WarningSimpleString = "VRUĆ"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "OPREZ! Vršak je vruć!";
|
const char* WarningAdvancedString = "OPREZ! Vršak je vruć!";
|
||||||
|
|
||||||
const char SettingTrueChar = '+';
|
|
||||||
const char SettingFalseChar = '-';
|
|
||||||
const char SettingRightChar = 'D';
|
const char SettingRightChar = 'D';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -618,147 +607,89 @@ const char* SettingsShortNames[16][2] = {
|
|||||||
|
|
||||||
#ifdef LANG_CS_CZ
|
#ifdef LANG_CS_CZ
|
||||||
const char* SettingsLongNames[16] = {
|
const char* SettingsLongNames[16] = {
|
||||||
/*These are all the help text for all the settings.*/
|
// These are all the help text for all the settings.
|
||||||
/*No requirements on spacing or length*/
|
// No requirements on spacing or length
|
||||||
"Zdroj napajeni. Pri nizsim napeti se odpoji <DC=10V, xS=x*3.3V pro LiPo,LiIon...>", //Power Source
|
/* Power source (DC or batt) */ "Pri nizsim napeti se odpoji <DC=10V, xS=x*3.3V pro LiPo,LiIon...>",
|
||||||
"Teplota v rezimu spanku",//Sleep Temp
|
/* Sleep temperature */ "Teplota v rezimu spanku",
|
||||||
"Cas do rezimu spanku <Minut/Sekund>",//Sleep Timeout
|
/* Sleep timeout */ "Cas do rezimu spanku <Minut/Sekund>",
|
||||||
"Cas do automatickeho vypnuti <Minut>",//Shutdown Time
|
/* Shutdown timeout */ "Cas do automatickeho vypnuti <Minut>",
|
||||||
"Citlivost detekce pohybu <0=Vyp, 1=Min, ... 9=Max>",//Motion Sensitivity
|
/* Motion sensitivity level */ "Citlivost detekce pohybu <0=Vyp, 1=Min, ... 9=Max>",
|
||||||
"Jednotky mereni teploty <C=Celsius, F=Fahrenheit>",//Temp Unit
|
/* Temperature in F and C */ "Jednotky mereni teploty <C=Celsius, F=Fahrenheit>",
|
||||||
"Zobrazit podrobnosti na vychozi obrazovce <Z=Zap, V=Vyp>",//Detailed Information
|
/* Advanced idle display mode enabled */ "Zobrazit podrobnosti na vychozi obrazovce <Z=Zap, V=Vyp>",
|
||||||
"Otoceni displaye <A=Auto, L=Levak, P=Pravak>",//Orientation
|
/* Display rotation mode */ "Orientace obrazovky <A=Auto, L=Levak, P=Pravak>",
|
||||||
"Povolit boost drzenim leveho tlacitka pri pajeni <Z=Zap, V=Vyp>",//Boost enable
|
/* Boost enabled */ "Povolit boost drzenim leveho tlacitka pri pajeni <Z=Zap, V=Vyp>",
|
||||||
"Teplota pri boostu",//Boost Temp
|
/* Boost temperature */ "Teplota v rezimu boost",
|
||||||
"Pri startu ihned nahrivat hrot <Z=Zap, V=Vyp, S=Rezim spanku>",//Auto start
|
/* Automatic start mode */ "Pri startu ihned nahrivat hrot <Z=Zap, V=Vyp, S=Rezim spanku>",
|
||||||
"Blikani teploty pri chladnuti, dokud je hrot horky <Z=Zap, V=Vyp>",//Cooling Blink
|
/* Cooldown blink */ "Blikani teploty pri chladnuti, dokud je hrot horky <Z=Zap, V=Vyp>",
|
||||||
"Kalibrovat mereni teploty",//Calibrate Tip
|
/* Temperature calibration enter menu */ "Kalibrovat mereni teploty",
|
||||||
"Obnovit tovarni nastaveni",//Reset Settings
|
/* Settings reset command */ "Obnovit tovarni nastaveni",
|
||||||
"Kalibrovat vstupni napeti. Tlacitky upravte, podrzenim potvrdte.",//VIN Cal
|
/* Calibrate input voltage */ "Kalibrovat vstupni napeti. Tlacitky upravte, podrzenim potvrdte.",
|
||||||
"Zobrazit podrobnosti pri pajeni <Z=Zap, V=Vyp>",//ADV SLD
|
/* Advanced soldering screen enabled */ "Zobrazit podrobnosti pri pajeni <Z=Zap, V=Vyp>",
|
||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Ujistete se, ze hrot ma pokojovou teplotu! "; // ending space needed
|
const char* SettingsCalibrationWarning = "Ujistete se, ze hrot ma pokojovou teplotu! "; // ending space needed
|
||||||
|
const char* SettingsResetWarning = "Opravdu chcete resetovat zarizeni do tovarniho nastaveni?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzz "; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzz "; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Rezim spanku..."; // <=17 chars
|
const char* SleepingAdvancedString = "Rezim spanku..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "!! HORKY HROT !!"; // <= 16 chars
|
const char* WarningAdvancedString = "!! HORKY HROT !!"; // <= 16 chars
|
||||||
|
|
||||||
const char SettingTrueChar = 'Z';
|
|
||||||
const char SettingFalseChar = 'V';
|
|
||||||
const char SettingRightChar = 'P';
|
const char SettingRightChar = 'P';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
|
|
||||||
const enum ShortNameType SettingsShortNameType = SHORT_NAME_SINGLE_LINE;
|
const enum ShortNameType SettingsShortNameType = SHORT_NAME_DOUBLE_LINE;
|
||||||
const char* SettingsShortNames[16][2] = {
|
const char* SettingsShortNames[16][2] = {
|
||||||
/* (<= 5) Power source (DC or batt) */{"PWRSC"},
|
/* (<= 11) Power source (DC or batt) */ {"Zdroj", "napajeni"},
|
||||||
/* (<= 4) Sleep temperature */{"STMP"},
|
/* (<= 9) Sleep temperature */ {"Teplota v", "r. spanku"},
|
||||||
/* (<= 4) Sleep timeout */{"STME"},
|
/* (<= 9) Sleep timeout */ {"Cas do", "r. spanku"},
|
||||||
/* (<= 5) Shutdown timeout */{"SHTME"},
|
/* (<= 11) Shutdown timeout */ {"Cas do", "vypnuti"},
|
||||||
/* (<= 6) Motion sensitivity level */{"MSENSE"},
|
/* (<= 13) Motion sensitivity level */ {"Citlivost", "det. pohybu"},
|
||||||
/* (<= 6) Temperature in F and C */{"TMPUNT"},
|
/* (<= 13) Temperature in F and C */ {"Jednotky", "teploty"},
|
||||||
/* (<= 6) Advanced idle display mode enabled */{"ADVIDL"},
|
/* (<= 13) Advanced idle display mode enabled */ {"Podrobnosti", "na vych. obr."},
|
||||||
/* (<= 6) Display rotation mode */{"DSPROT"},
|
/* (<= 13) Display rotation mode */ {"Orientace", "obrazovky"},
|
||||||
/* (<= 6) Boost enabled */{"BOOST"},
|
/* (<= 13) Boost enabled */ {"Povolit", "boost"},
|
||||||
/* (<= 4) Boost temperature */{"BTMP"},
|
/* (<= 9) Boost temperature */ {"Teplota v", "r. boost"},
|
||||||
/* (<= 6) Automatic start mode */{"ASTART"},
|
/* (<= 13) Automatic start mode */ {"Auto", "start"},
|
||||||
/* (<= 6) Cooldown blink */{"CLBLNK"},
|
/* (<= 13) Cooldown blink */ {"Blikani pri", "chladnuti"},
|
||||||
/* (<= 8) Temperature calibration enter menu */{"TMP CAL?"},
|
/* (<= 16) Temperature calibration enter menu */ {"Kalibrovat", "teplotu?"},
|
||||||
/* (<= 8) Settings reset command */{"RESET?"},
|
/* (<= 16) Settings reset command */ {"Tovarni", "nastaveni?"},
|
||||||
/* (<= 8) Calibrate input voltage */{"CAL VIN?"},
|
/* (<= 16) Calibrate input voltage */ {"Kalibrovat", "vstupni napeti?"},
|
||||||
/* (<= 6) Advanced soldering screen enabled */{"ADVSLD"},
|
/* (<= 13) Advanced soldering screen enabled */ {"Podrobnosti", "pri pajeni"},
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef LANG_HUN
|
#ifdef LANG_HUN
|
||||||
const char* SettingsLongNames[16] = {
|
const char* SettingsLongNames[16] = {
|
||||||
/*These are all the help text for all the settings.*/
|
// These are all the help text for all the settings.
|
||||||
/*No requirements on spacing or length*/
|
// No requirements on spacing or length
|
||||||
"Áramforrás. Beállítja a lekapcsolási feszültséget. <DC 10V> <S 3.3V cellánként>", //Power Source
|
/* Power source (DC or batt) */ "Áramforrás. Beállítja a lekapcsolási feszültséget. <DC 10V> <S 3.3V cellánként>",
|
||||||
"Alvási hőmérséklet <C>",//Sleep Temp
|
/* Sleep temperature */ "Alvási hőmérséklet <C>",
|
||||||
"Elalvási időzítő <Perc/Másodperc>",//Sleep Timeout
|
/* Sleep timeout */ "Elalvási időzítő <Perc/Másodperc>",
|
||||||
"Kikapcsolási időzítő <Minutes>",//Shutdown Time
|
/* Shutdown timeout */ "Kikapcsolási időzítő <Minutes>",
|
||||||
"Mozgás érzékenység beállítása. <0.Ki 1.kevésbé érzékeny 9.legérzékenyebb>",//Motion Sensitivity
|
/* Motion sensitivity level */ "Mozgás érzékenység beállítása. <0.Ki 1.kevésbé érzékeny 9.legérzékenyebb>",
|
||||||
"Hőmérsékleti egység <C=Celsius F=Fahrenheit>",//Temp Unit
|
/* Temperature in F and C */ "Hőmérsékleti egység <C=Celsius F=Fahrenheit>",
|
||||||
"Részletes információ megjelenítése kisebb betűméretben a készenléti képernyőn.",//Detailed Information
|
/* Advanced idle display mode enabled */ "Részletes információ megjelenítése kisebb betűméretben a készenléti képernyőn.",
|
||||||
"Megjelenítési tájolás <A. Automatikus L. Balkezes R. Jobbkezes>",//Orientation
|
/* Display rotation mode */ "Megjelenítési tájolás <A. Automatikus L. Balkezes R. Jobbkezes>",
|
||||||
"Elülső gombbal lépjen boost módba, 450C forrasztás közben",//Boost enable
|
/* Boost enabled */ "Elülső gombbal lépjen boost módba, 450C forrasztás közben",
|
||||||
"Hőmérséklet \"boost\" módban",//Boost Temp
|
/* Boost temperature */ "Hőmérséklet \"boost\" módban",
|
||||||
"Bekapcsolás után automatikusan lépjen forrasztás módba. T=Forrasztás, S=Alvó mód,F=Ki",//Auto start
|
/* Automatic start mode */ "Bekapcsolás után automatikusan lépjen forrasztás módba. T=Forrasztás, S=Alvó mód,F=Ki",
|
||||||
"Villogjon a hőmérséklet hűlés közben, amíg a hegy forró.",//Cooling Blink
|
/* Cooldown blink */ "Villogjon a hőmérséklet hűlés közben, amíg a hegy forró.",
|
||||||
"Hegy hőmérsékletének kalibrálása",//Calibrate Tip
|
/* Temperature calibration enter menu */ "Hegy hőmérsékletének kalibrálása",
|
||||||
"Beállítások alaphelyzetbe állítása",//Reset Settings
|
/* Settings reset command */ "Beállítások alaphelyzetbe állítása",
|
||||||
"A bemeneti feszültség kalibrálása. Röviden megnyomva állítsa be, hosszan nyomja meg a kilépéshez.",//VIN Cal
|
/* Calibrate input voltage */ "A bemeneti feszültség kalibrálása. Röviden megnyomva állítsa be, hosszan nyomja meg a kilépéshez.",
|
||||||
"Részletes információk megjelenítése forrasztás közben",//ADV SLD
|
/* Advanced soldering screen enabled */ "Részletes információk megjelenítése forrasztás közben",
|
||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Folytatás előtt győződj meg róla, hogy a hegy szobahőmérsékletű!";
|
const char* SettingsCalibrationWarning = "Folytatás előtt győződj meg róla, hogy a hegy szobahőmérsékletű!";
|
||||||
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Alvás..."; // <=17 chars
|
const char* SleepingAdvancedString = "Alvás..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "FIGYELEM! FORRÓ HEGY!";
|
const char* WarningAdvancedString = "FIGYELEM! FORRÓ HEGY!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'F';
|
|
||||||
const char SettingRightChar = 'R';
|
|
||||||
const char SettingLeftChar = 'L';
|
|
||||||
const char SettingAutoChar = 'A';
|
|
||||||
|
|
||||||
const enum ShortNameType SettingsShortNameType = SHORT_NAME_SINGLE_LINE;
|
|
||||||
const char* SettingsShortNames[16][2] = {
|
|
||||||
/* (<= 5) Power source (DC or batt) */{"PWRSC"},
|
|
||||||
/* (<= 4) Sleep temperature */{"STMP"},
|
|
||||||
/* (<= 4) Sleep timeout */{"STME"},
|
|
||||||
/* (<= 5) Shutdown timeout */{"SHTME"},
|
|
||||||
/* (<= 6) Motion sensitivity level */{"MSENSE"},
|
|
||||||
/* (<= 6) Temperature in F and C */{"TMPUNT"},
|
|
||||||
/* (<= 6) Advanced idle display mode enabled */{"ADVIDL"},
|
|
||||||
/* (<= 6) Display rotation mode */{"DSPROT"},
|
|
||||||
/* (<= 6) Boost enabled */{"BOOST"},
|
|
||||||
/* (<= 4) Boost temperature */{"BTMP"},
|
|
||||||
/* (<= 6) Automatic start mode */{"ASTART"},
|
|
||||||
/* (<= 6) Cooldown blink */{"CLBLNK"},
|
|
||||||
/* (<= 8) Temperature calibration enter menu */{"TMP CAL?"},
|
|
||||||
/* (<= 8) Settings reset command */{"RESET?"},
|
|
||||||
/* (<= 8) Calibrate input voltage */{"CAL VIN?"},
|
|
||||||
/* (<= 6) Advanced soldering screen enabled */{"ADVSLD"},
|
|
||||||
};
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef LANG_TR
|
|
||||||
const char* SettingsLongNames[16] = {
|
|
||||||
/*These are all the help text for all the settings.*/
|
|
||||||
/*No requirements on spacing or length*/
|
|
||||||
/* Power source (DC or batt) */"Güç Kaynağı. kesim geriliminı ayarlar. <DC 10V> <S 3.3V hücre başına>", //Power Source
|
|
||||||
/* Sleep temperature */"Uyku Sıcaklığı <C>",//Sleep Temp
|
|
||||||
/* Sleep timeout */"Uyku Zaman Aşımı <Dakika/Saniye>",//Sleep Timeout
|
|
||||||
/* Shutdown timeout */"Kapatma Zaman Aşımı <Dakika>",//Shutdown Time
|
|
||||||
/* Motion sensitivity level */"Hareket Hassasiyeti <0.Kapalı 1.En az duyarlı 9.En duyarlı>",//Motion Sensitivity
|
|
||||||
/* Temperature in F and C */"Sıcaklık Ünitesi <C=Celsius F=Fahrenheit>",//Temp Unit
|
|
||||||
/* Advanced idle display mode enabled */"Boş ekranda ayrıntılı bilgileri daha küçük bir yazı tipi ile göster.",//Detailed Information
|
|
||||||
/* Display rotation mode */"Görüntü Yönlendirme <A. Otomatik L. Solak R. Sağlak>",//Orientation
|
|
||||||
/* Boost enabled */"Lehimleme yaparken ön tuşa basmak Boost moduna sokar(450C)",//Boost enable
|
|
||||||
/* Boost temperature */"\"boost\" Modu Derecesi",//Boost Temp
|
|
||||||
/* Automatic start mode */"Güç verildiğinde otomatik olarak lehimleme modunda başlat. T=Lehimleme Modu, S= Uyku Modu,F=Kapalı",//Auto start
|
|
||||||
/* Cooldown blink */"Soğutma ekranında uç hala sıcakken derece yanıp sönsün.",//Cooling Blink
|
|
||||||
/* Temperature calibration enter menu */"Ucu kalibre et.",//Calibrate Tip
|
|
||||||
/* Settings reset command */"Bütün ayarları sıfırla",//Reset Settings
|
|
||||||
/* Calibrate input voltage */"VIN Kalibrasyonu. Düğmeler ayarlar, çıkmak için uzun bas.",//VIN Cal
|
|
||||||
/* Advanced soldering screen enabled */"Lehimleme yaparken detaylı bilgi göster",//ADV SLD
|
|
||||||
};
|
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning = "Lütfen devam etmeden önce ucun oda sıcaklığında olduğunu garantiye alın!";
|
|
||||||
const char* UVLOWarningString = "LOW VOLT"; //Fixed width 8 chars
|
|
||||||
const char* SleepingSimpleString = "Zzzz";// Must be <= 4 chars
|
|
||||||
const char* SleepingAdvancedString = "Uyuyor...";// <=17 chars
|
|
||||||
const char* WarningSimpleString = "HOT!";//Must be <= 4 chars
|
|
||||||
const char* WarningAdvancedString = "UYARI! UÇ SICAK!";
|
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'F';
|
|
||||||
const char SettingRightChar = 'R';
|
const char SettingRightChar = 'R';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -785,38 +716,35 @@ const char* SettingsShortNames[16][2] = {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef LANG_DK
|
#ifdef LANG_DK
|
||||||
const char* SettingsLongNames[16] =
|
const char* SettingsLongNames[16] = {
|
||||||
{
|
// These are all the help text for all the settings.
|
||||||
/*These are all the help text for all the settings.*/
|
// No requirements on spacing or length
|
||||||
/*No requirements on spacing or length*/
|
/* Power source (DC or batt) */ "Strømforsyning. Indstil Cutoff Spændingen. <DC 10V <S 3.3V per cell",
|
||||||
"Strømforsyning. Indstil Cutoff Spændingen. <DC 10V <S 3.3V per cell", //Power Source
|
/* Sleep temperature */ "Dvale Temperatur <C",
|
||||||
"Dvale Temperatur <C",//Sleep Temp
|
/* Sleep timeout */ "Dvale Timeout <Minutter/Sekunder",
|
||||||
"Dvale Timeout <Minutter/Sekunder",//Sleep Timeout
|
/* Shutdown timeout */ "sluknings Timeout <Minutter",
|
||||||
"sluknings Timeout <Minutter",//Shutdown Time
|
/* Motion sensitivity level */ "Bevægelsesfølsomhed <0.Slukket 1.Mindst følsom 9.Mest følsom",
|
||||||
"Bevægelsesfølsomhed <0.Slukket 1.Mindst følsom 9.Mest følsom",//Motion Sensitivity
|
/* Temperature in F and C */ "Temperatur Enhed <C=Celsius F=Fahrenheit",
|
||||||
"Temperatur Enhed <C=Celsius F=Fahrenheit",//Temp Unit
|
/* Advanced idle display mode enabled */ "Vis detialieret information med en mindre skriftstørrelse på standby skærmen.",
|
||||||
"Vis detialieret information med en mindre skriftstørrelse på standby skærmen.",//Detailed Information
|
/* Display rotation mode */ "Skærm Orientering <A. Automatisk V. Venstre Håndet H. Højre Håndet",
|
||||||
"Skærm Orientering <A. Automatisk V. Venstre Håndet H. Højre Håndet",//Orientation
|
/* Boost enabled */ "Ved tryk på front knap Aktiveres boost-funktionen, 450C tilstand når der loddes",
|
||||||
"Ved tryk på front knap Aktiveres boost-funktionen, 450C tilstand når der loddes",//Boost enable
|
/* Boost temperature */ "Temperatur i \"boost\" mode",
|
||||||
"Temperatur i \"boost\" mode",//Boost Temp
|
/* Automatic start mode */ "Start automatisk med lodning når strøm sættes til. L=Lodning, D= Dvale tilstand,S=Slukket",
|
||||||
"Start automatisk med lodning når strøm sættes til. L=Lodning, D= Dvale tilstand,S=Slukket",//Auto start
|
/* Cooldown blink */ "Blink temperaturen på skærmen, mens spidsen stadig er varm.",
|
||||||
"Blink temperaturen på skærmen, mens spidsen stadig er varm.",//Cooling Blink
|
/* Temperature calibration enter menu */ "kalibrere spids temperatur.",
|
||||||
"kalibrere spids temperatur.",//Calibrate Tip
|
/* Settings reset command */ "Gendan alle indstillinger",
|
||||||
"Gendan alle indstillinger",//Reset Settings
|
/* Calibrate input voltage */ "VIN kalibrering. Knapperne justere, Lang tryk for at gå ud",
|
||||||
"VIN kalibrering. Knapperne justere, Lang tryk for at gå ud",//VIN Cal
|
/* Advanced soldering screen enabled */ "Vis detialieret information mens der loddes",
|
||||||
"Vis detialieret information mens der loddes",//ADV SLD
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning =
|
const char* SettingsCalibrationWarning = "Sørg for at loddespidsen er ved stuetemperatur, inden du fortsætter!";
|
||||||
"Sørg for at loddespidsen er ved stuetemperatur, inden du fortsætter!";
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "Lav Volt"; // Fixed width 8 chars
|
const char* UVLOWarningString = "Lav Volt"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzzz"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Dvale..."; // <=17 chars
|
const char* SleepingAdvancedString = "Dvale..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "Varm"; // Must be <= 4 chars
|
const char* WarningSimpleString = "Varm"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "ADVARSEL! VARM LODDESPIDS!";
|
const char* WarningAdvancedString = "ADVARSEL! VARM LODDESPIDS!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'j';
|
|
||||||
const char SettingFalseChar = 'N';
|
|
||||||
const char SettingRightChar = 'H';
|
const char SettingRightChar = 'H';
|
||||||
const char SettingLeftChar = 'V';
|
const char SettingLeftChar = 'V';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -841,39 +769,37 @@ const char* SettingsShortNames[16][2] = {
|
|||||||
/* (<= 6) Advanced soldering screen enabled */ {"ADVSLD"},
|
/* (<= 6) Advanced soldering screen enabled */ {"ADVSLD"},
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef LANG_PL
|
#ifdef LANG_PL
|
||||||
const char* SettingsLongNames[16] =
|
const char* SettingsLongNames[16] = {
|
||||||
{
|
// These are all the help text for all the settings.
|
||||||
/*These are all the help text for all the settings.*/
|
// No requirements on spacing or length
|
||||||
/*No requirements on spacing or length*/
|
/* Power source (DC or batt) */ "Źródło zasilania. Ustaw napięcie odcięcia. <DC 10V> <S 3.3V dla ogniw Li>",
|
||||||
"Źródło zasilania. Ustaw napięcie odcięcia. <DC 10V> <S 3.3V dla ogniw Li>", //Power Source
|
/* Sleep temperature */ "Temperatura uśpienia <°C>",
|
||||||
"Temperatura uśpienia <°C>",//Sleep Temp
|
/* Sleep timeout */ "Czas uśpienia <Minuty/Sekundy>",
|
||||||
"Czas uśpienia <Minuty/Sekundy>",//Sleep Timeout
|
/* Shutdown timeout */ "Czas wyłączenia <Minuty>",
|
||||||
"Czas wyłączenia <Minuty>",//Shutdown Time
|
/* Motion sensitivity level */ "Czułość ruchu <0.Wyłączona 1.minimalna 9.maksymalna>",
|
||||||
"Czułość ruchu <0.Wyłączona 1.minimalna 9.maksymalna>",//Motion Sensitivity
|
/* Temperature in F and C */ "Jednostka temperatury <C=Celsius F=Fahrenheit>",
|
||||||
"Jednostka temperatury <C=Celsius F=Fahrenheit>",//Temp Unit
|
/* Advanced idle display mode enabled */ "Wyświetla szczegółowe informacje za pomocą mniejszej czcionki na ekranie bezczynnośći <T = wł., N = wył.>",
|
||||||
"Wyświetla szczegółowe informacje za pomocą mniejszej czcionki na ekranie bezczynnośći <T = wł., N = wył.>",//Detailed Information
|
/* Display rotation mode */ "Orientacja wyświetlacza <A. Automatyczna L. Leworęczna P. Praworęczna>",
|
||||||
"Orientacja wyświetlacza <A. Automatyczna L. Leworęczna P. Praworęczna>",//Orientation
|
/* Boost enabled */ "Użyj przycisku przedniego w celu zwiększenia temperatury <T = wł., N = wył.>",
|
||||||
"Użyj przycisku przedniego w celu zwiększenia temperatury <T = wł., N = wył.>",//Boost enable
|
/* Boost temperature */ "Temperatura w trybie \"boost\" ",
|
||||||
"Temperatura w trybie \"boost\" ",//Boost Temp
|
/* Automatic start mode */ "Automatyczne uruchamianie trybu lutowania po włączeniu zasilania. T=Lutowanie, S= Tryb Uspienia ,N=Wyłącz",
|
||||||
"Automatyczne uruchamianie trybu lutowania po włączeniu zasilania. T=Lutowanie, S= Tryb Uspienia ,N=Wyłącz",//Auto start
|
/* Cooldown blink */ "Temperatura na ekranie miga, gdy grot jest jeszcze gorący. <T = wł., N = wył.>",
|
||||||
"Temperatura na ekranie miga, gdy grot jest jeszcze gorący. <T = wł., N = wył.>",//Cooling Blink
|
/* Temperature calibration enter menu */ "Kalibracja temperatury grota lutownicy",
|
||||||
"Kalibracja temperatury grota lutownicy",//Calibrate Tip
|
/* Settings reset command */ "Zresetuj wszystkie ustawienia",
|
||||||
"Zresetuj wszystkie ustawienia",//Reset Settings
|
/* Calibrate input voltage */ "Kalibracja napięcia wejściowego. Krótkie naciśnięcie, aby ustawić, długie naciśnięcie, aby wyjść.",
|
||||||
"Kalibracja napięcia wejściowego. Krótkie naciśnięcie, aby ustawić, długie naciśnięcie, aby wyjść.",//VIN Cal
|
/* Advanced soldering screen enabled */ "Wyświetl szczegółowe informacje podczas lutowania <T = wł., N = wył.>",
|
||||||
"Wyświetl szczegółowe informacje podczas lutowania <T = wł., N = wył.>",//ADV SLD
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const char* SettingsCalibrationWarning =
|
const char* SettingsCalibrationWarning = "Przed kontynuowaniem upewnij się, że końcówka osiągnela temperature pokojowa!";
|
||||||
"Przed kontynuowaniem upewnij się, że końcówka osiągnela temperature pokojowa!";
|
const char* SettingsResetWarning = "Are you sure to reset settings to default values?";
|
||||||
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
const char* UVLOWarningString = "LOW VOLT"; // Fixed width 8 chars
|
||||||
const char* SleepingSimpleString = "Zzz!"; // Must be <= 4 chars
|
const char* SleepingSimpleString = "Zzz!"; // Must be <= 4 chars
|
||||||
const char* SleepingAdvancedString = "Uspienie..."; // <=17 chars
|
const char* SleepingAdvancedString = "Uspienie..."; // <=17 chars
|
||||||
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
const char* WarningSimpleString = "HOT!"; // Must be <= 4 chars
|
||||||
const char* WarningAdvancedString = "UWAGA! GORĄCA KOŃCÓWKA!";
|
const char* WarningAdvancedString = "UWAGA! GORĄCA KOŃCÓWKA!";
|
||||||
|
|
||||||
const char SettingTrueChar = 'T';
|
|
||||||
const char SettingFalseChar = 'N';
|
|
||||||
const char SettingRightChar = 'P';
|
const char SettingRightChar = 'P';
|
||||||
const char SettingLeftChar = 'L';
|
const char SettingLeftChar = 'L';
|
||||||
const char SettingAutoChar = 'A';
|
const char SettingAutoChar = 'A';
|
||||||
@@ -895,5 +821,6 @@ const char* SettingsShortNames[16][2] = {
|
|||||||
/* (<= 8) Temperature calibration enter menu */ {"TMP CAL?"},
|
/* (<= 8) Temperature calibration enter menu */ {"TMP CAL?"},
|
||||||
/* (<= 8) Settings reset command */ {"RESET?"},
|
/* (<= 8) Settings reset command */ {"RESET?"},
|
||||||
/* (<= 8) Calibrate input voltage */ {"CAL VIN?"},
|
/* (<= 8) Calibrate input voltage */ {"CAL VIN?"},
|
||||||
/* (<= 6) Advanced soldering screen enabled */{"ADVSLD"},};
|
/* (<= 6) Advanced soldering screen enabled */ {"ADVSLD"},
|
||||||
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -6,9 +6,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gui.h"
|
#include "gui.h"
|
||||||
#include "string.h"
|
|
||||||
#include "hardware.h"
|
|
||||||
#include "cmsis_os.h"
|
#include "cmsis_os.h"
|
||||||
|
#include "hardware.h"
|
||||||
|
#include "string.h"
|
||||||
|
|
||||||
static void settings_setInputVRange(void);
|
static void settings_setInputVRange(void);
|
||||||
static void settings_displayInputVRange(void);
|
static void settings_displayInputVRange(void);
|
||||||
static void settings_setSleepTemp(void);
|
static void settings_setSleepTemp(void);
|
||||||
@@ -43,28 +44,59 @@ static void settings_displayCalibrate(void);
|
|||||||
static void settings_setCalibrateVIN(void);
|
static void settings_setCalibrateVIN(void);
|
||||||
static void settings_displayCalibrateVIN(void);
|
static void settings_displayCalibrateVIN(void);
|
||||||
|
|
||||||
bool settingsResetRequest = false;
|
const menuitem settingsMenu[] = {
|
||||||
const menuitem settingsMenu[] = { /*Struct used for all settings options in the settings menu*/
|
/*Struct used for all settings options in the settings menu*/
|
||||||
{ (const char*) SettingsLongNames[0], { settings_setInputVRange }, { settings_displayInputVRange } },/*Voltage input*/
|
{(const char*)SettingsLongNames[0],
|
||||||
{ (const char*) SettingsLongNames[1], { settings_setSleepTemp }, { settings_displaySleepTemp } }, /*Sleep Temp*/
|
{settings_setInputVRange},
|
||||||
{ (const char*) SettingsLongNames[2], { settings_setSleepTime }, { settings_displaySleepTime } }, /*Sleep Time*/
|
{settings_displayInputVRange}}, /*Voltage input*/
|
||||||
{ (const char*) SettingsLongNames[3], { settings_setShutdownTime }, { settings_displayShutdownTime } }, /*Shutdown Time*/
|
{(const char*)SettingsLongNames[1],
|
||||||
{ (const char*) SettingsLongNames[4], { settings_setSensitivity }, { settings_displaySensitivity } },/* Motion Sensitivity*/
|
{settings_setSleepTemp},
|
||||||
{ (const char*) SettingsLongNames[5], { settings_setTempF }, { settings_displayTempF } },/* Motion Sensitivity*/
|
{settings_displaySleepTemp}}, /*Sleep Temp*/
|
||||||
{ (const char*) SettingsLongNames[6], { settings_setAdvancedIDLEScreens }, { settings_displayAdvancedIDLEScreens } },/* Advanced screens*/
|
{(const char*)SettingsLongNames[2],
|
||||||
{ (const char*) SettingsLongNames[15], { settings_setAdvancedSolderingScreens }, { settings_displayAdvancedSolderingScreens } },/* Advanced screens*/
|
{settings_setSleepTime},
|
||||||
{ (const char*) SettingsLongNames[7], { settings_setDisplayRotation }, { settings_displayDisplayRotation } }, /*Display Rotation*/
|
{settings_displaySleepTime}}, /*Sleep Time*/
|
||||||
{ (const char*) SettingsLongNames[8], { settings_setBoostModeEnabled }, { settings_displayBoostModeEnabled } }, /*Enable Boost*/
|
{(const char*)SettingsLongNames[3],
|
||||||
{ (const char*) SettingsLongNames[9], { settings_setBoostTemp }, { settings_displayBoostTemp } }, /*Boost Temp*/
|
{settings_setShutdownTime},
|
||||||
{ (const char*) SettingsLongNames[10], { settings_setAutomaticStartMode }, { settings_displayAutomaticStartMode } },/*Auto start*/
|
{settings_displayShutdownTime}}, /*Shutdown Time*/
|
||||||
{ (const char*) SettingsLongNames[11], { settings_setCoolingBlinkEnabled }, { settings_displayCoolingBlinkEnabled } }, /*Cooling blink warning*/
|
{(const char*)SettingsLongNames[4],
|
||||||
{ (const char*) SettingsLongNames[12], { settings_setCalibrate }, { settings_displayCalibrate } }, /*Calibrate tip*/
|
{settings_setSensitivity},
|
||||||
{ (const char*) SettingsLongNames[13], { settings_setResetSettings }, { settings_displayResetSettings } }, /*Resets settings*/
|
{settings_displaySensitivity}}, /* Motion Sensitivity*/
|
||||||
{ (const char*) SettingsLongNames[14], { settings_setCalibrateVIN }, { settings_displayCalibrateVIN } }, /*Voltage input cal*/
|
{(const char*)SettingsLongNames[5],
|
||||||
|
{settings_setTempF},
|
||||||
|
{settings_displayTempF}}, /* Motion Sensitivity*/
|
||||||
|
{(const char*)SettingsLongNames[6],
|
||||||
|
{settings_setAdvancedIDLEScreens},
|
||||||
|
{settings_displayAdvancedIDLEScreens}}, /* Advanced screens*/
|
||||||
|
{(const char*)SettingsLongNames[15],
|
||||||
|
{settings_setAdvancedSolderingScreens},
|
||||||
|
{settings_displayAdvancedSolderingScreens}}, /* Advanced screens*/
|
||||||
|
{(const char*)SettingsLongNames[7],
|
||||||
|
{settings_setDisplayRotation},
|
||||||
|
{settings_displayDisplayRotation}}, /*Display Rotation*/
|
||||||
|
{(const char*)SettingsLongNames[8],
|
||||||
|
{settings_setBoostModeEnabled},
|
||||||
|
{settings_displayBoostModeEnabled}}, /*Enable Boost*/
|
||||||
|
{(const char*)SettingsLongNames[9],
|
||||||
|
{settings_setBoostTemp},
|
||||||
|
{settings_displayBoostTemp}}, /*Boost Temp*/
|
||||||
|
{(const char*)SettingsLongNames[10],
|
||||||
|
{settings_setAutomaticStartMode},
|
||||||
|
{settings_displayAutomaticStartMode}}, /*Auto start*/
|
||||||
|
{(const char*)SettingsLongNames[11],
|
||||||
|
{settings_setCoolingBlinkEnabled},
|
||||||
|
{settings_displayCoolingBlinkEnabled}}, /*Cooling blink warning*/
|
||||||
|
{(const char*)SettingsLongNames[12],
|
||||||
|
{settings_setCalibrate},
|
||||||
|
{settings_displayCalibrate}}, /*Calibrate tip*/
|
||||||
|
{(const char*)SettingsLongNames[13],
|
||||||
|
{settings_setResetSettings},
|
||||||
|
{settings_displayResetSettings}}, /*Resets settings*/
|
||||||
|
{(const char*)SettingsLongNames[14],
|
||||||
|
{settings_setCalibrateVIN},
|
||||||
|
{settings_displayCalibrateVIN}}, /*Voltage input cal*/
|
||||||
{NULL, {NULL}, {NULL}} // end of menu marker. DO NOT REMOVE
|
{NULL, {NULL}, {NULL}} // end of menu marker. DO NOT REMOVE
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
static void printShortDescriptionSingleLine(uint32_t shortDescIndex) {
|
static void printShortDescriptionSingleLine(uint32_t shortDescIndex) {
|
||||||
lcd.setFont(0);
|
lcd.setFont(0);
|
||||||
lcd.setCharCursor(0, 0);
|
lcd.setCharCursor(0, 0);
|
||||||
@@ -83,14 +115,15 @@ static void printShortDescriptionDoubleLine(uint32_t shortDescIndex) {
|
|||||||
* Prints two small lines of short description
|
* Prints two small lines of short description
|
||||||
* and prepares cursor in big font after it.
|
* and prepares cursor in big font after it.
|
||||||
* @param shortDescIndex Index to of short description.
|
* @param shortDescIndex Index to of short description.
|
||||||
* @param cursorCharPosition Custom cursor char position to set after printing description.
|
* @param cursorCharPosition Custom cursor char position to set after printing
|
||||||
|
* description.
|
||||||
*/
|
*/
|
||||||
static void printShortDescription(uint32_t shortDescIndex, uint16_t cursorCharPosition) {
|
static void printShortDescription(uint32_t shortDescIndex,
|
||||||
|
uint16_t cursorCharPosition) {
|
||||||
// print short description (default single line, explicit double line)
|
// print short description (default single line, explicit double line)
|
||||||
if (SettingsShortNameType == SHORT_NAME_DOUBLE_LINE) {
|
if (SettingsShortNameType == SHORT_NAME_DOUBLE_LINE) {
|
||||||
printShortDescriptionDoubleLine(shortDescIndex);
|
printShortDescriptionDoubleLine(shortDescIndex);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
printShortDescriptionSingleLine(shortDescIndex);
|
printShortDescriptionSingleLine(shortDescIndex);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -99,6 +132,41 @@ static void printShortDescription(uint32_t shortDescIndex, uint16_t cursorCharPo
|
|||||||
lcd.setCharCursor(cursorCharPosition, 0);
|
lcd.setCharCursor(cursorCharPosition, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int userConfirmation(const char* message) {
|
||||||
|
uint8_t maxOffset = strlen(message) + 7;
|
||||||
|
uint32_t messageStart = HAL_GetTick();
|
||||||
|
|
||||||
|
lcd.setFont(0);
|
||||||
|
lcd.setCursor(0, 0);
|
||||||
|
|
||||||
|
for (;;) {
|
||||||
|
int16_t messageOffset = (((HAL_GetTick() - messageStart) / 150) % maxOffset);
|
||||||
|
|
||||||
|
lcd.clearScreen();
|
||||||
|
lcd.setCursor(12 * (7 - messageOffset), 0);
|
||||||
|
lcd.print(message);
|
||||||
|
|
||||||
|
ButtonState buttons = getButtonState();
|
||||||
|
switch (buttons) {
|
||||||
|
case BUTTON_F_SHORT:
|
||||||
|
//User confirmed
|
||||||
|
return 1;
|
||||||
|
|
||||||
|
case BUTTON_BOTH:
|
||||||
|
case BUTTON_B_SHORT:
|
||||||
|
case BUTTON_F_LONG:
|
||||||
|
case BUTTON_B_LONG:
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
case BUTTON_NONE:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
lcd.refresh();
|
||||||
|
osDelay(50);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static void settings_setInputVRange(void) {
|
static void settings_setInputVRange(void) {
|
||||||
systemSettings.cutoutSetting = (systemSettings.cutoutSetting + 1) % 5;
|
systemSettings.cutoutSetting = (systemSettings.cutoutSetting + 1) % 5;
|
||||||
@@ -110,8 +178,7 @@ static void settings_displayInputVRange(void) {
|
|||||||
if (systemSettings.cutoutSetting) {
|
if (systemSettings.cutoutSetting) {
|
||||||
lcd.drawChar('0' + 2 + systemSettings.cutoutSetting);
|
lcd.drawChar('0' + 2 + systemSettings.cutoutSetting);
|
||||||
lcd.drawChar('S');
|
lcd.drawChar('S');
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
lcd.print("DC");
|
lcd.print("DC");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -119,8 +186,7 @@ static void settings_displayInputVRange(void) {
|
|||||||
|
|
||||||
static void settings_setSleepTemp(void) {
|
static void settings_setSleepTemp(void) {
|
||||||
systemSettings.SleepTemp += 10;
|
systemSettings.SleepTemp += 10;
|
||||||
if (systemSettings.SleepTemp > 300)
|
if (systemSettings.SleepTemp > 300) systemSettings.SleepTemp = 50;
|
||||||
systemSettings.SleepTemp = 50;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void settings_displaySleepTemp(void) {
|
static void settings_displaySleepTemp(void) {
|
||||||
@@ -143,8 +209,7 @@ static void settings_displaySleepTime(void) {
|
|||||||
if (systemSettings.SleepTime < 6) {
|
if (systemSettings.SleepTime < 6) {
|
||||||
lcd.printNumber(systemSettings.SleepTime * 10, 2);
|
lcd.printNumber(systemSettings.SleepTime * 10, 2);
|
||||||
lcd.drawChar('S');
|
lcd.drawChar('S');
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
lcd.printNumber(systemSettings.SleepTime - 5, 2);
|
lcd.printNumber(systemSettings.SleepTime - 5, 2);
|
||||||
lcd.drawChar('M');
|
lcd.drawChar('M');
|
||||||
}
|
}
|
||||||
@@ -171,11 +236,7 @@ static void settings_setTempF(void) {
|
|||||||
static void settings_displayTempF(void) {
|
static void settings_displayTempF(void) {
|
||||||
printShortDescription(5, 7);
|
printShortDescription(5, 7);
|
||||||
|
|
||||||
lcd.drawChar(
|
lcd.drawChar((systemSettings.temperatureInF) ? 'F' : 'C');
|
||||||
(systemSettings.temperatureInF)
|
|
||||||
? 'F'
|
|
||||||
: 'C'
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -197,11 +258,7 @@ static void settings_setAdvancedSolderingScreens(void) {
|
|||||||
static void settings_displayAdvancedSolderingScreens(void) {
|
static void settings_displayAdvancedSolderingScreens(void) {
|
||||||
printShortDescription(15, 7);
|
printShortDescription(15, 7);
|
||||||
|
|
||||||
lcd.drawChar(
|
lcd.drawCheckbox(systemSettings.detailedSoldering);
|
||||||
(systemSettings.detailedSoldering)
|
|
||||||
? SettingTrueChar
|
|
||||||
: SettingFalseChar
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -212,11 +269,7 @@ static void settings_setAdvancedIDLEScreens(void) {
|
|||||||
static void settings_displayAdvancedIDLEScreens(void) {
|
static void settings_displayAdvancedIDLEScreens(void) {
|
||||||
printShortDescription(6, 7);
|
printShortDescription(6, 7);
|
||||||
|
|
||||||
lcd.drawChar(
|
lcd.drawCheckbox(systemSettings.detailedIDLE);
|
||||||
(systemSettings.detailedIDLE)
|
|
||||||
? SettingTrueChar
|
|
||||||
: SettingFalseChar
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -238,6 +291,9 @@ static void settings_displayDisplayRotation(void) {
|
|||||||
case 2:
|
case 2:
|
||||||
lcd.drawChar(SettingAutoChar);
|
lcd.drawChar(SettingAutoChar);
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
lcd.drawChar(SettingRightChar);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -249,11 +305,7 @@ static void settings_setBoostModeEnabled(void) {
|
|||||||
static void settings_displayBoostModeEnabled(void) {
|
static void settings_displayBoostModeEnabled(void) {
|
||||||
printShortDescription(8, 7);
|
printShortDescription(8, 7);
|
||||||
|
|
||||||
lcd.drawChar(
|
lcd.drawCheckbox(systemSettings.boostModeEnabled);
|
||||||
(systemSettings.boostModeEnabled)
|
|
||||||
? SettingTrueChar
|
|
||||||
: SettingFalseChar
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -263,8 +315,7 @@ static void settings_setBoostTemp(void) {
|
|||||||
if (systemSettings.BoostTemp > 850) {
|
if (systemSettings.BoostTemp > 850) {
|
||||||
systemSettings.BoostTemp = 480; // loop back at 250
|
systemSettings.BoostTemp = 480; // loop back at 250
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
if (systemSettings.BoostTemp > 450) {
|
if (systemSettings.BoostTemp > 450) {
|
||||||
systemSettings.BoostTemp = 250; // loop back at 250
|
systemSettings.BoostTemp = 250; // loop back at 250
|
||||||
}
|
}
|
||||||
@@ -285,11 +336,7 @@ static void settings_setAutomaticStartMode(void) {
|
|||||||
static void settings_displayAutomaticStartMode(void) {
|
static void settings_displayAutomaticStartMode(void) {
|
||||||
printShortDescription(10, 7);
|
printShortDescription(10, 7);
|
||||||
|
|
||||||
lcd.drawChar(
|
lcd.drawCheckbox(systemSettings.autoStartMode);
|
||||||
(systemSettings.autoStartMode)
|
|
||||||
? SettingTrueChar
|
|
||||||
: SettingFalseChar
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -300,47 +347,30 @@ static void settings_setCoolingBlinkEnabled(void) {
|
|||||||
static void settings_displayCoolingBlinkEnabled(void) {
|
static void settings_displayCoolingBlinkEnabled(void) {
|
||||||
printShortDescription(11, 7);
|
printShortDescription(11, 7);
|
||||||
|
|
||||||
lcd.drawChar(
|
lcd.drawCheckbox(systemSettings.coolingTempBlink);
|
||||||
(systemSettings.coolingTempBlink)
|
|
||||||
? SettingTrueChar
|
|
||||||
: SettingFalseChar
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void settings_setResetSettings(void) {
|
static void settings_setResetSettings(void) {
|
||||||
settingsResetRequest = !settingsResetRequest;
|
if(userConfirmation(SettingsResetWarning)) {
|
||||||
|
resetSettings();
|
||||||
|
|
||||||
|
lcd.setFont(0);
|
||||||
|
lcd.setCursor(0, 0);
|
||||||
|
lcd.print("RESET OK");
|
||||||
|
lcd.refresh();
|
||||||
|
|
||||||
|
waitForButtonPressOrTimeout(2000);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void settings_displayResetSettings(void) {
|
static void settings_displayResetSettings(void) {
|
||||||
printShortDescription(13, 7);
|
printShortDescription(13, 7);
|
||||||
|
|
||||||
lcd.drawChar(
|
|
||||||
(settingsResetRequest)
|
|
||||||
? SettingTrueChar
|
|
||||||
: SettingFalseChar
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void settings_setCalibrate(void) {
|
static void settings_setCalibrate(void) {
|
||||||
//Calibrate the offset
|
if(userConfirmation(SettingsCalibrationWarning)) {
|
||||||
//We split off here to confirm with the user
|
|
||||||
uint8_t maxOffset = strlen(SettingsCalibrationWarning) + 5;
|
|
||||||
uint32_t descriptionStart = HAL_GetTick();
|
|
||||||
|
|
||||||
lcd.setFont(0);
|
|
||||||
lcd.clearScreen();
|
|
||||||
lcd.setCursor(0, 0);
|
|
||||||
|
|
||||||
for (;;) {
|
|
||||||
int16_t descriptionOffset = (((HAL_GetTick() - descriptionStart) / 150) % maxOffset);
|
|
||||||
|
|
||||||
lcd.setCursor(12 * (7 - descriptionOffset), 0);
|
|
||||||
lcd.print(SettingsCalibrationWarning);
|
|
||||||
|
|
||||||
ButtonState buttons = getButtonState();
|
|
||||||
switch (buttons) {
|
|
||||||
case BUTTON_F_SHORT: {
|
|
||||||
//User confirmed
|
//User confirmed
|
||||||
//So we now perform the actual calculation
|
//So we now perform the actual calculation
|
||||||
lcd.clearScreen();
|
lcd.clearScreen();
|
||||||
@@ -363,21 +393,6 @@ static void settings_setCalibrate(void) {
|
|||||||
systemSettings.CalibrationOffset = rawTempC;
|
systemSettings.CalibrationOffset = rawTempC;
|
||||||
setCalibrationOffset(rawTempC); //store the error
|
setCalibrationOffset(rawTempC); //store the error
|
||||||
osDelay(100);
|
osDelay(100);
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
case BUTTON_BOTH:
|
|
||||||
case BUTTON_B_SHORT:
|
|
||||||
case BUTTON_F_LONG:
|
|
||||||
case BUTTON_B_LONG:
|
|
||||||
return;
|
|
||||||
|
|
||||||
case BUTTON_NONE:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
lcd.refresh();
|
|
||||||
osDelay(50);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -416,6 +431,7 @@ static void settings_setCalibrateVIN(void) {
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
case BUTTON_NONE:
|
case BUTTON_NONE:
|
||||||
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -425,8 +441,7 @@ static void settings_setCalibrateVIN(void) {
|
|||||||
// Cap to sensible values
|
// Cap to sensible values
|
||||||
if (systemSettings.voltageDiv < 90) {
|
if (systemSettings.voltageDiv < 90) {
|
||||||
systemSettings.voltageDiv = 90;
|
systemSettings.voltageDiv = 90;
|
||||||
}
|
} else if (systemSettings.voltageDiv > 130) {
|
||||||
else if (systemSettings.voltageDiv > 130) {
|
|
||||||
systemSettings.voltageDiv = 130;
|
systemSettings.voltageDiv = 130;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,14 +1,14 @@
|
|||||||
// By Ben V. Brown - V2.0 of the TS100 firmware
|
// By Ben V. Brown - V2.0 of the TS100 firmware
|
||||||
#include <main.hpp>
|
|
||||||
#include <MMA8652FC.hpp>
|
#include <MMA8652FC.hpp>
|
||||||
#include "stm32f1xx_hal.h"
|
#include <main.hpp>
|
||||||
#include "cmsis_os.h"
|
|
||||||
#include "OLED.hpp"
|
#include "OLED.hpp"
|
||||||
#include "Settings.h"
|
#include "Settings.h"
|
||||||
#include "Translation.h"
|
#include "Translation.h"
|
||||||
#include "string.h"
|
#include "cmsis_os.h"
|
||||||
#include "gui.h"
|
#include "gui.h"
|
||||||
#include "stdlib.h"
|
#include "stdlib.h"
|
||||||
|
#include "stm32f1xx_hal.h"
|
||||||
|
#include "string.h"
|
||||||
|
|
||||||
// C++ objects
|
// C++ objects
|
||||||
OLED lcd(&hi2c1);
|
OLED lcd(&hi2c1);
|
||||||
@@ -35,13 +35,15 @@ void startRotationTask(void const * argument);
|
|||||||
|
|
||||||
// Main inits hardware then hands over to the FreeRTOS kernel
|
// Main inits hardware then hands over to the FreeRTOS kernel
|
||||||
int main(void) {
|
int main(void) {
|
||||||
/* Reset of all peripherals, Initializes the Flash interface and the Systick. */
|
/* Reset of all peripherals, Initializes the Flash interface and the Systick.
|
||||||
|
*/
|
||||||
HAL_Init();
|
HAL_Init();
|
||||||
Setup_HAL(); // Setup all the HAL objects
|
Setup_HAL(); // Setup all the HAL objects
|
||||||
setTipPWM(0);
|
setTipPWM(0);
|
||||||
lcd.initialize(); // start up the LCD
|
lcd.initialize(); // start up the LCD
|
||||||
lcd.setFont(0); // default to bigger font
|
lcd.setFont(0); // default to bigger font
|
||||||
accel.initalize(); //this sets up the I2C registers and loads up the default settings
|
accel.initalize(); // this sets up the I2C registers and loads up the default
|
||||||
|
// settings
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
restoreSettings(); // load the settings from flash
|
restoreSettings(); // load the settings from flash
|
||||||
setCalibrationOffset(systemSettings.CalibrationOffset);
|
setCalibrationOffset(systemSettings.CalibrationOffset);
|
||||||
@@ -63,8 +65,10 @@ int main(void) {
|
|||||||
MOVTaskHandle = osThreadCreate(osThread(MOVTask), NULL);
|
MOVTaskHandle = osThreadCreate(osThread(MOVTask), NULL);
|
||||||
|
|
||||||
/* Create the objects*/
|
/* Create the objects*/
|
||||||
rotationChangedSemaphore = xSemaphoreCreateBinary(); // Used to unlock rotation thread
|
rotationChangedSemaphore =
|
||||||
accelDataAvailableSemaphore = xSemaphoreCreateBinary(); // Used to unlock the movement thread
|
xSemaphoreCreateBinary(); // Used to unlock rotation thread
|
||||||
|
accelDataAvailableSemaphore =
|
||||||
|
xSemaphoreCreateBinary(); // Used to unlock the movement thread
|
||||||
/* Start scheduler */
|
/* Start scheduler */
|
||||||
osKernelStart();
|
osKernelStart();
|
||||||
|
|
||||||
@@ -88,7 +92,6 @@ void gui_drawTipTemp() {
|
|||||||
// Temp = systemSettings.SolderingTemp;
|
// Temp = systemSettings.SolderingTemp;
|
||||||
|
|
||||||
lcd.printNumber(Temp, 3); // Draw the tip temp out finally
|
lcd.printNumber(Temp, 3); // Draw the tip temp out finally
|
||||||
|
|
||||||
}
|
}
|
||||||
ButtonState getButtonState() {
|
ButtonState getButtonState() {
|
||||||
/*
|
/*
|
||||||
@@ -96,25 +99,26 @@ ButtonState getButtonState() {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If the previous state was 00 Then we want to latch the new state if different & update time
|
* If the previous state was 00 Then we want to latch the new state if
|
||||||
* If the previous state was !00 Then we want to search if we trigger long press (buttons still down), or if release we trigger press (downtime>filter)
|
* different & update time
|
||||||
|
* If the previous state was !00 Then we want to search if we trigger long
|
||||||
|
* press (buttons still down), or if release we trigger press
|
||||||
|
* (downtime>filter)
|
||||||
*/
|
*/
|
||||||
static uint8_t previousState = 0;
|
static uint8_t previousState = 0;
|
||||||
static uint32_t previousStateChange = 0;
|
static uint32_t previousStateChange = 0;
|
||||||
const uint16_t timeout = 400;
|
const uint16_t timeout = 400;
|
||||||
uint8_t currentState;
|
uint8_t currentState;
|
||||||
currentState = (
|
currentState =
|
||||||
HAL_GPIO_ReadPin(KEY_A_GPIO_Port, KEY_A_Pin) == GPIO_PIN_RESET ?
|
(HAL_GPIO_ReadPin(KEY_A_GPIO_Port, KEY_A_Pin) == GPIO_PIN_RESET ? 1 : 0)
|
||||||
1 : 0) << 0;
|
<< 0;
|
||||||
currentState |= (
|
currentState |=
|
||||||
HAL_GPIO_ReadPin(KEY_B_GPIO_Port, KEY_B_Pin) == GPIO_PIN_RESET ?
|
(HAL_GPIO_ReadPin(KEY_B_GPIO_Port, KEY_B_Pin) == GPIO_PIN_RESET ? 1 : 0)
|
||||||
1 : 0) << 1;
|
<< 1;
|
||||||
|
|
||||||
if (currentState)
|
if (currentState) lastButtonTime = HAL_GetTick();
|
||||||
lastButtonTime = HAL_GetTick();
|
|
||||||
if (currentState == previousState) {
|
if (currentState == previousState) {
|
||||||
if (currentState == 0)
|
if (currentState == 0) return BUTTON_NONE;
|
||||||
return BUTTON_NONE;
|
|
||||||
if ((HAL_GetTick() - previousStateChange) > timeout) {
|
if ((HAL_GetTick() - previousStateChange) > timeout) {
|
||||||
// User has been holding the button down
|
// User has been holding the button down
|
||||||
// We want to send a buttong is held message
|
// We want to send a buttong is held message
|
||||||
@@ -134,7 +138,8 @@ ButtonState getButtonState() {
|
|||||||
|
|
||||||
} else {
|
} else {
|
||||||
// User has released buttons
|
// User has released buttons
|
||||||
// If they previously had the buttons down we want to check if they were < long hold and trigger a press
|
// If they previously had the buttons down we want to check if they were <
|
||||||
|
// long hold and trigger a press
|
||||||
if ((HAL_GetTick() - previousStateChange) < timeout) {
|
if ((HAL_GetTick() - previousStateChange) < timeout) {
|
||||||
// The user didn't hold the button for long
|
// The user didn't hold the button for long
|
||||||
// So we send button press
|
// So we send button press
|
||||||
@@ -146,7 +151,6 @@ ButtonState getButtonState() {
|
|||||||
else
|
else
|
||||||
retVal = BUTTON_BOTH; // Both being held case
|
retVal = BUTTON_BOTH; // Both being held case
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
previousState = currentState;
|
previousState = currentState;
|
||||||
previousStateChange = HAL_GetTick();
|
previousStateChange = HAL_GetTick();
|
||||||
@@ -172,18 +176,16 @@ static void waitForButtonPress() {
|
|||||||
lcd.refresh();
|
lcd.refresh();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
static void waitForButtonPressOrTimeout(uint32_t timeout) {
|
|
||||||
|
void waitForButtonPressOrTimeout(uint32_t timeout) {
|
||||||
timeout += HAL_GetTick();
|
timeout += HAL_GetTick();
|
||||||
// Make timeout our exit value
|
// Make timeout our exit value
|
||||||
for (;;) {
|
for (;;) {
|
||||||
ButtonState buttons = getButtonState();
|
ButtonState buttons = getButtonState();
|
||||||
if (buttons)
|
if (buttons) return;
|
||||||
return;
|
if (HAL_GetTick() > timeout) return;
|
||||||
if (HAL_GetTick() > timeout)
|
|
||||||
return;
|
|
||||||
GUIDelay();
|
GUIDelay();
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -198,11 +200,9 @@ static bool checkVoltageForExit() {
|
|||||||
lcd.print("Undervoltage");
|
lcd.print("Undervoltage");
|
||||||
lcd.setCursor(0, 8);
|
lcd.setCursor(0, 8);
|
||||||
lcd.print("Input V: ");
|
lcd.print("Input V: ");
|
||||||
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) / 10,
|
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) / 10, 2);
|
||||||
2);
|
|
||||||
lcd.drawChar('.');
|
lcd.drawChar('.');
|
||||||
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) % 10,
|
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) % 10, 1);
|
||||||
1);
|
|
||||||
lcd.print("V");
|
lcd.print("V");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
@@ -222,19 +222,15 @@ static void gui_drawBatteryIcon() {
|
|||||||
// User is on a lithium battery
|
// User is on a lithium battery
|
||||||
// we need to calculate which of the 10 levels they are on
|
// we need to calculate which of the 10 levels they are on
|
||||||
uint8_t cellCount = systemSettings.cutoutSetting + 2;
|
uint8_t cellCount = systemSettings.cutoutSetting + 2;
|
||||||
uint16_t cellV = getInputVoltageX10(systemSettings.voltageDiv)
|
uint16_t cellV = getInputVoltageX10(systemSettings.voltageDiv) / cellCount;
|
||||||
/ cellCount;
|
|
||||||
// Should give us approx cell voltage X10
|
// Should give us approx cell voltage X10
|
||||||
// Range is 42 -> 33 = 9 steps therefore we will use battery 1-10
|
// Range is 42 -> 33 = 9 steps therefore we will use battery 1-10
|
||||||
if (cellV < 33)
|
if (cellV < 33) cellV = 33;
|
||||||
cellV = 33;
|
|
||||||
cellV -= 33; // Should leave us a number of 0-9
|
cellV -= 33; // Should leave us a number of 0-9
|
||||||
if (cellV > 9)
|
if (cellV > 9) cellV = 9;
|
||||||
cellV = 9;
|
|
||||||
lcd.drawBattery(cellV + 1);
|
lcd.drawBattery(cellV + 1);
|
||||||
} else
|
} else
|
||||||
lcd.drawSymbol(16); // Draw the DC Logo
|
lcd.drawSymbol(16); // Draw the DC Logo
|
||||||
|
|
||||||
}
|
}
|
||||||
static void gui_solderingTempAdjust() {
|
static void gui_solderingTempAdjust() {
|
||||||
uint32_t lastChange = HAL_GetTick();
|
uint32_t lastChange = HAL_GetTick();
|
||||||
@@ -244,8 +240,7 @@ static void gui_solderingTempAdjust() {
|
|||||||
lcd.clearScreen();
|
lcd.clearScreen();
|
||||||
lcd.setFont(0);
|
lcd.setFont(0);
|
||||||
ButtonState buttons = getButtonState();
|
ButtonState buttons = getButtonState();
|
||||||
if (buttons)
|
if (buttons) lastChange = HAL_GetTick();
|
||||||
lastChange = HAL_GetTick();
|
|
||||||
switch (buttons) {
|
switch (buttons) {
|
||||||
case BUTTON_NONE:
|
case BUTTON_NONE:
|
||||||
// stay
|
// stay
|
||||||
@@ -274,6 +269,8 @@ static void gui_solderingTempAdjust() {
|
|||||||
systemSettings.SolderingTemp -= 10; // sub 10
|
systemSettings.SolderingTemp -= 10; // sub 10
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
// constrain between 50-450 C
|
// constrain between 50-450 C
|
||||||
if (systemSettings.temperatureInF) {
|
if (systemSettings.temperatureInF) {
|
||||||
@@ -288,8 +285,7 @@ static void gui_solderingTempAdjust() {
|
|||||||
if (systemSettings.SolderingTemp < 120)
|
if (systemSettings.SolderingTemp < 120)
|
||||||
systemSettings.SolderingTemp = 120;
|
systemSettings.SolderingTemp = 120;
|
||||||
} else {
|
} else {
|
||||||
if (systemSettings.SolderingTemp < 50)
|
if (systemSettings.SolderingTemp < 50) systemSettings.SolderingTemp = 50;
|
||||||
systemSettings.SolderingTemp = 50;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (HAL_GetTick() - lastChange > 1500)
|
if (HAL_GetTick() - lastChange > 1500)
|
||||||
@@ -311,11 +307,10 @@ static void gui_settingsMenu() {
|
|||||||
// Draw the settings menu and provide iteration support etc
|
// Draw the settings menu and provide iteration support etc
|
||||||
uint8_t currentScreen = 0;
|
uint8_t currentScreen = 0;
|
||||||
uint32_t autoRepeatTimer = 0;
|
uint32_t autoRepeatTimer = 0;
|
||||||
settingsResetRequest = false;
|
|
||||||
bool earlyExit = false;
|
bool earlyExit = false;
|
||||||
uint32_t descriptionStart = 0;
|
uint32_t descriptionStart = 0;
|
||||||
while ((settingsMenu[currentScreen].incrementHandler.func != NULL)
|
while ((settingsMenu[currentScreen].incrementHandler.func != NULL) &&
|
||||||
&& earlyExit == false) {
|
earlyExit == false) {
|
||||||
lcd.setFont(0);
|
lcd.setFont(0);
|
||||||
lcd.clearScreen();
|
lcd.clearScreen();
|
||||||
lcd.setCursor(0, 0);
|
lcd.setCursor(0, 0);
|
||||||
@@ -326,13 +321,11 @@ static void gui_settingsMenu() {
|
|||||||
} else {
|
} else {
|
||||||
// Draw description
|
// Draw description
|
||||||
// draw string starting from descriptionOffset
|
// draw string starting from descriptionOffset
|
||||||
int16_t maxOffset = strlen(settingsMenu[currentScreen].description)
|
int16_t maxOffset = strlen(settingsMenu[currentScreen].description) + 7;
|
||||||
+ 5;
|
if (descriptionStart == 0) descriptionStart = HAL_GetTick();
|
||||||
if (descriptionStart == 0)
|
|
||||||
descriptionStart = HAL_GetTick();
|
|
||||||
|
|
||||||
int16_t descriptionOffset = (((HAL_GetTick() - descriptionStart)
|
int16_t descriptionOffset =
|
||||||
/ 10) % (maxOffset * 12));
|
(((HAL_GetTick() - descriptionStart) / 3) % (maxOffset * 12));
|
||||||
//^ Rolling offset based on time
|
//^ Rolling offset based on time
|
||||||
lcd.setCursor(((7 * 12) - descriptionOffset), 0);
|
lcd.setCursor(((7 * 12) - descriptionOffset), 0);
|
||||||
lcd.print(settingsMenu[currentScreen].description);
|
lcd.print(settingsMenu[currentScreen].description);
|
||||||
@@ -373,21 +366,20 @@ static void gui_settingsMenu() {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case BUTTON_NONE:
|
case BUTTON_NONE:
|
||||||
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
lcd.refresh(); // update the LCD
|
lcd.refresh(); // update the LCD
|
||||||
osDelay(20);
|
osDelay(20);
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
|
|
||||||
}
|
}
|
||||||
if (settingsResetRequest)
|
|
||||||
resetSettings();
|
|
||||||
saveSettings();
|
saveSettings();
|
||||||
}
|
}
|
||||||
|
|
||||||
static int gui_showTipTempWarning() {
|
static int gui_showTipTempWarning() {
|
||||||
for (;;) {
|
for (;;) {
|
||||||
|
|
||||||
uint16_t tipTemp = tipMeasurementToC(getTipRawTemp(0));
|
uint16_t tipTemp = tipMeasurementToC(getTipRawTemp(0));
|
||||||
lcd.clearScreen();
|
lcd.clearScreen();
|
||||||
lcd.setCursor(0, 0);
|
lcd.setCursor(0, 0);
|
||||||
@@ -419,8 +411,7 @@ static int gui_showTipTempWarning() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (systemSettings.coolingTempBlink && tipTemp > 50) {
|
if (systemSettings.coolingTempBlink && tipTemp > 50) {
|
||||||
if (HAL_GetTick() % 500 < 250)
|
if (HAL_GetTick() % 500 < 250) lcd.clearScreen();
|
||||||
lcd.clearScreen();
|
|
||||||
}
|
}
|
||||||
lcd.refresh();
|
lcd.refresh();
|
||||||
ButtonState buttons = getButtonState();
|
ButtonState buttons = getButtonState();
|
||||||
@@ -429,8 +420,7 @@ static int gui_showTipTempWarning() {
|
|||||||
else if (buttons == BUTTON_B_SHORT || buttons == BUTTON_BOTH)
|
else if (buttons == BUTTON_B_SHORT || buttons == BUTTON_BOTH)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
if (tipTemp < 30)
|
if (tipTemp < 30) return 0;
|
||||||
return 0;
|
|
||||||
|
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
GUIDelay();
|
GUIDelay();
|
||||||
@@ -447,22 +437,18 @@ static int gui_SolderingSleepingMode() {
|
|||||||
|
|
||||||
for (;;) {
|
for (;;) {
|
||||||
ButtonState buttons = getButtonState();
|
ButtonState buttons = getButtonState();
|
||||||
if (buttons)
|
if (buttons) return 0;
|
||||||
return 0;
|
if ((HAL_GetTick() - lastMovementTime < 1000) ||
|
||||||
if ((HAL_GetTick() - lastMovementTime < 1000)
|
(HAL_GetTick() - lastButtonTime < 1000))
|
||||||
|| (HAL_GetTick() - lastButtonTime < 1000))
|
|
||||||
return 0; // user moved or pressed a button, go back to soldering
|
return 0; // user moved or pressed a button, go back to soldering
|
||||||
if (checkVoltageForExit())
|
if (checkVoltageForExit()) return 1; // return non-zero on error
|
||||||
return 1; //return non-zero on error
|
|
||||||
|
|
||||||
if (systemSettings.temperatureInF)
|
if (systemSettings.temperatureInF)
|
||||||
currentlyActiveTemperatureTarget = ftoTipMeasurement(
|
currentlyActiveTemperatureTarget = ftoTipMeasurement(
|
||||||
min(systemSettings.SleepTemp,
|
min(systemSettings.SleepTemp, systemSettings.SolderingTemp));
|
||||||
systemSettings.SolderingTemp));
|
|
||||||
else
|
else
|
||||||
currentlyActiveTemperatureTarget = ctoTipMeasurement(
|
currentlyActiveTemperatureTarget = ctoTipMeasurement(
|
||||||
min(systemSettings.SleepTemp,
|
min(systemSettings.SleepTemp, systemSettings.SolderingTemp));
|
||||||
systemSettings.SolderingTemp));
|
|
||||||
// draw the lcd
|
// draw the lcd
|
||||||
uint16_t tipTemp;
|
uint16_t tipTemp;
|
||||||
if (systemSettings.temperatureInF)
|
if (systemSettings.temperatureInF)
|
||||||
@@ -484,11 +470,9 @@ static int gui_SolderingSleepingMode() {
|
|||||||
lcd.print("C");
|
lcd.print("C");
|
||||||
|
|
||||||
lcd.print(" ");
|
lcd.print(" ");
|
||||||
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) / 10,
|
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) / 10, 2);
|
||||||
2);
|
|
||||||
lcd.drawChar('.');
|
lcd.drawChar('.');
|
||||||
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) % 10,
|
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) % 10, 1);
|
||||||
1);
|
|
||||||
lcd.drawChar('V');
|
lcd.drawChar('V');
|
||||||
} else {
|
} else {
|
||||||
lcd.setFont(0);
|
lcd.setFont(0);
|
||||||
@@ -501,8 +485,8 @@ static int gui_SolderingSleepingMode() {
|
|||||||
}
|
}
|
||||||
if (systemSettings.ShutdownTime) // only allow shutdown exit if time > 0
|
if (systemSettings.ShutdownTime) // only allow shutdown exit if time > 0
|
||||||
if (lastMovementTime)
|
if (lastMovementTime)
|
||||||
if (((uint32_t) (HAL_GetTick() - lastMovementTime))
|
if (((uint32_t)(HAL_GetTick() - lastMovementTime)) >
|
||||||
> (uint32_t) (systemSettings.ShutdownTime * 60 * 1000)) {
|
(uint32_t)(systemSettings.ShutdownTime * 60 * 1000)) {
|
||||||
// shutdown
|
// shutdown
|
||||||
currentlyActiveTemperatureTarget = 0;
|
currentlyActiveTemperatureTarget = 0;
|
||||||
return 1; // we want to exit soldering mode
|
return 1; // we want to exit soldering mode
|
||||||
@@ -510,7 +494,6 @@ static int gui_SolderingSleepingMode() {
|
|||||||
lcd.refresh();
|
lcd.refresh();
|
||||||
GUIDelay();
|
GUIDelay();
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
static void gui_solderingMode() {
|
static void gui_solderingMode() {
|
||||||
@@ -522,7 +505,8 @@ static void gui_solderingMode() {
|
|||||||
* ---> Use buttons to change forward and back on temperature
|
* ---> Use buttons to change forward and back on temperature
|
||||||
* ---> Both buttons or timeout for exiting
|
* ---> Both buttons or timeout for exiting
|
||||||
* --> Long hold front button to enter boost mode
|
* --> Long hold front button to enter boost mode
|
||||||
* ---> Just temporarily sets the system into the alternate temperature for PID control
|
* ---> Just temporarily sets the system into the alternate temperature for
|
||||||
|
* PID control
|
||||||
* --> Long hold back button to exit
|
* --> Long hold back button to exit
|
||||||
* --> Double button to exit
|
* --> Double button to exit
|
||||||
*/
|
*/
|
||||||
@@ -550,8 +534,7 @@ static void gui_solderingMode() {
|
|||||||
break;
|
break;
|
||||||
case BUTTON_F_LONG:
|
case BUTTON_F_LONG:
|
||||||
// if boost mode is enabled turn it on
|
// if boost mode is enabled turn it on
|
||||||
if (systemSettings.boostModeEnabled)
|
if (systemSettings.boostModeEnabled) boostModeOn = true;
|
||||||
boostModeOn = true;
|
|
||||||
break;
|
break;
|
||||||
case BUTTON_F_SHORT:
|
case BUTTON_F_SHORT:
|
||||||
case BUTTON_B_SHORT: {
|
case BUTTON_B_SHORT: {
|
||||||
@@ -560,7 +543,8 @@ static void gui_solderingMode() {
|
|||||||
if (oldTemp != systemSettings.SolderingTemp) {
|
if (oldTemp != systemSettings.SolderingTemp) {
|
||||||
saveSettings(); // only save on change
|
saveSettings(); // only save on change
|
||||||
}
|
}
|
||||||
}
|
} break;
|
||||||
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
// else we update the screen information
|
// else we update the screen information
|
||||||
@@ -601,7 +585,6 @@ static void gui_solderingMode() {
|
|||||||
else
|
else
|
||||||
lcd.drawSymbol(15);
|
lcd.drawSymbol(15);
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
// Draw heating/cooling symbols
|
// Draw heating/cooling symbols
|
||||||
// If tip PWM > 10% then we are 'heating'
|
// If tip PWM > 10% then we are 'heating'
|
||||||
if (getTipPWM() > 10)
|
if (getTipPWM() > 10)
|
||||||
@@ -631,19 +614,19 @@ static void gui_solderingMode() {
|
|||||||
// Update the setpoints for the temperature
|
// Update the setpoints for the temperature
|
||||||
if (boostModeOn) {
|
if (boostModeOn) {
|
||||||
if (systemSettings.temperatureInF)
|
if (systemSettings.temperatureInF)
|
||||||
currentlyActiveTemperatureTarget = ftoTipMeasurement(
|
currentlyActiveTemperatureTarget =
|
||||||
systemSettings.BoostTemp);
|
ftoTipMeasurement(systemSettings.BoostTemp);
|
||||||
else
|
else
|
||||||
currentlyActiveTemperatureTarget = ctoTipMeasurement(
|
currentlyActiveTemperatureTarget =
|
||||||
systemSettings.BoostTemp);
|
ctoTipMeasurement(systemSettings.BoostTemp);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
if (systemSettings.temperatureInF)
|
if (systemSettings.temperatureInF)
|
||||||
currentlyActiveTemperatureTarget = ftoTipMeasurement(
|
currentlyActiveTemperatureTarget =
|
||||||
systemSettings.SolderingTemp);
|
ftoTipMeasurement(systemSettings.SolderingTemp);
|
||||||
else
|
else
|
||||||
currentlyActiveTemperatureTarget = ctoTipMeasurement(
|
currentlyActiveTemperatureTarget =
|
||||||
systemSettings.SolderingTemp);
|
ctoTipMeasurement(systemSettings.SolderingTemp);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Undervoltage test
|
// Undervoltage test
|
||||||
@@ -653,8 +636,8 @@ static void gui_solderingMode() {
|
|||||||
|
|
||||||
lcd.refresh();
|
lcd.refresh();
|
||||||
if (systemSettings.sensitivity)
|
if (systemSettings.sensitivity)
|
||||||
if (HAL_GetTick() - lastMovementTime > sleepThres
|
if (HAL_GetTick() - lastMovementTime > sleepThres &&
|
||||||
&& HAL_GetTick() - lastButtonTime > sleepThres) {
|
HAL_GetTick() - lastButtonTime > sleepThres) {
|
||||||
if (gui_SolderingSleepingMode()) {
|
if (gui_SolderingSleepingMode()) {
|
||||||
return; // If the function returns non-0 then exit
|
return; // If the function returns non-0 then exit
|
||||||
}
|
}
|
||||||
@@ -662,7 +645,6 @@ static void gui_solderingMode() {
|
|||||||
GUIDelay();
|
GUIDelay();
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
#define ACCELDEBUG 0
|
#define ACCELDEBUG 0
|
||||||
/* StartGUITask function */
|
/* StartGUITask function */
|
||||||
@@ -677,7 +659,8 @@ void startGUITask(void const * argument) {
|
|||||||
* ---> Use buttons to change forward and back on temperature
|
* ---> Use buttons to change forward and back on temperature
|
||||||
* ---> Both buttons or timeout for exiting
|
* ---> Both buttons or timeout for exiting
|
||||||
* --> Long hold front button to enter boost mode
|
* --> Long hold front button to enter boost mode
|
||||||
* ---> Just temporarily sets the system into the alternate temperature for PID control
|
* ---> Just temporarily sets the system into the alternate temperature for
|
||||||
|
* PID control
|
||||||
* --> Long hold back button to exit
|
* --> Long hold back button to exit
|
||||||
* --> Double button to exit
|
* --> Double button to exit
|
||||||
* * Settings Menu (gui_settingsMenu)
|
* * Settings Menu (gui_settingsMenu)
|
||||||
@@ -691,13 +674,11 @@ void startGUITask(void const * argument) {
|
|||||||
uint8_t tempWarningState = 0;
|
uint8_t tempWarningState = 0;
|
||||||
|
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
if (showBootLogoIfavailable())
|
if (showBootLogoIfavailable()) waitForButtonPressOrTimeout(2000);
|
||||||
waitForButtonPressOrTimeout(2000);
|
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
if (systemSettings.autoStartMode) {
|
if (systemSettings.autoStartMode) {
|
||||||
// jump directly to the autostart mode
|
// jump directly to the autostart mode
|
||||||
if (systemSettings.autoStartMode == 1)
|
if (systemSettings.autoStartMode == 1) gui_solderingMode();
|
||||||
gui_solderingMode();
|
|
||||||
}
|
}
|
||||||
#if ACCELDEBUG
|
#if ACCELDEBUG
|
||||||
|
|
||||||
@@ -710,8 +691,7 @@ void startGUITask(void const * argument) {
|
|||||||
|
|
||||||
for (;;) {
|
for (;;) {
|
||||||
ButtonState buttons = getButtonState();
|
ButtonState buttons = getButtonState();
|
||||||
if (tempWarningState == 2)
|
if (tempWarningState == 2) buttons = BUTTON_F_SHORT;
|
||||||
buttons = BUTTON_F_SHORT;
|
|
||||||
switch (buttons) {
|
switch (buttons) {
|
||||||
case BUTTON_NONE:
|
case BUTTON_NONE:
|
||||||
// Do nothing
|
// Do nothing
|
||||||
@@ -732,7 +712,6 @@ void startGUITask(void const * argument) {
|
|||||||
lcd.refresh();
|
lcd.refresh();
|
||||||
waitForButtonPress();
|
waitForButtonPress();
|
||||||
lcd.setFont(0); // reset font
|
lcd.setFont(0); // reset font
|
||||||
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case BUTTON_F_LONG:
|
case BUTTON_F_LONG:
|
||||||
@@ -750,23 +729,26 @@ void startGUITask(void const * argument) {
|
|||||||
lcd.displayOnOff(true); // turn lcd on
|
lcd.displayOnOff(true); // turn lcd on
|
||||||
gui_settingsMenu(); // enter the settings menu
|
gui_settingsMenu(); // enter the settings menu
|
||||||
saveSettings();
|
saveSettings();
|
||||||
setCalibrationOffset(systemSettings.CalibrationOffset); //ensure cal offset is applied
|
setCalibrationOffset(
|
||||||
|
systemSettings.CalibrationOffset); // ensure cal offset is applied
|
||||||
|
break;
|
||||||
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
currentlyActiveTemperatureTarget = 0; // ensure tip is off
|
currentlyActiveTemperatureTarget = 0; // ensure tip is off
|
||||||
|
|
||||||
if (systemSettings.sensitivity) {
|
if (systemSettings.sensitivity) {
|
||||||
if ((HAL_GetTick() - lastMovementTime) > 60000
|
if ((HAL_GetTick() - lastMovementTime) > 60000 &&
|
||||||
&& (HAL_GetTick() - lastButtonTime) > 60000)
|
(HAL_GetTick() - lastButtonTime) > 60000)
|
||||||
lcd.displayOnOff(false); // turn lcd off when no movement
|
lcd.displayOnOff(false); // turn lcd off when no movement
|
||||||
else if (HAL_GetTick() - lastMovementTime < 1000
|
else if (HAL_GetTick() - lastMovementTime < 1000 ||
|
||||||
|| HAL_GetTick() - lastButtonTime < 1000) /*Use short time for test, and prevent lots of I2C writes for no need*/
|
HAL_GetTick() - lastButtonTime <
|
||||||
|
1000) /*Use short time for test, and prevent lots of I2C
|
||||||
|
writes for no need*/
|
||||||
lcd.displayOnOff(true); // turn lcd back on
|
lcd.displayOnOff(true); // turn lcd back on
|
||||||
|
|
||||||
}
|
}
|
||||||
uint16_t tipTemp = tipMeasurementToC(getTipRawTemp(0));
|
uint16_t tipTemp = tipMeasurementToC(getTipRawTemp(0));
|
||||||
if (tipTemp > 600)
|
if (tipTemp > 600) tipTemp = 0;
|
||||||
tipTemp = 0;
|
|
||||||
if (tipTemp > 50) {
|
if (tipTemp > 50) {
|
||||||
if (tempWarningState == 0) {
|
if (tempWarningState == 0) {
|
||||||
currentlyActiveTemperatureTarget = 0; // ensure tip is off
|
currentlyActiveTemperatureTarget = 0; // ensure tip is off
|
||||||
@@ -797,11 +779,9 @@ void startGUITask(void const * argument) {
|
|||||||
}
|
}
|
||||||
lcd.setCursor(0, 8);
|
lcd.setCursor(0, 8);
|
||||||
lcd.print("Input V: ");
|
lcd.print("Input V: ");
|
||||||
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) / 10,
|
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) / 10, 2);
|
||||||
2);
|
|
||||||
lcd.drawChar('.');
|
lcd.drawChar('.');
|
||||||
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) % 10,
|
lcd.printNumber(getInputVoltageX10(systemSettings.voltageDiv) % 10, 1);
|
||||||
1);
|
|
||||||
lcd.print("V");
|
lcd.print("V");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
@@ -815,24 +795,25 @@ void startGUITask(void const * argument) {
|
|||||||
lcd.setCursor(84, 0);
|
lcd.setCursor(84, 0);
|
||||||
gui_drawBatteryIcon();
|
gui_drawBatteryIcon();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
lcd.refresh();
|
lcd.refresh();
|
||||||
animationStep++;
|
animationStep++;
|
||||||
HAL_IWDG_Refresh(&hiwdg);
|
HAL_IWDG_Refresh(&hiwdg);
|
||||||
GUIDelay();
|
GUIDelay();
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* StartPIDTask function */
|
/* StartPIDTask function */
|
||||||
void startPIDTask(void const *argument) {
|
void startPIDTask(void const *argument) {
|
||||||
/*
|
/*
|
||||||
* We take the current tip temperature & evaluate the next step for the tip control PWM
|
* We take the current tip temperature & evaluate the next step for the tip
|
||||||
* Tip temperature is measured by getTipTemperature(1) so we get instant result
|
* control PWM
|
||||||
|
* Tip temperature is measured by getTipTemperature(1) so we get instant
|
||||||
|
* result
|
||||||
* This comes in Cx10 format
|
* This comes in Cx10 format
|
||||||
* We then control the tip temperature to aim for the setpoint in the settings struct
|
* We then control the tip temperature to aim for the setpoint in the settings
|
||||||
|
* struct
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
int32_t integralCount = 0;
|
int32_t integralCount = 0;
|
||||||
@@ -844,13 +825,15 @@ void startPIDTask(void const * argument) {
|
|||||||
kd = 40;
|
kd = 40;
|
||||||
kb = 0;
|
kb = 0;
|
||||||
// REMEBER ^^^^ These constants are backwards
|
// REMEBER ^^^^ These constants are backwards
|
||||||
// They act as dividers, so to 'increase' a P term, you make the number smaller.
|
// They act as dividers, so to 'increase' a P term, you make the number
|
||||||
|
// smaller.
|
||||||
const int32_t itermMax = 40;
|
const int32_t itermMax = 40;
|
||||||
for (;;) {
|
for (;;) {
|
||||||
uint16_t rawTemp = getTipRawTemp(1); // get instantaneous reading
|
uint16_t rawTemp = getTipRawTemp(1); // get instantaneous reading
|
||||||
if (currentlyActiveTemperatureTarget) {
|
if (currentlyActiveTemperatureTarget) {
|
||||||
// Compute the PID loop in here
|
// Compute the PID loop in here
|
||||||
//Because our values here are quite large for all measurements (0-16k ~= 33 counts per C)
|
// Because our values here are quite large for all measurements (0-16k ~=
|
||||||
|
// 33 counts per C)
|
||||||
// P I & D are divisors, so inverse logic applies (beware)
|
// P I & D are divisors, so inverse logic applies (beware)
|
||||||
|
|
||||||
int32_t rawTempError = currentlyActiveTemperatureTarget - rawTemp;
|
int32_t rawTempError = currentlyActiveTemperatureTarget - rawTemp;
|
||||||
@@ -865,12 +848,9 @@ void startPIDTask(void const * argument) {
|
|||||||
|
|
||||||
/*Compute PID Output*/
|
/*Compute PID Output*/
|
||||||
int32_t output = (rawTempError / kp);
|
int32_t output = (rawTempError / kp);
|
||||||
if (ki)
|
if (ki) output += integralCount;
|
||||||
output += integralCount;
|
if (kd) output -= (dInput / kd);
|
||||||
if (kd)
|
if (kb) output -= backoffOverflow / kb;
|
||||||
output -= (dInput / kd);
|
|
||||||
if (kb)
|
|
||||||
output -= backoffOverflow / kb;
|
|
||||||
|
|
||||||
if (output > 100) {
|
if (output > 100) {
|
||||||
backoffOverflow = output;
|
backoffOverflow = output;
|
||||||
@@ -888,7 +868,8 @@ void startPIDTask(void const * argument) {
|
|||||||
}
|
}
|
||||||
setTipPWM(output);
|
setTipPWM(output);
|
||||||
} else {
|
} else {
|
||||||
setTipPWM(0); //disable the output driver if the output is set to be off elsewhere
|
setTipPWM(0); // disable the output driver if the output is set to be off
|
||||||
|
// elsewhere
|
||||||
integralCount = 0;
|
integralCount = 0;
|
||||||
backoffOverflow = 0;
|
backoffOverflow = 0;
|
||||||
derivativeLastValue = 0;
|
derivativeLastValue = 0;
|
||||||
@@ -910,8 +891,7 @@ void startMOVTask(void const * argument) {
|
|||||||
memset(dataz, 0, MOVFilter * sizeof(int16_t));
|
memset(dataz, 0, MOVFilter * sizeof(int16_t));
|
||||||
int16_t tx, ty, tz;
|
int16_t tx, ty, tz;
|
||||||
int32_t avgx, avgy, avgz;
|
int32_t avgx, avgy, avgz;
|
||||||
if (systemSettings.sensitivity > 9)
|
if (systemSettings.sensitivity > 9) systemSettings.sensitivity = 9;
|
||||||
systemSettings.sensitivity = 9;
|
|
||||||
#if ACCELDEBUG
|
#if ACCELDEBUG
|
||||||
uint32_t max = 0;
|
uint32_t max = 0;
|
||||||
#endif
|
#endif
|
||||||
@@ -950,10 +930,10 @@ void startMOVTask(void const * argument) {
|
|||||||
|
|
||||||
lcd.printNumber((abs(avgx - tx) + abs(avgy - ty) + abs(avgz - tz)), 5);
|
lcd.printNumber((abs(avgx - tx) + abs(avgy - ty) + abs(avgz - tz)), 5);
|
||||||
lcd.refresh();
|
lcd.refresh();
|
||||||
if (HAL_GPIO_ReadPin(KEY_A_GPIO_Port, KEY_A_Pin) == GPIO_PIN_RESET)
|
if (HAL_GPIO_ReadPin(KEY_A_GPIO_Port, KEY_A_Pin) == GPIO_PIN_RESET) max = 0;
|
||||||
max = 0;
|
|
||||||
#endif
|
#endif
|
||||||
//Only run the actual processing if the sensitivity is set (aka we are enabled)
|
// Only run the actual processing if the sensitivity is set (aka we are
|
||||||
|
// enabled)
|
||||||
if (systemSettings.sensitivity) {
|
if (systemSettings.sensitivity) {
|
||||||
// calculate averages
|
// calculate averages
|
||||||
avgx = avgy = avgz = 0;
|
avgx = avgy = avgz = 0;
|
||||||
@@ -966,7 +946,8 @@ void startMOVTask(void const * argument) {
|
|||||||
avgy /= MOVFilter;
|
avgy /= MOVFilter;
|
||||||
avgz /= MOVFilter;
|
avgz /= MOVFilter;
|
||||||
|
|
||||||
//So now we have averages, we want to look if these are different by more than the threshold
|
// So now we have averages, we want to look if these are different by more
|
||||||
|
// than the threshold
|
||||||
int32_t error = (abs(avgx - tx) + abs(avgy - ty) + abs(avgz - tz));
|
int32_t error = (abs(avgx - tx) + abs(avgy - ty) + abs(avgz - tz));
|
||||||
// If error has occured then we update the tick timer
|
// If error has occured then we update the tick timer
|
||||||
if (error > threshold) {
|
if (error > threshold) {
|
||||||
@@ -975,7 +956,6 @@ void startMOVTask(void const * argument) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
osDelay(100); // Slow down update rate
|
osDelay(100); // Slow down update rate
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* StartRotationTask function */
|
/* StartRotationTask function */
|
||||||
@@ -989,7 +969,8 @@ void startRotationTask(void const * argument) {
|
|||||||
HAL_NVIC_EnableIRQ(EXTI3_IRQn);
|
HAL_NVIC_EnableIRQ(EXTI3_IRQn);
|
||||||
HAL_NVIC_SetPriority(EXTI9_5_IRQn, 5, 0);
|
HAL_NVIC_SetPriority(EXTI9_5_IRQn, 5, 0);
|
||||||
HAL_NVIC_EnableIRQ(EXTI9_5_IRQn);
|
HAL_NVIC_EnableIRQ(EXTI9_5_IRQn);
|
||||||
//^ We hold off enabling these until now to ensure the semaphore is available to be used first
|
//^ We hold off enabling these until now to ensure the semaphore is available
|
||||||
|
// to be used first
|
||||||
switch (systemSettings.OrientationMode) {
|
switch (systemSettings.OrientationMode) {
|
||||||
case 0:
|
case 0:
|
||||||
lcd.setRotation(false);
|
lcd.setRotation(false);
|
||||||
@@ -1000,18 +981,19 @@ void startRotationTask(void const * argument) {
|
|||||||
case 2:
|
case 2:
|
||||||
lcd.setRotation(false);
|
lcd.setRotation(false);
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
for (;;) {
|
for (;;) {
|
||||||
if ( xSemaphoreTake( rotationChangedSemaphore, portMAX_DELAY ) == pdTRUE
|
if (xSemaphoreTake(rotationChangedSemaphore, portMAX_DELAY) == pdTRUE ||
|
||||||
|| (HAL_GPIO_ReadPin(INT_Orientation_GPIO_Port,
|
(HAL_GPIO_ReadPin(INT_Orientation_GPIO_Port, INT_Orientation_Pin) ==
|
||||||
INT_Orientation_Pin) == GPIO_PIN_RESET)) {
|
GPIO_PIN_RESET)) {
|
||||||
// a rotation event has occured
|
// a rotation event has occured
|
||||||
bool rotation = accel.getOrientation();
|
bool rotation = accel.getOrientation();
|
||||||
if (systemSettings.OrientationMode == 2)
|
if (systemSettings.OrientationMode == 2)
|
||||||
lcd.setRotation(rotation); // link the data through
|
lcd.setRotation(rotation); // link the data through
|
||||||
}
|
}
|
||||||
osDelay(300);
|
osDelay(300);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1019,16 +1001,16 @@ void startRotationTask(void const * argument) {
|
|||||||
void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin) {
|
void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin) {
|
||||||
static signed long xHigherPriorityTaskWoken;
|
static signed long xHigherPriorityTaskWoken;
|
||||||
if (GPIO_Pin == INT_Orientation_Pin) {
|
if (GPIO_Pin == INT_Orientation_Pin) {
|
||||||
xSemaphoreGiveFromISR(rotationChangedSemaphore,
|
xSemaphoreGiveFromISR(rotationChangedSemaphore, &xHigherPriorityTaskWoken);
|
||||||
&xHigherPriorityTaskWoken);
|
|
||||||
} else if (GPIO_Pin == INT_Movement_Pin) {
|
} else if (GPIO_Pin == INT_Movement_Pin) {
|
||||||
// New data is available for reading from the unit
|
// New data is available for reading from the unit
|
||||||
//xSemaphoreGiveFromISR(accelDataAvailableSemaphore, &xHigherPriorityTaskWoken);
|
// xSemaphoreGiveFromISR(accelDataAvailableSemaphore,
|
||||||
|
// &xHigherPriorityTaskWoken);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#define FLASH_LOGOADDR (0x8000000|0xB800) /*second last page of flash set aside for logo image*/
|
#define FLASH_LOGOADDR \
|
||||||
|
(0x8000000 | 0xF800) /*second last page of flash set aside for logo image*/
|
||||||
|
|
||||||
bool showBootLogoIfavailable() {
|
bool showBootLogoIfavailable() {
|
||||||
// check if the header is there (0xAA,0x55,0xF0,0x0D)
|
// check if the header is there (0xAA,0x55,0xF0,0x0D)
|
||||||
@@ -1042,20 +1024,14 @@ bool showBootLogoIfavailable() {
|
|||||||
for (uint8_t i = 0; i < 98; i++) {
|
for (uint8_t i = 0; i < 98; i++) {
|
||||||
temp8[i * 2] = temp[i] >> 8;
|
temp8[i * 2] = temp[i] >> 8;
|
||||||
temp8[i * 2 + 1] = temp[i] & 0xFF;
|
temp8[i * 2 + 1] = temp[i] & 0xFF;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (temp8[0] != 0xAA)
|
if (temp8[0] != 0xAA) return false;
|
||||||
return false;
|
if (temp8[1] != 0x55) return false;
|
||||||
if (temp8[1] != 0x55)
|
if (temp8[2] != 0xF0) return false;
|
||||||
return false;
|
if (temp8[3] != 0x0D) return false;
|
||||||
if (temp8[2] != 0xF0)
|
|
||||||
return false;
|
|
||||||
if (temp8[3] != 0x0D)
|
|
||||||
return false;
|
|
||||||
|
|
||||||
lcd.drawArea(0, 0, 96, 16, (uint8_t *)(temp8 + 4));
|
lcd.drawArea(0, 0, 96, 16, (uint8_t *)(temp8 + 4));
|
||||||
lcd.refresh();
|
lcd.refresh();
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,48 +1,3 @@
|
|||||||
/**
|
|
||||||
*****************************************************************************
|
|
||||||
**
|
|
||||||
** File : syscalls.c
|
|
||||||
**
|
|
||||||
** Abstract : System Workbench Minimal System calls file
|
|
||||||
**
|
|
||||||
** For more information about which c-functions
|
|
||||||
** need which of these lowlevel functions
|
|
||||||
** please consult the Newlib libc-manual
|
|
||||||
**
|
|
||||||
** Environment : System Workbench for MCU
|
|
||||||
**
|
|
||||||
** Distribution: The file is distributed <20>as is,<2C> without any warranty
|
|
||||||
** of any kind.
|
|
||||||
**
|
|
||||||
*****************************************************************************
|
|
||||||
**
|
|
||||||
** <h2><center>© COPYRIGHT(c) 2014 Ac6</center></h2>
|
|
||||||
**
|
|
||||||
** Redistribution and use in source and binary forms, with or without modification,
|
|
||||||
** are permitted provided that the following conditions are met:
|
|
||||||
** 1. Redistributions of source code must retain the above copyright notice,
|
|
||||||
** this list of conditions and the following disclaimer.
|
|
||||||
** 2. Redistributions in binary form must reproduce the above copyright notice,
|
|
||||||
** this list of conditions and the following disclaimer in the documentation
|
|
||||||
** and/or other materials provided with the distribution.
|
|
||||||
** 3. Neither the name of Ac6 nor the names of its contributors
|
|
||||||
** may be used to endorse or promote products derived from this software
|
|
||||||
** without specific prior written permission.
|
|
||||||
**
|
|
||||||
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
||||||
** AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
** IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
||||||
** DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
|
||||||
** FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
||||||
** DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
||||||
** SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
|
||||||
** CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
||||||
** OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
||||||
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
**
|
|
||||||
*****************************************************************************
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Includes */
|
/* Includes */
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|||||||
2
workspace/ts100/.gitignore
vendored
2
workspace/ts100/.gitignore
vendored
@@ -1,2 +0,0 @@
|
|||||||
/Debug/
|
|
||||||
/Release/
|
|
||||||
Reference in New Issue
Block a user