Skip to content

Latest commit

 

History

History
51 lines (34 loc) · 3.31 KB

910_diagram_exampls.md

File metadata and controls

51 lines (34 loc) · 3.31 KB

For embedded software written in C, you'll want diagrams that capture both high-level architectural views and detailed functional or data flow aspects. Here are common types of diagrams and the tools best suited for each:

1. System Block Diagram

  • Purpose: Illustrates the overall system architecture, showing connections between microcontrollers, peripherals, sensors, actuators, and external systems.
  • Recommended Tool: Microsoft Visio, Lucidchart, or Draw.io.
  • Details: This diagram is typically a high-level overview showing hardware components, communication links, and any dependencies on other systems.

2. Data Flow Diagram (DFD)

  • Purpose: Shows how data moves through the system, highlighting data sources, processing stages, and destinations.
  • Recommended Tool: Lucidchart or Visual Paradigm.
  • Details: Especially useful for understanding input/output flows and the processing layers, a DFD is key for embedded systems where data flows between sensors, processing units, and output devices.

3. Control Flow Diagram

  • Purpose: Maps out the control flow, often used to depict how a system's state changes with inputs or events.
  • Recommended Tool: Draw.io or Enterprise Architect (EA).
  • Details: This is valuable in embedded systems with interrupt-driven designs, helping to clarify the order and control of operations triggered by hardware interrupts or software events.

4. State Machine Diagram

  • Purpose: Describes the states within a system and how transitions occur based on events.
  • Recommended Tool: PlantUML for code-based diagrams, or Visual Paradigm for drag-and-drop.
  • Details: Especially helpful in embedded systems where software often operates in specific modes or states (e.g., initialization, idle, active).

5. Sequence Diagram

  • Purpose: Demonstrates the order of interactions between software components and hardware over time.
  • Recommended Tool: Enterprise Architect (EA) or Lucidchart.
  • Details: Useful for depicting time-dependent interactions, particularly in C-based embedded applications with inter-module or inter-process communication.

6. Component Diagram

  • Purpose: Shows how modules or components are organized and interact with each other within the software.
  • Recommended Tool: Microsoft Visio or Draw.io.
  • Details: This helps you visualize how the different C modules (e.g., drivers, HALs, application logic) interact and depend on each other.

7. Flowchart

  • Purpose: Illustrates the flow of functions or specific algorithms.
  • Recommended Tool: Lucidchart or Draw.io.
  • Details: Useful for detailing specific algorithms or control flows within a C function, especially when debugging or optimizing complex logic.

8. Timing Diagram

  • Purpose: Used to depict time-based interactions and signal timing, critical in real-time embedded systems.
  • Recommended Tool: SystemView by SEGGER (for ARM Cortex-M tracing) or Lucidchart for manual timing diagrams.
  • Details: Timing diagrams can show how tasks, interrupts, and communication signals interact over time, ensuring time constraints are met.

These diagram clarify designs, you don't need all these diagram, depending on your specific project.