fix: BLE TX 먹통 해결 및 메모리 안전성 개선

- binary_tx_handler를 dr_binary_tx_safe로 전체 교체 (APP_ERROR_CHECK 제거)
- data_tx_handler APP_ERROR_CHECK → DBG_PRINTF 교체
- memset/memcpy 하드코딩 크기를 define 상수로 교체 (버퍼 오버런 수정)
- SERIAL_NO_LENGTH, HW_NO_LENGTH, PASSKEY_LENGTH를 main.h로 통합
- 미사용 HW 드라이버/EEPROM 코드 삭제, TWI를 i2c_manager.c로 통합
- EEPROM → FDS 전환, 코드 리뷰 현황 문서 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-16 16:39:26 +09:00
parent 836ebe5878
commit a1ad2a4b5b
76 changed files with 43253 additions and 16370 deletions

View File

@@ -9,6 +9,13 @@
#ifndef MAIN_H__
#define MAIN_H__
/*==============================================================================
* DATA LENGTH CONSTANTS
*============================================================================*/
#define SERIAL_NO_LENGTH 12
#define HW_NO_LENGTH 12
#define PASSKEY_LENGTH 6
#include <stdio.h>
#include <string.h>
#include <stdarg.h>
@@ -54,7 +61,6 @@ static void PM_s(void * p_context);
static void main_routine_handler(void * p_context);
void received_command_process(uint8_t const *data_array, which_cmd_t cmd_t,uint8_t length);
void data_tx_handler(char const *p_data_to_send);
void binary_tx_handler(uint8_t const *ble_bin_buff , uint16_t length);
void dr_binary_tx_safe(uint8_t const *ble_bin_buff, uint16_t length);
void dr_sd_delay_ms(uint32_t ms);
void single_format_data(uint8_t *buffer, const char *tag, const uint16_t value) ;