FastLED 3.9.15
Loading...
Searching...
No Matches

◆ PrintPins< 0 >()

template<>
void PrintPins< 0 > ( )
Examples
Pintest.ino.

Definition at line 163 of file Pintest.ino.

163 {
164 RwReg *systemThinksPortIs = portOutputRegister(digitalPinToPort(0));
165 RwReg systemThinksMaskIs = digitalPinToBitMask(0);
166
167 int maskBit = 0;
168 while(systemThinksMaskIs > 1) { systemThinksMaskIs >>= 1; maskBit++; }
169
170 const char *pinport = GetPinPort((void*)systemThinksPortIs);
171 if (pinport) {
172 Serial.print("__FL_DEFPIN("); Serial.print(0);
173 Serial.print(","); Serial.print(maskBit);
174 Serial.print(","); Serial.print(pinport);
175 Serial.print("); ");
176 pcount++;
177 if(pcount == 4) { pcount = 0; Serial.println(""); }
178 }
179}
const char * GetPinPort(void *ptr)
Definition Pintest.ino:134
static uint8_t pcount
Definition Pintest.ino:138

References GetPinPort(), and pcount.

+ Here is the call graph for this function: