Grouped Clickable Topic Index
The index intentionally lists titles only. Click any title to jump directly to the typed details for that topic.
Functions 144
Advanced I/O 6
Analog I/O 5
Bits and Bytes 7
Characters 13
Communication 64
- if (Serial)
- print()
- Serial
- Serial.available()
- Serial.parseFloat()
- Serial.print()
- Serial.println()
- Serial.read()
- Serial.readBytes()
- Serial.readBytesUntil()
- Serial.readStringUntil()
- Serial.write()
- SPI
- SPI.begin()
- SPI.beginTransaction()
- SPI.end()
- SPI.endTransaction()
- SPI.setBitOrder()
- SPI.setClockDivider()
- SPI.setDataMode()
- SPI.transfer()
- SPI.usingInterrupt()
- Stream
- Stream.available()
- Stream.find()
- Stream.findUntil()
- Stream.flush()
- Stream.parseFloat()
- Stream.parseInt()
- Stream.peek()
- Stream.read()
- Stream.readBytes()
- Stream.readBytesUntil()
- Stream.readString()
- Stream.readStringUntil()
- Stream.setTimeout()
- Wire
- Wire.begin()
- Wire.beginTransmission()
- Wire.end()
- Wire.getWireTimeoutFlag()
- Wire.onReceive()
- Serial.begin()
- Serial.end()
- Serial.availableForWrite()
- Serial.find()
- Serial.findUntil()
- Serial.flush()
- Serial.parseInt()
- Serial.peek()
- Serial.readString()
- Serial.setTimeout()
- serialEvent()
- SPISettings
- Stream.getTimeout()
- Wire.available()
- Wire.clearWireTimeoutFlag()
- Wire.endTransmission()
- Wire.onRequest()
- Wire.read()
- Wire.requestFrom()
- Wire.setClock()
- Wire.setWireTimeout()
- Wire.write()
Digital I/O 3
External Interrupts 3
Interrupts 2
Random Numbers 2
USB 18
Structure 51
Arithmetic Operators 6
Bitwise Operators 6
Boolean Operators 3
Comparison Operators 6
Compound Operators 10
Further Syntax 6
Pointer Access Operators 2
Variables 71
Constants 6
Conversion 8
Data Types 51
- bool
- byte
- char
- float
- int
- long
- short
- size_t
- string
- String
- String append operator
- String comparison operators
- String concatenation operator
- String different-from operator
- String element access operator
- String greater-than operator
- String greater-than-or-equal-to operator
- String less-than operator
- String less-than-or-equal-to operator
- String.c_str()
- String.charAt()
- String.compareTo()
- String.concat()
- String.endsWith()
- String.equals()
- String.equalsIgnoreCase()
- String.getBytes()
- String.indexOf()
- String.lastIndexOf()
- String.length()
- String.remove()
- String.replace()
- String.reserve()
- String.setCharAt()
- String.startsWith()
- String.substring()
- String.toCharArray()
- String.toDouble()
- String.toFloat()
- String.toInt()
- String.toLowerCase()
- String.toUpperCase()
- String.trim()
- unsigned char
- unsigned int
- word
- array
- boolean
- double
- unsigned long
- void
Detailed Topic Sections
Functions / Advanced I/O
noTone()
Description
Stops a square-wave tone that was previously started with tone(). If no tone is active on that pin, it has no effect.
Syntax / common form
noTone(pin);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Advanced I/O
pulseIn()
Description
Measures how long a pin stays HIGH or LOW and returns the pulse duration in microseconds.
Syntax / common form
pulseIn(pin, value);
pulseIn(pin, value, timeout);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Advanced I/O
pulseInLong()
Description
Measures longer pulse durations in microseconds and is used when pulseIn() is not the best fit for a longer signal.
Syntax / common form
pulseInLong(pin, value);
pulseInLong(pin, value, timeout);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Advanced I/O
shiftIn()
Description
Reads one byte of data one bit at a time from a data pin using a clock pin.
Syntax / common form
byte value = shiftIn(dataPin, clockPin, bitOrder);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Advanced I/O
shiftOut()
Description
Writes one byte of data one bit at a time to a data pin using a clock pin.
Syntax / common form
shiftOut(dataPin, clockPin, bitOrder, value);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Advanced I/O
tone()
Description
Generates a square wave on a pin at a specified frequency, often used for buzzers or simple audio output.
Syntax / common form
tone(pin, frequency);
tone(pin, frequency, duration);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Analog I/O
analogRead()
Description
Reads the value from an analog input pin and converts it to a digital number.
Syntax / common form
int value = analogRead(pin);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Analog I/O
analogReadResolution()
Description
Sets the number of bits used when reading analog values on boards that support adjustable ADC resolution.
Syntax / common form
analogReadResolution(bits);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Analog I/O
analogReference()
Description
Configures the reference voltage used for analog input readings on supported boards.
Syntax / common form
analogReference(type);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Analog I/O
analogWrite()
Description
Writes a PWM value, or a true analog value on supported boards, to an output pin.
Syntax / common form
analogWrite(pin, value);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Analog I/O
analogWriteResolution()
Description
Sets the number of bits used when writing analog or PWM values on boards that support adjustable output resolution.
Syntax / common form
analogWriteResolution(bits);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Bits and Bytes
bit()
Description
Reference entry for bit() in the Arduino Bits and Bytes group.
Syntax / common form
bit(n);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Bits and Bytes
bitClear()
Description
Reference entry for bitClear() in the Arduino Bits and Bytes group.
Syntax / common form
bitClear(x, n);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Bits and Bytes
bitRead()
Description
Reads the next byte or character from the input buffer.
Syntax / common form
bitRead(x, n);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Bits and Bytes
bitSet()
Description
Reference entry for bitSet() in the Arduino Bits and Bytes group.
Syntax / common form
bitSet(x, n);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Bits and Bytes
bitWrite()
Description
Writes binary data to the output stream.
Syntax / common form
bitWrite(x, n, b);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Bits and Bytes
highByte()
Description
Reference entry for highByte() in the Arduino Bits and Bytes group.
Syntax / common form
highByte(x);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Bits and Bytes
lowByte()
Description
Reference entry for lowByte() in the Arduino Bits and Bytes group.
Syntax / common form
lowByte(x);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isAlpha()
Description
Tests whether a character is alphabetic.
Syntax / common form
// Syntax varies by use case for isAlpha()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isAlphaNumeric()
Description
Tests whether a character is a letter or number.
Syntax / common form
// Syntax varies by use case for isAlphaNumeric()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isAscii()
Description
Tests whether a character is within the ASCII range.
Syntax / common form
// Syntax varies by use case for isAscii()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isControl()
Description
Tests whether a character is a control character.
Syntax / common form
// Syntax varies by use case for isControl()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isDigit()
Description
Tests whether a character is a decimal digit.
Syntax / common form
// Syntax varies by use case for isDigit()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isGraph()
Description
Tests whether a character has a visible representation other than a space.
Syntax / common form
// Syntax varies by use case for isGraph()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isHexadecimalDigit()
Description
Tests whether a character is a valid hexadecimal digit.
Syntax / common form
// Syntax varies by use case for isHexadecimalDigit()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isLowerCase()
Description
Tests whether a character is lowercase.
Syntax / common form
// Syntax varies by use case for isLowerCase()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isPrintable()
Description
Tests whether a character is printable.
Syntax / common form
// Syntax varies by use case for isPrintable()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isPunct()
Description
Tests whether a character is punctuation.
Syntax / common form
// Syntax varies by use case for isPunct()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isSpace()
Description
Tests whether a character is a whitespace/spacing character.
Syntax / common form
// Syntax varies by use case for isSpace()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isUpperCase()
Description
Tests whether a character is uppercase.
Syntax / common form
// Syntax varies by use case for isUpperCase()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Characters
isWhitespace()
Description
Tests whether a character is whitespace.
Syntax / common form
// Syntax varies by use case for isWhitespace()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Communication
if (Serial)
Description
Reference entry for if (Serial) in the Arduino Communication group.
Syntax / common form
if (Serial) { /* USB serial is ready */ }
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
print()
Description
Prints data in human-readable text form.
Syntax / common form
// Syntax varies by use case for print()
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial
Description
Represents the serial communication interface used to send and receive data over USB or UART, depending on the board.
Syntax / common form
// See methods in the Serial reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.available()
Description
Returns how many bytes are available to read without blocking.
Syntax / common form
int count = Serial.available();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.parseFloat()
Description
Reads characters from a stream and converts them into a floating-point value.
Syntax / common form
float value = Serial.parseFloat();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.print()
Description
Prints data in human-readable text form.
Syntax / common form
Serial.print(value);
Serial.print(value, format);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.println()
Description
Prints data followed by a newline.
Syntax / common form
Serial.println(value);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.read()
Description
Reads the next byte or character from the input buffer.
Syntax / common form
int byteValue = Serial.read();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.readBytes()
Description
Reads multiple bytes into a buffer.
Syntax / common form
Serial.readBytes(buffer, length);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.readBytesUntil()
Description
Reads bytes into a buffer until a terminator character or length limit is reached.
Syntax / common form
Serial.readBytesUntil(character, buffer, length);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.readStringUntil()
Description
Reads characters into a String until a terminator is found or timeout occurs.
Syntax / common form
String s = Serial.readStringUntil(terminator);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.write()
Description
Writes binary data to the output stream.
Syntax / common form
Serial.write(value);
Serial.write(buffer, length);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI
Description
Represents the SPI bus used for fast synchronous communication with peripherals.
Syntax / common form
// See methods in the SPI reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.begin()
Description
Starts or initializes the interface.
Syntax / common form
SPI.begin();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.beginTransaction()
Description
Starts an SPI transaction using a selected settings object.
Syntax / common form
SPI.beginTransaction(settings);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.end()
Description
Stops or shuts down the interface.
Syntax / common form
SPI.end();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.endTransaction()
Description
Ends the active SPI transaction.
Syntax / common form
SPI.endTransaction();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.setBitOrder()
Description
Sets whether SPI data is shifted most-significant-bit first or least-significant-bit first.
Syntax / common form
SPI.setBitOrder(order);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.setClockDivider()
Description
Sets the SPI clock divider on older SPI APIs.
Syntax / common form
SPI.setClockDivider(divider);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.setDataMode()
Description
Sets the SPI clock polarity and phase mode.
Syntax / common form
SPI.setDataMode(mode);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.transfer()
Description
Transfers data over SPI while simultaneously receiving data.
Syntax / common form
byte result = SPI.transfer(value);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
SPI.usingInterrupt()
Description
Informs the SPI library that an interrupt may use SPI so transactions can be protected.
Syntax / common form
SPI.usingInterrupt(interruptNumber);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream
Description
Base class for stream-like input/output objects such as Serial, Ethernet clients, and file streams.
Syntax / common form
// See methods in the Stream reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.available()
Description
Returns how many bytes are available to read without blocking.
Syntax / common form
int count = stream.available();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.find()
Description
Searches a stream for a target sequence.
Syntax / common form
bool found = stream.find(target);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.findUntil()
Description
Searches a stream for a target sequence until a terminator is found.
Syntax / common form
bool found = stream.findUntil(target, terminator);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.flush()
Description
Waits for outgoing data to finish or clears/handles buffered data depending on the stream implementation.
Syntax / common form
stream.flush();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.parseFloat()
Description
Reads characters from a stream and converts them into a floating-point value.
Syntax / common form
float value = stream.parseFloat();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.parseInt()
Description
Reads characters from a stream and converts them into an integer value.
Syntax / common form
long value = stream.parseInt();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.peek()
Description
Returns the next byte without removing it from the input buffer.
Syntax / common form
int value = stream.peek();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.read()
Description
Reads the next byte or character from the input buffer.
Syntax / common form
int value = stream.read();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.readBytes()
Description
Reads multiple bytes into a buffer.
Syntax / common form
stream.readBytes(buffer, length);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.readBytesUntil()
Description
Reads bytes into a buffer until a terminator character or length limit is reached.
Syntax / common form
stream.readBytesUntil(character, buffer, length);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.readString()
Description
Reads characters from a stream into a String until timeout.
Syntax / common form
String s = stream.readString();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.readStringUntil()
Description
Reads characters into a String until a terminator is found or timeout occurs.
Syntax / common form
String s = stream.readStringUntil(terminator);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Stream.setTimeout()
Description
Sets how long stream parsing/read functions wait before timing out.
Syntax / common form
stream.setTimeout(milliseconds);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Wire
Description
Arduino I2C/TWI library interface used to communicate with I2C devices.
Syntax / common form
// See methods in the Wire reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Wire.begin()
Description
Starts or initializes the interface.
Syntax / common form
Wire.begin();
Wire.begin(address);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Wire.beginTransmission()
Description
Begins an I2C transmission to a device address.
Syntax / common form
Wire.beginTransmission(address);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Wire.end()
Description
Stops or shuts down the interface.
Syntax / common form
Wire.end();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Wire.getWireTimeoutFlag()
Description
Checks whether the I2C/Wire interface has detected a timeout condition.
Syntax / common form
bool flag = Wire.getWireTimeoutFlag();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Wire.onReceive()
Description
Registers a handler function that runs when I2C data is received.
Syntax / common form
Wire.onReceive(handler);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / Communication
Serial.begin()
Description
Starts serial communication and sets the data rate.
Syntax / common form
Serial.begin(speed);
Serial.begin(speed, config);
Parameters / values
Serial baud rate, and optionally a serial configuration.
Returns / result
Usually returns nothing.
Notes
Call before using Serial communication in most sketches.
Functions / Communication
Serial.end()
Description
Disables serial communication so the serial pins can be used for general input or output again.
Syntax / common form
Serial.end();
Parameters / values
No parameters.
Returns / result
Usually returns nothing.
Notes
After ending serial communication, call Serial.begin() again before using Serial.
Functions / Communication
Serial.availableForWrite()
Description
Returns the number of bytes that can be written to the serial buffer without blocking.
Syntax / common form
int count = Serial.availableForWrite();
Parameters / values
No parameters.
Returns / result
Returns the available write-buffer space in bytes.
Notes
Useful when sending data without blocking the sketch.
Functions / Communication
Serial.find()
Description
Reads from the serial stream until a target string is found or a timeout occurs.
Syntax / common form
Serial.find(target);
Parameters / values
Target text to search for in the incoming stream.
Returns / result
Returns true if the target is found; otherwise false.
Notes
Uses the current stream timeout setting.
Functions / Communication
Serial.findUntil()
Description
Reads from the serial stream until a target string or a terminator string is found.
Syntax / common form
Serial.findUntil(target, terminal);
Parameters / values
Target text and terminal text.
Returns / result
Returns true if the target is found before the terminator or timeout.
Notes
Useful for parsing incoming serial data with delimiters.
Functions / Communication
Serial.flush()
Description
Waits for outgoing serial data to finish transmitting.
Syntax / common form
Serial.flush();
Parameters / values
No parameters.
Returns / result
Usually returns nothing.
Notes
This affects outgoing data transmission rather than clearing unread incoming data.
Functions / Communication
Serial.parseInt()
Description
Reads incoming serial characters and returns the first valid integer value found.
Syntax / common form
long value = Serial.parseInt();
Parameters / values
Optional lookahead and ignore-character behavior may be supported depending on the core.
Returns / result
Returns the parsed integer value.
Notes
Parsing stops at timeout or when a non-numeric terminator is reached.
Functions / Communication
Serial.peek()
Description
Returns the next byte from the serial buffer without removing it.
Syntax / common form
int value = Serial.peek();
Parameters / values
No parameters.
Returns / result
Returns the next byte, or -1 if no data is available.
Notes
Use when you need to inspect incoming data before reading it.
Functions / Communication
Serial.readString()
Description
Reads characters from the serial buffer into a String until timeout.
Syntax / common form
String value = Serial.readString();
Parameters / values
No parameters.
Returns / result
Returns the characters read as a String.
Notes
Timeout behavior depends on Serial.setTimeout().
Functions / Communication
Serial.setTimeout()
Description
Sets the maximum time to wait for serial stream parsing and reading operations.
Syntax / common form
Serial.setTimeout(time);
Parameters / values
Timeout duration in milliseconds.
Returns / result
Usually returns nothing.
Notes
Affects stream methods such as parseInt(), parseFloat(), readString(), and readBytes().
Functions / Communication
serialEvent()
Description
A function that can be called when new serial data is available, on boards/cores that support it.
Syntax / common form
void serialEvent() {
// handle incoming serial data
}
Parameters / values
No parameters.
Returns / result
Returns nothing.
Notes
Board support varies. It is not a replacement for checking Serial.available() in all sketches.
Functions / Communication
SPISettings
Description
Defines SPI transaction settings such as clock speed, bit order, and data mode.
Syntax / common form
SPISettings(clock, bitOrder, dataMode);
Parameters / values
Clock speed, bit order, and SPI data mode.
Returns / result
Creates an SPI settings object used with SPI.beginTransaction().
Notes
Use with SPI transactions so devices can use the correct bus configuration.
Functions / Communication
Stream.getTimeout()
Description
Returns the current timeout value used by stream parsing and reading operations.
Syntax / common form
unsigned long timeout = stream.getTimeout();
Parameters / values
No parameters.
Returns / result
Returns the timeout in milliseconds.
Notes
The timeout can be changed with setTimeout().
Functions / Communication
Wire.available()
Description
Returns how many bytes are available to read from the I2C buffer.
Syntax / common form
int count = Wire.available();
Parameters / values
No parameters.
Returns / result
Returns the number of bytes available.
Notes
Usually called after requestFrom() or inside receive handlers.
Functions / Communication
Wire.clearWireTimeoutFlag()
Description
Clears the I2C timeout flag on supported Wire implementations.
Syntax / common form
Wire.clearWireTimeoutFlag();
Parameters / values
No parameters.
Returns / result
Usually returns nothing.
Notes
Useful after handling a Wire timeout condition.
Functions / Communication
Wire.endTransmission()
Description
Ends an I2C transmission to a device and sends the queued bytes.
Syntax / common form
byte result = Wire.endTransmission();
Parameters / values
Optional stop behavior may be supported.
Returns / result
Returns a status code indicating the result of the transmission.
Notes
Commonly used after beginTransmission() and write().
Functions / Communication
Wire.onRequest()
Description
Registers a function to run when an I2C controller requests data from this device.
Syntax / common form
Wire.onRequest(handler);
Parameters / values
Function name to call when data is requested.
Returns / result
Usually returns nothing.
Notes
Used when the Arduino acts as an I2C peripheral.
Functions / Communication
Wire.read()
Description
Reads one byte from the I2C receive buffer.
Syntax / common form
int value = Wire.read();
Parameters / values
No parameters.
Returns / result
Returns the next byte, or -1 if no data is available.
Notes
Use Wire.available() to check whether data is ready.
Functions / Communication
Wire.requestFrom()
Description
Requests bytes from an I2C peripheral device.
Syntax / common form
Wire.requestFrom(address, quantity);
Parameters / values
Device address and number of bytes to request.
Returns / result
Returns the number of bytes returned by the device.
Notes
Usually followed by Wire.available() and Wire.read().
Functions / Communication
Wire.setClock()
Description
Sets the I2C clock frequency.
Syntax / common form
Wire.setClock(clockFrequency);
Parameters / values
Clock frequency in hertz.
Returns / result
Usually returns nothing.
Notes
Supported frequencies depend on the board and devices on the bus.
Functions / Communication
Wire.setWireTimeout()
Description
Configures timeout behavior for Wire operations on supported boards.
Syntax / common form
Wire.setWireTimeout(timeout, reset_on_timeout);
Parameters / values
Timeout duration and optional reset behavior.
Returns / result
Usually returns nothing.
Notes
Useful for preventing a sketch from hanging indefinitely during I2C problems.
Functions / Communication
Wire.write()
Description
Writes data to the I2C transmit buffer or sends data during an I2C request handler.
Syntax / common form
Wire.write(value);
Wire.write(buffer, length);
Parameters / values
A byte, string, or buffer with a length.
Returns / result
Returns the number of bytes written on implementations that report it.
Notes
Use during transmissions or in onRequest handlers.
Functions / Digital I/O
digitalRead()
Description
Reads whether a digital pin is HIGH or LOW.
Syntax / common form
int state = digitalRead(pin);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Digital I/O
digitalWrite()
Description
Writes HIGH or LOW to a digital output pin, or enables/disables pull-up behavior on an input pin.
Syntax / common form
digitalWrite(pin, value);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Digital I/O
pinMode()
Description
Configures a pin as an input, input with pull-up resistor, or output.
Syntax / common form
pinMode(pin, mode);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / External Interrupts
attachInterrupt()
Description
Attaches an interrupt service routine to a hardware interrupt so code can react quickly to pin changes.
Syntax / common form
attachInterrupt(digitalPinToInterrupt(pin), ISR, mode);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / External Interrupts
detachInterrupt()
Description
Removes a previously attached interrupt handler.
Syntax / common form
detachInterrupt(digitalPinToInterrupt(pin));
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / External Interrupts
digitalPinToInterrupt()
Description
Converts a board pin number into the interrupt number expected by attachInterrupt().
Syntax / common form
digitalPinToInterrupt(pin);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Interrupts
interrupts()
Description
Re-enables interrupts after they were disabled.
Syntax / common form
interrupts();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Interrupts
noInterrupts()
Description
Temporarily disables interrupts for timing-sensitive critical sections.
Syntax / common form
noInterrupts();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Math
abs()
Description
Returns the absolute value of a number.
Syntax / common form
abs(x);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Math
constrain()
Description
Restricts a value so it stays between a lower and upper bound.
Syntax / common form
constrain(x, a, b);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Math
map()
Description
Re-maps a number from one numeric range into another.
Syntax / common form
map(value, fromLow, fromHigh, toLow, toHigh);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Math
max()
Description
Returns the larger of two values.
Syntax / common form
max(x, y);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Math
min()
Description
Returns the smaller of two values.
Syntax / common form
min(x, y);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Math
pow()
Description
Raises a number to a power.
Syntax / common form
pow(base, exponent);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Math
sq()
Description
Returns the square of a value.
Syntax / common form
sq(x);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Math
sqrt()
Description
Returns the square root of a value.
Syntax / common form
sqrt(x);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Random Numbers
random()
Description
Returns a pseudo-random number in a specified range.
Syntax / common form
random(max);
random(min, max);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Random Numbers
randomSeed()
Description
Initializes the pseudo-random number generator with a seed value.
Syntax / common form
randomSeed(seed);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Time
delay()
Description
Pauses the sketch for a specified number of milliseconds.
Syntax / common form
delay(ms);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Time
delayMicroseconds()
Description
Pauses the sketch for a specified number of microseconds.
Syntax / common form
delayMicroseconds(us);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Time
micros()
Description
Returns the number of microseconds since the board began running the current program.
Syntax / common form
unsigned long now = micros();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Timing-sensitive functions may be affected by interrupts, board speed, and hardware capabilities.
Functions / Time
millis()
Description
Returns the number of milliseconds since the board began running the current sketch.
Syntax / common form
unsigned long time = millis();
Parameters / values
No parameters.
Returns / result
Returns elapsed time in milliseconds.
Notes
Use subtraction-based timing instead of delay() for non-blocking timing logic.
Functions / Trigonometry
cos()
Description
Returns the cosine of an angle in radians.
Syntax / common form
cos(rad);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Trigonometry
sin()
Description
Returns the sine of an angle in radians.
Syntax / common form
sin(rad);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / Trigonometry
tan()
Description
Returns the tangent of an angle in radians.
Syntax / common form
tan(rad);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Returns a value. The exact type depends on the function.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Functions / USB
Keyboard
Description
USB HID keyboard interface for supported boards that can emulate keyboard input.
Syntax / common form
// See methods in the Keyboard reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Keyboard Modifiers
Description
Reference entry for Keyboard Modifiers in the Arduino USB group.
Syntax / common form
// Syntax varies by use case for Keyboard Modifiers
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Keyboard.end()
Description
Stops or shuts down the interface.
Syntax / common form
Keyboard.end();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Keyboard.press()
Description
Reference entry for Keyboard.press() in the Arduino USB group.
Syntax / common form
Keyboard.press(key);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Keyboard.print()
Description
Prints data in human-readable text form.
Syntax / common form
Keyboard.print(value);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Keyboard.println()
Description
Prints data followed by a newline.
Syntax / common form
Keyboard.println(value);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Keyboard.release()
Description
Reference entry for Keyboard.release() in the Arduino USB group.
Syntax / common form
Keyboard.release(key);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Keyboard.releaseAll()
Description
Reference entry for Keyboard.releaseAll() in the Arduino USB group.
Syntax / common form
Keyboard.releaseAll();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Mouse
Description
USB HID mouse interface for supported boards that can emulate mouse input.
Syntax / common form
// See methods in the Mouse reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Mouse.begin()
Description
Starts or initializes the interface.
Syntax / common form
Mouse.begin();
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Mouse.release()
Description
Reference entry for Mouse.release() in the Arduino USB group.
Syntax / common form
Mouse.release(button);
Parameters / values
Common parameters include pins, values, buffers, counts, strings, addresses, modes, or timeouts depending on the function.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / USB
Keyboard.begin()
Description
Starts keyboard emulation on supported USB-capable boards.
Syntax / common form
Keyboard.begin();
Parameters / values
No parameters.
Returns / result
Usually returns nothing.
Notes
Only use on boards that support USB keyboard emulation.
Functions / USB
Keyboard.write()
Description
Sends a single keystroke through keyboard emulation.
Syntax / common form
Keyboard.write(character);
Parameters / values
Character or key value to send.
Returns / result
Returns the number of bytes sent on implementations that report it.
Notes
Use carefully because it can type into the connected computer.
Functions / USB
Mouse.click()
Description
Sends a mouse click using USB mouse emulation.
Syntax / common form
Mouse.click(button);
Parameters / values
Mouse button to click.
Returns / result
Usually returns nothing.
Notes
Only works on boards that support USB mouse emulation.
Functions / USB
Mouse.end()
Description
Stops mouse emulation on supported USB-capable boards.
Syntax / common form
Mouse.end();
Parameters / values
No parameters.
Returns / result
Usually returns nothing.
Notes
Call Mouse.begin() again before sending more mouse actions.
Functions / USB
Mouse.isPressed()
Description
Checks whether a mouse button is currently pressed by the emulation state.
Syntax / common form
bool pressed = Mouse.isPressed(button);
Parameters / values
Mouse button to check.
Returns / result
Returns true if the button is pressed; otherwise false.
Notes
Useful when managing press and release state manually.
Functions / USB
Mouse.move()
Description
Moves the mouse pointer and optionally scrolls the wheel.
Syntax / common form
Mouse.move(xVal, yVal, wheel);
Parameters / values
Horizontal movement, vertical movement, and optional wheel movement.
Returns / result
Usually returns nothing.
Notes
Movement is relative, not absolute screen positioning.
Functions / USB
Mouse.press()
Description
Presses and holds a mouse button using USB mouse emulation.
Syntax / common form
Mouse.press(button);
Parameters / values
Mouse button to press.
Returns / result
Usually returns nothing.
Notes
Call Mouse.release() or Mouse.releaseAll() to stop holding the button.
Functions / WiFi
Client
Description
Base client networking interface for TCP-style connections.
Syntax / common form
// See methods in the Client reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / WiFi
IPAddress
Description
Represents an IPv4 address used with networking functions.
Syntax / common form
// See methods in the IPAddress reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / WiFi
Overview
Description
General overview entry for the WiFi reference group.
Syntax / common form
// See methods in the Overview reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / WiFi
Server
Description
Base server networking interface for listening for incoming clients.
Syntax / common form
// See methods in the Server reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / WiFi
UDP
Description
Interface for sending and receiving UDP datagrams.
Syntax / common form
// See methods in the UDP reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Functions / WiFi
WiFiClass
Description
Main WiFi control class used by WiFi-capable Arduino boards or WiFi libraries.
Syntax / common form
// See methods in the WiFiClass reference group.
Parameters / values
Not a callable function; see related methods or examples for the object/class.
Returns / result
Usually returns nothing unless the specific method is documented otherwise.
Notes
Board/library support can vary. Confirm the target board supports this interface before relying on it.
Structure / Arithmetic Operators
Addition: +
Description
Adds two values.
Syntax / common form
result = a + b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Arithmetic Operators
Division: /
Description
Divides the left value by the right value.
Syntax / common form
result = a / b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Arithmetic Operators
Multiplication: *
Description
Multiplies two values.
Syntax / common form
result = a * b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Arithmetic Operators
Remainder: %
Description
Returns the remainder after integer division.
Syntax / common form
result = a % b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Arithmetic Operators
Subtraction: –
Description
Subtracts the right value from the left value.
Syntax / common form
result = a - b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Arithmetic Operators
Assignment: =
Description
Assigns a value to a variable.
Syntax / common form
variable = value;
Parameters / values
Variable on the left and value or expression on the right.
Returns / result
Produces the assigned value as an expression in C/C++.
Notes
Do not confuse assignment = with equality comparison ==.
Structure / Bitwise Operators
Bitshift Left: <<
Description
Shifts bits left by a selected number of positions.
Syntax / common form
result = a << b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Bitwise Operators
Bitwise NOT: ~
Description
Inverts every bit in a value.
Syntax / common form
result = a ~ b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Bitwise Operators
Bitwise OR: |
Description
Sets each result bit when either input bit is 1.
Syntax / common form
result = a | b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Bitwise Operators
Bitwise XOR: ^
Description
Sets each result bit when the input bits differ.
Syntax / common form
result = a ^ b;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Bitwise Operators
Bitshift Right: >>
Description
Shifts the bits of a value to the right.
Syntax / common form
result = value >> count;
Parameters / values
Value to shift and number of bit positions.
Returns / result
Returns the shifted result.
Notes
Right shifting can be used for division by powers of two with integer values.
Structure / Bitwise Operators
Bitwise AND: &
Description
Compares bits from two values and keeps only bits that are set in both.
Syntax / common form
result = a & b;
Parameters / values
Two integer values.
Returns / result
Returns the bitwise AND result.
Notes
Useful for masking selected bits.
Structure / Boolean Operators
Boolean AND: &&
Description
Tests whether two conditions are both true.
Syntax / common form
if (a && b) {
// both are true
}
Parameters / values
Two Boolean expressions.
Returns / result
Returns true only when both expressions are true.
Notes
Commonly used in if, while, and other condition checks.
Structure / Boolean Operators
Boolean NOT: !
Description
Reverses a Boolean condition.
Syntax / common form
if (!condition) {
// condition is false
}
Parameters / values
One Boolean expression.
Returns / result
Returns true when the expression is false, and false when it is true.
Notes
Useful for checking the opposite of a condition.
Structure / Boolean Operators
Boolean OR: ||
Description
Tests whether at least one of two conditions is true.
Syntax / common form
if (a || b) {
// at least one is true
}
Parameters / values
Two Boolean expressions.
Returns / result
Returns true when either expression is true.
Notes
Commonly used for alternate acceptable conditions.
Structure / Comparison Operators
Less Than or Equal To: <=
Description
Tests whether the left value is less than or equal to the right value.
Syntax / common form
if (a <= b) {
// code
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Comparison Operators
Less Than: <
Description
Tests whether the left value is less than the right value.
Syntax / common form
if (a < b) {
// code
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Comparison Operators
Equal To: ==
Description
Compares two values to see whether they are equal.
Syntax / common form
if (a == b) {
// values are equal
}
Parameters / values
Two values or expressions.
Returns / result
Returns true when the values are equal.
Notes
Use == for comparison, not =.
Structure / Comparison Operators
Greater Than: >
Description
Compares whether the left value is greater than the right value.
Syntax / common form
if (a > b) {
// a is greater
}
Parameters / values
Two values or expressions.
Returns / result
Returns true when the left side is greater.
Notes
Commonly used in thresholds and range checks.
Structure / Comparison Operators
Greater Than or Equal To: >=
Description
Compares whether the left value is greater than or equal to the right value.
Syntax / common form
if (a >= b) {
// a is at least b
}
Parameters / values
Two values or expressions.
Returns / result
Returns true when the left side is greater than or equal to the right side.
Notes
Useful for inclusive upper or lower bounds.
Structure / Comparison Operators
Not Equal To: !=
Description
Compares two values to see whether they are different.
Syntax / common form
if (a != b) {
// values are different
}
Parameters / values
Two values or expressions.
Returns / result
Returns true when the values are not equal.
Notes
Useful for detecting changed states or invalid values.
Structure / Compound Operators
Compound Bitwise XOR: ^=
Description
Applies bitwise XOR and stores the result back into the variable.
Syntax / common form
x ^= value;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Compound Operators
Compound Multiplication: *=
Description
Multiplies a variable by a value and stores the result back into the variable.
Syntax / common form
x *= value;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Compound Operators
Compound Subtraction: -=
Description
Subtracts a value from a variable and stores the result back into the variable.
Syntax / common form
x -= value;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Compound Operators
Decrement: —
Description
Decreases a variable by one.
Syntax / common form
x--;
--x;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Compound Operators
Increment: ++
Description
Increases a variable by one.
Syntax / common form
x++;
++x;
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Compound Operators
Compound Addition: +=
Description
Adds a value to a variable and stores the result back in that variable.
Syntax / common form
x += amount;
Parameters / values
Variable and value to add.
Returns / result
Updates the variable.
Notes
Equivalent to x = x + amount.
Structure / Compound Operators
Compound Bitwise AND: &=
Description
Applies bitwise AND to a variable and stores the result back in that variable.
Syntax / common form
x &= mask;
Parameters / values
Variable and mask value.
Returns / result
Updates the variable.
Notes
Useful for clearing or preserving selected bits.
Structure / Compound Operators
Compound Bitwise OR: |=
Description
Applies bitwise OR to a variable and stores the result back in that variable.
Syntax / common form
x |= mask;
Parameters / values
Variable and mask value.
Returns / result
Updates the variable.
Notes
Useful for setting selected bits.
Structure / Compound Operators
Compound Division: /=
Description
Divides a variable by a value and stores the result back in that variable.
Syntax / common form
x /= divisor;
Parameters / values
Variable and divisor.
Returns / result
Updates the variable.
Notes
Equivalent to x = x / divisor.
Structure / Compound Operators
Compound Remainder: %=
Description
Applies the remainder operation to a variable and stores the result back in that variable.
Syntax / common form
x %= divisor;
Parameters / values
Variable and divisor.
Returns / result
Updates the variable.
Notes
Useful for wrapping counters or keeping values within a range.
Structure / Control Structure
else
Description
Runs an alternate block of code when an if condition is false.
Syntax / common form
if (condition) {
// code
} else {
// alternate code
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Structure / Control Structure
if
Description
Runs a block of code only when a condition is true.
Syntax / common form
if (condition) {
// code
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Structure / Control Structure
switch…case
Description
Chooses between multiple code paths based on a matching value.
Syntax / common form
switch (value) {
case 1:
// code
break;
default:
// code
break;
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Structure / Control Structure
while
Description
Repeats a block of code while a condition remains true.
Syntax / common form
while (condition) {
// repeated code
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Structure / Control Structure
break
Description
Exits the nearest loop or switch statement.
Syntax / common form
break;
Parameters / values
No parameters.
Returns / result
Exits the current loop or switch block.
Notes
Commonly used in switch cases and loops.
Structure / Control Structure
continue
Description
Skips the rest of the current loop iteration and starts the next iteration.
Syntax / common form
continue;
Parameters / values
No parameters.
Returns / result
Continues with the next loop iteration.
Notes
Use inside for, while, or do…while loops.
Structure / Control Structure
do…while
Description
Runs a block of code once, then repeats while a condition remains true.
Syntax / common form
do {
// code
} while (condition);
Parameters / values
Condition tested after each loop run.
Returns / result
Repeats while the condition is true.
Notes
A do…while loop always runs at least once.
Structure / Control Structure
for
Description
Repeats a block of code using initialization, condition, and update expressions.
Syntax / common form
for (initialization; condition; increment) {
// code
}
Parameters / values
Initialization, loop condition, and increment expression.
Returns / result
Repeats while the condition is true.
Notes
Useful when the number of loop iterations is known or countable.
Structure / Control Structure
goto
Description
Jumps execution to a labeled statement.
Syntax / common form
goto label;
label:
Parameters / values
Label name.
Returns / result
Transfers control to the label.
Notes
Avoid in normal sketches unless there is a specific reason.
Structure / Control Structure
return
Description
Exits a function and optionally sends a value back to the caller.
Syntax / common form
return;
return value;
Parameters / values
Optional return value.
Returns / result
Ends the function and may return a value.
Notes
The returned value must match the function return type.
Structure / Further Syntax
Block Comment: /* */
Description
Creates a multi-line comment ignored by the compiler.
Syntax / common form
/*
comment text
*/
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Structure / Further Syntax
Curly Braces: { }
Description
Groups statements into a block for functions, conditions, loops, and classes.
Syntax / common form
functionName() {
// block
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Structure / Further Syntax
#define
Description
Creates a preprocessor macro or named constant before compilation.
Syntax / common form
#define NAME value
Parameters / values
Macro name and replacement value.
Returns / result
No runtime return value.
Notes
Prefer const or constexpr for typed constants when appropriate.
Structure / Further Syntax
#include
Description
Adds a library or header file to the sketch before compilation.
Syntax / common form
#include <Library.h>
#include "localfile.h"
Parameters / values
Header or library file name.
Returns / result
No runtime return value.
Notes
Required when using many libraries or declarations from separate files.
Structure / Further Syntax
Semicolon: ;
Description
Marks the end of many Arduino/C++ statements.
Syntax / common form
statement;
Parameters / values
No parameters.
Returns / result
Ends a statement.
Notes
Missing semicolons are a common compile error.
Structure / Further Syntax
Single-line Comment: //
Description
Adds a comment that continues to the end of the line.
Syntax / common form
// comment text
Parameters / values
Comment text.
Returns / result
No runtime effect.
Notes
Useful for notes and temporarily disabling one line of code.
Structure / Pointer Access Operators
Dereference Operator: *
Description
Accesses the value stored at a pointer address.
Syntax / common form
// Pointer syntax depends on declaration and use context.
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Pointer Access Operators
Reference Operator: &
Description
Gets the memory address of a variable.
Syntax / common form
// Pointer syntax depends on declaration and use context.
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Operator precedence can affect results. Use parentheses when code clarity matters.
Structure / Sketch
loop()
Description
Special Arduino function that runs repeatedly after setup() finishes.
Syntax / common form
void loop() {
// repeats forever
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Structure / Sketch
setup()
Description
Special Arduino function that runs once when the sketch starts.
Syntax / common form
void setup() {
// runs once
}
Parameters / values
Conditions, expressions, operands, or code blocks depending on the language feature.
Returns / result
Not applicable as a standalone return value.
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Constants
Floating point constants
Description
Numeric constants written with decimal points or exponent notation.
Syntax / common form
3.14
1.0e-3
Parameters / values
Floating-point literal value.
Returns / result
Used as a floating-point number.
Notes
Use floating-point constants when fractional precision is needed.
Variables / Constants
HIGH | LOW
Description
Constants used to represent digital logic levels.
Syntax / common form
digitalWrite(pin, HIGH);
digitalWrite(pin, LOW);
Parameters / values
HIGH or LOW.
Returns / result
Used as digital state values.
Notes
Actual voltage depends on the board.
Variables / Constants
INPUT | OUTPUT | INPUT_PULLUP
Description
Pin mode constants used with pinMode().
Syntax / common form
pinMode(pin, INPUT);
pinMode(pin, OUTPUT);
pinMode(pin, INPUT_PULLUP);
Parameters / values
Pin mode constant.
Returns / result
Configures the pin behavior.
Notes
INPUT_PULLUP enables the internal pull-up resistor on supported pins.
Variables / Constants
Integer constants
Description
Whole-number constants written in decimal, binary, octal, or hexadecimal notation.
Syntax / common form
10
0b1010
0x0A
Parameters / values
Integer literal value.
Returns / result
Used as an integer number.
Notes
Choose notation that makes the value easiest to understand.
Variables / Constants
LED_BUILTIN
Description
Constant that refers to the board’s built-in LED pin when defined by the board package.
Syntax / common form
pinMode(LED_BUILTIN, OUTPUT);
Parameters / values
No parameters.
Returns / result
Represents the built-in LED pin number.
Notes
The actual pin varies by board.
Variables / Constants
true | false
Description
Boolean constants representing true and false logic values.
Syntax / common form
bool state = true;
bool state = false;
Parameters / values
true or false.
Returns / result
Used as Boolean values.
Notes
Commonly used in conditions, flags, and state variables.
Variables / Conversion
char()
Description
Casts or converts a value to char.
Syntax / common form
char(value);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Conversion
long()
Description
Casts or converts a value to long.
Syntax / common form
long(value);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Conversion
unsigned int()
Description
Casts or converts a value to unsigned int.
Syntax / common form
unsigned int(value);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Conversion
unsigned long()
Description
Casts or converts a value to unsigned long.
Syntax / common form
unsigned long(value);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Conversion
word()
Description
Casts or creates a word-sized unsigned value.
Syntax / common form
word(value);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Conversion
byte()
Description
Converts a value to the byte data type.
Syntax / common form
byte value = byte(x);
Parameters / values
Value to convert.
Returns / result
Returns the value as a byte.
Notes
A byte stores an 8-bit unsigned value.
Variables / Conversion
float()
Description
Converts a value to the float data type.
Syntax / common form
float value = float(x);
Parameters / values
Value to convert.
Returns / result
Returns the value as a float.
Notes
Useful when an expression should be treated as floating point.
Variables / Conversion
int()
Description
Converts a value to the int data type.
Syntax / common form
int value = int(x);
Parameters / values
Value to convert.
Returns / result
Returns the value as an int.
Notes
Range depends on the board architecture.
Variables / Data Types
bool
Description
Boolean type that stores true or false.
Syntax / common form
bool value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Data Types
byte
Description
8-bit unsigned integer type, commonly used for raw byte values.
Syntax / common form
byte value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Exact size can vary by board architecture. Check the board family when range matters.
Variables / Data Types
char
Description
Character type, usually an 8-bit value storing a character or small integer.
Syntax / common form
char value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Data Types
float
Description
Floating-point numeric type used for decimal values.
Syntax / common form
float value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Data Types
int
Description
Integer type used for whole numbers. Size depends on the board architecture.
Syntax / common form
int value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Exact size can vary by board architecture. Check the board family when range matters.
Variables / Data Types
long
Description
Larger signed integer type used when int is not large enough.
Syntax / common form
long value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Exact size can vary by board architecture. Check the board family when range matters.
Variables / Data Types
short
Description
Short signed integer type.
Syntax / common form
short value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Exact size can vary by board architecture. Check the board family when range matters.
Variables / Data Types
size_t
Description
Unsigned integer type used to represent sizes and counts.
Syntax / common form
size_t value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Exact size can vary by board architecture. Check the board family when range matters.
Variables / Data Types
string
Description
C-style character array string.
Syntax / common form
string value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Data Types
String
Description
Arduino String object class for handling text with methods and operators.
Syntax / common form
String value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String append operator
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String comparison operators
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String concatenation operator
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String different-from operator
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String element access operator
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String greater-than operator
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String greater-than-or-equal-to operator
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String less-than operator
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String less-than-or-equal-to operator
Description
Operator reference for comparing, joining, indexing, or modifying Arduino String objects.
Syntax / common form
String a = "hello";
String b = "world";
// operator syntax depends on operation
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.c_str()
Description
Returns a C-style null-terminated character pointer for the String.
Syntax / common form
const char* p = myString.c_str();
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.charAt()
Description
Returns the character at a specified index.
Syntax / common form
char c = myString.charAt(index);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.compareTo()
Description
Compares two strings and returns ordering information.
Syntax / common form
int result = myString.compareTo(otherString);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.concat()
Description
Appends another value to the end of the String.
Syntax / common form
myString.concat(value);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.endsWith()
Description
Tests whether the String ends with a specified suffix.
Syntax / common form
bool ok = myString.endsWith(suffix);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.equals()
Description
Tests whether the String equals another value exactly.
Syntax / common form
bool ok = myString.equals(otherString);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.equalsIgnoreCase()
Description
Tests equality while ignoring letter case.
Syntax / common form
bool ok = myString.equalsIgnoreCase(otherString);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.getBytes()
Description
Copies String bytes into a byte buffer.
Syntax / common form
myString.getBytes(buffer, bufferSize);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.indexOf()
Description
Finds the first index of a character or substring.
Syntax / common form
int i = myString.indexOf(value);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.lastIndexOf()
Description
Finds the last index of a character or substring.
Syntax / common form
int i = myString.lastIndexOf(value);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.length()
Description
Returns the number of characters in the String.
Syntax / common form
unsigned int n = myString.length();
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.remove()
Description
Removes characters from the String.
Syntax / common form
myString.remove(index);
myString.remove(index, count);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.replace()
Description
Replaces matching characters or substrings.
Syntax / common form
myString.replace(find, replace);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.reserve()
Description
Pre-allocates memory for a String to reduce fragmentation.
Syntax / common form
myString.reserve(size);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.setCharAt()
Description
Changes the character at a selected index.
Syntax / common form
myString.setCharAt(index, character);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.startsWith()
Description
Tests whether the String begins with a specified prefix.
Syntax / common form
bool ok = myString.startsWith(prefix);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.substring()
Description
Extracts part of a String.
Syntax / common form
String part = myString.substring(from);
String part = myString.substring(from, to);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.toCharArray()
Description
Copies the String into a C-style character array.
Syntax / common form
myString.toCharArray(buffer, bufferSize);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.toDouble()
Description
Converts the String to a double value when supported.
Syntax / common form
double value = myString.toDouble();
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.toFloat()
Description
Converts the String to a float value.
Syntax / common form
float value = myString.toFloat();
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.toInt()
Description
Converts the String to an integer value.
Syntax / common form
long value = myString.toInt();
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.toLowerCase()
Description
Converts the String to lowercase in place.
Syntax / common form
myString.toLowerCase();
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.toUpperCase()
Description
Converts the String to uppercase in place.
Syntax / common form
myString.toUpperCase();
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
String.trim()
Description
Removes leading and trailing whitespace from the String.
Syntax / common form
myString.trim();
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
On small-memory boards, heavy String use can fragment memory. For critical projects, consider fixed character buffers.
Variables / Data Types
unsigned char
Description
8-bit unsigned character/integer type.
Syntax / common form
unsigned char value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Exact size can vary by board architecture. Check the board family when range matters.
Variables / Data Types
unsigned int
Description
Unsigned integer type that cannot represent negative values.
Syntax / common form
unsigned int value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Exact size can vary by board architecture. Check the board family when range matters.
Variables / Data Types
word
Description
Unsigned 16-bit value on many Arduino platforms.
Syntax / common form
word value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Exact size can vary by board architecture. Check the board family when range matters.
Variables / Data Types
array
Description
A collection of values stored under one name and accessed by index.
Syntax / common form
type name[count];
type name[] = { value1, value2 };
Parameters / values
Type, array name, size, and optional initial values.
Returns / result
Stores multiple values of the same type.
Notes
Array indexing starts at 0.
Variables / Data Types
boolean
Description
An older Arduino Boolean type that stores true or false.
Syntax / common form
boolean state = true;
Parameters / values
Variable name and true/false value.
Returns / result
Stores a Boolean value.
Notes
bool is the standard C++ Boolean type.
Variables / Data Types
double
Description
Floating-point data type for decimal numbers.
Syntax / common form
double value = 3.14;
Parameters / values
Variable name and numeric value.
Returns / result
Stores a floating-point value.
Notes
On some Arduino boards, double has the same precision as float.
Variables / Data Types
unsigned long
Description
Unsigned integer type commonly used for large non-negative values.
Syntax / common form
unsigned long value = 0;
Parameters / values
Variable name and non-negative value.
Returns / result
Stores a large unsigned integer.
Notes
Often used with millis() and micros() timing values.
Variables / Data Types
void
Description
Indicates that a function does not return a value.
Syntax / common form
void functionName() {
// code
}
Parameters / values
Used as a function return type.
Returns / result
Returns no value.
Notes
setup() and loop() are declared with void.
Variables / Utilities
PROGMEM
Description
Places constant data into program memory/flash on platforms where this saves RAM.
Syntax / common form
PROGMEM value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Utilities
sizeof()
Description
Returns the number of bytes used by a type or variable.
Syntax / common form
sizeof(variable);
sizeof(type);
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Variable Scope Qualifiers
const
Description
Qualifier that marks a value as read-only after initialization.
Syntax / common form
const value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Variable Scope Qualifiers
scope
Description
Describes where a variable can be seen or used in a program.
Syntax / common form
scope value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Variable Scope Qualifiers
volatile
Description
Qualifier for variables that may change unexpectedly, often inside interrupts.
Syntax / common form
volatile value;
Parameters / values
Variable name, type, value, or object instance depending on the entry.
Returns / result
Not applicable unless the entry is a conversion function or sizeof().
Notes
Use this entry as a quick reference and verify board-specific behavior when needed.
Variables / Variable Scope Qualifiers
static
Description
Preserves a local variable’s value between function calls or limits visibility depending on where it is used.
Syntax / common form
static type name = value;
Parameters / values
Variable type, name, and optional initial value.
Returns / result
Changes storage duration or linkage.
Notes
Useful when a function needs to remember state between calls.