How matoseder/heltec-lora-com works
Main Components
• Master Device (master.cpp): Represents the Heltec WiFi LoRa 32 V2 acting as a gateway. This component’s responsibilities include sending messages, managing timeouts, and handling retransmission if the ACK is not received.
• Slave Device (slave.cpp): Represents the remote Heltec device. It is responsible for receiving messages and sending back an acknowledgment (ACK).
Relationships and Interactions
• Interaction Pattern: Highlight the request-response (and possibly retransmission) mechanism. This feedback loop is crucial to the design.
Architectural Patterns and Design Principles
• Asynchronous Communication: Emphasize that the master awaits an ACK and may retry sending messages if a timeout occurs.
• Event-Driven Behavior: The system likely leverages interrupt-handling or event detection for message reception and ACK processing.
• Embedded Systems Implementation: Since it’s built using the Arduino framework (via Arduino IDE or PlatformIO) and the Heltec ESP32 library, capture the constraints and timing aspects typical in embedded designs.
Technologies and Frameworks
• Hardware: Heltec WiFi LoRa 32 V2 boards.
• Communication: LoRa wireless communication protocol configured for 915 MHz (optimized for the Brazilian frequency band).
• Software: Arduino framework and the Heltec ESP32 library (see https://github.com/Heltec-Aaron-Lee/WiFi_Kit_series).
• Components/Modules: Break out the following if needed:
• LoRa Radio Interface (inside both devices).
• Communication Management (showing the logic for timeouts and retransmission on the Master).
• Acknowledgment Handling (in the Slave).
• Representation of the External Dependency: Note the role of the Heltec ESP32 library as it supports the LoRa functionality.