Files
time_manager/config.py
insulee 3c14e1e401 Initial commit: Dabit Time Manager project
Python-based time management application with UDP discovery,
TCP protocol communication, time sync, and drift monitoring.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-10 11:10:55 +09:00

38 lines
744 B
Python

"""상수 및 기본 설정"""
# UDP 포트
UDP_PORT_ETHERNET = 5108
UDP_PORT_WIFI = 5107
UDP_BROADCAST_IP = "255.255.255.255"
# UDP 명령
SEARCH_CMD = "SEARCHING DIBD B\r\n"
SETT_PREFIX = "SETT "
RESET_PREFIX = "RESET "
# UDP 수신 버퍼
UDP_RECV_BUFFER = 1024
UDP_RECV_TIMEOUT = 3.0 # 초
# TCP 설정
TCP_TIMEOUT = 5.0 # 초
TCP_RECV_BUFFER = 256
# ASCII 프로토콜
CMD_TIME_SYNC = "30" # PC 시간 동기화
CMD_TIME_READ = "31" # 컨트롤러 시간 읽기
# DIBD 응답 패킷 크기
DIBD_PACKET_SIZE = 222
# 모니터링 기본 주기 (초)
DEFAULT_MONITOR_INTERVAL = 3600 # 1시간
# 인코딩
PROTOCOL_ENCODING = "euc-kr" # MS949 호환
# GUI
APP_TITLE = "Dabit Time Manager"
APP_WIDTH = 1050
APP_HEIGHT = 720