Skip to content

Conversation

@RyLeeHarrison
Copy link
Contributor

📝 Add EventEmitter Library to Arduino Library Manager

This pull request adds the EventEmitter library to the Arduino Library Manager.

Repository URL: https://github.com/RyLeeHarrison/EventEmitter

Library Summary:
EventEmitter for Arduino brings an efficient event-driven model to embedded systems.
It provides lightweight event handling with fixed-size buffers and statically allocated arrays,
making it ideal for low-memory environments.

Visual Example:

#include <Arduino.h>
#include "EventEmitter.hpp"

EventEmitter emitter;

void messageHandler(const char* msg, int count) {
  Serial.print("Message: ");
  Serial.print(msg);
  Serial.print(" | Count: ");
  Serial.println(count);
}

void setup() {
  Serial.begin(9600);
  emitter.on("message", messageHandler);
}

int count = 0;

void loop() {
  emitter.emit("message", "Hello, Arduino!", count++);
  delay(1000);
}

Features

  • Event Registration: Attach multiple callbacks to an event.
  • Event Emission: Emit events and pass arguments to callbacks.
  • One‑Shot Listeners: Automatically remove listeners after their first call.
  • Listener Management: Remove individual or all listeners.
  • Memory Efficiency: Uses fixed‑size buffers and statically allocated arrays, ideal for microcontrollers.

Version: v1.0.0

@github-actions github-actions bot added the topic: submission Add library to the list label Feb 8, 2025
@github-actions github-actions bot merged commit 843db19 into arduino:main Feb 8, 2025
11 checks passed
@github-actions
Copy link
Contributor

github-actions bot commented Feb 8, 2025

Your submission has now been accepted! Thanks for your contribution to the Arduino Library Manager index.

The library(s) will be available for installation via Library Manager within a day's time.

You can check the logs from the Library Manager indexer for your library(s) here:
http://downloads.arduino.cc/libraries/logs/github.com/RyLeeHarrison/EventEmitter/

github-actions bot pushed a commit that referenced this pull request Feb 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic: submission Add library to the list

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant