Useful, thanks. I have done a few microcontroller projects, mostly using Arduino IDE and proceeding somewhat blindly by just copying existing code. This helps.
not sure if the software has changed over time but could you explain what you mean when you say to install cmake? anytime I try to put in "sudo snap install cmake" my chromebook just tells me "sudo: snap: command not found" (6:16 in the video)
You need to install cmake. Snap is the way he does that. There are others. For example I typed this command into my terminal(Msys2): pacman -S mingw-w64-x86_64-cmake
Ah that's because you don't have the `snap` installed. If `cmake` is somewhere in your package repositories. With sudo priviledge, run the command for installing `cmake` using your GNU/Linux distro's package manager. For example `apt install cmake` (on Debian GNU/Linux and derivatives) or `pacman -S cmake` (for arch btw and derivatives).
Great tutorial, clear and professional. Have you done anything with the little OLED displays SSD1306 - I've got a 128x32 and a 128x64 but the few examples I can find for the Pico are all C++ and I would really like to stick to C if possible.
I got to the 7:32 mark, the make moment, and the first line looks like in the video, but then after that about 200 errors. The first line says Assembler messages, then next line S89: Error unknown pseudo-op: '.syntax', and then about 199 more of the same. Any ideas? Thanks
Tried again from scratch this time on a newly fresh install of a raspberry pi 4. This time i got only about 70 errors. All goes fine until 93% progress, then it says pico_standard_link/new_delete.cpp.obj and then follow 70 errors of stuff not defined.
I followed your youtube. I get an error "fatal error # include cstdlib no such file or directory" I have tried using the raspberry pi sdk instructions to run blink and get the same error. Where should I look for this file.
distro does not matter. he is using ubuntu. it might look different because he is not using any "traditional" desktop environments. its all the same under the hood.
I have gone through this over and over what a nightmare. In the end the make fails. I deleted everything several time and went through again. everything works up until make. Then I get a whole bunch of errors when it hits elf2uf2
@UNOSEEMEk yes, I did but I can't remember what it was. The process for using C or C++ is a joke or at least was 9 months ago. I gave up and started using circuit python and micro python with thonny. It is much easier to get your code built and running on them with that.
My CMakeList.txt looks nothing like yours when I downloaded the examples. Was this completely re-written by you? I am new to Cmake. Been using Arduino and venturing into Raspberry Pi Pico
Do you know of a good NRF2401 C ONLY driver and example for the Pico? I have seen C++ versions but really look for a pure C one with a good send/recv example.
it would be nice if you made this video few minutes longer and explain how you connected into the Raspberry Pico and how you connected Pico to the web etc. Otherwise great video.
pico cant connect to the web.What he didnt makeclear was that he was running the commands from either a linux pc or a rasberry pi4 etc.However i did manage to blink an LED from watching this so i think he did ok.
Hi, I'm curious. I really want to know how your CMakeLists.txt is much different from the one in the git repository. How did you came about to write this ?? Anyways, the one in the git repository didn't work for me but yours worked perfectly and i made no modifications to my blink.c I have actually looked up in the Raspberry Pi Pico C/C++ SDK pdf and didn't find any info on how you set your CMakeLists.txt to be the way it is. Eventually, i will be writing my own project and i will need to write my own CMakeLists.txt to suit my codes. Thanks a lot for your tutorial. It's my first time getting into c/c++ baremetal armeabi.. gcc stuff and i wouldn't have been able to get this going without this tutorial
Some criticism: 1. Where's the C++ ? This is pure C. 2. Why instruct cmake (CMakeLists.txt) that your project uses C++ and ASM when in fact it only uses C? You don't need to set the C++ standard either if you don't use C. 3. Type safety! Why define GPIO_ON/GPIO_OFF as 1/0 instead of true/false? Match the API signature. 4. Let me post a C++ modification that also gets rid of using the preprocessor for the defines: #include namespace { //anonymous namespace, makes variables local to this translation unit. Same as defining them as static. constexpr bool GPIO_ON = true; constexpr bool GPIO_OFF = false; constexpr unsigned int LED_PIN = 25; } int main() { //blah }
I am more excited about a blinking light than I probably should be, thanks!
way more haha
this tutorial saved the one of the two brain cells i have left
Cool a very nice and concise guide to getting started with cmake and bcc. Appreciate your hard work.
Glad you liked it
@@LowLevelTV How can we set this up for Mac M1? Any Advice?
@@XStance7 you can start with looking up for the equivalent brew packages
From where do you get this : set(PICO_EXAMPLES_PATH ${PROJECT_SOURCE_DIR}) ?
and you did not mention installing arm-none-eabi-gcc-cs-c++ ;)
Useful, thanks. I have done a few microcontroller projects, mostly using Arduino IDE and proceeding somewhat blindly by just copying existing code. This helps.
good video relatively easy to follow and understand
not sure if the software has changed over time but could you explain what you mean when you say to install cmake? anytime I try to put in "sudo snap install cmake" my chromebook just tells me "sudo: snap: command not found" (6:16 in the video)
You need to install cmake. Snap is the way he does that. There are others. For example I typed this command into my terminal(Msys2): pacman -S mingw-w64-x86_64-cmake
Ah that's because you don't have the `snap` installed.
If `cmake` is somewhere in your package repositories. With sudo priviledge, run the command for installing `cmake` using your GNU/Linux distro's package manager. For example `apt install cmake` (on Debian GNU/Linux and derivatives) or `pacman -S cmake` (for arch btw and derivatives).
Very well explained and pertinent
Thank you, it was very explained!
Great tutorial, clear and professional. Have you done anything with the little OLED displays SSD1306 - I've got a 128x32 and a 128x64 but the few examples I can find for the Pico are all C++ and I would really like to stick to C if possible.
I haven't, but I think theyre controlled over I2C. I plan to do SPI and I2C tutorials soon. Thanks for watching!
Thank you very much!
You're welcome!
I got to the 7:32 mark, the make moment, and the first line looks like in the video, but then after that about 200 errors. The first line says Assembler messages, then next line S89: Error unknown pseudo-op: '.syntax', and then about 199 more of the same. Any ideas? Thanks
Tried again from scratch this time on a newly fresh install of a raspberry pi 4. This time i got only about 70 errors. All goes fine until 93% progress, then it says pico_standard_link/new_delete.cpp.obj and then follow 70 errors of stuff not defined.
great tutorial!
awesome tutorial, thank
I followed your youtube. I get an error "fatal error # include cstdlib no such file or directory" I have tried using the raspberry pi sdk instructions to run blink and get the same error. Where should I look for this file.
What’s the IDE you’re using? Sublime?
Vim
How I can mount the raspberry pi pico filesystem without unplug and plug into the USB Port (with holding the BOOTSEL button), like in your video?
i am looking for this too. have you been able to solve it?
First of all, thank you! Great explanation. But, what about Pico C LED blink bare-metal video, just like you did with Arduino? :)
Great suggestion!
My 'cmake ..' command did create a lot of things.....makefile not being one of them. Why do you think that is?
is the CMakeLists.txt exactly same as it is shown in the video?
bro how to learn Raspberry Pi Pico programming (c/c++)
Thanks :)
Anytime :)
Which Linux distro is he using for these tutorials? I’m at a loss.
distro does not matter. he is using ubuntu. it might look different because he is not using any "traditional" desktop environments. its all the same under the hood.
I have gone through this over and over what a nightmare. In the end the make fails. I deleted everything several time and went through again. everything works up until make. Then I get a whole bunch of errors when it hits elf2uf2
same, have you figured out how to solve this yet?
@UNOSEEMEk yes, I did but I can't remember what it was. The process for using C or C++ is a joke or at least was 9 months ago. I gave up and started using circuit python and micro python with thonny. It is much easier to get your code built and running on them with that.
arm-none-eabi-newlib
check if anything changes after installing this package.
I am new to code in C. I cannot run "sudo snap install cmake". How to install 'snap' first?
sudo apt install snapd
Its not a C thing. Its a ubuntu thing.
My CMakeList.txt looks nothing like yours when I downloaded the examples. Was this completely re-written by you? I am new to Cmake. Been using Arduino and venturing into Raspberry Pi Pico
is there a tutorial for c++ and raspberry pi robotics? i really wanna learn
Do you know of a good NRF2401 C ONLY driver and example for the Pico? I have seen C++ versions but really look for a pure C one with a good send/recv example.
Mr LLL, a little ARM ASSEMBLY example in the future ? Currently no videos on Pico just Rpi-board:
$ as
$ ls
$ gdb (or GDB server)
But those for OS-RPI
"I'll put this link in the description." *doesn't*
What a chad.
It will be helpful if you could explain connection of hardware
pico -> (usb mini) usb cable with standard usb 2 type A in pc/laptop/raspberrypi
it would be nice if you made this video few minutes longer and explain how you connected into the Raspberry Pico and how you connected Pico to the web etc. Otherwise great video.
pico cant connect to the web.What he didnt makeclear was that he was running the commands from either a linux pc or a rasberry pi4 etc.However i did manage to blink an LED from watching this so i think he did ok.
Please please please please make a modern video for this.
Thanks. Can you make a tutorial with window OS ♥
A "little" more complicated... I decided to stick with Python on the Pi and C++ on the Arduino as a result of seeing that "little" extra complication.
i think i bricked it :(
Mmmmm, tasty...
😋
:-)
Hi, I'm curious. I really want to know how your CMakeLists.txt is much different from the
one in the git repository. How did you came about to write this ??
Anyways, the one in the git repository didn't work for me but yours worked perfectly
and i made no modifications to my blink.c
I have actually looked up in the Raspberry Pi Pico C/C++ SDK pdf and didn't find any info on how
you set your CMakeLists.txt to be the way it is.
Eventually, i will be writing my own project and i will need to write my own CMakeLists.txt
to suit my codes.
Thanks a lot for your tutorial. It's my first time getting into c/c++ baremetal armeabi.. gcc stuff
and i wouldn't have been able to get this going without this tutorial
Some criticism:
1. Where's the C++ ? This is pure C.
2. Why instruct cmake (CMakeLists.txt) that your project uses C++ and ASM when in fact it only uses C? You don't need to set the C++ standard either if you don't use C.
3. Type safety! Why define GPIO_ON/GPIO_OFF as 1/0 instead of true/false? Match the API signature.
4. Let me post a C++ modification that also gets rid of using the preprocessor for the defines:
#include
namespace { //anonymous namespace, makes variables local to this translation unit. Same as defining them as static.
constexpr bool GPIO_ON = true;
constexpr bool GPIO_OFF = false;
constexpr unsigned int LED_PIN = 25;
}
int main() {
//blah
}
thanks!