BW16 (RTL8720DN) Supported ARDUINO built-in example table
There are many built-in examples in Arduino. In the table below, we list all examples that are compatible with Ameba.
Please refer the following link to set up Ameba for Arduino IDE. https://www.amebaiot.com/amebad-bw16-arduino-getting-started/
Refer the following link for Arduino built-in example details. https://www.arduino.cc/en/Tutorial/BuiltInExamples/
Category | Name | Comment | Remarks |
01. Basics | AnalogReadSerial | Connect potentiometer to 3.3V. Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. |
BareMinimum | |||
Blink | Pin LED_BUILTIN sets to LED_G | Onboard LEDs options LED_R, LED_B, and LED_G. (red, blue, and green) | |
DigitalReadSerial | |||
Fade | Use PWM pins D7(PA25), D8(PA26), D11(PA13), D12(PA12) | ||
ReadAnalogVoltage | Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. | |
02. Digital | BlinkWithoutDelay | Pin LED_BUILTIN sets to LED_G | Onboard LEDs options LED_R, LED_B, and LED_G. |
Button | Replace “ledPin = 13;” by available digital pins. e.g. “ledPin = LED_BUILTIN;” | Onboard LEDs options LED_R, LED_B, and LED_G. | |
Debounce | Replace “ledPin = 13;” by available digital pins. e.g. “ledPin = LED_BUILTIN;” | Onboard LEDs options LED_R, LED_B, and LED_G. | |
DigitalInputPullup | Replace “ledPin = 13;” by available digital pins. e.g. “ledPin = LED_BUILTIN;” | Onboard LEDs options LED_R, LED_B, and LED_G. | |
StateChangeDetection | Replace “ledPin = 13;” by available digital pins. e.g. “ledPin = LED_BUILTIN;” | Onboard LEDs options LED_R, LED_B, and LED_G. | |
toneKeyboard | Replace “tone(8, notes[thisSensor], 20);” by a PWM pin D7(PA25), D8(PA26), D11(PA13) or D12(PA12)). e.g. “tone(PA25, notes[thisSensor – 4], 20);”, “tone(7, notes[thisSensor – 4], 20);” | ||
toneMelody | Replace “tone(8, notes[thisSensor], 20);” by a PWM pin D7(PA25), D8(PA26), D11(PA13) or D12(PA12)). e.g. “tone(PA25, notes[thisSensor – 4], 20);”, “tone(7, notes[thisSensor – 4], 20);” | ||
toneMultiple | Replace “tone(8, notes[thisSensor], 20);” by a PWM pin D7(PA25), D8(PA26), D11(PA13) or D12(PA12)). e.g. “tone(PA25, notes[thisSensor – 4], 20);”, “tone(7, notes[thisSensor – 4], 20);” | ||
tonePitchFollower | Replace “tone(8, notes[thisSensor], 20);” by a PWM pin D7(PA25), D8(PA26), D11(PA13) or D12(PA12)). e.g. “tone(PA25, notes[thisSensor – 4], 20);”, “tone(7, notes[thisSensor – 4], 20);” | ||
03. Analog | AnalogInOutSerial | Replace “analogOutPin = 9;” by a PWM pin (D7(PA25), D8(PA26), D11(PA13) or D12(PA12))). e.g. “analogOutPin = 7;”. Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. |
AnalogInput | Replace “ledPin = 13;” by available digital pins. e.g. “ledPin = LED_BUILTIN;”. Use ADC pin A2(PB3). | Onboard LEDs options LED_R, LED_B, and LED_G. ADC pin reading voltage range 0 to 3.3V. | |
Analog Write Mega | Use PWM pins D7(PA25), D8(PA26), D11(PA13), D12(PA12) | Onboard LEDs with PWM. LED_B(D11), and LED_G(D12). | |
Calibration | Connect another LED to pin D13. Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. | |
Fading | Use PWM pins D7(PA25), D8(PA26), D11(PA13), D12(PA12). | Onboard LEDs with PWM. LED_B(D11), and LED_G(D12). | |
Smoothing | Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. | |
04. Communication | ASCIITable | ||
Dimmer | Onboard LEDs options LED_R, LED_B, and LED_G. | ||
Graph | Connect potentiometer to 3.3V. Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. | |
Midi | Use Serial1 and pin D4(PB1). | ||
MultiSerial | Required external USB-to-UART module. | ||
PhysicalPixel | Replace “ledPin = 13;” by available digital pins. e.g. “ledPin = LED_BUILTIN;”. | Onboard LEDs options LED_R, LED_B, and LED_G. | |
ReadASCIIString | Use PWM pins for LED, D7(PA25), D8(PA26), D11(PA13), D12(PA12). | Onboard LEDs with PWM. LED_B(D11), and LED_G(D12). | |
SerialEvent | |||
SerialPassthrough | Required external USB-to-UART module. | ||
05. Control | Arrays | Use pins D9, D2, D8, D1, D11, D10. | |
ForLoopIteration | Use pins D9, D2, D8, D1, D11, D10. | ||
IfStatementConditional | Replace “ledPin = 13;” by available digital pins. e.g. “ledPin = LED_BUILTIN;”. Use ADC pin A2(PB3). | Onboard LEDs options LED_R, LED_B, and LED_G. ADC pin reading voltage range 0 to 3.3V. | |
switchCase | Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. | |
switchCase2 | Use pins D9, D2, D8, D1, D11, D10. | ||
WhileStatementConditional | Use ADC pin A2(PB3). Replace “indicatorLedPin = 13;” by available digital pins. e.g. “indicatorLedPin = LED_BUILTIN;”. Replace “ledPin = 9;” by a PWM pin D7(PA25), D8(PA26), D11(PA13) or D12(PA12)). e.g. “ledPin = 7;” | ADC pin reading voltage range 0 to 3.3V. Onboard LEDs options LED_R, LED_B, and LED_G. Onboard LEDs with PWM. LED_B(D11), and LED_G(D12). | |
06. Display | barGraph | Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. |
07. Strings | CharacterAnalysis | ||
StringAdditionOperator | |||
StringAppendOperator | |||
StringCaseChanges | |||
StringCharacters | |||
StringComparisonOperators | Use ADC pin A2(PB3). | ADC pin reading voltage range 0 to 3.3V. | |
StringIndexOf | |||
StringLength | |||
StringLengthTrim | |||
StringReplace | |||
StringStartsWithEndsWith | |||
StringSubstring | |||
StringToInt |
Realtek IoT/Wi-Fi MCU Solutions . All Rights Reserved. Terms of Use