🛰️Zafer Satılmış - Aviora

Modular File System Platform

Switch file systems per customer and platform without #if/#else. Single stable API, JSON-based configuration, automatic code generation. Developers always use the same interface; backend changes stay transparent.

Zero #if/#else Single Include JSON Config Code Generation

Why This Platform Is Strong

The design removes customer-specific #if/#else branches from application code. File system selection and parameters are configured via JSON; a generator script produces headers before build.

  • Single API contract — Developers always use the same fs* functions
  • Configuration-driven — Customer selects backend via activeFsName
  • Tested units — New FS is developed and tested externally; added via config
  • Hardware independence — read/prog/erase/sync callbacks injected from JSON via flashHwFunc
Stable API Hardware Injection Modular

Quick Startup Flow

  • #include "Midd_FS/fs_port.h"
  • FS_HARDWARE_INIT(error)
  • fsInit()
  • fsOpenFile, fsReadFile, fsWriteFile

The application is isolated from backend changes. Customer and platform details are pushed into generated headers.

Include Chain Animation

A single include resolves automatically to customer-specific headers and the active FS port.

Include chain flow

Generator Pipeline Animation

From JSON input to generated headers — the generator script pipeline.

Generator flow

System Flow Diagram

General Flow (Mermaid)
flowchart LR
  J[fs_config.json] --> G[generate_fs_port_config.py]
  G --> C[cus_fs_port_config.h]
  G --> F[FS_Port_Config.h]
  A[fs_port.h] --> F
  F --> C
  C --> H["fs_port_xx.h"]
  H --> I[FS_HARDWARE_INIT]
  I --> M[fsInit]
  M --> O["fs API"]

Benefits Summary

🔒

Immutable Application Code

Same source compiles and runs regardless of backend.

⚙️

Fast Customer Adaptation

Change activeFsName, run generator — new build ready.

🧪

Independent Test Cycle

New FS unit developed in isolation; added via config after test.