Raspberry Pi Pico - Review and Getting Started
Вставка
- Опубліковано 16 лип 2024
- The Raspberry Pi Foundation seems to be searching for a new vision and so has decided to get into the crowded microcontroller market with the Raspberry Pi Pico. Based on a dual-core Cortex-M0+ microcontroller, it runs MicroPython or C/C++ and is designed for makers, enthusiasts, and hobbyists. Here is my review and getting start guide.
Useful Raspberry Pi Pico links:
Thonny - thonny.org/
Getting Started - www.raspberrypi.org/documenta...
SD1306 driver - github.com/raspberrypi/microp...
Introduction to Android app development: www.dgitacademy.com
Let Me Explain T-shirt: teespring.com/gary-explains-l...
Twitter: / garyexplains
Instagram: / garyexplains
#garyexplains
I find it odd that a lot of UA-cam users now rely on recommendations instead of subscriptions. That was never the point of recommendations yet I see people complaining about it all the time.
Great video as always :)
Well, since subscriptions are kinda broken...
I've been seeing claims of sub boxes being broken for many years, but it's never clear whether it's a momentary bug, the person confusing the notification system for subs (I've spoken to people who didn't know the difference) or an actual longstanding widespread issue.
UA-cam did confirm some years ago that the notification system is "broken" (not the word they used) by design in that it doesn't guarantee you'll get a notification, but nothing about subscriptions.
Sample size of one and all that, but I've never had a video not appear in my sub box, at least not unless there was a temporary problem with UA-cam. Every time I think that's the case, I've just missed it because I'm subscribed to a lot of channels. It's possible there's an issue, but I certainly have never seen good evidence of it
I'm subscribed to over 400 channels, I believe most of old users are in a similar situation. It's just in UA-cam best interests and mine to kinda ignore my subscription list and guess what I wanna watch. If i got a notification when a channel uploaded something I would just get spammed from UA-cam and end up turning the notification off
You just brought back my passion for programming with this little cutie. Gotta get me one (or two) of those. Thanx, Gary 👍
Go for it!
@@GaryExplains I think I'll blow the budget and go for three pieces - the price for coming back to C++ for the first time in 20 years ;-)
I've attempted soldering things exactly 4 times in my life (49yrs) so far. Four blisters. Nevertheless ... my engineer son bought 4 of these little do-hickeys and I've got one to play with. Going to attempt a garden protection device to dissuade wallabies and possums from munching on our yard. So far, I can flash the LED. $0.02
That's an important step. Maybe the most important one... I was you 2 years ago on arduino;
Thank you very much for this starter video. I was stubborn and wanted to use Visual Studio Code and ran into a number of issues. After I switch to Thony everything went swimmingly.
Your teaching style is very good and easy to follow. Pico's are still as rare as hen's teeth but I managed to get one. Keep broadcasting!!
Great video Gary, thanks!
Thorough, interesting, and very useful. Now I understand what this little device is all about.
Keep up the excellent work!
Well this is interesting , can you do a performance comparison between the board running python and it running C ? You might even use the same prime number method.
Thank you for making this video and explaining in crisp way. Your efforts are very much appreciated.
Glad it was helpful!
That's a very wholesome video! Congratulations!
Big help ! Can't wait to try out the OLED example.
Excellent video. Thanks Gary!
Awesome content, thanks Garry!
A great video, as ever. Have mine hooked up to my Pi400 and they make a great combination. May not be the cheapest or most feature-rich microcontroller on the planet, but it is easy to use and brilliant for home or school education purposes, which is the Pi Foundation's main target market and objective.
But with esp32 u get WiFi/Bluetooth :) & if u want to use microphython u can also flash micropython on it ;)
@@johndripper adafruit is making a board soon, esp32-mini and rp2040
@@jyvben1520 great
@@johndripper True. but it doesn't have a dual core? and that is why they make those BT/wifi modules to hook to these types of things. I'd like to see a speed test though, done with eps32 vs Pico .. curious on which is faster?
@@compubyte2010 It is dual core
Nice video, It got me to try out Thonny
Have fun
I`ve got about 10 arduino`s running the house. Alarms central heating etc. The arduino mega finally gave up a few years ago after I added too much stuff onto it. I got a touch screen and wanted to use that instead with a pi. Then the screen broke lol. So now I`m on my 4th pico because I thought I had broken them. But one of your video`s got me up to speed and they all work now. Thank you. Now to convert the house to pico. :)
Okay, been outside the raspberry pie. Loop for a few years. Really like the idea of having a simple embedded control of board. With most of the GPIO functionality and some added to ADCs now all done by python will be using this in one of my projects ASAP.
Gary: "It cant run Linux"
uCLinux: "Hold my beer"
Nice video!! Thank you!!
Hi Gary, great video! Very helpful for getting started with the Pico. Do you have any experience on how to use an RTC module with the Pico, like the DS3231?
Had trouble with RPi Pico run from Arduino IDE using C++. Ran fine when USB connected to laptop but would not run from ext power or battery. Turns out, in this scenario, RPi Pico hangs if there’s an attempt to do serial output when USB unplugged. So - added two resistors to A1 input, 20k to Gnd, and 10k to VBUS. Sense this input at top of setup() and only do serial IO if high (this is 5V in from USB). Resistor keep the 5V to 3.3V. Works fine now. I get serial output when USB plugged in, and RPi Pico runs fine from just the power supply or battery.
Interesting. I thought that only happened if you had "while (! Serial);" or similar in your code.
Great video, thank you! 😁
Glad you liked it!
Good one, ordered picos
4:35 swd debug using a rpi, bookmarked/draft mail for later !
*GARY!!!*
*Good evening Professor!*
*Good evening fellow classmates!*
Stay safe out there everyone!
MARK!
Fascinating.
I haven't seen you in a while, Mr. Sims. I love your content! I need to learn some Python.
I know, a whole 6 days without me posting a video!!! 😂
@@GaryExplains Yeah, it kills me. LOL Thanks for being so awesome!
good videos gary
Very interesting informative video
I'd already have ordered the board, if it was not for the lack of radios for at least wifi. While the PIO feature looks cool, for now ESP32 (or even ESP8266) works better for me. Of course, there is also the similar Pyboard D-series, including wifi, but that gets pretty expensive in comparison.
How does the dual core M0+ core compare to other high end microcontrollers using M4F core or M7 core, or the ESP32? ESP32 is the same price and has Bluetooth and wifi. And unlike the pico it can be sourced and used in larger scale production.
I find the Itsy Bitsy M4 and the micro:bit v2 (M4) more attractive boards. The whole ecosystem around these is so much more mature, and everything just works whether you code in C++, Python, Javascript or visual blocks. Even though the micro:bit is a little slower, you get great sensors and radio's (BLE 5!) instead, and thanks to true USB2 it is fast to work with, your code flies onto the micro:bit. The Itsy Bitsy can surpass the Pi Pico in speed in many areas, not all though. A Pi Pico feels a bit like an Apple 1 DIY kit in a wooden box. No pin numbers, no headers, no status LED's, no documentation, too big, too cheap (yes TOO cheap), hard baked not-so-good bootloader. Definitely NOT for the classroom. Teensy 4.1 with M7 is a complete other league, toasting the Pico and the ESP32 in one go, almost as fast as a Raspberry Pi 1. ESP32 is good for final products, but never for prototyping, it is too slow for that.
I have used Python on the Pico for my hobbyist projects, it works pretty well. Will you consider introducing the Nim programming language in the not too distant future?
Nice video! Can you also do an explanation on the PIO thingies? They sounded really cool but no idea how to program those
basically from what I heard from some people is that its hardware that can adapt do any digital communications you program it to do (assuming the pico is fast enough for it). You could use it for more i2c or uart, or you could use it for other stuff
at least that was my understanding, I would not be supprised if i am wrong
I agree, what are those PIOs? They talk so much about this but how to actually use it ?
Good look to anyone trying to find one..I've been looking since they came out...best lead time was march 17....I want 10 of them. A micro controller doesn't need wifi or an os.
I had no trouble getting mine and I just checked and they are still in stock. I guess it depends where you live.
@@GaryExplains Im in the US and they are on back order everywhere here..except there are a few places setting them for 12 dollars each.. 10 at 4 dollars each is good but not 12 dollars. I guess i'm going to be using the Arduino Nano another month or 2.
Also when you save the .py (python) files on the Pico where are they stored. What is the path
From a sea of fog to two LEDs flashing. That's all you need to get started. Thank you very much.
well made
Hey...I completed all the setup and downloading of the files required for the pico...after trying few different codes I was getting a error as module not found for 'machine' and 'gpiozero'.Tried installing it from the tool section in Thonny app and also from my windows terminal and also manually imported the library files in the /lib folder of the pico.Can anyone please help me in solving this issue???😢
How to put extra library into pico
This microcontroller is a good decision. SBC are a different market which was hiding the goal of the raspberry pi.
Right. A lot of electronics projects on raspberry pi are microcontroller-like. It’s almost as though the pi is just a convenient interface for microcontroller programming.
Using an actual microcontroller is the next logical step.
I know some simple programming, do you have to be a programmer to learn this? Any suggestions would be helpful.
I am giving you a thumbs up primarily because you spell your first name the same as I spell mine ;-)
The RPip is nice and all, but here I am wondering... why does the tick function need a parameter ? It doesn't seem to be using it at all....
We got couple of boards !
First: I know Windows 7 is no longer supported. Second: I do have multiple linux machines. BUT: I want to develop on an existing Win7 laptop. The driver install doesn't seem to work on Windows 7. Anyone got a working win7 setup?
How are you powering the pico in your video? is it via that usb connection?
Yes
What happened to the link of the github? It no longer exist....
I am using a MacBook Pro (M1 processor). Following your steps didn't work right away for me. First problem, booting the PICO into USB storage mode (Boot Select button) - nothing happened, repeatedly. I tried a few things with other devices to make sure the cables, etc were all good. They were. Rebooted the MacBook, first time in 4 months and bingo, the RP1-RP2 drive appeared on the desktop. Great. I tried installing the micro python off the Rpi website using download-drag-then-drop as you demonstrated - didn't work. I got an error from MacOS. Tried it via the Thonny method and that seemed to work, but MacOS warned me to eject the "hard drive" before rebooting. The simple Flash-the-onboard-LED program doesn't work - and that's when I decided to document my experience here. The program crashes wth a traceback on Thonny: Traceback (blah blah)/n File "" line 1/nSyntaxError: invalid syntax. Interesting error, stdin is a C/Unix/Linux file, so it seems like the micro python image has some problems. /sigh. Will keep digging.
There was a bug in macos that means the drive isn't seen. You should check you are running the latest version.
@@GaryExplains Thank you for the tip. Actually it works consistently since the reboot, so that may clear the buggy condition. Actually, I've been a PC user for decades and only switched to Mac in August. Cheers!
@@GaryExplains I would be grateful if you could say whether the .uf2 file remains in the RP1-RP2 directory forever or is it deleted after the PICO has done processing it and reboots.
hi, I am dragging and dropping uf2 file onto rp2 drive, it dispears but I can't find micro python from drop down in Thornny in Interpretor drop down in options. can you help?
I expect you've solved this now. Try MMBASIC and connect using Putty. In Linux you can also install putty but run it with sudo putty. You may not have permission to use the serial port unless you start the program with sudo.
I've never been able to find any Raspberry Pi shipped for anywhere near their advertised price. Cheapest I could ever find a Pi Zero was about $30 shipped. At least Pico's are not 6X advertised price. I guess $8 for a $4 board is a good price in comparison.
Unless you need a tiny Linux PC then the Pico is what you need for electronics projects.
I'd love to see how you program it in C.
I made a video about that as well ua-cam.com/video/NCaL6tXAF0c/v-deo.html
Go Pico Yeah Yeah Go Pico Oh Go Pico Yeah Yeah Go Pico
Hi Gary! Not actually related to this video, but I've heard that Linux is not suited for real-time control systems. F.ex flight controllers for drones and autonomous aircrafts I've heard that MCU's such as Arduino is much more reliable than a Raspberry Pi f.ex. Even if the processing power is 100x better on a Pi, it is not considered a good option for real-time processing. Can you please explain?
The operating system must be capable of real-time responses, or it is not suited for hard real-time applications (like in cars or airplains), where failure to perform a task before the set deadline will result in grave issues. Bare metal programming is the only option in such a case, but you will need to do pretty much everything software-wise yourself, while knowing how to keep up with the requirements for a real-time sytem.
No Windows here Gary, Linux only for the last 10 years 8-)
Can you use it for fso gary
fso? Fabryka Samochodów Osobowych, a Polish automotive company?
@@GaryExplains fso free space optical communication systeme can you use pico for it if you can i really could use your help thanks
I have zero experience or knowledge about FSO, sorry.
@@GaryExplains thank you my friend
when the rassbery pie is from an old school shooter game on newgrounds
Every one is first so I'm second?eh
would you like a pico breakout board for use in your videos? I just had 10 made. contact me for details.
Can you give me details, I am interested
@@suziepiper6812 Its better if you email me zeroohm@cmetech.com then I can send you schematic and pics of it. I tried to put a lot of features on it.
I came pretty soon I guess..
First.
A friendly comment from an old bench tech. Most users haven't got a clue on what going on. That fact is something to consider when you do one of your micro training videos. If you keep it simple and go over the basics that's what people are looking for in a "Let's get started video" In this video, you have people confused by jumping ahead and started typing up code that's too complex for new users to understand.
True, I hear what you are saying, but at the same time I have dozens of getting started videos here on this channel and I ain't going to keep repeating myself. Don't fall into the trap of thinking that this is my only video. Also, if you look at my audience in general they are a little more sophisticated than newbies.
@@GaryExplains / I agree on that point but at the same time new users are part of your subscriber base. The title of this video was a bit misleading for some people. Your channel is offering a lot of good content for more experienced users as you have stated but how do you keep new users happy. Anyway keep up with the good work 🧐
@@NewAgeDIY Indeed. Unfortunately it is never possible to know what knowledge a viewer already has. So I rely on my whole body of works as a resource to bring everyone to a more advanced level.
Having said that maybe I should consider a "Pico for the absolute beginner" type video. 👍
@@GaryExplains / now that could be the ticket!
but can it run doom
It can:
ua-cam.com/video/eDVazQVycP4/v-deo.html
Pico is poco, ❤️
Not really. It's one of the worst value mcu.
@Hassan Zahin that is an interesting comment. Why is it "worst value mcu"? At $4 I can't see how you can call it "worst value".
8 minutes ago
Pity about noisy neighbours music
Sorry but 200 MHz is not the highest you can get, there is esp32 at 240Mhz, stm32h7 series up to 550Mhz, teensy 4 at 600Mhz
True, I guess I generalized too much. Sorry about that.
Copied the exact same code with the exact same display, not working :(
It's Pi Jim but not as we know it.
Can someone forward me the code to determine the spread of prime numbers in the space of reel numbers please?
There's a million dollar cashout i'd like to comlect from the clay institute, we'll split it.
Btw this isn't a nigerian prince scam, its just a classic make you do all the work and comlect the reward scam, so no worries
where's the orange haired kid with the gun.
jk
me 613th
The not so humble micro-controller eco system may end up at the only place that MS won't get it's filthy grabbing hooks into. See this for how the RPi Foundation sold out to big money: ua-cam.com/video/TuYPIohzo2Y/v-deo.html
Great video Gary - thanks for sharing.
I am glad you like my video, thanks. I watched the first couple of minutes of that video you linked, and sorry, it is a load of nonsense. The issues he is talking about is true for all and any software that isn't build from source of the host machine. Sorry, but no.
@@GaryExplains Hi Gary, thanks for replying. I think that you may have misunderstood. To explain: A few days ago I performed a fresh install of Pi OS - obtained from the Rpi official site - onto a Rpi 3b. A day or so after that, and without installing anything other than a Unifi 6.0.45.0 Controller (using standard apt install procedures), I came across the video that I linked in my previous comment. Naturally worried, I found that my Rpi 3b had the MS repository and trusted key present - which I have since removed. I emailed the Rpi developer who’s name appears in the Rpi script that is used during the Pi OS install process asking for an explanation. Coincidentally he has just replied:
Hi ,
Thanks for your email. I haven't watched the video, but I have of course been following the general response and concerns people have raised.
A somewhat official response can be found here:
www.raspberrypi.org/forums/viewtopic.php?f=63&t=302590&p=1813842#p1813827
Other than that, we're waiting to hear back from a few people to decide how to address remaining concerns.
We are targeting beginners and prioritising ease of use, which means we sometimes make decisions which can be unpopular with other users. I would never insist that anybody use Raspberry Pi OS if it does not suit them.
Kind regards,
Amongst other things, the official Raspberry Pi org. response, linked in the developer’s reply above, states that “we have made the decision to trust Microsoft”. That may sit well with some; me not so much.
The aim of the Raspberry Pi foundation is to make it as easy and as affordable as possible to educate people from all around the world, adding the microsoft repository to the OS makes it easier for people who wish to use the Pi to develop for the Pico.
As for selling out, companies like microsoft and google and even red hat, who got flak for changing centos into centos stream contribute far more to the open source world by funding various open source projects with cash or even providing code than all the people who complain about trivial little things such as having a microsoft repo in the raspberry pi os.
There is nothing stopping you from compiling your own spin of linux from source and only adding code that you wish to be in there, that is the beauty of using linux and open source software, just google Linux from scratch.
EDIT:
P.S. Thanks for another great video Gary.
in japanese... id call that "boku no pico"... as in "my pico"...😂
oh no...
At 5:30 *WRONG!* If people are smart, (and most AREN'T), They will be using it with Linux, NOT windoz !!
Wow, you use Linux, you must be so smart 🤷♂️🤦♂️
I think most people here would be quite happy using the Pico with both Windows and Linux. I am using MMBASIC from Putty in Linux. That means one Microsoft type language, one Windows native program on Linux.
@@wayland7150 - I'll except that! Where did you get the MMBASIC from?
Should it be pronounced Pie co instead of Pee co
in the uk it’s /ˈpiː.kəʊ/ and in the us /ˈpi.koʊ/. it’s derived from the italian word piccolo (/ˈpik.ko.lo/) which means small
@@cool-person1161 its derived from greek letter pico.
@@lulube11e111 There’s no letter pico in the greek alphabet
esp8266, esp32 or even bluepills are much better than the pico.
OK, WiFi support is nice on some of the ESP modules, but besides that, why are you saying the others are "much better"???
Do these also support micro python as well, or is this the selling point of the RPF, the simplicity of this language in comparison to the c++ based one?
Yes, they support MicroPython. MicroPython is available for Espressif ESP-based boards, both ESP8266 and ESP32.
@@GaryExplains Spec, price & benchmark wise
@O. M. Well, you don't need to bit bang IO ports if you have enough peripherals. Btw, you can get esp8266 module for $1. If you ditch esp8266 for less peripherals (except wifi), even than the others are under $2.50.
another great product if I want I have to pay at least 10 times the prices :'(
If i have one i will name it Boku no Pico so nobody would claim it when i lost it
WTFs this micropython business? why wouldn't I just stick to C, good old C.
You are free to use C if you want to, no one is stopping you.
@@GaryExplains me being a Luddite aside; seriously what’s the advantage? Seems like a new fashionable language every year
C vs Python is a big topic and I can't do it justice here in the comments. It certainly isn't "a new fashionable language", it has been around since the 80s. In short Python is interpreted rather than compiled. It is easy to learn. Python code is much more readable than C, and therefore more maintainable. It is very popular, well supported, and has a huge number of frameworks. It is open source. It runs on just about everything (as the Pico demonstrates). IT is also the lingua franca for Machine Learning and Data Science. Downsides, it isn't compiled so not good for writing OSes or drivers or other very low stuff. It isn't compiled so ultimately C will be faster in many situations. Here are a couple of articles you might find interesting: medium.com/@mindfiresolutions.usa/python-7-important-reasons-why-you-should-use-python-5801a98a0d0b and www.upgrad.com/blog/reasons-why-python-popular-with-developers
@@GaryExplains a very good and succinct explanation, I didn’t realise it was that old. I’ve heard there was significance to whitespace in it, so now that makes sense....but I still think people choosing python is yet more evidence of the disgenic fertility and collapse of western civilisation 😜😜
P.s my original comment was underlined by the fact that every single video I saw on the pico was people using python and not one person ran a programme in C 😒
Why are you quoting prices in Dollars? The Pi is British and from your accent, you are British so it would be a reasonable assumption that you would quote prices in Pounds. Are you saying that your British audience are clever enough to work out what the conversion is, but the reverse is not the case?
USD is the universal currency for quoting prices. Even the Raspberry Pi Foundation quoted dollars for the launch: "Meet Raspberry Silicon: Raspberry Pi Pico now on sale at $4" www.raspberrypi.org/blog/raspberry-pi-silicon-pico-now-on-sale/
Give it a rest, Syd. Find something else to gripe about.
sd1306.py link page is *404*
@@PadreAG - Thanks!