comit_job ver new modbus

This commit is contained in:
2025-11-07 16:22:00 +03:00
parent 461a206fe7
commit 81d95635f9
17 changed files with 564 additions and 2616 deletions

View File

@@ -22,7 +22,7 @@
#include "stm32f1xx_it.h"
/* Private includes ----------------------------------------------------------*/
/* USER CODE BEGIN Includes */
#include "rs_message.h"
#include "modbus.h"
/* USER CODE END Includes */
/* Private typedef -----------------------------------------------------------*/
@@ -281,11 +281,12 @@ void TIM1_CC_IRQHandler(void)
void TIM2_IRQHandler(void)
{
/* USER CODE BEGIN TIM2_IRQn 0 */
RS_TIM_Handler(&hmodbus1);
return;
/* USER CODE END TIM2_IRQn 0 */
HAL_TIM_IRQHandler(&htim2);
/* USER CODE BEGIN TIM2_IRQn 1 */
// RS_TIM_Handler(&hmodbus1);
//RS_TIM_Handler(&hmodbus1);
/* USER CODE END TIM2_IRQn 1 */
}
@@ -313,15 +314,12 @@ static uint8_t first_in=1;
void USART1_IRQHandler(void)
{
/* USER CODE BEGIN USART1_IRQn 0 */
if (__HAL_UART_GET_FLAG(&huart1, UART_FLAG_IDLE))
{
__HAL_UART_CLEAR_IDLEFLAG(&huart1);
RS_TIM_Handler(&hmodbus1);
}
RS_UART_Handler(&hmodbus1);
return;
/* USER CODE END USART1_IRQn 0 */
HAL_UART_IRQHandler(&huart1);
/* USER CODE BEGIN USART1_IRQn 1 */
RS_UART_Handler(&hmodbus1);
//RS_UART_Handler(&hmodbus1);
/* USER CODE END USART1_IRQn 1 */