* returns true if values do match */
| 1214 | * returns true if values do match |
| 1215 | */ |
| 1216 | bool IRrecv::checkHeader(PulseDistanceWidthProtocolConstants *aProtocolConstants) { |
| 1217 | // Check header "mark" and "space" |
| 1218 | if (!matchMark(irparams.rawbuf[1], aProtocolConstants->DistanceWidthTimingInfo.HeaderMarkMicros)) { |
| 1219 | TRACE_PRINT(::getProtocolString(aProtocolConstants->ProtocolIndex)); |
| 1220 | TRACE_PRINTLN(F(": Header mark length is wrong")); |
| 1221 | return false; |
| 1222 | } |
| 1223 | if (!matchSpace(irparams.rawbuf[2], aProtocolConstants->DistanceWidthTimingInfo.HeaderSpaceMicros)) { |
| 1224 | TRACE_PRINT(::getProtocolString(aProtocolConstants->ProtocolIndex)); |
| 1225 | TRACE_PRINTLN(F(": Header space length is wrong")); |
| 1226 | return false; |
| 1227 | } |
| 1228 | return true; |
| 1229 | } |
| 1230 | |
| 1231 | bool IRrecv::checkHeader_P(PulseDistanceWidthProtocolConstants const *aProtocolConstantsPGM) { |
| 1232 | // Check header "mark" and "space" |
nothing calls this directly
no test coverage detected