auto-sync 2026-07-03 18:00

This commit is contained in:
Leopoldo Rodríguez 2026-07-03 18:00:09 -06:00
parent 2c3dffa232
commit addebea5bb
26 changed files with 1292 additions and 911 deletions

View File

@ -1,4 +1,4 @@
% cuerpo.tex — Guía de Conexión en Protoboard v2.1 (bloques 1–11) % cuerpo.tex — Guía de Conexión en Protoboard v2.2 (bloques 1–11)
% Fuente de datos autoritativa: ../Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx % Fuente de datos autoritativa: ../Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx
% (hojas: Conexiones · Mapa de pines · Fuentes y convertidores · Estado y cambios) % (hojas: Conexiones · Mapa de pines · Fuentes y convertidores · Estado y cambios)
@ -16,7 +16,8 @@ sección~\ref{sec:orden}, que va de lo más simple (solo USB) a lo más delicado
\texttt{Drogheda\_Conexiones-por-Bloque\_Proto\_v1.xlsx} (hojas \textit{Conexiones}, \texttt{Drogheda\_Conexiones-por-Bloque\_Proto\_v1.xlsx} (hojas \textit{Conexiones},
\textit{Mapa de pines}, \textit{Fuentes y convertidores}, \textit{Estado y cambios}). \textit{Mapa de pines}, \textit{Fuentes y convertidores}, \textit{Estado y cambios}).
Si esta guía y el XLSX difieren, \textbf{manda el XLSX}. Si esta guía y el XLSX difieren, \textbf{manda el XLSX}.
\item \textbf{Diagramas por bloque (CircuiTikZ):} carpeta \texttt{circuitikz-wiring/} — \item \textbf{Diagramas por bloque (CircuiTikZ):} \textbf{incrustados en esta guía} al final
de cada bloque (v2.2). Los mismos dibujos, por separado: carpeta \texttt{circuitikz-wiring/} —
\texttt{Drogheda\_Diagrama\_CircuiTikZ.pdf} (lámina completa) y \texttt{Drogheda\_Diagrama\_CircuiTikZ.pdf} (lámina completa) y
\texttt{Drogheda\_Diagrama\_Beamer.pdf} (una diapositiva por bloque). \texttt{Drogheda\_Diagrama\_Beamer.pdf} (una diapositiva por bloque).
\item \textbf{Estado eléctrico canónico del diseño:} \item \textbf{Estado eléctrico canónico del diseño:}
@ -49,6 +50,11 @@ Batería & Respaldo proto = TP4056 + MT3608 & 2$\times$ 1N5819 en «O» (OR) hac
Firmware — pendiente & Gauge PB12--15 · CHRG\_EN · fan-fault por temperatura & \textbf{Bench-test antes de flashear} (el sandbox no compila STM32).\\ Firmware — pendiente & Gauge PB12--15 · CHRG\_EN · fan-fault por temperatura & \textbf{Bench-test antes de flashear} (el sandbox no compila STM32).\\
PCB — pendiente & Bloque B (LTC4040) + bypass fail-safe UART2 & El bypass \textbf{normalmente cerrado} evita que un MCU ausente/colgado corte las correcciones (Modo~B). Ver Bloque~9.\\ PCB — pendiente & Bloque B (LTC4040) + bypass fail-safe UART2 & El bypass \textbf{normalmente cerrado} evita que un MCU ausente/colgado corte las correcciones (Modo~B). Ver Bloque~9.\\
Cobertura de partes & Sección 1 + 3 = suficiente para el core & La sección 2 (TP4056/MT3608) solo hace falta para el respaldo de batería.\\ Cobertura de partes & Sección 1 + 3 = suficiente para el core & La sección 2 (TP4056/MT3608) solo hace falta para el respaldo de batería.\\
Temp/RH & \textbf{Suite proto = AHT10 + LM35 + NTC$\rightarrow$PB1} (2026-07-03) & El \textbf{AHT10} (0x38, I\textsuperscript{2}C1, \textbf{solo} en el bus) sustituye al SHT40 (sin stock; SHT40/TMP102 quedan para el PCB). \textbf{LM35 $\rightarrow$ PA7} (único ADC libre, alimentado a 5\,V). \textbf{Triple temperatura} por 3 rutas; humedad = solo AHT10. Firmware: driver AHT10 (0x44$\rightarrow$0x38) + canal PA7.\\
Batería / carga & \textbf{TP4056 sin pin TEMP $\rightarrow$ corte por PA8} (2026-07-03) & El módulo del kit no expone TEMP: su NTC queda \textbf{sin usar} en proto. Nuevo corte de carga: PA8 (\textbf{CHRG\_RUN}) $\rightarrow$ 2N3904 $\rightarrow$ IRF9540 en el IN+ del TP4056. PA8 ALTO = carga; MCU ausente = \textbf{sin carga}. \textbf{Inversión vs PCB} (CHRG\_EN alto = corta) $\rightarrow$ flag en firmware. Bloque~10.\\
Corte general & Apagador SPST tras el nodo OR (2026-07-03) & Nodo SYS (unión de los 2$\times$ 1N5819) $\rightarrow$ \textbf{apagador} $\rightarrow$ riel MAIN5V: mata vehículo \textbf{y} batería (= Bloque E del PCB, P11). Bloque~10.\\
Capacitores & En mano: 100\,nF cer. + 10\,$\mu$F y 100\,$\mu$F elec. (2026-07-03) & Cubren toda la guía. Los 10\,$\mu$F = desacople local opcional en salidas de módulos. \textbf{Electrolíticos CON polaridad.}\\
Vent. / botones & Ventilador 2 hilos + apagador + botones \textbf{en mano} (2026-07-03) & Reset y gauge dejan de ser opcionales: \textbf{todo va en el protoboard}.\\
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
@ -88,13 +94,14 @@ PA3 & USART2 RX $\leftarrow$ F9P UART1 TX (NMEA) & UART & 8, 9\\
PA4 & 5V\_SENSE — vehículo $\div$2 & ADC & 4\\ PA4 & 5V\_SENSE — vehículo $\div$2 & ADC & 4\\
PA5 & IGN\_SENSE — digital, \texttt{INPUT\_PULLDOWN}, \textbf{sin divisor} (máx 3.3\,V) & Entrada dig. & 4\\ PA5 & IGN\_SENSE — digital, \texttt{INPUT\_PULLDOWN}, \textbf{sin divisor} (máx 3.3\,V) & Entrada dig. & 4\\
PA6 & FAN\_PWM — 25\,kHz (TIM3\_CH1) & PWM & 5\\ PA6 & FAN\_PWM — 25\,kHz (TIM3\_CH1) & PWM & 5\\
PA8 & CHRG\_EN (planeado) — corta la carga si la celda está caliente & Salida & batería / firmware\\ PA7 & LM35\_TEMP — 10\,mV/\textdegree C (ADC1\_IN7) & ADC & 11\\
PA8 & CHRG\_RUN (proto) — \textbf{ALTO = carga permitida}; corta el IN+ del TP4056 si la celda está caliente. \textbf{Inversión vs PCB} (CHRG\_EN alto = corta) & Salida & 10\\
PA9 & Modo B: USART1 TX $\rightarrow$ 4G DIN (relé \texttt{\$PHLG}) & UART & 9\\ PA9 & Modo B: USART1 TX $\rightarrow$ 4G DIN (relé \texttt{\$PHLG}) & UART & 9\\
PA10 & Modo B: USART1 RX $\leftarrow$ F9P TX2 (relé); 22\,k$\Omega \rightarrow$ 3V3 & UART & 9\\ PA10 & Modo B: USART1 RX $\leftarrow$ F9P TX2 (relé); 22\,k$\Omega \rightarrow$ 3V3 & UART & 9\\
PB0 & EXT\_LED — LED de estado & Salida & 2\\ PB0 & EXT\_LED — LED de estado & Salida & 2\\
PB1 & Temperatura analógica (divisor NTC) — ADC1\_IN9 (libre) & ADC & 11\\ PB1 & Temperatura analógica (divisor NTC) — ADC1\_IN9 (libre) & ADC & 11\\
PB6 & I\textsuperscript{2}C1 SCL — SHT40/TMP102 & I\textsuperscript{2}C & 6\\ PB6 & I\textsuperscript{2}C1 SCL — AHT10 (0x38, \textbf{solo} en el bus; SHT40/TMP102 = PCB) & I\textsuperscript{2}C & 6\\
PB7 & I\textsuperscript{2}C1 SDA — SHT40/TMP102 & I\textsuperscript{2}C & 6\\ PB7 & I\textsuperscript{2}C1 SDA — AHT10 (0x38) & I\textsuperscript{2}C & 6\\
PB10 & FAN\_TACH — DNP (ventilador de 2 hilos) & — & 5\\ PB10 & FAN\_TACH — DNP (ventilador de 2 hilos) & — & 5\\
PB12--PB15 & Gauge de batería (4 LEDs) — firmware pendiente & Salida & 7\\ PB12--PB15 & Gauge de batería (4 LEDs) — firmware pendiente & Salida & 7\\
PC13 & LED onboard (activo-bajo) & Salida & —\\ PC13 & LED onboard (activo-bajo) & Salida & —\\
@ -112,7 +119,7 @@ NRST & Reset (botón a GND) & Reset & 7\\
Mean Well SD-15B-05 & Fuente principal 24$\rightarrow$5\,V (o un banco de 5\,V). Es el riel \textbf{MAIN5V} (módulo industrial). & 18--36\,V $\rightarrow$ 5\,V · 3\,A & 1\\ Mean Well SD-15B-05 & Fuente principal 24$\rightarrow$5\,V (o un banco de 5\,V). Es el riel \textbf{MAIN5V} (módulo industrial). & 18--36\,V $\rightarrow$ 5\,V · 3\,A & 1\\
LM2596 (o MP1584) & 5\,V \textbf{separado} para el ventilador. \textbf{¡Ajústalo a 5.0\,V con el multímetro ANTES de conectar!} Vienen en voltaje aleatorio. En el PCB este papel lo hace el MP1584 (U2). & 24\,V $\rightarrow$ 5.0\,V ajustable & 5\\ LM2596 (o MP1584) & 5\,V \textbf{separado} para el ventilador. \textbf{¡Ajústalo a 5.0\,V con el multímetro ANTES de conectar!} Vienen en voltaje aleatorio. En el PCB este papel lo hace el MP1584 (U2). & 24\,V $\rightarrow$ 5.0\,V ajustable & 5\\
DFR1015 & Acondiciona la ignición. Acepta 12 y 24\,V; 4 terminales (IN$\pm$/OUT$\pm$) y \textbf{ambos GND al GND del sistema}. On-board en la v3 (GX16 pin~3 = ignición cruda). & 12--24\,V $\rightarrow$ 5\,V & 4\\ DFR1015 & Acondiciona la ignición. Acepta 12 y 24\,V; 4 terminales (IN$\pm$/OUT$\pm$) y \textbf{ambos GND al GND del sistema}. On-board en la v3 (GX16 pin~3 = ignición cruda). & 12--24\,V $\rightarrow$ 5\,V & 4\\
TP4056 & Cargador del 18650 (\textbf{proto}; stand-in de banco). El PCB usa el LTC4040. & 5\,V vehículo $\rightarrow$ carga 1S & 10\\ TP4056 & Cargador del 18650 (\textbf{proto}; stand-in de banco). El módulo \textbf{no expone el pin TEMP} $\rightarrow$ corte de carga por PA8 (CHRG\_RUN) en el IN+. El PCB usa el LTC4040. & 5\,V vehículo $\rightarrow$ carga 1S & 10\\
MT3608 & Elevador de respaldo. Ajústalo \textbf{apenas por debajo} del 5\,V del vehículo para que el vehículo tenga prioridad. & 3.6\,V $\rightarrow$ 5\,V & 10\\ MT3608 & Elevador de respaldo. Ajústalo \textbf{apenas por debajo} del 5\,V del vehículo para que el vehículo tenga prioridad. & 3.6\,V $\rightarrow$ 5\,V & 10\\
LTC4040 (PCB) & Battery-backup manager: carga + power-path + boost + NTC. Carga temp-cualificada por NTC; R\textsubscript{PROG} $\approx$ C/5 $\le$ 2.5\,A para 12\,Ah. & 5\,V vehículo / batería $\rightarrow$ 5\,V & B (por diseñar)\\ LTC4040 (PCB) & Battery-backup manager: carga + power-path + boost + NTC. Carga temp-cualificada por NTC; R\textsubscript{PROG} $\approx$ C/5 $\le$ 2.5\,A para 12\,Ah. & 5\,V vehículo / batería $\rightarrow$ 5\,V & B (por diseñar)\\
18650 1S4P & Pack de respaldo \textbf{$\sim$12\,Ah} («40\,Ah» era un error, corregido 2026-06-30). \textbf{Respeta la polaridad.} & — $\rightarrow$ 3.6\,V · $\sim$12\,Ah & 4, 10\\ 18650 1S4P & Pack de respaldo \textbf{$\sim$12\,Ah} («40\,Ah» era un error, corregido 2026-06-30). \textbf{Respeta la polaridad.} & — $\rightarrow$ 3.6\,V · $\sim$12\,Ah & 4, 10\\
@ -133,7 +140,7 @@ la sección~\ref{sec:orden}.
\toprule \toprule
\theadconex \theadconex
\midrule \midrule
\redV & Fuente 5\,V (SD-15B-05 o banco) (+) $\rightarrow$ riel MAIN5V & Fuente principal\\ \redV & Fuente 5\,V (SD-15B-05 o banco) (+) $\rightarrow$ \textbf{apagador de corte} (SPST) $\rightarrow$ riel MAIN5V & Fuente principal — corte general \textbf{en mano}. Con el Bloque~10 armado, el apagador se recoloca: nodo SYS $\rightarrow$ riel (ver Bloque~10)\\
\redG & Fuente 5\,V ($-$) $\rightarrow$ riel GND & Tierra común\\ \redG & Fuente 5\,V ($-$) $\rightarrow$ riel GND & Tierra común\\
\redV & Riel MAIN5V $\rightarrow$ pin 5V del Blackpill & El Blackpill genera el 3.3\,V (LDO interno)\\ \redV & Riel MAIN5V $\rightarrow$ pin 5V del Blackpill & El Blackpill genera el 3.3\,V (LDO interno)\\
\redG & Riel GND $\rightarrow$ pin GND del Blackpill & \\ \redG & Riel GND $\rightarrow$ pin GND del Blackpill & \\
@ -142,6 +149,8 @@ la sección~\ref{sec:orden}.
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\diagramabloque{1}{\blkRieles}
\bloque{2}{LED de estado (PB0)} \bloque{2}{LED de estado (PB0)}
\queprueba{los códigos de parpadeo cambian con el estado.} \queprueba{los códigos de parpadeo cambian con el estado.}
@ -155,6 +164,8 @@ la sección~\ref{sec:orden}.
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\diagramabloque{2}{\blkLED}
\bloque{3}{Interruptor de carga del «stack» (PA1) — EL CORAZÓN} \bloque{3}{Interruptor de carga del «stack» (PA1) — EL CORAZÓN}
\queprueba{APAGADO al reset (estado seguro), ON cuando PA1 activa.} \queprueba{APAGADO al reset (estado seguro), ON cuando PA1 activa.}
@ -176,12 +187,7 @@ la sección~\ref{sec:orden}.
\noindent{\small\textit{El pull-up de 10\,k$\Omega$ garantiza el invariante «apagado = estado \noindent{\small\textit{El pull-up de 10\,k$\Omega$ garantiza el invariante «apagado = estado
seguro»: sin MCU (o durante el reset) el stack queda \textbf{apagado}.}} seguro»: sin MCU (o durante el reset) el stack queda \textbf{apagado}.}}
\begin{center} \diagramabloque{3}{\blkCarga}
\begin{adjustbox}{max width=\textwidth}
\begin{tikzpicture}[every node/.append style={font=\footnotesize}]\blkCarga\end{tikzpicture}
\end{adjustbox}\\
{\small\itshape Bloque 3 — el mismo dibujo que la lámina CircuiTikZ (\texttt{circuitikz-wiring/}).}
\end{center}
\bloque{4}{Sensado: batería / 5\,V / ignición} \bloque{4}{Sensado: batería / 5\,V / ignición}
\queprueba{\texttt{veh}/\texttt{ign}/\texttt{vbat} cambian en el log (TLM).} \queprueba{\texttt{veh}/\texttt{ign}/\texttt{vbat} cambian en el log (TLM).}
@ -205,6 +211,8 @@ seguro»: sin MCU (o durante el reset) el stack queda \textbf{apagado}.}}
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\diagramabloque{4}{\blkSensado}
\bloque{5}{Ventilador (2 hilos)} \bloque{5}{Ventilador (2 hilos)}
\queprueba{el ventilador arranca/sube con la temperatura.} \queprueba{el ventilador arranca/sube con la temperatura.}
@ -225,27 +233,36 @@ seguro»: sin MCU (o durante el reset) el stack queda \textbf{apagado}.}}
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\bloque{6}{Sensor de temperatura I\textsuperscript{2}C (si lo tienes)} \diagramabloque{5}{\blkVent}
\queprueba{al calentar el sensor, el ventilador sube.}
\bloque{6}{Sensor de temperatura y humedad I\textsuperscript{2}C — AHT10}
\queprueba{el log reporta temperatura + humedad del aire; al calentar el sensor, el ventilador sube.}
\hwtab{% \hwtab{%
\begin{tabularx}{\textwidth}{@{}l X L{4.4cm}@{}} \begin{tabularx}{\textwidth}{@{}l X L{4.4cm}@{}}
\toprule \toprule
\theadconex \theadconex
\midrule \midrule
\redT & SHT40 / TMP102 VCC $\rightarrow$ 3V3 & Parte de 3.3\,V (no 5\,V)\\ \redT & AHT10 VCC $\rightarrow$ 3V3 & \textbf{1.8--3.6\,V — NUNCA a 5\,V} (el breakout no trae regulador)\\
\redG & SHT40 / TMP102 GND $\rightarrow$ GND & \\ \redG & AHT10 GND $\rightarrow$ GND & \\
\redS & SCL $\rightarrow$ PB6 & I\textsuperscript{2}C1 SCL\\ \redS & AHT10 SCL $\rightarrow$ PB6 & I\textsuperscript{2}C1 SCL\\
\redT & SCL $\rightarrow$ R 4.7\,k$\Omega$ $\rightarrow$ 3V3 & Pull-up I\textsuperscript{2}C (muchos breakouts ya lo traen)\\ \redT & SCL $\rightarrow$ R 4.7\,k$\Omega$ $\rightarrow$ 3V3 & Pull-up I\textsuperscript{2}C (muchos breakouts ya lo traen)\\
\redS & SDA $\rightarrow$ PB7 & I\textsuperscript{2}C1 SDA\\ \redS & AHT10 SDA $\rightarrow$ PB7 & I\textsuperscript{2}C1 SDA\\
\redT & SDA $\rightarrow$ R 4.7\,k$\Omega$ $\rightarrow$ 3V3 & Pull-up I\textsuperscript{2}C\\ \redT & SDA $\rightarrow$ R 4.7\,k$\Omega$ $\rightarrow$ 3V3 & Pull-up I\textsuperscript{2}C\\
\redN & Direcciones: SHT40 = 0x44 · TMP102 = 0x48 & TMP102 en pigtail a la celda/módem (punto caliente)\\ \redN & Dirección: AHT10 = \textbf{0x38 (fija)} & Firmware: 0x44 $\rightarrow$ 0x38\\
\redN & Sin SHT40/TMP102 $\rightarrow$ usa el Bloque 11 (NTC $\rightarrow$ PB1) & Alternativa analógica\\ \redN & \textbf{SOLO el AHT10 en el bus} (restricción Aosong) & SHT40/TMP102 quedan para el PCB; no agregues otro dispositivo I\textsuperscript{2}C\\
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\bloque{7}{Reset (opcional) y gauge de batería (opcional)} \noindent{\small\textit{El AHT10 sustituye al SHT40 en el proto (sin stock, entrega larga) y mide
\queprueba{el botón reinicia; los 4 LEDs quedan listos para el firmware.} \textbf{temperatura + humedad del aire} del gabinete. Con el LM35 $\rightarrow$ PA7 y el
NTC $\rightarrow$ PB1 (Bloque~11) forman la \textbf{triple ruta de temperatura}; la humedad
la da solo el AHT10.}}
\diagramabloque{6}{\blkTemp}
\bloque{7}{Reset y gauge de batería}
\queprueba{el botón reinicia; los 4 LEDs quedan listos para el firmware. Botones y LEDs \textbf{en mano} — van todos en el protoboard.}
\hwtab{% \hwtab{%
\begin{tabularx}{\textwidth}{@{}l X L{4.4cm}@{}} \begin{tabularx}{\textwidth}{@{}l X L{4.4cm}@{}}
@ -257,6 +274,8 @@ seguro»: sin MCU (o durante el reset) el stack queda \textbf{apagado}.}}
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\diagramabloque{7}{\blkResetGauge}
\bloque{8}{Conexión del stack RTK (modo por defecto)} \bloque{8}{Conexión del stack RTK (modo por defecto)}
\queprueba{el watchdog observa; solo 4 cables al stack.} \queprueba{el watchdog observa; solo 4 cables al stack.}
@ -276,6 +295,8 @@ seguro»: sin MCU (o durante el reset) el stack queda \textbf{apagado}.}}
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\diagramabloque{8}{\blkStack}
\bloque{9}{Modo B — Diagnóstico por NTRIP (relé, opcional)} \bloque{9}{Modo B — Diagnóstico por NTRIP (relé, opcional)}
\queprueba{inyecta \texttt{\$PHLG} al servidor por 4G. Requiere breakout XBee.} \queprueba{inyecta \texttt{\$PHLG} al servidor por 4G. Requiere breakout XBee.}
@ -307,44 +328,57 @@ para no perder RTCM3. (Invariante: las correcciones viajan por el módem 4G; nin
MCU debe interrumpirlas.) MCU debe interrumpirlas.)
\end{helgennotice} \end{helgennotice}
\bloque{10}{Respaldo de batería (proto): TP4056 + MT3608} \diagramabloque{9}{\blkStackB}
\queprueba{reproduce carga / respaldo. El PCB usa el LTC4040.}
\bloque{10}{Respaldo de batería (proto): TP4056 + MT3608 + corte de carga (PA8) + apagador}
\queprueba{reproduce carga / respaldo; PA8 corta la carga; el apagador mata todo. El PCB usa el LTC4040.}
\hwtab{% \hwtab{%
\begin{tabularx}{\textwidth}{@{}l X L{4.4cm}@{}} \begin{tabularx}{\textwidth}{@{}l X L{4.4cm}@{}}
\toprule \toprule
\theadconex \theadconex
\midrule \midrule
\redV & 5\,V vehículo (SD-15B-05) $\rightarrow$ TP4056 IN+ & Camino de carga\\ \redV & 5\,V vehículo (SD-15B-05) $\rightarrow$ \textbf{IRF9540 (CHRG\_RUN)} $\rightarrow$ TP4056 IN+ & Camino de carga — \textbf{conmutado por PA8} (el módulo no expone TEMP)\\
\redG & TP4056 IN$-$ $\rightarrow$ GND & \\ \redG & TP4056 IN$-$ $\rightarrow$ GND & \\
\redN & TP4056 BAT+ $\rightarrow$ 18650+ (nodo compartido) & \\ \redN & TP4056 BAT+ $\rightarrow$ 18650+ (nodo compartido) & \\
\redN & 18650+ $\rightarrow$ MT3608 IN+ & Nodo compartido (carga + boost)\\ \redN & 18650+ $\rightarrow$ MT3608 IN+ & Nodo compartido (carga + boost)\\
\redG & 18650$-$ $\rightarrow$ GND & \\ \redG & 18650$-$ $\rightarrow$ GND & \\
\redG & MT3608 IN$-$ / OUT$-$ $\rightarrow$ GND & \\ \redG & MT3608 IN$-$ / OUT$-$ $\rightarrow$ GND & \\
\redV & MT3608 OUT+ (eleva 3.6$\rightarrow$5\,V) $\rightarrow$ 1N5819 $\rightarrow$ MAIN5V & Respaldo (OR)\\ \redV & MT3608 OUT+ (eleva 3.6$\rightarrow$5\,V) $\rightarrow$ 1N5819 $\rightarrow$ \textbf{nodo SYS} & Respaldo (OR)\\
\redV & 5\,V vehículo $\rightarrow$ 1N5819 $\rightarrow$ MAIN5V & Primario (OR) — el vehículo tiene prioridad\\ \redV & 5\,V vehículo $\rightarrow$ 1N5819 $\rightarrow$ \textbf{nodo SYS} & Primario (OR) — el vehículo tiene prioridad\\
\redN & NTC 10\,k $\rightarrow$ \textbf{pin TEMP del cargador} (TP4056 proto / LTC4040 PCB) & Temperatura de celda — \textbf{NO va al MCU} (ver aviso)\\ \redV & nodo SYS $\rightarrow$ \textbf{apagador de corte} (SPST) $\rightarrow$ riel MAIN5V & \textbf{Corte general}: mata vehículo \textbf{y} batería (= Bloque E del PCB, P11)\\
\redS & PA8 (CHRG\_RUN) $\rightarrow$ R 1\,k$\Omega$ $\rightarrow$ base 2N3904 (B) & Corte de carga por temperatura\\
\redG & 2N3904 emisor (E) $\rightarrow$ GND & \\
\redS & 2N3904 colector (C) $\rightarrow$ compuerta IRF9540 (G) & Mismo patrón que el Bloque~3\\
\redV & compuerta IRF9540 (G) $\rightarrow$ R 10\,k$\Omega$ $\rightarrow$ 5\,V vehículo & Pull-up $\rightarrow$ \textbf{sin carga con MCU ausente}\\
\redV & IRF9540 source (S) $\rightarrow$ 5\,V vehículo · drain (D) $\rightarrow$ TP4056 IN+ & PA8 \textbf{ALTO = carga permitida}\\
\redN & NTC 10\,k del kit: \textbf{SIN USAR en proto} & El módulo TP4056 no expone TEMP; en el PCB va al pin NTC del LTC4040\\
\redA & 18650+ $\rightarrow$ (Bloque 4) $\rightarrow$ PA0 (BAT\_SENSE) & Sensado de voltaje de batería\\ \redA & 18650+ $\rightarrow$ (Bloque 4) $\rightarrow$ PA0 (BAT\_SENSE) & Sensado de voltaje de batería\\
\redN & MT3608: ajustar \textbf{apenas} $<$ 5\,V del vehículo & Prioridad al vehículo; el PCB usa el LTC4040\\ \redN & MT3608: ajustar \textbf{apenas} $<$ 5\,V del vehículo & Prioridad al vehículo; el PCB usa el LTC4040\\
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\begin{helgennotice}[El NTC del pack va al cargador, NUNCA al MCU] \begin{helgennotice}[Corte de carga en el proto: lo hace el MCU (PA8), porque el TP4056 del kit no tiene NTC]
El termistor pegado a la celda se conecta al \textbf{pin TEMP del cargador} (TP4056 en el En el PCB, el termistor de la celda va al pin NTC del \textbf{LTC4040} y el cargador
proto, LTC4040 en el PCB): es el \textbf{cargador} quien califica la carga por temperatura y califica la carga por temperatura en hardware. El módulo TP4056 del kit \textbf{no expone
la corta si la celda está fría o caliente — protección por hardware, sin firmware de por el pin TEMP}, así que en el proto esa protección la hace el \textbf{firmware}: lee la
medio. \textbf{No lo lleves al Blackpill.} El MCU lee la temperatura por I\textsuperscript{2}C \textbf{triple ruta de temperatura} (AHT10 · LM35 $\rightarrow$ PA7 · NTC $\rightarrow$ PB1)
con el \textbf{TMP102} (Bloque~6, en pigtail al punto caliente). El divisor y con \textbf{PA8 (CHRG\_RUN)} corta el 5\,V de entrada del TP4056 vía el IRF9540. Con el
NTC $\rightarrow$ PB1 del \textbf{Bloque~11} es otra pieza: la ruta \textit{analógica} de MCU ausente o en reset, el pull-up deja el FET \textbf{apagado = sin carga} (estado seguro:
punto caliente cuando no hay SHT40/TMP102. el proto no tiene guardia térmica de hardware). \textbf{Ojo firmware:} la polaridad es
\textbf{inversa} a la del PCB — proto CHRG\_RUN ALTO = carga; PCB CHRG\_EN ALTO = corta
(LTC4040 con pull-down, carga habilitada sin MCU porque su NTC sí vigila). Usa un flag de
compilación.
\end{helgennotice} \end{helgennotice}
\noindent\textbf{Pack:} 1S4P $\sim$\textbf{12\,Ah} — \textit{nunca} 40\,Ah (ese dato fue un \noindent\textbf{Pack:} 1S4P $\sim$\textbf{12\,Ah} — \textit{nunca} 40\,Ah (ese dato fue un
error, corregido el 2026-06-30). Con 12\,Ah, la corriente de carga del LTC4040 se dimensiona error, corregido el 2026-06-30). Con 12\,Ah, la corriente de carga del LTC4040 se dimensiona
con R\textsubscript{PROG} $\approx$ C/5 $\le$ 2.5\,A. con R\textsubscript{PROG} $\approx$ C/5 $\le$ 2.5\,A.
\bloque{11}{Temperatura analógica (NTC 10\,k $\rightarrow$ PB1)} \diagramabloque{10}{\blkBatt}
\queprueba{sin SHT40, esta es tu temperatura.}
\bloque{11}{Temperatura analógica: NTC 10\,k $\rightarrow$ PB1 + LM35 $\rightarrow$ PA7}
\queprueba{dos canales analógicos independientes; con el AHT10 (Bloque~6) completan la triple ruta.}
\hwtab{% \hwtab{%
\begin{tabularx}{\textwidth}{@{}l X L{4.4cm}@{}} \begin{tabularx}{\textwidth}{@{}l X L{4.4cm}@{}}
@ -352,16 +386,24 @@ con R\textsubscript{PROG} $\approx$ C/5 $\le$ 2.5\,A.
\theadconex \theadconex
\midrule \midrule
\redT & 3V3 $\rightarrow$ R 10\,k$\Omega$ (1\,\%) $\rightarrow$ nodo & Divisor fijo (superior)\\ \redT & 3V3 $\rightarrow$ R 10\,k$\Omega$ (1\,\%) $\rightarrow$ nodo & Divisor fijo (superior)\\
\redA & nodo $\rightarrow$ PB1 (ADC1\_IN9, libre) & $\approx$1.65\,V @ 25\,\textdegree C; baja al calentar\\ \redA & nodo $\rightarrow$ PB1 (ADC1\_IN9) & $\approx$1.65\,V @ 25\,\textdegree C; baja al calentar\\
\redN & nodo $\rightarrow$ NTC 10\,k$\Omega$ $\rightarrow$ GND & Termistor · Beta $\approx$3950\\ \redN & nodo $\rightarrow$ NTC 10\,k$\Omega$ $\rightarrow$ GND & Termistor · Beta $\approx$3950\\
\redG & nodo $\rightarrow$ C 100\,nF $\rightarrow$ GND & Filtro\\ \redG & nodo $\rightarrow$ C 100\,nF $\rightarrow$ GND & Filtro\\
\redN & Colócalo en el punto caliente (batería / módem) & Firmware: Beta/Steinhart + CHRG\_EN\\ \redV & LM35 VCC $\rightarrow$ MAIN5V & \textbf{Necesita $\ge$4\,V $\rightarrow$ al 5\,V, NO al 3V3}\\
\redA & LM35 OUT $\rightarrow$ PA7 (ADC1\_IN7) & 10\,mV/\textdegree C; $\le$1.5\,V a 150\,\textdegree C $\rightarrow$ seguro para el ADC de 3.3\,V\\
\redG & LM35 GND $\rightarrow$ GND & \\
\redG & LM35 VCC $\rightarrow$ C 100\,nF $\rightarrow$ GND & Desacople junto al sensor\\
\redN & Colocación: \textbf{NTC = contacto} en el punto caliente (celda/módem) · \textbf{LM35 = aire/tarjeta} (junto a TP4056/MT3608) · AHT10 = aire + RH & Firmware: Beta/Steinhart (PB1), 10\,mV/\textdegree C (PA7); cualquiera puede disparar CHRG\_RUN\\
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\noindent{\small\textit{Este NTC es \textbf{distinto} del NTC del cargador (Bloque~10): este \noindent{\small\textit{Este NTC es \textbf{distinto} del NTC del kit para el cargador
sí va al MCU (PB1) y mide el punto caliente; aquel va al pin TEMP del cargador y protege la (Bloque~10, sin usar en proto): este sí va al MCU (PB1) y mide el punto caliente por
celda.}} contacto. \textbf{Triple temperatura} = AHT10 (I\textsuperscript{2}C) + LM35 (ADC) + NTC
(ADC) — tres tecnologías y tres rutas eléctricas independientes; la \textbf{humedad} la da
solo el AHT10.}}
\diagramabloque{11}{\blkTempA}
\section{Patitas de los componentes} \section{Patitas de los componentes}
@ -377,6 +419,9 @@ IRF9540 (TO-220, canal P) & Metal atrás, izq $\rightarrow$ der: \textbf{G -- D
IRLZ44N (TO-220, lógico) & Metal atrás, izq $\rightarrow$ der: \textbf{G -- D -- S}. Debe ser «lógico» (\textbf{NO} IRF540/IRFZ44)\\ IRLZ44N (TO-220, lógico) & Metal atrás, izq $\rightarrow$ der: \textbf{G -- D -- S}. Debe ser «lógico» (\textbf{NO} IRF540/IRFZ44)\\
BAT54 · 1N5819 (diodos) & La banda impresa = \textbf{cátodo (K)}\\ BAT54 · 1N5819 (diodos) & La banda impresa = \textbf{cátodo (K)}\\
NTC 10\,k (termistor) & Sin polaridad. Divisor con R 10\,k (1\,\%) a 3V3\\ NTC 10\,k (termistor) & Sin polaridad. Divisor con R 10\,k (1\,\%) a 3V3\\
LM35 (TO-92) & Cara plana hacia ti, izq $\rightarrow$ der: \textbf{+V\textsubscript{S} -- OUT -- GND}. \textbf{Al revés se quema}\\
AHT10 (tarjetita I\textsuperscript{2}C) & 4 pines rotulados: VCC (\textbf{a 3V3}) · GND · SCL · SDA\\
Capacitor electrolítico & \textbf{CON polaridad}: la franja/pata corta = negativo ($-$) $\rightarrow$ GND\\
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
@ -393,8 +438,8 @@ NTC 10\,k (termistor) & Sin polaridad. Divisor con R 10\,k (1\,\%) a 3V3\\
3 & Interruptor de carga & Bloque 3. Confirma: \textbf{APAGADO al reset}, ON cuando PA1 activa.\\ 3 & Interruptor de carga & Bloque 3. Confirma: \textbf{APAGADO al reset}, ON cuando PA1 activa.\\
4 & Sensado & Bloque 4. Divisores PA0/PA4; ignición por DFR1015 (12/24\,V) o el apagador a 3V3.\\ 4 & Sensado & Bloque 4. Divisores PA0/PA4; ignición por DFR1015 (12/24\,V) o el apagador a 3V3.\\
5 & Ventilador & Bloque 5. \textbf{Primero} ajusta el LM2596 a 5.0\,V, luego conecta el ventilador.\\ 5 & Ventilador & Bloque 5. \textbf{Primero} ajusta el LM2596 a 5.0\,V, luego conecta el ventilador.\\
6 & Temperatura & Bloque 6 (si tienes SHT40/TMP102) o Bloque 11 (NTC $\rightarrow$ PB1).\\ 6 & Temperatura / humedad & Bloques 6 y 11: AHT10 (0x38, \textbf{solo} en el bus) + LM35 $\rightarrow$ PA7 + NTC $\rightarrow$ PB1. Verifica las tres lecturas en el log.\\
7 & Respaldo de batería & Bloque 10. TP4056 + MT3608 (ajusta el MT3608 apenas $<$ 5\,V del vehículo).\\ 7 & Respaldo de batería & Bloque 10. TP4056 + MT3608 (ajusta el MT3608 apenas $<$ 5\,V del vehículo) + corte de carga PA8 (CHRG\_RUN) + \textbf{apagador} SYS $\rightarrow$ MAIN5V. Prueba: PA8 en bajo = el LED CHRG del TP4056 se apaga; el apagador mata todo.\\
8 & Stack RTK & Bloque 8. Solo 4 cables (SAL, GND, PA2, PA3); el 4G va en el socket XBee del Pro.\\ 8 & Stack RTK & Bloque 8. Solo 4 cables (SAL, GND, PA2, PA3); el 4G va en el socket XBee del Pro.\\
9 & (Opcional) Modo B & Bloque 9. Relé por breakout XBee — solo si vas a probar el diagnóstico por NTRIP.\\ 9 & (Opcional) Modo B & Bloque 9. Relé por breakout XBee — solo si vas a probar el diagnóstico por NTRIP.\\
\bottomrule \bottomrule
@ -414,10 +459,15 @@ NTC 10\,k (termistor) & Sin polaridad. Divisor con R 10\,k (1\,\%) a 3V3\\
\item El 4G va en el \textbf{socket XBee del Pro} (no al Blackpill), salvo el Modo B. \item El 4G va en el \textbf{socket XBee del Pro} (no al Blackpill), salvo el Modo B.
En el PCB v3, el bypass UART2 \textbf{normalmente cerrado} garantiza que un MCU En el PCB v3, el bypass UART2 \textbf{normalmente cerrado} garantiza que un MCU
muerto/ausente nunca corte el RTCM3 (ver Bloque~9). muerto/ausente nunca corte el RTCM3 (ver Bloque~9).
\item El NTC del pack va al \textbf{pin TEMP del cargador} (TP4056 proto / LTC4040 PCB), \item \textbf{AHT10 solo a 3V3} (1.8--3.6\,V, se quema a 5\,V) y \textbf{solo él} en el bus
\textbf{nunca al MCU}. El MCU lee temperatura por el TMP102 (I\textsuperscript{2}C, I\textsuperscript{2}C (restricción Aosong); dirección \textbf{0x38 fija}.
Bloque~6); el NTC $\rightarrow$ PB1 (Bloque~11) es la ruta de punto caliente cuando \textbf{LM35 al revés:} necesita $\ge$4\,V $\rightarrow$ va al \textbf{5\,V}, nunca al 3V3.
no hay SHT40/TMP102. \item El TP4056 del kit \textbf{no expone el pin TEMP} $\rightarrow$ el corte de carga lo hace
\textbf{PA8 (CHRG\_RUN)} sobre el IN+ (Bloque~10). \textbf{Polaridad inversa al PCB}:
proto ALTO = carga; PCB (CHRG\_EN) ALTO = corta — flag en firmware. El NTC del kit
queda sin usar en proto (en el PCB va al LTC4040).
\item Capacitores electrolíticos (10\,$\mu$F / 100\,$\mu$F) \textbf{con polaridad}: negativo
a GND. Los 100\,nF cerámicos no tienen polaridad.
\item 18650: respeta la polaridad; pack 1S4P $\sim$\textbf{12\,Ah} (nunca 40\,Ah). \item 18650: respeta la polaridad; pack 1S4P $\sim$\textbf{12\,Ah} (nunca 40\,Ah).
\textbf{Bench-test} el firmware antes de flashear en campo. \textbf{Bench-test} el firmware antes de flashear en campo.
\item Cobertura de partes: \textbf{Sección 1 + 3} de la lista de compras = suficiente para \item Cobertura de partes: \textbf{Sección 1 + 3} de la lista de compras = suficiente para
@ -440,11 +490,20 @@ convertidores». Nuevo: tabla «Estado y cambios», aviso del \textbf{bypass UAR
cerrado} del PCB (Bloque 9), aclaración \textbf{NTC del cargador vs TMP102 vs NTC$\rightarrow$PB1}, cerrado} del PCB (Bloque 9), aclaración \textbf{NTC del cargador vs TMP102 vs NTC$\rightarrow$PB1},
pack 1S4P $\sim$12\,Ah (nunca 40\,Ah), leyenda con colores de los diagramas CircuiTikZ, pack 1S4P $\sim$12\,Ah (nunca 40\,Ah), leyenda con colores de los diagramas CircuiTikZ,
figura del Bloque 3 y referencias cruzadas.\\ figura del Bloque 3 y referencias cruzadas.\\
v2.2 & 2026-07-03 & \textbf{Suite de sensores realineada a las partes en mano:} AHT10
(0x38, solo en el bus, a 3V3) sustituye al SHT40 en el Bloque 6 (SHT40/TMP102 quedan para
el PCB); \textbf{LM35 $\rightarrow$ PA7} nuevo en el Bloque 11 $\rightarrow$ \textbf{triple
temperatura} (AHT10 + LM35 + NTC$\rightarrow$PB1), humedad = solo AHT10. \textbf{Corte de
carga por PA8 (CHRG\_RUN)} sobre el IN+ del TP4056 (el módulo no expone TEMP; inversión de
polaridad vs PCB) y \textbf{apagador de corte general} nodo SYS $\rightarrow$ MAIN5V
(= Bloque E del PCB) en el Bloque 10. Reset/gauge dejan de ser opcionales; patitas del LM35,
AHT10 y electrolíticos; capacitores en mano (100\,nF / 10\,$\mu$F / 100\,$\mu$F).
\textbf{Diagramas CircuiTikZ incrustados} al final de cada uno de los 11 bloques.\\
\bottomrule \bottomrule
\end{tabularx}} \end{tabularx}}
\vspace{6pt} \vspace{6pt}
\noindent{\footnotesize Helgen Technologies · Proyecto Drogheda · Guía de conexión en \noindent{\footnotesize Helgen Technologies · Proyecto Drogheda · Guía de conexión en
protoboard v2.1 (bloques 1--11) · Firmware v2.3 · Documento para el técnico de armado. protoboard v2.2 (bloques 1--11) · Firmware v2.3 · Documento para el técnico de armado.
Datos de conexión: \texttt{Drogheda\_Conexiones-por-Bloque\_Proto\_v1.xlsx} · Diagramas: Datos de conexión: \texttt{Drogheda\_Conexiones-por-Bloque\_Proto\_v1.xlsx} · Diagramas:
\texttt{circuitikz-wiring/}.} \texttt{circuitikz-wiring/}.}

View File

@ -1,5 +1,5 @@
% Helgen Drogheda — Guía de Conexión en Protoboard · DRG-PROTO-001 (es-MX) % Helgen Drogheda — Guía de Conexión en Protoboard · DRG-PROTO-001 (es-MX)
% Watchdog HBOX v3 · tarjeta DEV STM32F411 Blackpill · bloques 1–11 · v2.1 % Watchdog HBOX v3 · tarjeta DEV STM32F411 Blackpill · bloques 1–11 · v2.2
% %
% Compilar (preferido, con fuentes de marca): latexmk -xelatex main.tex % Compilar (preferido, con fuentes de marca): latexmk -xelatex main.tex
% Compilar (fallback sin fuentes de marca): latexmk -pdf main.tex (pdfLaTeX) % Compilar (fallback sin fuentes de marca): latexmk -pdf main.tex (pdfLaTeX)
@ -43,6 +43,15 @@
\newcommand{\bloque}[2]{\subsection*{Bloque #1 · #2}} \newcommand{\bloque}[2]{\subsection*{Bloque #1 · #2}}
\newcommand{\queprueba}[1]{\noindent{\small\textit{\textbf{Qué prueba:} #1}}\par\smallskip} \newcommand{\queprueba}[1]{\noindent{\small\textit{\textbf{Qué prueba:} #1}}\par\smallskip}
% ---- Diagrama CircuiTikZ incrustado por bloque (mismas macros que la lámina) ----
\newcommand{\diagramabloque}[2]{%
\begin{center}
\begin{adjustbox}{max width=\textwidth}
\begin{tikzpicture}[every node/.append style={font=\footnotesize}]#2\end{tikzpicture}
\end{adjustbox}\\
{\small\itshape Bloque #1 — mismo dibujo que la lámina CircuiTikZ (\texttt{circuitikz-wiring/}).}
\end{center}}
% ---- Encabezado estándar de las tablas de conexión ---- % ---- Encabezado estándar de las tablas de conexión ----
\newcommand{\theadconex}{\rowcolor{HelgenIndigo} \newcommand{\theadconex}{\rowcolor{HelgenIndigo}
\textcolor{white}{\textbf{Red}} & \textcolor{white}{\textbf{Red}} &
@ -53,8 +62,8 @@
\helgenportada{Guía de Conexión en Protoboard}{HBOX Watchdog v3 — tarjeta DEV / protoboard · bloques 1--11}{% \helgenportada{Guía de Conexión en Protoboard}{HBOX Watchdog v3 — tarjeta DEV / protoboard · bloques 1--11}{%
\begin{tabular}{@{}ll@{}} \begin{tabular}{@{}ll@{}}
\textbf{Documento} & DRG-PROTO-001 — Guía de Conexión en Protoboard\\ \textbf{Documento} & DRG-PROTO-001 — Guía de Conexión en Protoboard\\
\textbf{Versión} & 2.1 (sucede a la v2; fuente LaTeX reconstruida y mantenida en el repo)\\ \textbf{Versión} & 2.2 (suite de sensores en mano: AHT10 + LM35 + NTC; corte de carga PA8; apagador general)\\
\textbf{Fecha} & 2 de julio de 2026\\ \textbf{Fecha} & 3 de julio de 2026\\
\textbf{Firmware} & v2.3 · MCU STM32F411 «Blackpill»\\ \textbf{Firmware} & v2.3 · MCU STM32F411 «Blackpill»\\
\textbf{Dirigido a} & Técnico de armado — sigue el orden de la sección~\ref{sec:orden}\\ \textbf{Dirigido a} & Técnico de armado — sigue el orden de la sección~\ref{sec:orden}\\
\textbf{Fuente de datos} & \texttt{Drogheda\_Conexiones-por-Bloque\_Proto\_v1.xlsx} (autoritativa)\\ \textbf{Fuente de datos} & \texttt{Drogheda\_Conexiones-por-Bloque\_Proto\_v1.xlsx} (autoritativa)\\

View File

@ -52,7 +52,7 @@
\title[Watchdog v3 — Cableado del prototipo]{HBOX Watchdog v3 — Cableado del Prototipo} \title[Watchdog v3 — Cableado del prototipo]{HBOX Watchdog v3 — Cableado del Prototipo}
\subtitle{Guía de armado en protoboard — Tarjeta DEV — Firmware v2.3} \subtitle{Guía de armado en protoboard — Tarjeta DEV — Firmware v2.3}
\author[Helgen — Drogheda]{Helgen Technologies — Proyecto Drogheda} \author[Helgen — Drogheda]{Helgen Technologies — Proyecto Drogheda}
\date{Diagramas v2 · 2026-07-02} \date{Diagramas v2.1 · 2026-07-03}
\begin{document} \begin{document}
@ -63,7 +63,7 @@
\item Un bloque = un paso del armado; mismo orden que la guía PDF (1 $\rightarrow$ 11). \item Un bloque = un paso del armado; mismo orden que la guía PDF (1 $\rightarrow$ 11).
\item El \alert{color del cable} indica la red (5\,V, 3.3\,V, GND, señal, analógico, ignición cruda); une todos los GND. Sensados analógicos: \alert{PA0, PA4 y PB1}. \item El \alert{color del cable} indica la red (5\,V, 3.3\,V, GND, señal, analógico, ignición cruda); une todos los GND. Sensados analógicos: \alert{PA0, PA4 y PB1}.
\item \alert{PA5 (ignición)} es digital, sin divisor, máx 3.3\,V. \item \alert{PA5 (ignición)} es digital, sin divisor, máx 3.3\,V.
\item El \alert{NTC de la batería} va al pin \alert{TEMP del cargador} (TP4056 proto / LTC4040 en PCB), no al MCU; el NTC en \alert{PB1} (bloque 11) mide el punto caliente de la placa. \item El módulo TP4056 \alert{no expone el pin TEMP}: el NTC del pack queda sin usar en proto (en el PCB va al LTC4040). La carga la corta el MCU por \alert{PA8 (CHRG\_RUN)} — bloque 10. Temperatura: \alert{AHT10} (bloque 6) + \alert{LM35 $\rightarrow$ PA7} y \alert{NTC $\rightarrow$ PB1} (bloque 11).
\item El \alert{ventilador} usa un 5\,V separado, no la salida ``stack''. \item El \alert{ventilador} usa un 5\,V separado, no la salida ``stack''.
\item Cobertura: \textbf{Sección 1 + 3} alcanza para todo esto; Sección 2 (TP4056/MT3608) sólo para el respaldo de batería. \item Cobertura: \textbf{Sección 1 + 3} alcanza para todo esto; Sección 2 (TP4056/MT3608) sólo para el respaldo de batería.
\end{itemize} \end{itemize}
@ -74,12 +74,12 @@
\blockframe{3 · Interruptor de carga del ``stack'' (PA1) — el corazón}{\blkCarga} \blockframe{3 · Interruptor de carga del ``stack'' (PA1) — el corazón}{\blkCarga}
\blockframe{4 · Sensado: batería / 5 V / ignición}{\blkSensado} \blockframe{4 · Sensado: batería / 5 V / ignición}{\blkSensado}
\blockframe{5 · Ventilador (2 hilos, 5 V — PA6)}{\blkVent} \blockframe{5 · Ventilador (2 hilos, 5 V — PA6)}{\blkVent}
\blockframe{6 · Sensor de temperatura I\textsuperscript{2}C (PB6 / PB7)}{\blkTemp} \blockframe{6 · Temperatura y humedad I\textsuperscript{2}C — AHT10 (PB6 / PB7)}{\blkTemp}
\blockframe{7 · Reset (opcional) y Gauge de batería}{\blkResetGauge} \blockframe{7 · Reset y Gauge de batería}{\blkResetGauge}
\blockframe{8 · Conexión del stack RTK — modo por defecto (observa)}{\blkStack} \blockframe{8 · Conexión del stack RTK — modo por defecto (observa)}{\blkStack}
\blockframe{9 · Modo B — Diagnóstico por NTRIP (relé + inyección \$PHLG)}{\blkStackB} \blockframe{9 · Modo B — Diagnóstico por NTRIP (relé + inyección \$PHLG)}{\blkStackB}
\blockframe{10 · Respaldo de batería (proto): TP4056 + MT3608}{\blkBatt} \blockframe{10 · Respaldo de batería (proto): TP4056 + MT3608 + corte (PA8 / apagador)}{\blkBatt}
\blockframe{11 · Temperatura analógica (NTC 10k $\rightarrow$ PB1)}{\blkTempA} \blockframe{11 · Temperatura analógica (NTC $\rightarrow$ PB1 + LM35 $\rightarrow$ PA7)}{\blkTempA}
\begin{frame}[standout] \begin{frame}[standout]
Diagrama de referencia\\ para el armado del prototipo Diagrama de referencia\\ para el armado del prototipo

View File

@ -10,7 +10,7 @@
\node[anchor=north west,font=\bfseries\Large,Indigo] at (-2,6.0) \node[anchor=north west,font=\bfseries\Large,Indigo] at (-2,6.0)
{HBOX Watchdog v3 — Diagrama de Cableado del Prototipo (CircuiTikZ)}; {HBOX Watchdog v3 — Diagrama de Cableado del Prototipo (CircuiTikZ)};
\node[anchor=north west,font=\small,gray] at (-2,5.2) \node[anchor=north west,font=\small,gray] at (-2,5.2)
{Tarjeta DEV · Firmware v2.3 · STM32F411 Blackpill · Proyecto Drogheda / Helgen · Diagramas v2 · 2026-07-02}; {Tarjeta DEV · Firmware v2.3 · STM32F411 Blackpill · Proyecto Drogheda / Helgen · Diagramas v2.1 · 2026-07-03};
% legend % legend
\begin{scope}[shift={(-2,4.2)}] \begin{scope}[shift={(-2,4.2)}]
\foreach \i/\c/\t in {0/net5V/{5 V},1.7/net3V3/{3.3 V},3.3/netGND/GND,4.7/netSig/{Señal},6.3/netAna/{Analóg. (PA0, PA4, PB1)},10.1/netIgn/{Ign. cruda 12--24 V}}{ \foreach \i/\c/\t in {0/net5V/{5 V},1.7/net3V3/{3.3 V},3.3/netGND/GND,4.7/netSig/{Señal},6.3/netAna/{Analóg. (PA0, PA4, PB1)},10.1/netIgn/{Ign. cruda 12--24 V}}{
@ -25,12 +25,12 @@
\cell{0}{-1}{3 · Interruptor de carga (PA1) — el corazón}{\blkCarga} \cell{0}{-1}{3 · Interruptor de carga (PA1) — el corazón}{\blkCarga}
\cell{1}{-1}{4 · Sensado: batería / 5 V / ignición}{\blkSensado} \cell{1}{-1}{4 · Sensado: batería / 5 V / ignición}{\blkSensado}
\cell{0}{-2}{5 · Ventilador (2 hilos, 5 V)}{\blkVent} \cell{0}{-2}{5 · Ventilador (2 hilos, 5 V)}{\blkVent}
\cell{1}{-2}{6 · Sensor de temperatura I\textsuperscript{2}C}{\blkTemp} \cell{1}{-2}{6 · Temperatura y humedad I\textsuperscript{2}C — AHT10}{\blkTemp}
\cell{0}{-3}{7 · Reset (opcional) y Gauge de batería}{\blkResetGauge} \cell{0}{-3}{7 · Reset y Gauge de batería}{\blkResetGauge}
\cell{0}{-4}{8 · Conexión del stack RTK (modo por defecto): simpleRTK2B Pro + 4G NTRIP}{\blkStack} \cell{0}{-4}{8 · Conexión del stack RTK (modo por defecto): simpleRTK2B Pro + 4G NTRIP}{\blkStack}
\cell{0}{-5}{9 · Modo B — Diagnóstico por NTRIP (relé + inyección \$PHLG)}{\blkStackB} \cell{0}{-5}{9 · Modo B — Diagnóstico por NTRIP (relé + inyección \$PHLG)}{\blkStackB}
\cell{0}{-6}{10 · Respaldo de batería (proto): TP4056 + MT3608 — el PCB usa LTC4040}{\blkBatt} \cell{0}{-6}{10 · Respaldo de batería (proto): TP4056 + MT3608 — el PCB usa LTC4040}{\blkBatt}
\cell{1}{-6}{11 · Temperatura analógica (NTC $\rightarrow$ PB1)}{\blkTempA} \cell{1}{-6}{11 · Temperatura analógica (NTC $\rightarrow$ PB1 + LM35 $\rightarrow$ PA7)}{\blkTempA}
% notes cell (1,-3) % notes cell (1,-3)
\begin{scope}[shift={(1*\cw,-3*\ch)}] \begin{scope}[shift={(1*\cw,-3*\ch)}]
\node[anchor=north west,font=\bfseries,Indigo] at (-2,3.4){Avisos}; \node[anchor=north west,font=\bfseries,Indigo] at (-2,3.4){Avisos};

View File

@ -138,8 +138,8 @@
\newcommand{\blkTemp}{% \newcommand{\blkTemp}{%
\coordinate (r3) at (0,2.6); \coordinate (r3) at (0,2.6);
\node[draw,rounded corners,minimum width=2.3cm,minimum height=2.7cm](S) at (0,0){}; \node[draw,rounded corners,minimum width=2.3cm,minimum height=2.7cm](S) at (0,0){};
\node[font=\bfseries\scriptsize,align=center] at (0,0.7){SHT40 /\\TMP102}; \node[font=\bfseries\scriptsize,align=center] at (0,0.7){AHT10\\(T + RH)};
\node[font=\tiny] at (0,-0.7){0x44 / 0x48}; \node[font=\tiny] at (0,-0.7){0x38 (fija)};
\foreach \y/\nm in {0.9/VCC,0.35/GND,-0.4/SCL,-0.95/SDA}{\draw (1.15,\y)--(1.7,\y); \node[anchor=east,font=\tiny] at (1.05,\y){\nm};} \foreach \y/\nm in {0.9/VCC,0.35/GND,-0.4/SCL,-0.95/SDA}{\draw (1.15,\y)--(1.7,\y); \node[anchor=east,font=\tiny] at (1.05,\y){\nm};}
\draw[net3V3] (1.7,0.9) -| (3.2,2.6); \node[net3V3,anchor=south,font=\scriptsize] at (3.2,2.6){3V3}; \draw[net3V3] (1.7,0.9) -| (3.2,2.6); \node[net3V3,anchor=south,font=\scriptsize] at (3.2,2.6){3V3};
\draw[netGND] (1.7,0.35) -- ++(0.5,0) -- ++(0,-1.4) node[ground]{}; \draw[netGND] (1.7,0.35) -- ++(0.5,0) -- ++(0,-1.4) node[ground]{};
@ -147,6 +147,7 @@
\pin{netSig}{PB7}{3.6,-0.95}{PB7} \draw[netSig] (1.7,-0.95)--(PB7); \pin{netSig}{PB7}{3.6,-0.95}{PB7} \draw[netSig] (1.7,-0.95)--(PB7);
\draw[netSig] (2.6,-0.4) to[R,l=$4.7$k] (2.6,1.8) -- (2.6,2.6) -- (3.2,2.6); \draw[netSig] (2.6,-0.4) to[R,l=$4.7$k] (2.6,1.8) -- (2.6,2.6) -- (3.2,2.6);
\node[anchor=west,font=\scriptsize] at (4.4,-0.7){pull-ups 4.7\,k a 3V3}; \node[anchor=west,font=\scriptsize] at (4.4,-0.7){pull-ups 4.7\,k a 3V3};
\node[anchor=north west,font=\tiny,align=left,text width=9.6cm] at (-1.35,-1.75){\textbf{!} \textbf{AHT10} sustituye al SHT40 en el proto (sin stock; SHT40/TMP102 quedan para el PCB). VCC = \textbf{3V3, NUNCA 5 V} (1.8--3.6 V, el breakout no trae regulador). \textbf{SOLO el AHT10 en el bus} I\textsuperscript{2}C (restricción Aosong); dirección \textbf{0x38 fija} $\rightarrow$ firmware 0x44$\rightarrow$0x38. Mide \textbf{temperatura + humedad} del aire del gabinete.};
} }
% ===== 7 · RESET + GAUGE ===== % ===== 7 · RESET + GAUGE =====
@ -198,10 +199,15 @@
% ===== 10 · RESPALDO DE BATERÍA (PROTO): TP4056 + MT3608 ===== % ===== 10 · RESPALDO DE BATERÍA (PROTO): TP4056 + MT3608 =====
\newcommand{\blkBatt}{% \newcommand{\blkBatt}{%
\coordinate (r5) at (0,2.4); \coordinate (r5) at (0,2.4);
\draw[net5V,line width=1pt] (-2.0,2.4)--(8.8,2.4); \node[net5V,font=\bfseries,anchor=south east] at (8.8,2.45){MAIN5V (al sistema)}; % rail: nodo SYS -> apagador de corte -> MAIN5V
\draw[net5V,line width=1pt] (-2.0,2.4)--(6.9,2.4); \node[net5V,font=\bfseries\tiny,anchor=south east] at (6.85,2.45){nodo SYS};
\draw[net5V,line width=1pt] (6.9,2.4) to[nos] (7.9,2.4); \node[font=\tiny,anchor=south,align=center] at (7.4,2.75){apagador\\de corte};
\draw[net5V,line width=1pt] (7.9,2.4)--(8.8,2.4); \node[net5V,font=\bfseries\tiny,anchor=north east] at (8.8,2.3){MAIN5V};
% vehicle 5V + OR diode D1 % vehicle 5V + OR diode D1
\node[net5V,font=\bfseries\tiny,anchor=east,align=right] at (-2.05,1.4){5 V veh.\\(SD-15B-05)}; \node[net5V,font=\bfseries\tiny,anchor=east,align=right] at (-2.05,1.4){5 V veh.\\(SD-15B-05)};
\draw[net5V,line width=0.9pt] (-2.0,1.4) -- (-0.125,1.4); \draw[net5V,line width=0.9pt] (-2.0,1.4) -- (-1.1,1.4);
\draw[net5V,line width=0.9pt] (-1.1,1.4) to[nos] (-0.125,1.4);
\node[font=\tiny,anchor=north,align=center] at (-0.6,1.13){IRF9540\\CHRG\_RUN (PA8)};
\fill (-1.1,1.4) circle(1.2pt); \draw[line width=0.9pt] (-1.1,1.4) -- (-1.1,1.8); \draw[line width=0.9pt] (-1.1,1.8) to[D] (-1.1,2.4); \node[font=\tiny,anchor=west] at (-1.0,2.06){1N5819}; \fill (-1.1,1.4) circle(1.2pt); \draw[line width=0.9pt] (-1.1,1.4) -- (-1.1,1.8); \draw[line width=0.9pt] (-1.1,1.8) to[D] (-1.1,2.4); \node[font=\tiny,anchor=west] at (-1.0,2.06){1N5819};
% TP4056 charger % TP4056 charger
\node[draw,rounded corners,fill=blue!6,minimum width=1.55cm,minimum height=1.1cm,font=\tiny,align=center](TP) at (0.65,1.0){TP4056\\cargador}; \node[draw,rounded corners,fill=blue!6,minimum width=1.55cm,minimum height=1.1cm,font=\tiny,align=center](TP) at (0.65,1.0){TP4056\\cargador};
@ -211,14 +217,14 @@
\draw (2.5,0.74) -- (2.5,0.24); \draw (2.5,0.24) to[battery1] (2.5,-1.2); \fill (2.5,0.74) circle(1.2pt); \draw (2.5,0.74) -- (2.5,0.24); \draw (2.5,0.24) to[battery1] (2.5,-1.2); \fill (2.5,0.74) circle(1.2pt);
\node[font=\tiny,anchor=east,align=right] at (2.28,-0.55){18650\\1S4P $\sim$12 Ah}; \node[font=\tiny,anchor=east,align=right] at (2.28,-0.55){18650\\1S4P $\sim$12 Ah};
\draw[line width=0.9pt] (2.5,-1.2) -- (2.5,-1.65) node[ground]{}; \draw[line width=0.9pt] (2.5,-1.2) -- (2.5,-1.65) node[ground]{};
% NTC (cell temp) % NTC (cell temp) — UNUSED on proto: the TP4056 module has no TEMP pin
\draw[line width=0.8pt] (3.8,-0.28) to[thR,l_={NTC 10k}] (3.8,-1.2) node[ground]{}; \node[font=\tiny,anchor=south,align=center] at (3.8,-0.23){NTC — temp de celda\\$\rightarrow$ TEMP del cargador}; \draw[gray,line width=0.8pt,densely dashed] (3.8,-0.28) to[thR,l_={NTC 10k}] (3.8,-1.2) node[ground]{}; \node[gray,font=\tiny,anchor=south,align=center] at (3.8,-0.23){NTC — SIN USAR en proto\\(TP4056 sin pin TEMP; PCB $\rightarrow$ LTC4040)};
% MT3608 boost % MT3608 boost
\node[draw,rounded corners,fill=blue!6,minimum width=1.7cm,minimum height=1.1cm,font=\tiny,align=center](MT) at (4.75,1.0){MT3608\\elev.$\rightarrow$5 V}; \node[draw,rounded corners,fill=blue!6,minimum width=1.7cm,minimum height=1.1cm,font=\tiny,align=center](MT) at (4.75,1.0){MT3608\\elev.$\rightarrow$5 V};
\draw[line width=0.9pt] (4.75,0.45) -- (4.75,-0.55) node[ground]{}; \draw[line width=0.9pt] (4.75,0.45) -- (4.75,-0.55) node[ground]{};
\draw[line width=0.9pt] (5.6,1.26) -- (6.2,1.26); \fill (6.2,1.26) circle(1.2pt); \draw[line width=0.9pt] (6.2,1.26) -- (6.2,1.8); \draw[line width=0.9pt] (6.2,1.8) to[D] (6.2,2.4); \node[font=\tiny,anchor=west] at (6.3,2.06){1N5819}; \draw[line width=0.9pt] (5.6,1.26) -- (6.2,1.26); \fill (6.2,1.26) circle(1.2pt); \draw[line width=0.9pt] (6.2,1.26) -- (6.2,1.8); \draw[line width=0.9pt] (6.2,1.8) to[D] (6.2,2.4); \node[font=\tiny,anchor=west] at (6.3,2.06){1N5819};
% note % note
\node[anchor=north west,font=\tiny,align=left,text width=10.4cm] at (-2.05,-2.05){\textbf{!} \textbf{Stand-in de banco} (ya lo tienes): el \textbf{vehículo carga el 18650} por el TP4056; el \textbf{MT3608 eleva} 3.6 V $\rightarrow$ 5 V; los \textbf{2× 1N5819} hacen OR de veh + respaldo hacia MAIN5V (ajusta el MT3608 apenas por debajo del 5 V del vehículo para que el vehículo tenga prioridad). \textbf{BAT\_SENSE} = 18650+ $\rightarrow$ PA0 (Bloque 4). El \textbf{NTC va al pin TEMP del cargador} (TP4056 proto / LTC4040 en PCB), \textbf{no al MCU}; el MCU lee la temperatura por el \textbf{TMP102} (I\textsuperscript{2}C, Bloque 6). El \textbf{PCB usa el LTC4040} (Bloque B, por diseñar).}; \node[anchor=north west,font=\tiny,align=left,text width=10.4cm] at (-2.05,-2.05){\textbf{!} \textbf{Stand-in de banco} (ya lo tienes): el \textbf{vehículo carga el 18650} por el TP4056; el \textbf{MT3608 eleva} 3.6 V $\rightarrow$ 5 V; los \textbf{2× 1N5819} hacen OR de veh + respaldo hacia el \textbf{nodo SYS}, y el \textbf{apagador de corte} (SPST) une SYS $\rightarrow$ MAIN5V: \textbf{mata vehículo Y batería} (= Bloque E del PCB, P11). Ajusta el MT3608 apenas $<$ 5 V del vehículo (prioridad al vehículo). \textbf{BAT\_SENSE} = 18650+ $\rightarrow$ PA0 (Bloque 4). El módulo TP4056 \textbf{no expone el pin TEMP} $\rightarrow$ el NTC del kit queda \textbf{SIN USAR} en proto (en el PCB va al LTC4040); la protección térmica de carga la hace el MCU con \textbf{PA8 (CHRG\_RUN)}: 1 k $\rightarrow$ 2N3904 $\rightarrow$ IRF9540 (pull-up 10 k) en el IN+ del TP4056. \textbf{PA8 ALTO = carga; MCU ausente = SIN carga} (inversión vs PCB CHRG\_EN $\rightarrow$ flag en firmware). El MCU lee temperatura por \textbf{AHT10} (Bloque 6) + \textbf{LM35 $\rightarrow$ PA7} y \textbf{NTC $\rightarrow$ PB1} (Bloque 11). El \textbf{PCB usa el LTC4040} (Bloque B).};
} }
% ===== 11 · TEMPERATURA ANALÓGICA (NTC 10k -> PB1 ADC) ===== % ===== 11 · TEMPERATURA ANALÓGICA (NTC 10k -> PB1 ADC) =====
@ -232,7 +238,16 @@
\draw[netAna,line width=0.9pt] (nd) -- (1.3,0.45); \pin{netAna}{PB1}{1.6,0.45}{PB1} \draw[netAna,line width=0.9pt] (nd) -- (1.3,0.45); \pin{netAna}{PB1}{1.6,0.45}{PB1}
\node[font=\tiny,anchor=west] at (1.95,0.45){ADC (temperatura)}; \node[font=\tiny,anchor=west] at (1.95,0.45){ADC (temperatura)};
\draw (nd) -- (-0.85,0.45); \draw (-0.85,0.45) to[C,l_=100\,nF] (-0.85,-0.75) node[ground]{}; \draw (nd) -- (-0.85,0.45); \draw (-0.85,0.45) to[C,l_=100\,nF] (-0.85,-0.75) node[ground]{};
\node[anchor=north west,font=\scriptsize,align=left,text width=9.4cm] at (-1.7,-1.9){\textbf{!} \textbf{Sin SHT40, ésta es tu temperatura.} Divisor \textbf{3V3 — 10k(1\%) — NTC 10k — GND} $\to$ \textbf{PB1} (ADC1\_IN9, libre). $\approx$1.65 V a 25 °C; baja al calentar. $\approx$165\,$\mu$A (sin auto-calentamiento). Firmware: leer ADC + \textbf{Beta} ($\approx$3950)/Steinhart. \textbf{Colócalo en el punto caliente} (batería/modem) $>$ aire; puede disparar \textbf{CHRG\_EN} (corte de carga). Es PCB/firmware — en protoboard puentea el NTC a PB1 para probar.}; % LM35 (second analog channel -> PA7)
\node[draw,rounded corners,minimum width=1.5cm,minimum height=1.7cm,font=\bfseries\scriptsize,align=center](LM) at (6.3,0.45){LM35};
\node[font=\tiny,anchor=north] at (6.3,-0.45){TO-92};
\draw[net5V,line width=0.9pt] (6.3,1.3) -- (6.3,1.95); \node[net5V,font=\bfseries\scriptsize,anchor=south] at (6.3,1.95){MAIN5V (5 V)};
\draw[netGND,line width=0.9pt] (6.3,-0.75) -- (6.3,-1.15) node[ground]{};
\draw[netAna,line width=0.9pt] (7.05,0.45) -- (7.8,0.45); \pin{netAna}{PA7}{8.1,0.45}{PA7}
\node[font=\tiny,anchor=west] at (8.45,0.45){ADC1\_IN7};
\node[font=\tiny,anchor=south] at (7.42,0.5){OUT};
\draw[netGND,line width=0.7pt] (5.55,1.0) -- (5.0,1.0); \draw (5.0,1.0) to[C,l_=100\,nF] (5.0,-0.2) node[ground]{};
\node[anchor=north west,font=\scriptsize,align=left,text width=9.4cm] at (-1.7,-1.9){\textbf{!} \textbf{Ruta analógica — dos canales.} \textbf{NTC $\to$ PB1} (ADC1\_IN9): divisor \textbf{3V3 — 10k(1\%) — NTC 10k — GND}; $\approx$1.65 V a 25 °C, baja al calentar; $\approx$165\,$\mu$A (sin auto-calentamiento); Beta ($\approx$3950)/Steinhart; \textbf{de contacto, al punto caliente} (celda/módem). \textbf{LM35 $\to$ PA7} (ADC1\_IN7): 10 mV/°C, alimentado a \textbf{5 V (nunca 3V3, necesita $\ge$4 V)}; salida $\le$1.5 V $\to$ segura para el ADC; \textbf{aire/tarjeta} (junto a TP4056/MT3608). Con el \textbf{AHT10} (Bloque 6, aire + RH) son \textbf{TRIPLE temperatura por 3 rutas independientes}; la humedad la da solo el AHT10. Cualquiera puede disparar \textbf{CHRG\_RUN} (corte de carga, PA8 — Bloque 10).};
} }
% ===== 9 · MODO B — DIAGNÓSTICO POR NTRIP (relé + inyección $PHLG) ===== % ===== 9 · MODO B — DIAGNÓSTICO POR NTRIP (relé + inyección $PHLG) =====

File diff suppressed because it is too large Load Diff

View File

@ -512,6 +512,44 @@
"via_diameter": 0.6, "via_diameter": 0.6,
"via_drill": 0.3, "via_drill": 0.3,
"wire_width": 6 "wire_width": 6
},
{
"bus_width": 12,
"clearance": 0.2,
"diff_pair_gap": 0.25,
"diff_pair_via_gap": 0.25,
"diff_pair_width": 0.2,
"line_style": 0,
"microvia_diameter": 0.3,
"microvia_drill": 0.1,
"name": "PWR_HI",
"pcb_color": "rgba(0, 0, 0, 0.000)",
"priority": 0,
"schematic_color": "rgba(0, 0, 0, 0.000)",
"track_width": 2.5,
"tuning_profile": "",
"via_diameter": 1.2,
"via_drill": 0.6,
"wire_width": 6
},
{
"bus_width": 12,
"clearance": 0.2,
"diff_pair_gap": 0.25,
"diff_pair_via_gap": 0.25,
"diff_pair_width": 0.2,
"line_style": 0,
"microvia_diameter": 0.3,
"microvia_drill": 0.1,
"name": "PWR_MID",
"pcb_color": "rgba(0, 0, 0, 0.000)",
"priority": 0,
"schematic_color": "rgba(0, 0, 0, 0.000)",
"track_width": 1.0,
"tuning_profile": "",
"via_diameter": 0.8,
"via_drill": 0.4,
"wire_width": 6
} }
], ],
"meta": { "meta": {
@ -519,7 +557,68 @@
}, },
"net_colors": null, "net_colors": null,
"netclass_assignments": null, "netclass_assignments": null,
"netclass_patterns": [] "netclass_patterns": [
{
"netclass": "PWR_HI",
"pattern": "BAT_PLUS"
},
{
"netclass": "PWR_HI",
"pattern": "SW_BAT"
},
{
"netclass": "PWR_HI",
"pattern": "MAIN5V"
},
{
"netclass": "PWR_HI",
"pattern": "VEH5V"
},
{
"netclass": "PWR_HI",
"pattern": "SYS5V"
},
{
"netclass": "PWR_HI",
"pattern": "VIN_SW"
},
{
"netclass": "PWR_MID",
"pattern": "SW_5V"
},
{
"netclass": "PWR_MID",
"pattern": "3V3_MODEM"
},
{
"netclass": "PWR_MID",
"pattern": "5V_FAN"
},
{
"netclass": "PWR_MID",
"pattern": "24V"
},
{
"netclass": "PWR_MID",
"pattern": "24V_IN"
},
{
"netclass": "PWR_MID",
"pattern": "IGN_IN"
},
{
"netclass": "PWR_MID",
"pattern": "SW_FAN"
},
{
"netclass": "PWR_MID",
"pattern": "SW3_NODE"
},
{
"netclass": "PWR_MID",
"pattern": "FAN_RET"
}
]
}, },
"pcbnew": { "pcbnew": {
"last_paths": { "last_paths": {

File diff suppressed because one or more lines are too long

View File

@ -52,7 +52,7 @@ spec'd in design §7 but not yet coded) · ⚪ system/spare · 🔴 issue to fix
| PB10 | — | fan tach → EXTI | 🟡 | code pending | | PB10 | — | fan tach → EXTI | 🟡 | code pending |
| PB6 | — | I²C1 SCL → SHT40+TMP102 | 🟡 | code pending | | PB6 | — | I²C1 SCL → SHT40+TMP102 | 🟡 | code pending |
| PB7 | — | I²C1 SDA → SHT40+TMP102 | 🟡 | code pending | | PB7 | — | I²C1 SDA → SHT40+TMP102 | 🟡 | code pending |
| PA7 | — | NC (TIM3_CH2 spare) | ⚪ | reserved 2nd fan | | PA7 | — | NC (TIM3_CH2 spare) | ⚪ | reserved 2nd fan — **PCB only; the PROTO borrows PA7 for the LM35 (ADC1_IN7, 2026-07-03)** |
| PB12 | — | NC (EXTI spare) | ⚪ | reserved 2nd tach | | PB12 | — | NC (EXTI spare) | ⚪ | reserved 2nd tach |
| PA9 | `RELAY` TX *iff* `ENABLE_PHLG_RELAY` (default **0**) | H3.1 (DNP) → modem DIN | ⚪ | off in v3 ✓ | | PA9 | `RELAY` TX *iff* `ENABLE_PHLG_RELAY` (default **0**) | H3.1 (DNP) → modem DIN | ⚪ | off in v3 ✓ |
| PA10 | `RELAY` RX *iff* relay flag | H3.2 (DNP) ← F9P UART2 TX; Rdfu 22k→3V3 | ⚪ | off in v3; 22k = DFU‑safe ✓ | | PA10 | `RELAY` RX *iff* relay flag | H3.2 (DNP) ← F9P UART2 TX; Rdfu 22k→3V3 | ⚪ | off in v3; 22k = DFU‑safe ✓ |

View File

@ -45,13 +45,25 @@ is a dedicated power-design pass — *not fabricated blind*.
B (LTC4040) + E (cutoff) + F (PA4→VEH5V) + new Block H (fail-safe UART2 bypass) being wired B (LTC4040) + E (cutoff) + F (PA4→VEH5V) + new Block H (fail-safe UART2 bypass) being wired
on PROD; PCB layout kickoff follows.** Sized values live in the delta doc §4. on PROD; PCB layout kickoff follows.** Sized values live in the delta doc §4.
- **Latest proto-assumptions ledger** = `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` - **Latest proto-assumptions ledger** = `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx`
(sheet *Estado y cambios*) + `Drogheda_Guia-Conexion-Protoboard_ES_v2.1.pdf` (source: (sheet *Estado y cambios*) + `Drogheda_Guia-Conexion-Protoboard_ES_v2.2.pdf` (source:
`Guia-Conexion-Protoboard/`). Wiring diagrams: `circuitikz-wiring/` (sheet + Beamer, v2 2026-07-02). `Guia-Conexion-Protoboard/`). Wiring diagrams: `circuitikz-wiring/` (sheet + Beamer, v2.1 2026-07-03).
- **New this pass:** analog **NTC→PB1** hot-spot temperature (block 11 — no SHT40 in hand for - **New this pass:** analog **NTC→PB1** hot-spot temperature (block 11 — no SHT40 in hand for
the proto, so PB1 is the proto's temperature path); **Modo B** NTRIP diagnostic (watchdog the proto, so PB1 is the proto's temperature path); **Modo B** NTRIP diagnostic (watchdog
in-line on the uplink, injects `$PHLG`; RTCM3 downlink stays direct); on the PCB a in-line on the uplink, injects `$PHLG`; RTCM3 downlink stays direct); on the PCB a
**normally-closed relay bypass** on the Modo-B uplink guarantees a dead/absent MCU never cuts **normally-closed relay bypass** on the Modo-B uplink guarantees a dead/absent MCU never cuts
corrections (extends invariant #2/#3). corrections (extends invariant #2/#3).
- **Proto sensor suite realigned to parts in hand (2026-07-03).** No SHT40 (long lead) →
**AHT10** (0x38 fixed, 3V3 **only**, must be **alone** on I²C1 — Aosong restriction) takes
Block 6; **LM35 → PA7** (ADC1_IN7, the last free ADC channel; 5 V supply) joins NTC→PB1 in
Block 11 → **triple temperature** (I²C + 2 ADC, three technologies), humidity = AHT10 only.
SHT40 + TMP102 stay **PCB-only** (PROD schematic untouched). The kit's TP4056 module **does
not expose the TEMP pin** → its NTC is unused on proto; instead **PA8 (`CHRG_RUN`) gates the
TP4056 IN+** via 2N3904 + IRF9540N (10 k pull-up): **PA8 HIGH = charge, MCU absent = NO
charge** — *inverted vs PROD `CHRG_EN`* (flag in firmware), and the safe default given the
proto has no hardware NTC guard. **Cutoff switch finally wired:** nodo SYS (OR-diode merge)
→ SPST switch → MAIN5V rail (= PROD Block E / P11; kills vehicle **and** battery). Caps on
hand: 100 nF cer + 10 µF/100 µF elec. Fan confirmed 2-wire (PB10 DNP unchanged). Docs:
ledger xlsx (new *Estado* rows) · Guía **v2.2** · circuitikz **v2.1** · both proto BOMs.
- **CARRIER-BOARD conversion (2026-07-02 PM, Leo's call):** the PROD board hosts **all three - **CARRIER-BOARD conversion (2026-07-02 PM, Leo's call):** the PROD board hosts **all three
modules on female headers** — Blackpill (J1/J2), **simpleRTK2B Pro as an Arduino-UNO shield** modules on female headers** — Blackpill (J1/J2), **simpleRTK2B Pro as an Arduino-UNO shield**
(MOD1, `Module:Arduino_UNO_R3` pattern) and the **4G NTRIP Master on an on-board XBee socket** (MOD1, `Module:Arduino_UNO_R3` pattern) and the **4G NTRIP Master on an on-board XBee socket**
@ -94,14 +106,15 @@ J1 = header P1, J2 = header P2. SWD (PA13/PA14) is **not** on the 2×20 → flas
| PA4 | `5V_SENSE` | ADC ÷2, vehicle 5 V present | — | | PA4 | `5V_SENSE` | ADC ÷2, vehicle 5 V present | — |
| PA5 | `IGN_SENSE` | **digital** `INPUT_PULLDOWN` | from DFR1015 via Rig + D5 clamp — **NO ÷2** (Finding 2) | | PA5 | `IGN_SENSE` | **digital** `INPUT_PULLDOWN` | from DFR1015 via Rig + D5 clamp — **NO ÷2** (Finding 2) |
| PA6 | `FAN_PWM` | 25 kHz fan PWM | TIM3_CH1 | | PA6 | `FAN_PWM` | 25 kHz fan PWM | TIM3_CH1 |
| PA8 | `CHRG_EN` | LTC4040 charge disable (→ U6 CHGOFF) | **[PROD 2026-07-02]** HIGH = charge OFF; 100 k pull-down = charge enabled if MCU absent (NTC still guards) | | PA7 | `LM35_TEMP` | **[PROTO 2026-07-03]** analog temp #2, ADC1_IN7 | LM35 @5 V, 10 mV/°C (≤1.5 V) — air/board; last free ADC channel |
| PA8 | `CHRG_EN` / `CHRG_RUN` | PROD: LTC4040 charge disable (→ U6 CHGOFF) · PROTO: gates TP4056 IN+ (Q via 2N3904+IRF9540N) | **PROD:** HIGH = charge OFF; 100 k pull-down = charge enabled if MCU absent (NTC still guards). **PROTO (2026-07-03): INVERTED** — HIGH = charge ON; MCU absent = no charge (module has no TEMP pin → no hardware guard). Firmware flag |
| PA9 / PA10 | `USART1` — Modo B uplink | PA10 ← F9P TX2 (monitor tap) · PA9 → relay NO → 4G DIN | injects `$PHLG`; RTCM3 downlink never passes through the MCU | | PA9 / PA10 | `USART1` — Modo B uplink | PA10 ← F9P TX2 (monitor tap) · PA9 → relay NO → 4G DIN | injects `$PHLG`; RTCM3 downlink never passes through the MCU |
| PB0 | `EXT_LED` | status LED (low-side) | **FIXED 2026-06-24** (was disconnected) | | PB0 | `EXT_LED` | status LED (low-side) | **FIXED 2026-06-24** (was disconnected) |
| PB1 | `NTC_TEMP` | **[NEW]** analog hot-spot temp, ADC1_IN9 | 3V3–10k(1 %)–NTC 10k–GND ÷ + 100 nF; Beta≈3950/Steinhart in firmware; proto's temperature path (no SHT40 in hand); can drive the `CHRG_EN` cutoff | | PB1 | `NTC_TEMP` | analog hot-spot temp, ADC1_IN9 | 3V3–10k(1 %)–NTC 10k–GND ÷ + 100 nF; Beta≈3950/Steinhart in firmware; contact sensor at the hot spot — one of the proto's **three** temp paths (with AHT10 + LM35); can drive the charge cutoff |
| PB3 | `CHRG_STAT` | **[PROD]** U6 CHRG open-drain | 100 k pull-up to 3V3; LOW = charging (>C/8) | | PB3 | `CHRG_STAT` | **[PROD]** U6 CHRG open-drain | 100 k pull-up to 3V3; LOW = charging (>C/8) |
| PB4 | `CHRG_FAULT` | **[PROD]** U6 FAULT open-drain | 100 k pull-up to 3V3; LOW = temp/bad-battery fault | | PB4 | `CHRG_FAULT` | **[PROD]** U6 FAULT open-drain | 100 k pull-up to 3V3; LOW = temp/bad-battery fault |
| PB5 | `BYP_CTRL` | **[PROD]** Modo-B bypass relay driver | HIGH = energize K1 → MCU in-line; de-energized/absent = NC = corrections direct | | PB5 | `BYP_CTRL` | **[PROD]** Modo-B bypass relay driver | HIGH = energize K1 → MCU in-line; de-energized/absent = NC = corrections direct |
| PB6 / PB7 | `I2C1 SCL/SDA` | SHT40 (0x44) + TMP102 (0x48) | 4.7 k pull-ups | | PB6 / PB7 | `I2C1 SCL/SDA` | PCB: SHT40 (0x44) + TMP102 (0x48) · **PROTO: AHT10 (0x38, T+RH) ALONE on the bus** (Aosong restriction; 3V3 only) | 4.7 k pull-ups |
| PB10 | `FAN_TACH` | *(2-wire fan: tach unused)* | fans are **2-wire 5 V** → **DNP provision**; fan-fault inferred from temp | | PB10 | `FAN_TACH` | *(2-wire fan: tach unused)* | fans are **2-wire 5 V** → **DNP provision**; fan-fault inferred from temp |
| PB12–PB15 | `BATLED1–4` | **[NEW]** battery gauge bar | firmware-driven from `BAT_SENSE`, 330 Ω + LED each | | PB12–PB15 | `BATLED1–4` | **[NEW]** battery gauge bar | firmware-driven from `BAT_SENSE`, 330 Ω + LED each |
| PC13 | onboard LED | — | WeAct module | | PC13 | onboard LED | — | WeAct module |
@ -179,16 +192,18 @@ J1 = header P1, J2 = header P2. SWD (PA13/PA14) is **not** on the 2×20 → flas
- BOMs: `watchdog-protoboard-BOM-3boards.xlsx` (engineering, ≈ MXN 5,341) and - BOMs: `watchdog-protoboard-BOM-3boards.xlsx` (engineering, ≈ MXN 5,341) and
`watchdog-LISTA-DE-COMPRAS-ES.xlsx` (plain-Spanish shop list for a non-expert buyer). `watchdog-LISTA-DE-COMPRAS-ES.xlsx` (plain-Spanish shop list for a non-expert buyer).
- **Battery backup on proto = module stand-in:** **TP4056** charger + **MT3608** boost + 2× 1N5819 - **Battery backup on proto = module stand-in:** **TP4056** charger + **MT3608** boost + 2× 1N5819
OR-ing + 10 k NTC — reproduces charge / power-loss→backup / `BAT_SENSE` / cell-temp so the OR-ing — reproduces charge / power-loss→backup / `BAT_SENSE`. **The PCB uses the LTC4040.**
firmware is fully testable. **The PCB uses the LTC4040.** The one thing the proto can't test The kit's TP4056 module **has no TEMP pin** (2026-07-03) → the 10 k charger-NTC is unused on
exactly is the *temperature-qualified charge cutoff* (LTC4040-only) — validate it in firmware logic. proto; instead the *temperature-qualified charge cutoff* **is now testable in hardware**:
`CHRG_RUN` (PA8) switches the TP4056 IN+ via 2N3904 + IRF9540N, driven from the triple temp
suite (AHT10 + LM35→PA7 + NTC→PB1). Polarity is **inverted vs the LTC4040's CHGOFF** — firmware flag.
- **GNSS + 4G: one F9P + 4G set, shared** across the three watchdog boards (the watchdog logic, - **GNSS + 4G: one F9P + 4G set, shared** across the three watchdog boards (the watchdog logic,
sensing, fan/temp, gauge, reset, cutoff and backup all test without them). sensing, fan/temp, gauge, reset, cutoff and backup all test without them).
- **Proto fan rail = LM2596 module** (24→5 V, *adjust to 5.0 V with a meter*) so fan inrush never - **Proto fan rail = LM2596 module** (24→5 V, *adjust to 5.0 V with a meter*) so fan inrush never
sags MAIN5V; the PCB uses the discrete MP1584 (U2). Fans are **2-wire** (no tach). sags MAIN5V; the PCB uses the discrete MP1584 (U2). Fans are **2-wire** (no tach).
- **Assembly references:** `Drogheda_Guia-Conexion-Protoboard_ES_v2.1.pdf` (blocks 1–11, source in - **Assembly references:** `Drogheda_Guia-Conexion-Protoboard_ES_v2.2.pdf` (blocks 1–11, source in
`Guia-Conexion-Protoboard/`) · `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` (authoritative `Guia-Conexion-Protoboard/`) · `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` (authoritative
connection list) · `circuitikz-wiring/` diagrams (sheet + per-block Beamer). connection list) · `circuitikz-wiring/` diagrams v2.1 (sheet + per-block Beamer).
--- ---
@ -203,8 +218,10 @@ J1 = header P1, J2 = header P2. SWD (PA13/PA14) is **not** on the 2×20 → flas
- **Enclosure is ASA** (not PLA); the thermal liability is the **power components** (battery/boost/ - **Enclosure is ASA** (not PLA); the thermal liability is the **power components** (battery/boost/
modem), not the case. v3.0 thermal = **waterproof duct + Blackpill smart fan** (active managed). modem), not the case. v3.0 thermal = **waterproof duct + Blackpill smart fan** (active managed).
- No material softening < ~80 °C in the thermal path. - No material softening < ~80 °C in the thermal path.
- **The battery NTC belongs to the charger** (TEMP/NTC pin), never to the MCU; MCU temperature - **The battery NTC belongs to the charger** (TEMP/NTC pin), never to the MCU — **on the PCB**
view = TMP102 (I²C) + NTC→PB1 (ADC, hot spot). (LTC4040). On the **proto** the TP4056 module exposes no TEMP pin, so the MCU does the
qualification via `CHRG_RUN` (PA8), reading **AHT10 (I²C) + LM35→PA7 + NTC→PB1** — triple
temperature, three independent paths; humidity = AHT10 only.
- **Corrections must survive a dead MCU** on every path — in Modo B that means the K1 - **Corrections must survive a dead MCU** on every path — in Modo B that means the K1
normally-closed bypass (Block H); the RTCM3 downlink is always direct. normally-closed bypass (Block H); the RTCM3 downlink is always direct.
@ -222,8 +239,10 @@ J1 = header P1, J2 = header P2. SWD (PA13/PA14) is **not** on the 2×20 → flas
499k/100k (backup 4.79 V, RST −7.5 %), L 2.2 µH ≥8 A, NTC 10 k bias, F=4.00 V Li-ion. 499k/100k (backup 4.79 V, RST −7.5 %), L 2.2 µH ≥8 A, NTC 10 k bias, F=4.00 V Li-ion.
**Bench-validate before fab** (unchanged gate). **Bench-validate before fab** (unchanged gate).
- [x] ~~Confirm the real pack capacity~~ → **~12 Ah** (1S4P, ~3 Ah/cell); the "40 Ah" label was wrong (2026-06-30). - [x] ~~Confirm the real pack capacity~~ → **~12 Ah** (1S4P, ~3 Ah/cell); the "40 Ah" label was wrong (2026-06-30).
- [ ] **Firmware**: gauge-LED driver (PB12–15 from `BAT_SENSE`); `CHRG_EN` cut-charge-when-hot logic - [ ] **Firmware**: gauge-LED driver (PB12–15 from `BAT_SENSE`); cut-charge-when-hot logic —
(TMP102 + PB1); **PB1 NTC Beta/Steinhart channel**; `CHRG_STAT`/`CHRG_FAULT` into the STREAM **proto = `CHRG_RUN` (PA8, HIGH = charge, INVERTED vs PROD `CHRG_EN`) from the triple temp
suite**; **AHT10 driver (0x38, T+RH, replaces SHT40 0x44 on proto)**; **LM35 channel PA7
(10 mV/°C)**; **PB1 NTC Beta/Steinhart channel**; `CHRG_STAT`/`CHRG_FAULT` into the STREAM
log; **deep-discharge note:** full recharge of 12 Ah @2.42 A ≈ 5 h exceeds the LTC4040's log; **deep-discharge note:** full recharge of 12 Ah @2.42 A ≈ 5 h exceeds the LTC4040's
internal safety timer — restart the cycle via `CHRG_EN` toggle while cell is cool and internal safety timer — restart the cycle via `CHRG_EN` toggle while cell is cool and
`BAT_SENSE` low; Modo B `$PHLG` injection + `BYP_CTRL` handling; reset is hardware-only. `BAT_SENSE` low; Modo B `$PHLG` injection + `BYP_CTRL` handling; reset is hardware-only.
@ -245,7 +264,7 @@ J1 = header P1, J2 = header P2. SWD (PA13/PA14) is **not** on the 2×20 → flas
- **Design doc:** [[watchdog-pcb-v3-design]] (sub-circuits, pin map, findings). - **Design doc:** [[watchdog-pcb-v3-design]] (sub-circuits, pin map, findings).
- **Connections:** `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` (proto, authoritative) · - **Connections:** `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` (proto, authoritative) ·
`watchdog-connections.xlsx` (PCB list, H1 rows now DNP) + [[watchdog-connections-rationale]]. `watchdog-connections.xlsx` (PCB list, H1 rows now DNP) + [[watchdog-connections-rationale]].
- **Assembly guide:** `Guia-Conexion-Protoboard/` (source) → `Drogheda_Guia-Conexion-Protoboard_ES_v2.1.pdf`. - **Assembly guide:** `Guia-Conexion-Protoboard/` (source) → `Drogheda_Guia-Conexion-Protoboard_ES_v2.2.pdf`.
- **Diagrams:** `circuitikz-wiring/` — full sheet + per-block Beamer (v2, 2026-07-02, blocks 1–11). - **Diagrams:** `circuitikz-wiring/` — full sheet + per-block Beamer (v2, 2026-07-02, blocks 1–11).
- **BOMs:** [[BOM-master]] (production) · `watchdog-protoboard-BOM-3boards.xlsx` + - **BOMs:** [[BOM-master]] (production) · `watchdog-protoboard-BOM-3boards.xlsx` +
`watchdog-LISTA-DE-COMPRAS-ES.xlsx` (proto) · [[watchdog-protoboard-bringup]] (bench order). `watchdog-LISTA-DE-COMPRAS-ES.xlsx` (proto) · [[watchdog-protoboard-bringup]] (bench order).

View File

@ -15,6 +15,15 @@ status: Active — tomorrow's bench guide (supersedes the procedure half of watc
> (canonical) · firmware `04-Source-Code/firmware/blackpillrtkcode_v2/` (v2.3) · > (canonical) · firmware `04-Source-Code/firmware/blackpillrtkcode_v2/` (v2.3) ·
> schematic `kicad/hbox-watchdog-v3.kicad_sch`. > schematic `kicad/hbox-watchdog-v3.kicad_sch`.
> **⚠ UPDATE 2026-07-03 — sensor suite changed to parts in hand.** Proto sensors are now
> **AHT10** (0x38, I²C1 **alone**, 3V3) + **LM35 → PA7** + **NTC → PB1** (no SHT40/TMP102 on
> proto — PCB-only). The kit's TP4056 has **no TEMP pin** → charge cutoff is **PA8 `CHRG_RUN`**
> (IRF9540N on TP4056 IN+, **inverted vs PROD CHRG_EN**). Cutoff switch wired: nodo SYS → SPST
> → MAIN5V. **The fan in hand is 2-wire** → PB10 tach test drops. §1/§3 rows below are patched;
> the authoritative wiring = ledger xlsx + `Drogheda_Guia-Conexion-Protoboard_ES_v2.2.pdf`.
> **Firmware v2.3 still reads SHT40 (0x44)** — the AHT10 driver / LM35 channel / CHRG_RUN flag
> are a pending firmware pass; until then the I²C and charge-cut rows are wire-now/test-later.
--- ---
## 0. Verdict — are you ready to build? **Yes, with three caveats** ## 0. Verdict — are you ready to build? **Yes, with three caveats**
@ -50,15 +59,16 @@ your actual list against it.
| Status LED (blink codes) | PB0 | ✅ | **Yes** | | Status LED (blink codes) | PB0 | ✅ | **Yes** |
| **RTK-stack load switch** (the recovery heart) | PA1 → 2N3904 → IRF9540 | ✅ OFF-at-reset, MCU-asserts-ON | **Yes** | | **RTK-stack load switch** (the recovery heart) | PA1 → 2N3904 → IRF9540 | ✅ OFF-at-reset, MCU-asserts-ON | **Yes** |
| Sense: battery / 5 V / ignition | PA0 / PA4 / PA5 | ✅ hysteresis + debounce | **Yes** | | Sense: battery / 5 V / ignition | PA0 / PA4 / PA5 | ✅ hysteresis + debounce | **Yes** |
| Smart fan + tach | PA6 / PB10 | ✅ 25 kHz PWM, RPM, stall fault | **Yes (3-wire fan)** | | Smart fan (PWM) | PA6 · *(PB10 tach = DNP, fan in hand is 2-wire)* | ✅ 25 kHz PWM · RPM/stall **n/a** | **Yes** (PWM ramp; no tach) |
| I²C temp/RH (closed-loop fan) | PB6/PB7 → SHT40 0x44 + TMP102 0x48 | ✅ + MCU-temp fallback | **Yes** (fallback works even with no sensor) | | I²C temp/RH — **AHT10 0x38, alone on the bus** [2026-07-03] | PB6/PB7 | ❌ v2.3 reads SHT40 0x44 → **AHT10 driver pending** (+ MCU-temp fallback works) | wire OK, **reads after firmware patch** |
| Analog temp ×2 — NTC→PB1 + **LM35→PA7** [2026-07-03] | PB1 / PA7 | ❌ channels not coded | wire OK, verify with multimeter meanwhile |
| 4-LED battery gauge | PB12–15 | ❌ not coded | wire OK, **stays dark** | | 4-LED battery gauge | PB12–15 | ❌ not coded | wire OK, **stays dark** |
| Temp-qualified charge cut (`CHRG_EN`) | PA8 | ❌ not coded | **No** (also LTC4040/PROD-only) | | Temp-qualified charge cut — **`CHRG_RUN`** [2026-07-03] | PA8 → 2N3904 → IRF9540N on TP4056 IN+ | ❌ not coded (**inverted vs PROD `CHRG_EN`** — needs flag) | wire OK; hand-test by jumpering PA8 high/low |
| Reset (hardware) | NRST | n/a (HW only) | **Yes** — button just works | | Reset (hardware) | NRST | n/a (HW only) | **Yes** — button just works |
**Fan note:** v2.3 reads a **3-wire** tach on PB10, so use a **3-wire 5 V fan** on the breadboard. **Fan note [updated 2026-07-03]:** the fan in hand is **2-wire** → no tach; PB10 stays DNP and
(The "2-wire production fan" decision in the canonical doc is a *PCB* change; it doesn't apply to v2.3's RPM/stall check reads nothing (harmless). Fan-fault will be inferred from temperature in
tomorrow's bench.) the firmware pass. PWM drive on PA6 through the IRLZ44N tests exactly the same.
--- ---
@ -97,19 +107,24 @@ fan test. *F9P + 4G master are NOT needed for this bring-up.*
**Thermal (v3 new):** **Thermal (v3 new):**
- [ ] **3-wire** 5 V fan, 40–60 mm (3-wire so PB10 reads RPM — matches v2.3) - [x] 5 V fan, 40–60 mm — **2-wire, in hand** [2026-07-03] (no tach; PB10 DNP)
- [ ] **IRLZ44N** ×2 (logic-level N-FET, fan low-side) — *plain IRF540/IRFZ44 won't turn on from - [ ] **IRLZ44N** ×2 (logic-level N-FET, fan low-side) — *plain IRF540/IRFZ44 won't turn on from
3.3 V; if out of IRLZ44N use 2N2222A/TIP120 + 1 kΩ base* 3.3 V; if out of IRLZ44N use 2N2222A/TIP120 + 1 kΩ base*
- [ ] **1N5819** ×3 (fan flyback; 1N4007 acceptable) - [ ] **1N5819** ×3 (fan flyback; 1N4007 acceptable)
- [ ] I²C **SHT40/SHT31** breakout (0x44) — *or* LM35/DS18B20 fallback (tell me which; I'll patch the read) - [x] I²C **AHT10** breakout (0x38) — **in hand** [2026-07-03]; **alone on the bus**, 3V3 only;
firmware read patch pending (v2.3 speaks SHT40)
- [x] **LM35** (TO-92) — **in hand** [2026-07-03]; analog temp #2 on **PA7**, powered from 5 V
**v3 additions (build only if you want them wired now — see §4):** **v3 additions (build only if you want them wired now — see §4):**
- [ ] Reset: tactile button → NRST↔GND (+ optional 2-pin header for external reset) - [ ] Reset: tactile button → NRST↔GND (+ optional 2-pin header for external reset)
- [ ] Battery gauge: **4× LED + 4× 330 Ω** on PB12–15 *(will stay dark until firmware)* - [ ] Battery gauge: **4× LED + 4× 330 Ω** on PB12–15 *(will stay dark until firmware)*
- [ ] Battery-backup stand-in: **TP4056** module + **MT3608** boost + **2× 1N5819** (OR-ing) + - [ ] Battery-backup stand-in: **TP4056** module + **MT3608** boost + **2× 1N5819** (OR-ing)
**10 kΩ NTC** *(reproduces charge / power-loss→backup / BAT_SENSE; the temp-qualified cutoff is *(reproduces charge / power-loss→backup / BAT_SENSE)*. **[2026-07-03]** The kit's TP4056 has
LTC4040-only → firmware-validated, not on the proto)* **no TEMP pin** → the 10 kΩ charger-NTC is unused; the temp-qualified cutoff **is now on the
proto in hardware**: PA8 `CHRG_RUN` → 1 k → 2N3904 → IRF9540N (10 k pull-up) on TP4056 IN+
(HIGH = charge; MCU absent = no charge — inverted vs PROD). Plus the **cutoff switch**:
nodo SYS → SPST → MAIN5V (kills vehicle **and** battery)
--- ---

View File

@ -8,6 +8,12 @@ status: Active — shop list for the Blackpill bring-up
# Watchdog Bring‑up — Protoboard Shopping List (print me) # Watchdog Bring‑up — Protoboard Shopping List (print me)
> **⚠ SUPERSEDED for sensors (2026-07-03):** the proto suite is now **AHT10 (0x38, alone on
> I²C1, 3V3) + LM35→PA7 + NTC→PB1** — no SHT40/SHT31/BME280/TMP102 on the proto (PCB-only).
> Charge cutoff = **PA8 `CHRG_RUN`** on the TP4056 IN+ (the kit module has no TEMP pin).
> Current shop lists = `watchdog-protoboard-BOM-3boards.xlsx` / `watchdog-LISTA-DE-COMPRAS-ES.xlsx`;
> wiring = ledger xlsx + Guía v2.2. The sensor/substitute rows below are kept for history only.
> Goal: breadboard the v2.2 watchdog on your **existing Blackpill**, prove the > Goal: breadboard the v2.2 watchdog on your **existing Blackpill**, prove the
> state machine + sensing + load switch + fans + temp loop, **before** any PCB. > state machine + sensing + load switch + fans + temp loop, **before** any PCB.
> All parts are **through‑hole / breadboard‑friendly** and stocked at a normal MX > All parts are **through‑hole / breadboard‑friendly** and stocked at a normal MX

View File

@ -88,10 +88,21 @@ HBOX/cabinet mechanicals (+ verify D2/D8=RX2/TX2 on a physical Pro), then routin
SW_5V ≥0.8 mm per kicad-guide). Fab gate unchanged: bench-validate the LTC4040 backup + SW_5V ≥0.8 mm per kicad-guide). Fab gate unchanged: bench-validate the LTC4040 backup +
hot-cell charge cutoff on the proto first. Latest proto hot-cell charge cutoff on the proto first. Latest proto
assumptions ledger = `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` (*Estado y cambios*) + assumptions ledger = `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` (*Estado y cambios*) +
`Drogheda_Guia-Conexion-Protoboard_ES_v2.1.pdf` (LaTeX source now in repo: `Drogheda_Guia-Conexion-Protoboard_ES_v2.2.pdf` (LaTeX source in repo:
`Guia-Conexion-Protoboard/`). Wiring diagrams v2 (blocks 1–11) in `circuitikz-wiring/`; `Guia-Conexion-Protoboard/`). Wiring diagrams v2.1 (blocks 1–11) in `circuitikz-wiring/`;
client decks Avance + RCA refreshed to v1.1. client decks Avance + RCA refreshed to v1.1.
**Proto sensor suite realigned to parts in hand (2026-07-03).** No SHT40 (long lead) → proto
Block 6 = **AHT10** (0x38 fija, 3V3 only, **alone** on I²C1 — Aosong restriction); **LM35 →
PA7** (last free ADC channel) joins **NTC→PB1** → **triple temperature** (3 technologies,
3 electrical paths); humidity = AHT10 only. SHT40/TMP102 stay **PCB-only** (PROD schematic
untouched). The kit's TP4056 exposes **no TEMP pin** → charger-NTC unused on proto; new
**PA8 `CHRG_RUN`** high-side cut of TP4056 IN+ (2N3904+IRF9540N; HIGH = charge, MCU absent =
no charge — **inverted vs PROD `CHRG_EN`**, firmware flag). **Cutoff switch now wired:** nodo
SYS (OR merge) → SPST → MAIN5V (= Block E/P11, kills vehicle AND battery). Caps in hand
100 nF/10 µF/100 µF; fan confirmed 2-wire. Docs synced: ledger xlsx · Guía **v2.2** ·
circuitikz **v2.1** · both proto BOMs · design-state (canonical).
--- ---
## 1. System architecture (corrected from the BOM, 2026-06-20) ## 1. System architecture (corrected from the BOM, 2026-06-20)
@ -166,7 +177,7 @@ these before presenting; if it breaks one, say so and propose the compliant fix.
| `00-Project-Management` | plan, ethos, hackathon, **financials**, **handover**, client comms, Drive tooling | [[00-Project-Management/PLAN\|PLAN]] · [[00-Project-Management/Engineering-Handover\|Engineering-Handover]] · `ethos.md` · `hackathon-plan.md` · `Financials.md` · `Drive-Upload/` · `client-comms/` | | `00-Project-Management` | plan, ethos, hackathon, **financials**, **handover**, client comms, Drive tooling | [[00-Project-Management/PLAN\|PLAN]] · [[00-Project-Management/Engineering-Handover\|Engineering-Handover]] · `ethos.md` · `hackathon-plan.md` · `Financials.md` · `Drive-Upload/` · `client-comms/` |
| `01-Requirements` | what we build | `SRS.md` · `HBOX-product-spec.md` | | `01-Requirements` | what we build | `SRS.md` · `HBOX-product-spec.md` |
| `02-Architecture-Software` | backend/software analysis, ADRs | `backend-review.md` | | `02-Architecture-Software` | backend/software analysis, ADRs | `backend-review.md` |
| `03-Architecture-Hardware` | HBOX/cabinet, wiring, BOM, **watchdog PCB v3** | `hardware-respec-and-pcb-brief.md` · `cabinet-electrical-bom.md` · `watchdog-schematic.md` · `watchdog-health-telemetry.md` · `firmware-review.md` · `BOM-master.md` (+§5 Block B/E/H/I parts) · **`watchdog-pcb-v3-design.md`** (schematic spec) · `watchdog-pcb-v3-bom.xlsx` · `watchdog-pcb-v3-kicad-guide.md` (KiCad→JLCPCB) · `watchdog-pcb-v3-blockdiagram.svg` · `watchdog-protoboard-bringup.md` + `watchdog-proto-bench-bringup-v3.md` · `watchdog-connections.xlsx` (PCB pin/net list; H1 DNP; +B/H/I rows) · `watchdog-connections-rationale.md` (+§7 additions 2026-07-02) · **`watchdog-electrical-design-state.md`** (CANONICAL — read first) · **`watchdog-production-schematic-delta.md`** (PROD build spec; LTC4040 §4 values) · `kicad/` — `hbox-watchdog-v3.kicad_sch` (**DEV/proto**) · `hbox-watchdog-v3-PROD.kicad_sch/.kicad_pcb` (**PRODUCTION**: ERC 0, layout started, DRC baseline) · `Drogheda-sym.kicad_sym` (MP1584EN · LTC4040EUFD · AO4406A) · `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` (**proto assumptions ledger**) · `Guia-Conexion-Protoboard/` (LaTeX source) → `Drogheda_Guia-Conexion-Protoboard_ES_v2.1.pdf` · `circuitikz-wiring/` (sheet + Beamer v2, blocks 1–11) · `watchdog-protoboard-BOM-3boards.xlsx` + `watchdog-LISTA-DE-COMPRAS-ES.xlsx` (proto BOMs) | | `03-Architecture-Hardware` | HBOX/cabinet, wiring, BOM, **watchdog PCB v3** | `hardware-respec-and-pcb-brief.md` · `cabinet-electrical-bom.md` · `watchdog-schematic.md` · `watchdog-health-telemetry.md` · `firmware-review.md` · `BOM-master.md` (+§5 Block B/E/H/I parts) · **`watchdog-pcb-v3-design.md`** (schematic spec) · `watchdog-pcb-v3-bom.xlsx` · `watchdog-pcb-v3-kicad-guide.md` (KiCad→JLCPCB) · `watchdog-pcb-v3-blockdiagram.svg` · `watchdog-protoboard-bringup.md` + `watchdog-proto-bench-bringup-v3.md` · `watchdog-connections.xlsx` (PCB pin/net list; H1 DNP; +B/H/I rows) · `watchdog-connections-rationale.md` (+§7 additions 2026-07-02) · **`watchdog-electrical-design-state.md`** (CANONICAL — read first) · **`watchdog-production-schematic-delta.md`** (PROD build spec; LTC4040 §4 values) · `kicad/` — `hbox-watchdog-v3.kicad_sch` (**DEV/proto**) · `hbox-watchdog-v3-PROD.kicad_sch/.kicad_pcb` (**PRODUCTION**: ERC 0, layout started, DRC baseline) · `Drogheda-sym.kicad_sym` (MP1584EN · LTC4040EUFD · AO4406A) · `Drogheda_Conexiones-por-Bloque_Proto_v1.xlsx` (**proto assumptions ledger**) · `Guia-Conexion-Protoboard/` (LaTeX source) → `Drogheda_Guia-Conexion-Protoboard_ES_v2.2.pdf` · `circuitikz-wiring/` (sheet + Beamer v2.1, blocks 1–11) · `watchdog-protoboard-BOM-3boards.xlsx` + `watchdog-LISTA-DE-COMPRAS-ES.xlsx` (proto BOMs) |
| `04-Source-Code` | firmware + backend repos | `firmware/` (**own git repo `hbox-firmware`**: `blackpillrtkcode_v2/` deploy · `legacy/` v1 · `docs/LOGGING-SPEC.md` v2.1) · `htracker/` · `notifications/` · `rtk-config/` | | `04-Source-Code` | firmware + backend repos | `firmware/` (**own git repo `hbox-firmware`**: `blackpillrtkcode_v2/` deploy · `legacy/` v1 · `docs/LOGGING-SPEC.md` v2.1) · `htracker/` · `notifications/` · `rtk-config/` |
| `05-Analytics-Reports` | SQL views, dashboards (VERONICA/PowerBI), **observability** | `2026-06-22_Drogheda_Manual-Logs-Grafana_v1.0.pdf` (Grafana/Loki log-consultation manual) | | `05-Analytics-Reports` | SQL views, dashboards (VERONICA/PowerBI), **observability** | `2026-06-22_Drogheda_Manual-Logs-Grafana_v1.0.pdf` (Grafana/Loki log-consultation manual) |
| `06-Testing-Validation` | RCA, diagnostics, test evidence, **log analysis & tooling** | `RCA-2026-06-field-failures.md` · `remote-diagnostic-protocol.md` · `2026-06-20_Drogheda_Bench-Log-Analysis_v1.0.md` (rev-3) · `2026-06-20_Drogheda_GNSS-Findings-Summary.md` · `log-analysis/` (repo **`hbox-log-tools`**: `log-explorer.html` · `analyze_logs.py` · `build_dashboard.py` · `docs/manual.pdf`) | | `06-Testing-Validation` | RCA, diagnostics, test evidence, **log analysis & tooling** | `RCA-2026-06-field-failures.md` · `remote-diagnostic-protocol.md` · `2026-06-20_Drogheda_Bench-Log-Analysis_v1.0.md` (rev-3) · `2026-06-20_Drogheda_GNSS-Findings-Summary.md` · `log-analysis/` (repo **`hbox-log-tools`**: `log-explorer.html` · `analyze_logs.py` · `build_dashboard.py` · `docs/manual.pdf`) |