MCPcopy Create free account
hub / github.com/TactilityProject/Tactility / send

Method send

Tactility/Source/service/espnow/EspNowService.cpp:175–184  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

173}
174
175bool EspNowService::send(const uint8_t* address, const uint8_t* buffer, size_t bufferLength) {
176 auto lock = mutex.asScopedLock();
177 lock.lock();
178
179 if (!isEnabled()) {
180 return false;
181 } else {
182 return esp_now_send(address, buffer, bufferLength) == ESP_OK;
183 }
184}
185
186ReceiverSubscription EspNowService::subscribeReceiver(std::function<void(const esp_now_recv_info_t* receiveInfo, const uint8_t* data, int length)> onReceive) {
187 auto lock = mutex.asScopedLock();

Callers 2

bluetooth_midi_sendFunction · 0.80
sendFunction · 0.80

Calls 3

isEnabledFunction · 0.85
asScopedLockMethod · 0.80
lockMethod · 0.45

Tested by

no test coverage detected