MCPcopy Create free account
hub / github.com/FastLED/FastLED / swmAssignSctInput0

Function swmAssignSctInput0

src/platforms/arm/lpc/rx_sct_capture.cpp.hpp:210–215  ·  view source on GitHub ↗

Assign or unassign the user's GPIO pin to SCT input 0 (SCT0_GPIO_IN_A_I) via SWM PINASSIGN6 byte[31:24]. The byte value is the encoded pin number (PIO0_n -> n; PIO1_n -> 0x20+n).

Source from the content-addressed store, hash-verified

208// via SWM PINASSIGN6 byte[31:24]. The byte value is the encoded pin number
209// (PIO0_n -> n; PIO1_n -> 0x20+n).
210inline void swmAssignSctInput0(fl::u8 swm_byte) FL_NOEXCEPT {
211 volatile fl::u32& r = reg(kSwmBase, kOffPINASSIGN6);
212 fl::u32 v = r;
213 v = (v & 0x00FFFFFFu) | (static_cast<fl::u32>(swm_byte) << 24);
214 r = v;
215}
216
217// Convert an unsigned tick delta (free-running 32-bit SCT counter, F_CPU
218// ticks) to nanoseconds. F_CPU is the SCT clock when CLKMODE=0; on

Callers 2

beginMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected