Talk to Your Pico Over Serial | Raspberry Pi Pico UART Tutorial
In this video, we dive deep into how to use the serial port on the RP2040 Raspberry Pi Pico. Learn how to use the UART0 port on the Raspberry Pi Pico! Output data and parse user input to make your Pico projects more powerful. By being able to communicate with your Pi Pico, you are able to better debug your programs, or just make them generally more useful.
Buy the RP2040:
Code for this video is posted at
Subscribe for more videos like this! Thanks for watching!
===
i’ll be showing you how to write code to use serial input and output on the raspberry pi pico by the end of this video you’ll be able to write a program like this that lets you see the output from your pico as well as send it commands over serial to reset it enable and disable pins and more getting readable output from your code is an extremely important part of debugging without an idea of what state your program is in you might as well be trying to read the mind of your microcontroller which can be frustrating instead to communicate with the pico we’re going to use an ftdi rs232 cable like this one rs-232 is a physical layer protocol responsible for carrying the uart protocol or universal asynchronous receiving transmit we’re going to hook up our ftdi cable to the uart zero bus on our pico uart0 is the default bus used for standard input and output or standard io when we write code calls to functions like printf scanf etc use this bus the way we’re going to wire our ftdi cable to the pico is as follows the orange cable or host receive is going to go to pin 2 the yellow cable or host transmit is going to go to pin 1 and then finally the black cable for ground will go to pin 3. having a common ground between devices is extremely important without it it’s likely that your devices won’t be able to understand what the other one is saying so it’s important to not skip this step here you can see i have my pico wire the same way the ftdi cable is plugged into the uart zero bus for serial communications and the micro usb cable is plugged in so that i can program the device on my linux workstation when i plug in the ftdi usb cable it populates as dev tty usb0 to communicate with it we need to use a program able to open serial devices i use minicom to install it type sudo apt install minicom once it’s installed run sudo minicom capital d slash dev tty usb0 once inside minicom need to press control plus a then o to go to the options menu select serial port setup then press f and this disables hardware flow control so you can type to the pico alright now that we have the serial port hooked up let’s write some code by the way i’ll be posting all this code onto the channel’s github check the link in the description for that also i noticed that 90 of my viewers are not subscribed if you’re not subscribed right now do me a favor hit that sub button i’d really appreciate it step one we need to confirm that we can actually get output from the device remember like i said all standard output and input goes to the uart terminal we have hooked up so we can literally just type printf in our code and we in theory should get output to the terminal let’s try that real quick so first we need to
===
Теги: raspberry pi pico,raspberry pico uart,raspberry pi pico programming,raspberry pi,uart tutorial,rs232 tutorial,embedded programming tutorial
1 view
2864
1138
7 months ago 00:53:10 1
Александр Шепс — Битва Сильнейших | Предсказания Ванги | Сглазы и порча | Шарлатаны в интернете
7 months ago 01:21:44 1
The Making of Pentiment - Noclip Documentary
7 months ago 00:02:41 1
Royal Republic - Ain’t Got Time (Official Video)
7 months ago 00:18:15 1
РЕАКЦИЯ ЗАПАДНОГО БЛОГЕРА НА ТО, КАК РОССИЙСКИЙ ПОЛИТИК ПОГОВОРИЛ С ЗАПАДНЫМИ СМИ.
7 months ago 00:19:45 1
Please, never do this with your D&D backstory
7 months ago 00:00:49 1
UK Has The Best Geography 🔥🇬🇧 #shorts #uk #geography #history #maps #facts #knowledge
7 months ago 00:14:25 1
Sarah Silverman on Her Dad’s Final Days, Working with Bradley Cooper & Writing New Jokes
7 months ago 00:00:40 1
Vladimir Putin Talks War With NATO
7 months ago 00:04:27 1
Abba - Eagle
7 months ago 01:25:10 1
2024 Full Walking Tour of BORACAY Island! The Philippines’ BEST White Beach | Station 1 to 3
7 months ago 00:16:45 1
Chandler Riggs (Carl Grimes) reacts to BLR’s The Walking (And Talking) Dead. (And Carl Poppa)
7 months ago 00:02:34 1
Loren Gray - Cake
7 months ago 00:07:05 1
The Itch – Ursula
7 months ago 00:03:09 1
지민(JIMIN) - WALKING TALKING
7 months ago 00:25:33 1
Мастер-класс Весенний мини-альбом | Spring mini-album
7 months ago 00:01:33 1
John Galliano on Alexander McQueen | Charlie Rose
7 months ago 00:10:07 1
’STOP F***** FIGHTERS ABOUT’ - EDDIE HEARN GOES IN ON BEN SHALOM, JARON ENNIS SIGNING & JOSHUA/FURY
7 months ago 00:05:33 1
Sarah Meets Lady Liberty | I Love You, America on Hulu
7 months ago 03:34:11 1
Undeclared war. America is under attack
7 months ago 00:30:27 1
John Galliano at the Vogue Festival | Vogue Festival 2015 | British Vogue
7 months ago 00:50:03 1
Why this American moved to Russia?
7 months ago 00:02:13 1
WIB3X - Talkin All That Talk
7 months ago 00:02:53 1
WWE Vengeance 2007 - Chris Benoit chants/commentary