updates
This commit is contained in:
18
my_components/nimble_tracker/string_utils.h
Normal file
18
my_components/nimble_tracker/string_utils.h
Normal file
@@ -0,0 +1,18 @@
|
||||
// Copied from https://github.com/ESPresense/ESPresense/blob/master/lib/BleFingerprint/string_utils.h
|
||||
#pragma once
|
||||
#include <string>
|
||||
|
||||
#define Sprintf(f, ...) ({ char* s; asprintf(&s, f, __VA_ARGS__); std::string r = s; free(s); r; })
|
||||
|
||||
namespace esphome
|
||||
{
|
||||
namespace nimble_tracker
|
||||
{
|
||||
|
||||
std::string hexStr(const uint8_t *data, int len);
|
||||
uint8_t hextob(char ch);
|
||||
bool hextostr(const std::string &hexStr, uint8_t *output, size_t len);
|
||||
|
||||
} // namespace nimble_tracker
|
||||
|
||||
} // namespace esphome
|
||||
Reference in New Issue
Block a user