How 3dudu/agv-wcs works
Project Type and Purpose
• This is a full‐stack, monolithic .NET Framework (4.5.2) solution implementing a Warehouse Control System (WCS) for automated guided vehicles (AGVs).
• It provides:
• Communication with AGV hardware and PLCs
• Dispatch logic and route planning
• Data access to SQL Server / SQLite (db3.0)
• Multiple UIs: dispatch console, monitoring display, PDA client, 2D/3D simulators, map/edit tools
High‐Level Layered Structure
• Presentation Layer:
• AGVDispatchServer (WinForms dispatch UI)
• (monitoring map, status dashboards)
• WindowPDAClient (PDA Windows client)
• RCSEditTool (map & parameter editor)
• Simulation, SimulatorAGVTCP, SimulateCallBox, Wpf3DSimulator (2D/3D simulation UIs)
• Business Logic Layer:
• AGVCore (core events, state machine, dispatcher interfaces)
• AGVComponents (route planning, traffic control)
• AGVDispacth (dispatch engine, external/internal handlers, non-standard dispatch)
• DipatchModel (typed data contracts for commands, enums)
• SimulationModel (runtime simulation behavior)
• Communication & Integration Layer:
• AGVCommunication (AGV protocol sessions: OMARK, Fbell, custom)
• SocketServer / SocketClient / SocketModel (TCP socket framework, message packaging)
• S7PLCClient_AGV, PlcSMICECallAGV (Siemens PLC connectivity modules)
• MesModel (MES callback data structures)
• SQLServerOperator (generic DB operator)
• Tool (web service agent, encryption, config)
• Data Access Layer:
• AGVDAccess (client/server/simulation data repositories)
• Model (Comoon: shared DTOs for users, parameters; MDM: master data; MSM: I/O device info; CarInfoExtend)
• SQLXML folders (predefined SQL queries / schemas)
Component Relationships & Data Flow
• UI components invoke dispatch or simulation actions via public interfaces in AGVDispacth / SimulationModel.
• Dispatch engine calls AGVComponents for route planning and interacts with AGVCore state machine.
• Communication layer (AGVCommunication, SocketServer, PLC clients) sends/receives messages to/from AGV hardware and PLC.
• Business logic calls Data Access (AGVDAccess, SQLServerOperator) to read/write master and runtime data in SQL Server or SQLite.
Architectural Patterns & Principles
• Layered architecture: Presentation → Business → Integration → Data Access
• Separation of concerns: protocols (AGVCommunication), business rules (AGVCore, AGVComponents), UI, data storage
• Use of DTOs / typed contracts (Model and DipatchModel) for strong typing across layers
• Plugin‐style protocol sessions (AGVSessionBase + derived)
Technologies & Frameworks
• .NET Framework 4.5.2, C#
• WinForms (DispatchServer, Display, RCSEditTool, PDA, SimulationCommon)
• WPF (Wpf3DSimulator)
• SuperSocket (AGVDispacth/SupperSocket)
• ADO.NET / SQLXML for database
• SQLite (db3.0) for local data
• Custom TCP socket layer (SocketModel, SocketServer, SocketClient)
Detail Level
• Break each major module into subcomponents (e.g., AGVSessionBase + specific session classes)
• External dependencies (SuperSocket library, SQLXML scripts, images)
• Don’t over-partition: group by layer but call out specialized protocol/session plugins