MCPcopy Create free account
hub / github.com/SmingHub/Sming / readBytes

Method readBytes

Sming/Wiring/Stream.cpp:182–192  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

180}
181
182size_t Stream::readBytes(char* buffer, size_t length)
183{
184 size_t count = 0;
185 int c;
186 while(count < length && (c = timedRead()) >= 0) {
187 *buffer++ = char(c);
188 count++;
189 }
190
191 return count;
192}
193
194size_t Stream::readBytesUntil(char terminator, char* buffer, size_t length)
195{

Callers 2

checkMethod · 0.45
executeMethod · 0.45

Calls

no outgoing calls

Tested by 1

checkMethod · 0.36