мелкое

This commit is contained in:
KLASSENTS 2025-03-24 09:44:17 +07:00
parent 7a858b334a
commit b212f786da
4 changed files with 11 additions and 18 deletions

View File

@ -6,10 +6,6 @@
#ifndef FREERTOS_CONFIG_H #ifndef FREERTOS_CONFIG_H
#define FREERTOS_CONFIG_H #define FREERTOS_CONFIG_H
// #include "plf.h"
//#include "arch.h"
//#include "rtc.h"
//#include "mtimer.h"
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
@ -27,13 +23,11 @@ extern "C" {
* THESE PARAMETERS ARE DESCRIBED WITHIN THE 'CONFIGURATION' SECTION OF THE * THESE PARAMETERS ARE DESCRIBED WITHIN THE 'CONFIGURATION' SECTION OF THE
* FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE. * FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE.
* *
* See http://www.freertos.org/a00110.html. * See https://www.freertos.org/a00110.html.
*----------------------------------------------------------*/ *----------------------------------------------------------*/
// #define configMTIME_BASE_ADDRESS ( SCR1_TIMER->MTIME ) #define configMTIME_BASE_ADDRESS SCR1_TIMER_BASE_ADDRESS//((uintptr_t)&SCR1_TIMER->MTIME)
// #define configMTIMECMP_BASE_ADDRESS ( SCR1_TIMER->MTIMECMP ) #define configMTIMECMP_BASE_ADDRESS SCR1_TIMER_BASE_ADDRESS//((uintptr_t)&SCR1_TIMER->MTIMECMP)
#define configMTIME_BASE_ADDRESS 0//((uintptr_t)&SCR1_TIMER->MTIME)
#define configMTIMECMP_BASE_ADDRESS 0//((uintptr_t)&SCR1_TIMER->MTIMECMP)
/* Delay definition - here, the user can choose which delay implementation is required. /* Delay definition - here, the user can choose which delay implementation is required.
* The default is to change nothing. */ * The default is to change nothing. */
@ -128,4 +122,5 @@ to exclude the API function. */
#endif #endif
#endif #endif
#endif /* FREERTOS_CONFIG_H */ #endif /* FREERTOS_CONFIG_H */

View File

@ -211,7 +211,6 @@ void vListInsert( List_t * const pxList,
} }
/*-----------------------------------------------------------*/ /*-----------------------------------------------------------*/
UBaseType_t uxListRemove( ListItem_t * const pxItemToRemove ) UBaseType_t uxListRemove( ListItem_t * const pxItemToRemove )
{ {
/* The list item knows which list it is in. Obtain the list from the list /* The list item knows which list it is in. Obtain the list from the list

View File

@ -1,6 +1,6 @@
/* /*
* FreeRTOS Kernel V11.1.0 * FreeRTOS Kernel V11.1.0
* Copyright (C) 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. * Copyright (C) 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved.
* *
* SPDX-License-Identifier: MIT * SPDX-License-Identifier: MIT
* *

View File

@ -38,6 +38,8 @@ extern void loop(void);
/*-----------------------------------------------------------*/ /*-----------------------------------------------------------*/
void initVariant(void) __attribute__ ((OS_main));
void initVariant(void) void initVariant(void)
{ {
setup(); // the normal Arduino setup() function is run here. setup(); // the normal Arduino setup() function is run here.
@ -51,12 +53,10 @@ void initVariant(void)
* now all that remains is to configure the machine timer comparison register * now all that remains is to configure the machine timer comparison register
* and enable this interrupt. * and enable this interrupt.
*/ */
void vPortSetupTimerInterrupt(void) // void vPortSetupTimerInterrupt(void)
{ // {
SCR1_TIMER->MTIMEH; SCR1_TIMER->MTIME; // }
SCR1_TIMER->MTIMECMP; SCR1_TIMER->MTIMECMPH;
}
/*-----------------------------------------------------------*/ /*-----------------------------------------------------------*/
#if ( configUSE_IDLE_HOOK == 1 ) #if ( configUSE_IDLE_HOOK == 1 )
@ -152,7 +152,7 @@ void vApplicationStackOverflowHook( TaskHandle_t xTask __attribute__ ((unused)),
for(;;) for(;;)
{ {
// _delay_ms(2000); delay(2000);
prvBlinkMainLed(); // Main LED slow blink. prvBlinkMainLed(); // Main LED slow blink.
} }
} }
@ -212,7 +212,6 @@ void vApplicationAssertHook() {
prvSetMainLedOn(); // Main LED on. prvSetMainLedOn(); // Main LED on.
for(;;) for(;;)
{ {
// todo тут тоже заменить
delay(100); delay(100);
prvBlinkMainLed(); // Led off. prvBlinkMainLed(); // Led off.