eVectors Electric System
Overview
This repository contains the eVectors Electric System project, the complete electric development of the vehicle.
Repository Contents
Architecture
System architecture diagrams illustrating the electric system design at multiple levels of abstraction:
- Simplified architecture diagrams (high-level, low voltage, high voltage systems)
- Detailed architecture diagrams (all subsystems, computing unit, peripherals, powertrain, charging, motor)
See Architecture Documentation for visual diagrams.
VCU (Vehicle Control Unit)
Two parallel VCU implementations sharing the same top-level state machine design (BOOT → OFF → ON → CHARGE_REQUEST/CHARGING or RUN_REQUEST/RUNNING → ERROR), driven off the schematics' driving-peripherals and internal wiring signals (key switch, brake, gear selector):
eVectors_VCU_v0— S32K148-based control firmware (NXP RTD AUTOSAR 4.7 / S32 Design Studio project). GPIO shield bring-up, FlexIO-emulated UART, TinyBMS UART command layer.eVectors_VCU_STM_v0— STM32 Nucleo-F413ZH (PlatformIO/stm32cube) prototyping target for the peripheral links: TinyBMS UART (working on hardware), MEAN WELL NPB/NPP charger CAN via an MCP2515 CAN-HAT (working on hardware), and NetGain HyPer-Drive inverter CANopen telemetry decoding. See its README anddocs/notes for bring-up details.
iBSG Reverse Engineering
Reverse engineering attempt of the Valeo iBSG motor via CAN bus communication.
Key Components:
- Monitoring Tools: Passive CAN bus sniffers with real-time visualization and logging
- Control Tools: Active motor control with configurable torque, power modes, and operating parameters
- Analysis Tools: Signal plotting, communication visualization, and log analysis
- PCAN Utilities: Hardware diagnostics, driver verification, and CAN interface wrappers
- Documentation: CAN protocol specifications, DBC file analysis, and signal definitions
Main Features:
- Real-time CAN message capture and decoding
- Interactive dashboards for signal visualization
- CSV/JSON logging for historical analysis
- Command transmission for motor control
- Hardware diagnostics and troubleshooting tools
Component Sizing
Python scripts and a Fusion 360 model used for powertrain component selection: motor_sizing.py derives traction power/torque/speed requirements from WLTP Class 2 drive-cycle data, QuickBatteryModel_01.py runs a quick PyBaMM (Single Particle Model) battery simulation, and AssemblageEvectors_LongueurCables.f3d is the CAD assembly used to estimate harness cable lengths.
Documentation
MkDocs-based documentation system using Material theme with navigation tabs and markdown includes.
Getting Started
Prerequisites
- Python 3.8+
- PEAK PCAN-USB adapter (for CAN communication)
- PEAK PCAN-Basic driver and DLL (download here)
Project Structure
eVectors-Electric-System/
├── Architecture/
│ ├── eVectorsSchematics/ # KiCad 10 hierarchical schematics (see README)
│ └── evectors.kicad_sym # Custom parts library shared by the schematics
├── VCU/
│ ├── eVectors_VCU_v0/ # S32K148 VCU firmware (S32 Design Studio project)
│ └── eVectors_VCU_STM_v0/ # STM32 Nucleo-F413ZH VCU (PlatformIO) — BMS/charger/inverter CAN bring-up
├── Dashboard/
│ └── dashboard_v1/ # LVGL v9 + SDL2 dashboard simulator (CrowPanel 7.0")
├── RandomExperiment/ # Dashboard/UI hardware prototypes and reference material
├── ComponentSizing/ # Motor/battery sizing scripts and cable-length CAD model
├── docs/ # MkDocs documentation (this site)
├── iBSG_ReverseEngineering/
│ ├── analysis/ # CAN log analysis and plotting tools
│ ├── control/ # Motor control scripts and encoders
│ ├── monitoring/ # Passive CAN bus monitoring tools (incl. generic can_sniffer.py)
│ ├── pcan_utils/ # PCAN hardware interface and diagnostics
│ ├── documentation/ # Protocol specs and signal definitions
│ └── logs/ # Captured CAN communication logs
└── mkdocs.yml # Documentation configuration
Contributing
This is an active research and development project. Contributions, issue reports, and suggestions are welcome.
Git — Pushing to Both Remotes
This repository is mirrored on two remotes:
- GitHub (
origin):https://github.com/NAGIHarjeet/eVectors-Electric-System.git - GitLab (
gitlab):git@gitlab.com:evectors/EESys.git
To push your current branch to both remotes, run the two commands below:
git push origin <branch>
git push gitlab <branch>
For the dev and main branches specifically:
# Push dev branch
git push origin dev
git push gitlab dev
# Push main branch
git push origin main
git push gitlab main
You can also define a shell alias to push to both in one command:
# One-liner: push to both remotes at once
git push origin HEAD && git push gitlab HEAD
License
...