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

Function createAxp192

Devices/m5stack-core2/Source/devices/Power.cpp:6–11  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4static std::shared_ptr<Axp192> axp192 = nullptr;
5
6std::shared_ptr<Axp192> createAxp192() {
7 assert(axp192 == nullptr);
8 auto configuration = std::make_unique<Axp192::Configuration>(device_find_by_name("i2c_internal"));
9 axp192 = std::make_shared<Axp192>(std::move(configuration));
10 return axp192;
11}
12
13std::shared_ptr<Axp192> getAxp192() {
14 assert(axp192 != nullptr);

Callers 1

initAxpFunction · 0.70

Calls 1

device_find_by_nameFunction · 0.85

Tested by

no test coverage detected