# EDEL Elevator Controller — Pending Engineering Tasks

This document tracks all active and upcoming engineering tasks for the **EDEL Elevator Controller System** (`EDELElevatorFULL` - Firmware v4.4.0 / v0.6.2).

---

## Task Registry

| Task ID | Task Title | Category | Status | Detailed Explanation |
| :--- | :--- | :--- | :--- | :--- |
| **TASK-01** | **Automated PCA Hardware Test Suite & Computer Vision Test Bench** | QA / Factory Automation | ⏸️ Deferred (Not Current Priority) | Architecture documented in Dev Sections 0, 9, 27 & Tech Section 8. Full implementation deferred. [View Details](file:///p:/I+D/SOFTWARE/K2-64278/EDELElevatorFULL%20-%20v4.4.0%20-%20v0.6.2%20%28desarrollo%20+%20Token%29/tasks/task_01_automated_pca_testing.md) |
| **TASK-02** | **Electrical / Hardware Wiring Diagram Documentation** | Technical Documentation | ✅ Completed & Integrated | Documented in Developer Section 23 & Client Section 2 from ADVANCED EN81.20 and K2 manuals |
| **TASK-03** | **Complete Diagnostic & Fault Code Matrix Integration (All 99 Codes)** | Technical Documentation | ✅ Completed & Integrated | Documented in Developer Section 25 & Client Section 6 covering all 99 fault codes (01–99), Spanish/English designations, root causes, reset modes (AUTO/MANUAL/LOCKOUT), and field actions. |
| **TASK-04** | **EDELConnect PC & Mobile Companion Software Documentation** | Telemetry / Tools | ✅ Completed & Integrated | Documented in Developer Section 28 & Client Section 9 from `EDELCONNECT` documentation |
| **TASK-05** | **OEM Specific Branding & Firmware Customization Guides** | OEM Integration | ⏸️ Deferred (Awaiting Specs) | Requires OEM customer specification sheets. Not current priority. |
| **TASK-06** | **Programming Console — Complete Interaction Guide (Section 29)** | Technical Documentation | ✅ Completed & Integrated | New Developer Section 29 added. Covers full 8-menu tree, all serial protocols ($PS/$CC/$DC/$AC/$EE/$MP/$MA), PIN & Token security system, CicloBloqueo enforcement, iCOM Drive Virtual Console, EEPROM backup, and multi-language engine. Based on R13 + direct `Consola.c` / `Consola.h` analysis. |
| **TASK-07** | **Fuji Frenic Lift VFD Engineering & Pre-Built Installation Matrix (Section 30)** | Technical Documentation / Drive Systems | ✅ Completed & Integrated | New Developer Section 30 added. Comprehensive guide on Fuji Frenic Lift/Lift2 inverter setup, parameter dictionary (F03-F44, E01-E99, C01-C43, P01-P12, L01-L119), anti-rollback zero-speed loop, internal PLC logic blocks (U00-U87), emergency gravity rescue (descompensación) / UPS rescue, and full system elements & variations matrix across K2, K3, ADVANCED K2, and Premontadas installations. |
| **TASK-08** | **Complete Spanish Version of Entire Documentation Portal (Fuentes Originales)** | Technical Documentation / Localization | ✅ Completed & Integrated | Full authentic Spanish version (`data_es.js`) built directly from original Spanish source documentation (`P:\Documentación\DOCUMENTACIÓN INTERNA`, `P:\IT\DATA\DLJ`, and firmware `Idioma.h`, `main.c`). Includes all 32 Dev sections (with all 99 faults and Fuji VFD), all 9 In-House Tech sections (with interactive Spanish LCD simulator), all 9 Client Installer sections, top navbar language switcher `[ 🇪🇸 ES | 🇬🇧 EN ]`, search query localization, and local persistence. |
| **TASK-09** | **Complete 58-Subsection Bilingual Elevator Encyclopedia (All PCBs, Zones, & Protocols)** | Technical Documentation / Knowledge Base | ✅ Completed & Integrated | Full systematic taxonomy covering all 58 subsections across 7 major architectural domains (1. Anatomy & Zones, 2. Electrical Installation, 3. EDEL PCB Modules, 4. Third-Party Components, 5. Product Variants, 6. Dependencies & Compatibility Matrix, 7. Visual Maps). 100% bilingual in English and authentic Spanish (`encyclopedia.js`), fully integrated into instant search, top bar role switcher, and mobile-responsive layout. |
| **TASK-10** | **Multi-Device CAN Frame Matrix, TokenCustom Cryptography & Server Deployment (Section 31 & Tool 5.10)** | Telemetry & Cryptography / CI-CD | ✅ Completed & Published | Comprehensive R&D matrix covering all 8 devices (Mainboard K2-64278/K3-74278, Cabin K2-64290, Cabin v2 ADVANCED K2-64291, BotCAN K2-64292/64295, Encoder K2-64296, Landing K2-64280/64281, iCOM K2-64299, Duplex K2-64275MX), mathematical specification of `Cifrado()` with pseudo-random vector `RDM[8]`, CRC-8-SAE J1850 polynomial (`0x1D`), dynamic challenge-response rolling counters, sliding window (`TOKEN_RxWINDOW = 5`), and the server validation and deployment pipeline. Integrated into Developer Section 31, Section 5, Encyclopedia 2.3 & 6.4, and Interactive Tool 5.10. |
| **TASK-11** | **Clavei ERP Daily 14:00 Automated Sync & Material Needs PowerBI Recreation** | ERP Integration / BI | ✅ Completed & Integrated | Connected to live Clavei ERP SQL Server via Cloudflare Access TCP tunnel (`127.0.0.1:14330`), configured daily automated extraction at 14:00 + manual web trigger. Recreated PowerBI 'Necesidades Producción Laboratorio' dashboard (`Version Prueba Necesidad Materiales.pbip`) using views `WSTOCKPBI` (12,641 stock items), `WCOMPRASBIPED` (open POs with supplier delays), and `EscLin` (BOM multi-level explosion/where-used). Interactive 360° drill-down modal, clickable KPI cards, tab switcher, real-time search, and CSV exports under Secondary PIN `876321`. |
| **TASK-12** | **Multi-User Server-Side Auth & Session Cookies for BI Portal** | Security / Auth | ⏸️ Deferred (Postponed per User Directive) | Full server-side multi-user authentication (`scrypt` password hashing, HttpOnly session cookies, role-based access control, IP rate limiting) postponed. Access remains secured via secondary PIN code `876321` with client-side verification and session persistence. |
| **TASK-13** | **Additional PowerBI Dashboards Reverse-Engineering & Full Suite Ingestion** | ERP Integration / BI | ⏳ Queued (Awaiting Files Tomorrow) | Audit and eliminate any remaining mismatches on Material Needs, then ingest and reverse-engineer all additional PowerBI dashboard files (.pbip, .pbix, .pbit) provided by the user using the `powerbi-deep-scanner` skill. |
| **TASK-14** | **Forensic PDF-to-Order Cross-Reference & Knowledge Base Ingestion** | Order Engineering / Knowledge Base | ✅ Completed & Ingested | Batch scan of 415 order PDFs (2026) cross-referenced against Clavei ERP orders (1,928 orders, 12,038 lines) in `pdf_scan_state.db` and `edel_orders_2026.db`. Documented technical distributions, identified recurring engineering ambiguities, resolved configurator input field gaps, and stored full report as permanent Knowledge Item `ki_pdf_order_cross_reference`. |
| **TASK-15** | **Full Offline PWA Resilience & Service Worker Cache Pre-Heating** | Web Architecture / Field Tech PWA | ✅ Completed & Integrated | Upgraded `sw.js` (v1.2.0) with cache pre-heating for all core documentation assets, interactive simulators, encyclopedia, and BI scripts. Hardened `app.js` with instant-ready Service Worker registration and real-time offline status indicators for technicians in elevator shafts and machine rooms without 4G signal. |
| **TASK-16** | **Client-Specific ERP Commercial Pricing Engine (Tarifas / Clientes — Opción A)** | Commercial Quotation / ERP Integration | ✅ Completed & Integrated (Option A: 24h Snapshot) | Conectado al ERP Clavei (GESTICOM SQL Server). Matriz completa de 1.910 clientes, 6 tarifas y 1.088 reglas de descuento integrada en `client_pricing_snapshot.js`. Jerarquía estricta de 5 niveles comprobada contra pedidos reales (FAIN, ASMON, CATALUNYA, TRESA, ENINTER). Selector con Cód. Cliente ERP (`CodCli`), chips rápidos OEM, barra de sincronización de 24h con botón de actualización manual y desglose línea a línea en el escandallo BOM. [Ver Documento Comercial](file:///C:/Users/ecommerce/.gemini/antigravity-ide/brain/56293b2b-176c-43b3-8b96-83d6b55c529e/clavei_client_pricing_architecture.md) |
| **TASK-17** | **Main Board Serial Number Reverse-Lookup Tool (ERP Forensic Tracer)** | Inventory & Field Diagnostics | ✅ Completed & Integrated | Live in Interactive Tool 5.14 (`tool-serial-tracer`). Forensic bidirectional tracer linking 32,000+ Main Boards (K2-64278, Advanced 64MDP200, K3-74278) to their parent Maniobra serial (`EDEL...`), production order (OF), customer sales order, and delivery note. Includes 1,500 real units in-memory cache, 4-stage pipeline visualization, official MS-SQL query generator, and 1-click bridge to TASK-19 Firmware Exporter. |
| **TASK-18** | **Automated Forensic Regression Test Suite** | QA / Engineering Verification | ⏸️ Pending Rules Confirmation | Automated headless test suite running historical orders through `cfgBuildBOM(s)` against historical `EscLin` bills of materials. On hold pending final rules confirmation. |
| **TASK-19** | **Firmware Configuration File Export Tool (K2-64278 EEPROM Serializer)** | R&D / Factory Bench Automation | ✅ Phase 1 Live / ⏳ Phase 2 Target 01-11-2026 | Live in Section 7 of Configurator (`cfg-firmware-export`). Phase 1 complete (EEPROM serializer, checksum, 98-packet `$EE` generator). Phase 2 (WebSerial direct USB-to-RS232 physical transmission) scheduled for completion by **01-11-2026**. |
| **TASK-20** | **Canonical Order Structure & Deterministic CSV Catalog Engine** | Configurator / Order Engineering | ✅ Completed & Integrated (Review Page Live in Section 3) | Strict alignment of the Configurator with `maniobras-full.csv` (452 active models) and `configurador-botoneras.csv` (1,995 active SKUs). Formal definition of the 5 Order Types (Complete, Maniobra+IEP, Solo Maniobra, Solo Botoneras, Solo IEP) with mandatory vs optional components and normative/mechanical rationale (EN 81-20/70/28). Interactive review page live in Section 3 (`cfg-decision-matrix`) with dual live CSV catalog explorer. [Ver Especificación](file:///C:/Users/ecommerce/.gemini/antigravity-ide/brain/56293b2b-176c-43b3-8b96-83d6b55c529e/edel_order_structure_and_csv_catalog_logic.md) |
| **TASK-21** | **Botonera Visual Studio & A4 Technical Blueprint PDF Exporter** | Configurator / Fixture Engineering | ✅ Completed & Upgraded (Live in Section 5 & Section 6) | Full visual plate layout engine ported from `edel-dev-git/botoneras/botoneras.py` with 5 key refinements: (1) PDF preview positioned below inputs, (2) Enhanced zoom from 40% to 300% with steppers and presets, (3) Explicit '🚀 Generar' button avoiding unwanted re-renders, (4) Cascading dynamic selectors for Brand/Model/Finish/LED and crisp white text on Chrome/Inox buttons, (5) BOM split into 4 separate tables (Cuadro, IEP, Botoneras, Telefonía) with consolidated summary. |



---

## Detailed Task Summaries

### TASK-01: Automated PCA Hardware Test Suite & Computer Vision Test Bench
- **Status**: ⏸️ Deferred — not a current development priority.
- **Objective**: Replace manual bench testing (`mTest 1` through `mTest 11`) with an automated software suite utilizing RS-232 serial control, automated I/O signal generation, and Computer Vision for real-time LED / LCD feedback verification.
- **Full Specification & Architecture**: [task_01_automated_pca_testing.md](file:///p:/I+D/SOFTWARE/K2-64278/EDELElevatorFULL%20-%20v4.4.0%20-%20v0.6.2%20%28desarrollo%20+%20Token%29/tasks/task_01_automated_pca_testing.md)

### TASK-02: Hardware Schematics and Wiring Diagrams
- **Status**: ✅ Completed & Integrated in Developer Section 23 & Client Section 2.
- **Objective**: Document physical terminal block pinouts (e.g., Borna 40 110V series monitor, TP input, safety chain inputs, COP/LOP CAN connectors, expansion board relays) for incorporation into the Technician Guide.

### TASK-03: Diagnostic and Fault Code Matrix (All 99 Codes)
- **Status**: ✅ Completed & Integrated in Developer Section 25 & Client Section 6 at [http://localhost:3000](http://localhost:3000).
- **Objective**: Consolidate all numeric error codes (Fallo 01 through Fallo 99), root cause analyses, signal/terminal identification, reset behaviors (AUTO, MANUAL, permanent LOCKOUT e.g. Fallo 53), and step-by-step field repair actions into a complete searchable web matrix.
- **Delivered Content**:
  - Full matrix of 99 fault codes extracted from official R10/R13 engineering manuals and firmware source code (`segur.c`, `Consola.c`, `Idioma.h`).
  - Clear distinction between AUTO recovery faults, MANUAL reset faults, and safety trip LOCKOUTS requiring Console Menu 3.4.4.
  - Tailored views for both in-depth R&D engineering analysis (Dev Section 25) and fast field technician troubleshooting (Client Section 6).

### TASK-04: EDELConnect Telemetry and Companion Tools
- **Status**: ✅ Completed & Integrated in Developer Section 28 & Client Section 9.
- **Objective**: Create user guides and API specifications for EDELConnect PC diagnostic suite, remote monitoring tools, and Fuji iCOM inverter status interfaces.

### TASK-05: OEM Customizations Guide
- **Status**: ⏸️ Deferred — awaiting external OEM customer specification sheets.
- **Objective**: Document specific operational rules and custom console profiles for OEM brand targets (`ELEVAMON`, `JORDA`, `ATES`, `FAIN`, `TESTLIFT`).

### TASK-06: Programming Console — Complete Interaction Guide
- **Status**: ✅ Completed & Integrated — Developer Portal Section 29 live at [http://localhost:3000](http://localhost:3000).
- **Objective**: Deep documentation of the K2/ADVANCED 4-button LCD console as the primary product interface for initial setup and troubleshooting.

### TASK-07: Fuji Frenic Lift VFD Engineering & Pre-Built Installation Matrix
- **Status**: ✅ Completed & Integrated — Developer Portal Section 30 live at [http://localhost:3000](http://localhost:3000).
- **Objective**: Document the most common Voltage Converter (Fuji Frenic Lift / Lift2), pre-saved site profiles, internal PLC logic, emergency rescue architectures, and installation variations.
- **Delivered Content**:
  - Physical signal & terminal wiring map between EDEL K2 / ADVANCED mainboard and Fuji inverter (FWD, REV, X1-X8, Y1-Y5, 30A/B/C, THM, P+/DB).
  - Master parameter configuration dictionary based on `Programación 2.5m-s.xls`, `Lista Parametros a realizar.xls`, and `2.1 - Configuración Gearless.docx`.
  - Zero-speed anti-rollback loop tuning (`L65-L73`) for rollback prevention at brake opening.
  - Fuji internal PLC logic engine (`U00-U87`) extracted from `LOGICA PROGRAMABLE FUJI.xlsx` (Step 1 enable, Step 2 motor PTC supervision with delay, Step 4 automatic Low Voltage reset for gravity rescue, Steps 5-7 high-speed forced deceleration stop).
  - Emergency rescue configurations: Rescate por Descompensación (gravity drift with `E08=114`, `L117-L119`, console `Freno Abierto = 1000`, `Freno Cerrado = 0.0`) and Rescate por SAI / Baterías (UPS creep speed `C05=4%`).
  - System Elements Matrix: Comprehensive breakdown of invariable core elements vs. modular variable configurations across K2 Standard, K3, ADVANCED K2, and Premontadas installations.
  - Top 5 field commissioning troubleshooting checklist for installers.

### TASK-08: Complete Spanish Version of the Documentation Portal (Fuentes Originales)
- **Status**: ✅ Completed & Integrated live at [http://localhost:3000](http://localhost:3000).
- **Objective**: Deliver a full, authentic Spanish version of the entire web documentation portal drawn directly from original EDEL engineering sources, avoiding machine back-translation, and implement instant bilingual switching.
- **Delivered Content**:
  - `Documentation_Web/data_es.js` (219 KB) containing all 32 Developer sections, 9 In-House Tech sections, and 9 Client Installer sections (49 sections total).
  - Authentic Spanish engineering terminology directly from source manuals: *Borna 40* (serie cerrojos 110V), *Borna 41* (contacto puerta cabina), *Leva retráctil ELeva*, *Biestables de cambio y paradores de paro*, *Firma digital, PIN 1/2 y CicloBloqueo (estados 0–7)*, *Variador Fuji Frenic Lift2*, *Rescate por descompensación* (`E08=114`, `L117=150mm/s`, `Freno Abierto = 1000`, `Freno Cerrado = 0.0`), *Lógica PLC U00–U87*, and Premontadas variations across customers (TRESA, OMEGA, RALOE, FELESA, GMV, INELSA, etc.).
  - Complete Spanish Matrix of all 99 Fault Codes (Fallo 01 al 99) in Developer Section 25 and Client Section 6.
  - Interactive LCD Console Simulator operating in Spanish with 4-button navigation.
  - Top navigation bar bilingual pill switcher (`[ 🇪🇸 ES | 🇬🇧 EN ]`) with instant dynamic updates of role cards, sidebar nav, active section, search placeholder, and `localStorage` persistence.

### TASK-09: Complete 58-Subsection Bilingual Elevator Encyclopedia (All PCBs, Zones, & Protocols)
- **Status**: ✅ Completed & Integrated live at [http://localhost:3000](http://localhost:3000) and GitHub Pages.
- **Objective**: Build a systematic, deep internal knowledge base and taxonomy covering every physical zone, PCB module, third-party interface, and product variant across the entire EDEL ecosystem.
- **Delivered Content**:
  - `Documentation_Web/encyclopedia.js` (227 KB) containing all 58 subsections structured across 7 key architectural domains:
    1. *Elevator Anatomy (Physical Zones)*: Machine Room (1.1), Shaft (1.2), Cabin (1.3), Landings (1.4), Pit (1.5).
    2. *Electrical Installation Overview*: Power circuits (2.1), Safety chain loops under EN 81-20 (2.2), Dual CAN bus architecture ($XBD / $XTR) (2.3), Third-party integration points (2.4).
    3. *EDEL PCB Modules*: Complete catalog of all 18 board families including Mainboard K2-64278, Cabin boards (v1 K2-64290 with 5-language ADPCM audio vs v2 ADVANCED K2-64291), BotCAN floor buttons (v1 K2-64295 vs v2 K2-64292), Exterior displays (K2-64280 vs ARM mCAN-12 K2-64281), Position Encoder K2-64296 (SSI Wachendorff/ELGO with 100mm false door jump filter), Display modules (LCD, DRC rotating, DDM dot matrix, TFT color with 5 subversions, miniLCD v2.7), FlechasPP K2-64350 (dual-bus push-pull arrows), Expansion I/O K2-64297, iCOM Remote module K2-64299 (CANopen Lift CiA 417, UART Fuji bridge, 12/18 m/min overspeed supervision), MK Interface K2-64406 ($EMI ASCII bridge), and Access Control CA-02 K2-64435 (iButton Dallas DS1990A reader + KeyManager console).
    4. *Third-Party Components*: Fixed Fuji Frenic Lift motor VFD, door VFDs, interchangeable SSI encoders, and Dallas iButton keys.
    5. *Product Variants*: K2 Passenger, K3 Goods Lift (K3-74278 autonomous controller with hydraulic reenvío de aceite), and ADVANCED K2.
    6. *Dependencies & Compatibility*: Hardware brand variants (EDEL $X / GENESIS $Y / ATES $Z), CAN frame rules, minimum firmware dependencies, cryptographic Token signature system (`Cifrado()`), and failure cascades.
    7. *Visual Maps*: ASCII system block diagrams and CAN bus wiring topology.
  - 100% authentic bilingual parity across all 58 sections in English and Spanish.
  - Seamless integration into role switcher (Role 4), sidebar navigation, dynamic breadcrumbs, and real-time Ctrl+K search engine.

### TASK-10: Multi-Device CAN Frame Matrix, TokenCustom Cryptography & Server Deployment
- **Status**: ✅ Completed & Published live at [http://localhost:3000](http://localhost:3000).
- **Objective**: Consolidate low-level R&D specifications for CAN communication across all 8 peripheral devices, document TokenCustom firmware cryptography, and establish production CI/CD server validation.
- **Delivered Content**:
  - Full CAN arbitration ID and byte-level payload breakdown across Mainboard K2-64278, Cabin K2-64290/64291, BotCAN K2-64292/64295, Encoder K2-64296, Landing Displays K2-64280/64281, iCOM K2-64299, and Duplex K2-64275MX.
  - Complete mathematical specification of `Cifrado()` algorithm: 8-byte PRNG seed vector `RDM[8]`, polynomial CRC-8-SAE J1850 (`0x1D`), rolling nonce counters, and sliding window verification (`TOKEN_RxWINDOW = 5`).
  - Integrated into Developer Section 31, Section 5, Encyclopedia 2.3 & 6.4, and Interactive Token Verification Tool 5.10.

### TASK-11: Clavei ERP Daily 14:00 Automated Sync & Material Needs PowerBI Recreation
- **Status**: ✅ Completed & Integrated live at [http://localhost:3000/#role=bi&section=bi-materials](http://localhost:3000/#role=bi&section=bi-materials).
- **Objective**: Recreate the PowerBI 'Necesidades Producción Laboratorio' dashboard (`Version Prueba Necesidad Materiales.pbip`) as a web-native application with live Clavei ERP data integration and full relational depth.
- **Delivered Content**:
  - Cloudflare Access TCP tunnel to SQL Server (`GESTICOM`) on `127.0.0.1:14330`.
  - Node.js backend daemon (`bi_server`) on port 3100 with automated daily cron sync at 14:00 and manual instant sync endpoint.
  - Ingestion of 12,641 stock items (`WSTOCKPBI`), open purchase orders (`WCOMPRASBIPED`), and multi-level BOM escandallo trees (`EscLin`).
  - Interactive 360° modal drill-down on any SKU: Stock levels, Escandallo (BOM) explosion, Where-Used ("Producto Final") parent assemblies, and linked open POs with supplier delay indicators.
  - Interactive KPI cards acting as toggle filters (Roturas, Necesidad Total, Pedidos Pendientes, Retrasos Proveedor).
  - Multi-column sorting, live search, CSV export, and Secondary PIN protection (`876321`).

### TASK-12: Multi-User Server-Side Auth & Session Cookies for BI Portal
- **Status**: ⏸️ Deferred — Postponed per User Directive.
- **Objective**: Implement server-side multi-user authentication (`scrypt` password hashing, HttpOnly session cookies, role-based access control, IP rate limiting) for the BI portal.
- **Current Approach**: Access remains secured via secondary PIN code `876321` with client-side verification and session persistence.

### TASK-13: Additional PowerBI Dashboards Reverse-Engineering & Full Suite Ingestion
- **Status**: ⏳ Queued (Awaiting Dashboard Files Tomorrow).
- **Objective**: Systematically reverse-engineer, scan, and recreate all additional PowerBI dashboard files (.pbip, .pbix, .pbit) provided by the engineering team into the web portal with full interaction depth.
- **Execution Methodology**:
  - Utilize the newly created workspace skill [powerbi-deep-scanner](file:///p:/I+D/SOFTWARE/K2-64278/EDELElevatorFULL%20-%20v4.4.0%20-%20v0.6.2%20%28desarrollo%20+%20Token%29/.agents/skills/powerbi-deep-scanner/SKILL.md).
  - Extract visual layouts and data roles using `inspect_pbi_visuals.js`.
  - Trace cross-filtering and master-detail dependencies using `extract_interactions.py`.
  - Map underlying Clavei ERP SQL Server views and queries in `bi_server/src/queries.js`.
  - Build corresponding web UI views in `bi_dashboard.js` with matching KPI cards, interactive tables, and relational drill-downs.

### TASK-14: Forensic PDF-to-Order Cross-Reference & Knowledge Base Ingestion
- **Status**: ✅ Completed & Ingested into Knowledge Base (`ki_pdf_order_cross_reference`).
- **Objective**: Forensic audit of all 2026 production order PDFs against Clavei ERP production orders and lines to uncover engineering ambiguities, missing configurator input fields, and technical attribute distributions.
- **Delivered Content**:
  - Offline extraction of 415 production order PDFs indexed in `Documentation_Web/pdf_scan_state.db` (0 LLM tokens).
  - Cross-reference against 1,928 Clavei ERP orders and 12,038 line items in `Documentation_Web/edel_orders_2026.db`.
  - Taxonomy categorization: 187 General Specs, 141 IEP Premontadas, 84 Botoneras, 3 Maniobra/Workshop specs.
  - High-frequency ambiguity mapping: Inverter braking resistors (67 cases), Brake coil voltages (37 cases), Voice synthesis languages (9 cases), MRL Gearless encoder traveling harnesses (5 cases), Door lock handing (3 cases).
  - Identification and integration of 3 missing input fields (`freno_volt`, `distancia_cuadro_potencia_mdp`, `acople_botonera_existente`) into `configurator_portal.js`.
  - Permanent Knowledge Base artifact created at `ki_pdf_order_cross_reference/artifacts/pdf_order_cross_reference_findings.md`.

### TASK-15: Full Offline PWA Resilience & Service Worker Cache Pre-Heating
- **Status**: ✅ Completed & Integrated live at [http://localhost:3000](http://localhost:3000).
- **Objective**: Ensure 100% offline access to all documentation, schematics, pinouts, DIP switch calculators, and fault matrix for field technicians working in elevator shafts and machine rooms without cellular connectivity.
- **Delivered Content**:
  - Upgraded `sw.js` (v1.2.0) with cache pre-heating for all core JS files (`app.js`, `data_es.js`, `encyclopedia.js`, `interactive_tools.js`, `configurator_portal.js`, `bi_dashboard_data.js`, `bi_dashboard.js`), CSS, SVG icons, and architectural block diagrams.
  - Hardened Service Worker registration in `app.js` with instant-ready execution checking `document.readyState === 'complete'`.
  - Real-time online/offline network event listeners updating the top navbar status badge: `🟢 En línea (Offline Ready)` vs. `⚡ Sin conexión (Modo Foso/Sala Máquinas)`.

### TASK-16: Phase 2 — Client-Specific ERP Pricing Engine & Verified Modernization Presets
- **Status**: ⏳ Planned (Phase 2).
- **Objective**: Evolve the technical Configurator into an official commercial quotation generator utilizing client-specific price lists and trade discounts from Clavei ERP, pre-loaded with verified modernization presets.
- **Delivered Components (Prepared for Sales Validation)**:
  - 12 verified production presets extracted from historical production orders & FAIN OEM audits:
    *Modernization (6 Presets)*:
    1. *Otis 2000 Retrofit* (Geared 5.5kW 400V, 110V series, SAI RED-E 6A rescue, Fermator 230V door).
    2. *Thyssen F-Type / Silva Modernization* (High-power 22kW Gearless, dual-tension RDF/RAAF brake overexcitation, Fuji E08=114 Descompensación + PFRCA).
    3. *Schindler Smart / 001 MRL Modernization* (Door-frame MDP cabinet with MDP-102/202/302, silent contactors <45dB, absolute SSI toothed belt positioning).
    4. *Orona / MacPuarsa 2-Speed Modernization* (Variable speed conversion, special multitap secondary transformer 60V/190V DC for legacy brake, K2-64297 expansion).
    5. *Hidráulico GMV / Blain Modernization* (Autonomous controller K3-74278, Star-Delta 11kW, 12V/24V emergency descent valve `1105001194`, UCM re-leveling).
    6. *Duplex Riser Compartido* (Dual K2-64278 controllers, Duplex communication card K2-64275MX, shared landing call risers with diode switching).
    *New Installation / Obra Nueva (6 Presets)*:
    7. *FAIN TECNIKIT MRL ION Ziehl* (Ziehl-Abegg ZAdyn 7.5kW, Pasarela LTC EDEL-FAIN `C4010FLTC001`, baquetón Inox ION, aro verde `C3603FAV0099`, FAINVISION IV 10.1").
    8. *FAIN TECNIKIT MRL Fuji* (Fuji Frenic Lift 2 5.5kW/7.5kW, baquetón ION, Netel LTA200 trifonía).
    9. *RALOE ADVANCED K2 Obra Nueva* (Armario SCM acabado RAL 7032, instalación premontada IEP EN 81-20 con alumbrado continuo LED 5050, caja de revisión 240-D).
    10. *Residencial Obra Nueva K2 Standard* (Gearless 5.5kW MRL, cinta dentada SSI, display Giotto 5.6" color TFT CAN con síntesis de voz).
    11. *Comercial Gran Tráfico Obra Nueva* (Gearless 15kW 32A, armario con choque de red y filtro EMC, SAI Optima-T10 3kVA, display panorámico Giotto 7.0").
    12. *Unifamiliar / Homelift 230V Monofásico* (Frenic Lift 2 230V monofásico, 0.15 m/s, rescate por baterías a planta más próxima).

### TASK-17: Main Board Serial Number Reverse-Lookup Tool (ERP Forensic Tracer)
- **Status**: ✅ Completed & Integrated live at [http://localhost:3000](http://localhost:3000) under Interactive Tool 5.14.
- **Objective**: Implement a bidirectional forensic lookup tool connecting any Main Board serial number (K2-64278, Advanced 64MDP200, K3-74278) to its parent Maniobra serial (`EDEL...`), production order (OF), customer sales order, and delivery note.
- **Delivered Content**:
  - Live Interactive Tool 5.14 (`tool-serial-tracer`) added to `interactive_tools.js` with bilingual support.
  - Curated in-memory cache of 1,500 real production units (`serial_db_snapshot.js`) from 2025–2026 production runs across all clients (FAIN, ASMON, ASYMOSA, CUME24, ELEVAMON, SOLER, etc.).
  - 4-Box Visual Pipeline Graph: Placa Base ➔ Maniobra Padre ➔ Orden de Fabricación ➔ Albarán y Pedido Cliente.
  - Official MS-SQL query generator with NULL tolerance for both complete controller assemblies and direct spare parts.
  - 1-Click bridge button: *"Preconfigurar en Sección 7"* to transfer the parent elevator controller technical profile straight to TASK-19 Firmware Exporter for instant EEPROM compilation.
  - Multi-criteria real-time search with filter chips (All, K2-64278, Advanced MDP, K3, With Maniobra, Direct Spares) and 25-item paginated forensic table.

### TASK-18: Automated Forensic Regression Test Suite
- **Status**: ⏸️ Pending Rules Confirmation.
- **Objective**: Implement a headless test suite (`test_configurator_boms.js`) comparing dynamic BOM outputs against historical `EscLin` data across 415 production orders.
- **Blocker**: On hold pending confirmation of client-specific commercial pricing formulas and optional assembly rules.

### TASK-19: Firmware Configuration File Export Tool (K2-64278 EEPROM Serializer)
- **Status**: ✅ Phase 1 Completed & Integrated — Phase 2 Queued.
- **Objective**: Directly convert elevator configurations into the binary/serial payload required by the K2-64278 mainboard MCU (MC9S12XDT512), eliminating 45 minutes of manual parameter entry on the 4-button LCD console during bench commissioning.
- **Delivered Content (Phase 1)**:
  - Integrated into Section 7 of the Web Configurator (`cfg-firmware-export`).
  - Multi-source order ingestion: Ingests from live Configurator, Clavei ERP order numbers, or uploaded JSON/TXT files.
  - Serialization compiler (`window.compileK2FirmwareEEPROM`): Maps parameters to the exact 768-byte EEPROM memory range (`0x0880` to `0x0B7E`).
  - Strict checksum computation: Arithmetic sum of 383 words modulo 0x10000 stored at `param_checksum` @ `0xB7E`.
  - Console Serial Script Generator: Formats the 98-packet sequence (`$EE01;`, `$EE1000;`, and 96 frames of `$EE3<16 nibbles ASCII>;`).
  - UI export features: 1-click clipboard copy and direct download of `.edelcfg` parameter files.
### TASK-20: Canonical Order Structure & Deterministic CSV Catalog Engine
- **Status**: ✅ Completed & Integrated (Review Page Live in Section 3).
- **Objective**: Establish the formal canonical architecture for elevator production orders, clearly separating the 5 canonical order typologies, marking obligatory vs optional components with normative justifications (EN 81-20, EN 81-70, EN 81-28, UCM A3), and implementing deterministic filtering trees that strictly constrain selectable equipment to the official active CSV catalogs:
  - `maniobras-full.csv`: 452 active controllers (394 electric, 58 hydraulic).
  - `configurador-botoneras.csv`: 1,995 active SKUs (COP placa, COP columna, LOP piso, pulsadores, displays, telefonía).
- **Delivered Content**:
  - **Engineering Specification**: Saved as [edel_order_structure_and_csv_catalog_logic.md](file:///C:/Users/ecommerce/.gemini/antigravity-ide/brain/56293b2b-176c-43b3-8b96-83d6b55c529e/edel_order_structure_and_csv_catalog_logic.md).
  - **Standalone Database Snapshots**: `maniobras_db_snapshot.js` (452 rows) and `botoneras_db_snapshot.js` (1,995 rows) with Service Worker offline caching.
  - **Interactive Engineering Review Page**: Live in Section 3 of the Configurator portal (`#role=configurator&section=cfg-decision-matrix`) titled *"📐 3. Arquitectura de Pedidos & Matriz CSV"*.
  - **Features on the Page**:
    1. **5 Canonical Order Typology Cards**: Interactive cards for Pedido Completo, Maniobra + IEP, Solo Maniobra, Solo Botoneras, and Solo IEP, with 1-click *"⚡ Aplicar al Configurador"* buttons.
    2. **Component Obligatoriness Matrix**: Full breakdown of controllers, dynamic braking resistors, EMC filters, automatic rescue kits, load weighers, UCM valves, encoders, trailing cables, car roof inspection boxes, pit control boxes, COPs, LOPs, pushbuttons, braille, green rings, voice synthesizers, and EN 81-28 autodialers, with interactive subsystem filters.
    3. **Deterministic Decision Trees**: Step-by-step reduction paths from 452 controllers to 1 SKU and 1,995 pushbuttons/fixtures to 1 SKU.
    4. **Dual Live CSV Catalog Explorer**: Tabbed real-time test bench allowing engineering colleagues to test and validate filtering against both CSV catalogs simultaneously, displaying active match counters, dynamic table rows, 1-click *"Cargar"* actions, and the *"🎯 ¡1 Única Opción Exacta Alcanzada!"* badge when matches narrow down to exactly 1 item.
### TASK-21: Botonera Visual Studio & A4 Technical Blueprint PDF Exporter
- **Status**: ✅ Completed & Integrated (Options 1 & 2 Live in Section 5).
- **Objective**: Port the visual plate layout engine, photos, dimensions, and A4 PDF generation from `edel-dev-git/botoneras/botoneras.py` into the web application, providing:
  - **Option 1**: A real-time, interactive HTML5 Canvas studio displaying authentic photos of plates, pushbuttons, finishes, displays, and millimeter dimensions.
  - **Option 2**: A 1-click client-side official PDF generator producing the A4 technical blueprint (`plate_layout.pdf`) with EDEL title block, dimensional arrows, BOM table, and workshop approval box.
- **Delivered Content**:
  - **Asset Library Migration**: Copied all 107 image assets from `C:\Users\ecommerce\envz\edel-dev-git\botoneras\img` into `Documentation_Web/images/botoneras/` (COP plates, LOP landing fixtures, EDEL/SCHAEFER/DMG pushbuttons, Giotto/Raffaello displays, emergency icons, dimension arrows).
  - **Engine Module**: Created `botonera_layout_engine.js` (2480 × 3508 px canvas rendering pipeline, asset pre-loader, alternating button grid calculator matching `calculate_positions`, Braille and EN 81-70 green halo).
  - **Client-Side PDF Library**: Downloaded and integrated `jspdf.umd.min.js` (364 KB) with Service Worker offline caching in `sw.js`.
  - **Section 5 UI Integration**: Completely upgraded Section 5 (`cfg-botoneras`) with a split-screen workbench:
    - Left Column: Studio controls (Panel type, dimensions, button brand/model/finish/color, floor sequence, auxiliary buttons, displays, landing fixtures).
    - Right Column: Sticky high-resolution canvas viewport with live zoom (+ / - / 100%), dimension badges, and direct download buttons (`PDF A4`, `PNG HD`, `Aplicar al BOM`).




