Logo

FNK0064

  • C language
    • Welcome
      • Getting Started
      • Get Support and Offer Input
      • Safety and Precautions
      • About Freenove
      • Copyright
    • Preface
      • Raspberry Pi Pico
        • UART, I2C, SPI Default Pin
          • UART
          • I2C
          • SPI
      • Raspberry Pi Pico W
        • UART, I2C, SPI Default Pin
          • UART
          • I2C
          • SPI
          • Wireless
      • Raspberry Pi Pico 2
        • UART, I2C, SPI Default Pin
          • UART
          • I2C
          • SPI
    • 0. Chapter Getting Ready (Important)
      • Programming Software
      • Installation of Development Board Support Package
      • Uploading Arduino-compatible Firmware for Pico
      • Paste the Sticker on the Breadboard
    • 1. Chapter 1 LED (Important)
      • 1.1. Project Blink
        • 1.1.1. Component List
          • 1.1.1.1. Power
        • 1.1.2. Sketch
          • 1.1.2.1. Reference
      • 1.2. Project Blink
        • 1.2.1. Component List
        • 1.2.2. Component Knowledge
          • 1.2.2.1. LED
          • 1.2.2.2. Resistor
          • 1.2.2.3. Breadboard
          • 1.2.2.4. Power
        • 1.2.3. Circuit
        • 1.2.4. Sketch
    • 2. Chapter Button & LED
      • 2.1. Project Button & LED
        • 2.1.1. Component List
        • 2.1.2. Component Knowledge
          • 2.1.2.1. Push button
        • 2.1.3. Circuit
        • 2.1.4. Sketch
          • 2.1.4.1. Sketch_ButtonAndLed
          • 2.1.4.2. Reference
      • 2.2. Project MINI table lamp
        • 2.2.1. Debounce for Push Button
        • 2.2.2. Sketch
          • 2.2.2.1. Sketch_TableLamp
    • 3. Chapter LED Bar
      • 3.1. Project Flowing Light
        • 3.1.1. Component List
        • 3.1.2. Component Knowledge
          • 3.1.2.1. LED bar
        • 3.1.3. Circuit
        • 3.1.4. Sketch
          • 3.1.4.1. Sketch_FlowingLight
    • 4. Chapter Analog & PWM
      • 4.1. Project Breathing LED
        • 4.1.1. Component List
        • 4.1.2. Related Knowledge
          • 4.1.2.1. Analog & Digital
          • 4.1.2.2. PWM
          • 4.1.2.3. Raspberry Pi Pico and PWM
        • 4.1.3. Circuit
        • 4.1.4. Sketch
          • 4.1.4.1. Sketch_BreathingLight
            • analogWrite()
      • 4.2. Project Meteor Flowing Light
        • 4.2.1. Component List
        • 4.2.2. Circuit
        • 4.2.3. Sketch
          • 4.2.3.1. Sketch_FlowingLight2
            • map()
    • 5. Chapter RGBLED
      • 5.1. Project Random Color Light
        • 5.1.1. Component List
        • 5.1.2. Related Knowledge
        • 5.1.3. Circuit
        • 5.1.4. Sketch
          • 5.1.4.1. Sketch_ColorfulLight
      • 5.2. Project Gradient Color Light
        • 5.2.1. Sketch
          • 5.2.1.1. Sketch_SoftColorfulLight
    • 6. Chapter Buzzer
      • 6.1. Project Doorbell
        • 6.1.1. Component List
        • 6.1.2. Component Knowledge
          • 6.1.2.1. Buzzer
          • 6.1.2.2. Transistor
        • 6.1.3. Circuit
        • 6.1.4. Sketch
          • 6.1.4.1. Sketch_Doorbell
      • 6.2. Project Alertor
        • 6.2.1. Component List
        • 6.2.2. Circuit
        • 6.2.3. Sketch
          • 6.2.3.1. Sketch_Alertor
    • 7. Chapter Serial Communication
      • 7.1. Project Serial Print
        • 7.1.1. Component List
        • 7.1.2. Related Knowledge
          • 7.1.2.1. Serial communication
          • 7.1.2.2. Serial port on Raspberry Pi Pico
        • 7.1.3. Circuit
        • 7.1.4. Sketch
          • 7.1.4.1. Sketch_SerialPrinter
          • 7.1.4.2. Reference
      • 7.2. Project Serial Read and Write
        • 7.2.1. Sketch
          • 7.2.1.1. Sketch_SerialRW
          • 7.2.1.2. Reference
    • 8. Chapter AD Converter
      • 8.1. Project Read the Voltage of Potentiometer
        • 8.1.1. Component List
        • 8.1.2. Related Knowledge
          • 8.1.2.1. ADC
          • 8.1.2.2. ADC ChannelsRaspberry Pi Pico
        • 8.1.3. Component Knowledge
          • 8.1.3.1. Potentiometer
          • 8.1.3.2. Rotary potentiometer
        • 8.1.4. Circuit
        • 8.1.5. Sketch
          • 8.1.5.1. Sketch_ADC
          • 8.1.5.2. Reference
    • 9. Chapter Potentiometer & LED
      • 9.1. Project Soft Light
        • 9.1.1. Component List
        • 9.1.2. Circuit
        • 9.1.3. Sketch
          • 9.1.3.1. Sketch_Softlight
    • 10. Chapter Photoresistor & LED
      • 10.1. Project Control LED through Photoresistor
        • 10.1.1. Component List
        • 10.1.2. Component Knowledge
          • 10.1.2.1. Photoresistor
        • 10.1.3. Circuit
        • 10.1.4. Sketch
          • 10.1.4.1. Sketch_Nightlamp
    • 11. Chapter Thermistor
      • 11.1. Project Thermometer
        • 11.1.1. Component List
        • 11.1.2. Component Knowledge
          • 11.1.2.1. Thermistor
        • 11.1.3. Circuit
        • 11.1.4. Sketch
          • 11.1.4.1. Sketch_Thermometer
    • 12. Chapter WiFi Working Modes (Only for Pico W)
      • 12.1. Project Station mode
        • 12.1.1. Component List
        • 12.1.2. Component knowledge
          • 12.1.2.1. Wireless
          • 12.1.2.2. Station mode
        • 12.1.3. Circuit
        • 12.1.4. Sketch
          • 12.1.4.1. Sketch_12.1_Station_mode
      • 12.2. Project AP mode
        • 12.2.1. Component List & Circuit
        • 12.2.2. Component knowledge
          • 12.2.2.1. AP mode
        • 12.2.3. Circuit
        • 12.2.4. Sketch
          • 12.2.4.1. Sketch_AP_mode
          • 12.2.4.2. Reference
      • 12.3. Project AP+Station mode
        • 12.3.1. Component List & Circuit
        • 12.3.2. Component knowledge
          • 12.3.2.1. AP+Station mode
        • 12.3.3. Circuit
        • 12.3.4. Sketch
          • 12.3.4.1. Sketch_AP_Station_mode
    • 13. Chapter TCP/IP (Only for Pico W)
      • 13.1. Project as Client
        • 13.1.1. Component List
        • 13.1.2. Component knowledge
          • 13.1.2.1. TCP connection
          • 13.1.2.2. Install Processing
          • 13.1.2.3. Use Server mode for communication
        • 13.1.3. Circuit
        • 13.1.4. Sketch
          • 13.1.4.1. Sketch_As_Client
          • 13.1.4.2. Reference
      • 13.2. Project as Server
        • 13.2.1. Component List
        • 13.2.2. Circuit
        • 13.2.3. Sketch
          • 13.2.3.1. Sketch_As_Server
          • 13.2.3.2. Reference
    • 14. Chapter Control LED with Web (Only for Pico W)
      • 14.1. Project Control the LED with Web
        • 14.1.1. Component List
        • 14.1.2. Component knowledge
          • 14.1.2.1. HTML
        • 14.1.3. Circuit
        • 14.1.4. Sketch
          • 14.1.4.1. Sketch_Control_the_LED_with_Web
    • 15. Chapter Bluetooth (Only for Pico W)
      • 15.1. Project Bluetooth Passthrough
        • 15.1.1. Component List
        • 15.1.2. Component knowledge
          • 15.1.2.1. Master mode
          • 15.1.2.2. Slave mode
        • 15.1.3. Circuit
        • 15.1.4. Sketch
          • 15.1.4.1. Sketch_Serial_BT
          • 15.1.4.2. Reference
      • 15.2. Project Bluetooth Low Energy Data Passthrough
        • 15.2.1. Component List
        • 15.2.2. Circuit
        • 15.2.3. Sketch
          • 15.2.3.1. Sketch_Serial_BT
          • 15.2.3.2. Serial Bluetooth
          • 15.2.3.3. LightBlue
      • 15.3. Project Bluetooth Control LED
        • 15.3.1. Component List
        • 15.3.2. Circuit
        • 15.3.3. Sketch
          • 15.3.3.1. Sketch_LEDControl_BT
          • 15.3.3.2. Reference
      • 15.4. Project Bluetooth Low Energy Control LED
        • 15.4.1. Component List
        • 15.4.2. Circuit
        • 15.4.3. Sketch
          • 15.4.3.1. Sketch_LEDControl_BLE
    • What’s Next?
  • Python language
    • Welcome
      • Getting Started
      • Get Support and Offer Input
      • Safety and Precautions
      • About Freenove
      • Copyright
    • Preface
      • Raspberry Pi Pico
        • UART, I2C, SPI Default Pin
          • UART
          • I2C
          • SPI
      • Raspberry Pi Pico W
        • UART, I2C, SPI Default Pin
          • UART
          • I2C
          • SPI
          • Wireless
      • Raspberry Pi Pico 2
        • UART, I2C, SPI Default Pin
          • UART
          • I2C
          • SPI
    • 0. Chapter Getting Ready (Important)
      • 0.1 Installing Thonny (Important)
        • Downloading Thonny
        • Installing on Windows
      • 0.2 Basic Configuration of Thonny
      • 0.3 Burning Micropython Firmware (Important)
        • Downloading Micropython Firmware
          • Option 1
          • Option 2
        • Burning a Micropython Firmware
      • 0.4 Thonny Connected to Raspberry Pi Pico
      • 0.5 Testing codes (Important)
        • Running Online
          • Operation
          • Exiting Running Online
        • Running Offline
          • Operation
          • Exiting Offline Running
      • 0.6 Thonny Common Operation
        • Uploading Code to Raspberry Pi Pico
        • Downloading Code to Computer
        • Deleting Files from your Computer Directory
        • Creating and Saving the code
      • 0.7 Paste the Sticker on the Breadboard
    • 1. Chapter 1 LED (Important)
      • 1.1. Project Blink
        • 1.1.1. Component List
          • 1.1.1.1. Power
        • 1.1.2. Code
          • 1.1.2.1. 01.1_Blink
          • 1.1.2.2. Uploading code to Raspberry Pi Pico
          • 1.1.2.3. How to import python files
          • 1.1.2.4. Reference
      • 1.2. Project Blink
        • 1.2.1. Component List
        • 1.2.2. Component List
        • 1.2.3. Component Knowledge
          • 1.2.3.1. LED
          • 1.2.3.2. Resistor
          • 1.2.3.3. Breadboard
          • 1.2.3.4. Power
        • 1.2.4. Circuit
        • 1.2.5. Code
          • 1.2.5.1. 01.2_Blink
          • 1.2.5.2. Uploading code to Raspberry Pi Pico
    • 2. Chapter Button & LED
      • 2.1. Project Button & LED
        • 2.1.1. Component List
        • 2.1.2. Component Knowledge
          • 2.1.2.1. Push button
        • 2.1.3. Circuit
        • 2.1.4. Code
          • 2.1.4.1. ButtonAndLed
      • 2.2. Project MINI table lamp
        • 2.2.1. Debounce for Push Button
        • 2.2.2. Code
          • 2.2.2.1. Tablelamp
    • 3. Chapter LED Bar
      • 3.1. Project Flowing Light
        • 3.1.1. Component List
        • 3.1.2. Component Knowledge
          • 3.1.2.1. LED bar
        • 3.1.3. Circuit
        • 3.1.4. Code
          • 3.1.4.1. FlowingLight
          • 3.1.4.2. Reference
            • for()
    • 4. Chapter Analog & PWM
      • 4.1. Project Breathing LED
        • 4.1.1. Component List
        • 4.1.2. Related Knowledge
          • 4.1.2.1. Analog & Digital
          • 4.1.2.2. PWM
          • 4.1.2.3. Raspberry Pi Pico and PWM
        • 4.1.3. Circuit
        • 4.1.4. Code
          • 4.1.4.1. BreatheLight
          • 4.1.4.2. Reference
      • 4.2. Project Meteor Flowing Light
        • 4.2.1. Component List
        • 4.2.2. Circuit
        • 4.2.3. Code
          • 4.2.3.1. 04.2_FlowingLight
      • 4.3. How to import a custom python module
        • 4.3.1. Code
    • 5. Chapter RGBLED
      • 5.1. Project Random Color Light
        • 5.1.1. Component List
        • 5.1.2. Related Knowledge
        • 5.1.3. Circuit
        • 5.1.4. Sketch
          • 5.1.4.1. RandomColorLight
          • 5.1.4.2. Reference
      • 5.2. Project Gradient Color Light
        • 5.2.1. Code
          • 5.2.1.1. 05.2_GradientColorLight
    • 6. Chapter Buzzer
      • 6.1. Project Doorbell
        • 6.1.1. Component List
        • 6.1.2. Component Knowledge
          • 6.1.2.1. Buzzer
          • 6.1.2.2. Transistor
        • 6.1.3. Circuit
        • 6.1.4. Code
          • 6.1.4.1. Doorbell
      • 6.2. Project Alertor
        • 6.2.1. Component List
        • 6.2.2. Circuit
        • 6.2.3. Code
          • 6.2.3.1. Alertor
    • 7. Chapter Serial Communication
      • 7.1. Project Serial Print
        • 7.1.1. Component List
        • 7.1.2. Related Knowledge
          • 7.1.2.1. Serial communication
          • 7.1.2.2. Serial port on Raspberry Pi Pico
        • 7.1.3. Circuit
        • 7.1.4. Code
          • 7.1.4.1. Serial_Print
      • 7.2. Project Serial Read and Write
        • 7.2.1. Component List
        • 7.2.2. Circuit
        • 7.2.3. Code
          • 7.2.3.1. Serial_Read_and_Write_UART1_to_UART0
    • 8. Chapter AD Converter
      • 8.1. Project Read the Voltage of Potentiometer
        • 8.1.1. Component List
        • 8.1.2. Related Knowledge
          • 8.1.2.1. ADC
          • 8.1.2.2. ADC ChannelsRaspberry Pi Pico
        • 8.1.3. Component Knowledge
          • 8.1.3.1. Potentiometer
          • 8.1.3.2. Rotary potentiometer
        • 8.1.4. Circuit
        • 8.1.5. Code
          • 8.1.5.1. 08.1_AnalogRead
          • 8.1.5.2. Reference
    • 9. Chapter Potentiometer & LED
      • 9.1. Project Soft Light
        • 9.1.1. Component List
        • 9.1.2. Circuit
        • 9.1.3. Code
          • 9.1.3.1. Soft_LED
      • 9.2. Project Soft Colorful Light
        • 9.2.1. Component List
        • 9.2.2. Circuit
        • 9.2.3. Code
          • 9.2.3.1. Soft_Colorful_Light
      • 9.3. Project Soft Rainbow Light
        • 9.3.1. Component List
        • 9.3.2. Circuit
        • 9.3.3. Code
          • 9.3.3.1. Soft_Rainbow_Light
    • 10. Chapter Photoresistor & LED
      • 10.1. Project Control LED through Photoresistor
        • 10.1.1. Component List
        • 10.1.2. Component Knowledge
          • 10.1.2.1. Photoresistor
        • 10.1.3. Circuit
        • 10.1.4. Code
          • 10.1.4.1. Photoresistor
    • 11. Chapter Thermistor
      • 11.1. Project Thermometer
        • 11.1.1. Component List
        • 11.1.2. Component Knowledge
          • 11.1.2.1. Thermistor
        • 11.1.3. Circuit
        • 11.1.4. Code
          • 11.1.4.1. Thermometer
    • 12. Chapter WiFi Working Modes (Only for Pico W)
      • 12.1. Project Station mode
        • 12.1.1. Component List
        • 12.1.2. Component knowledge
          • 12.1.2.1. Wireless
          • 12.1.2.2. Station mode
        • 12.1.3. Circuit
        • 12.1.4. Code
          • 12.1.4.1. Station_mode
          • 12.1.4.2. Reference
      • 12.2. Project AP mode
        • 12.2.1. Component List & Circuit
        • 12.2.2. Component knowledge
          • 12.2.2.1. AP mode
        • 12.2.3. Circuit
        • 12.2.4. Code
          • 12.2.4.1. AP_mode
          • 12.2.4.2. Reference
      • 12.3. Project AP+Station mode
        • 12.3.1. Component List & Circuit
        • 12.3.2. Component knowledge
          • 12.3.2.1. AP+Station mode
        • 12.3.3. Circuit
        • 12.3.4. Code
          • 12.3.4.1. 12.3_AP+STA_mode
    • 13. Chapter TCP/IP (Only for Pico W)
      • 13.1. Project as Client
        • 13.1.1. Component List
        • 13.1.2. Component knowledge
          • 13.1.2.1. TCP connection
          • 13.1.2.2. Install Processing
          • 13.1.2.3. Use Server mode for communication
        • 13.1.3. Circuit
        • 13.1.4. Code
          • 13.1.4.1. TCP_as_Client
          • 13.1.4.2. Reference
      • 13.2. Project as Server
        • 13.2.1. Component List
        • 13.2.2. Circuit
        • 13.2.3. Code
      • 13.3. Project as Server
        • 13.3.1. Component List
        • 13.3.2. Circuit
        • 13.3.3. Sketch
          • 13.3.3.1. 13.2_TCP_as_Server
    • 14. Chapter Control LED with Web (Only for Pico W)
      • 14.1. Project Control the LED with Web
        • 14.1.1. Component List
        • 14.1.2. Component knowledge
          • 14.1.2.1. HTML
        • 14.1.3. Circuit
        • 14.1.4. Code
          • 14.1.4.1. Control_LED_through_Web
    • 15. Chapter Bluetooth (Only for Pico W)
      • 15.1. Project Bluetooth Passthrough
        • 15.1.1. Component List
        • 15.1.2. Component knowledge
          • 15.1.2.1. Master mode
          • 15.1.2.2. Slave mode
        • 15.1.3. Circuit
        • 15.1.4. Code
          • 15.1.4.1. 15.1_BLE
      • 15.2. Project Bluetooth Control LED
        • 15.2.1. Component List
      • 15.3. Project Bluetooth Control LED
        • 15.3.1. Component List
        • 15.3.2. Circuit
        • 15.3.3. Code
          • 15.3.3.1. BLE_LED
    • What’s Next?
  • Product Certification
fnk0064-docs
  • Search