MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / xs_onewire_select

Function xs_onewire_select

modules/drivers/onewire/esp/modonewire.c:150–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

148}
149
150void xs_onewire_select(xsMachine *the)
151{
152 modOneWire onewire = xsmcGetHostData(xsThis);
153 OneWireBus_ROMCode *rom_code = xsmcToArrayBuffer(xsArg(0));
154 bool present = false;
155 owb_reset(onewire->owb, &present);
156 owb_write_byte(onewire->owb, OWB_ROM_MATCH);
157 owb_write_rom_code(onewire->owb, *rom_code);
158}
159
160void xs_onewire_search(xsMachine *the)
161{

Callers

nothing calls this directly

Calls 3

owb_resetFunction · 0.85
owb_write_byteFunction · 0.85
owb_write_rom_codeFunction · 0.85

Tested by

no test coverage detected