658 questions
Best practices
0
votes
6
replies
105
views
How to use file sets in CMakeLists
I'm currently writing CMakeLists for a multidirectory project,and am trying to use file sets and target_sources as it is regarded as better than using target_include_directories, but the only problem ...
0
votes
0
answers
65
views
Raspberry doesn't show in my PC, nor is it detected in Arduino IDE
I was trying to upload a sketch in my RaspBerry PI Pico W (USB) when suddenly this error occurred:
Sketch uses 316068 bytes (15%) of program storage space. Maximum is 2093056 bytes.
Global variables ...
0
votes
1
answer
29
views
Micropython PIO interrupt causes loop on PICO
Extract of longer program. Just to toggle the .side pin and then quit the PIO program. Causes loop and have to nuke the PICO! Loops before the 'Run' print. Thanks
TypeError: function takes 2 ...
0
votes
1
answer
102
views
Calculation of CRC7
For a SD card driver I tried to calculate CRC7 for the commands.
Now, if I "enable CRC7 check" with CMD59, I get errors with some SD cards. But if I "disable CRC7" check with CMD59,...
2
votes
1
answer
92
views
Error: expected string literal before '__asm' in a pico-sdk project?
In my RP2040 pico-sdk project, I'm getting a problem when I try to use the CMSIS function __DSB() - "error: expected string literal":
/src/MyProject/my_main.c:848:5: error: expected string ...
0
votes
0
answers
76
views
How to use HIDAPI to communicate with rp2040 keyboard and mouse composite device on the pc to control keyboard and mouse actions
I saw the keyboard and mouse device example in Adafruit_TinyUSB_Arduino\examples\HID\hid_composite and I want to send control commands through HIDAPI on the PC to perform keyboard and mouse actions. ...
0
votes
0
answers
94
views
lwip include path for Raspberry Pi pico 2 w SDK
EDIT: I just needed to add target_link_libraries(${PROGRAM} pico_cyw43_arch_lwip_threadsafe_background) to CMakeLists.txt.
I'm trying to compile a program for the pi pico2 w but it can't find "...
0
votes
1
answer
132
views
Raspberry Pico W: Hangs after WLAN deinit()
My PICO W hangs sometimes after calling deinit(). I'm using Micropython v1.25.0 (2025-04-15)
Please see this example script:
import network
import time
from time import sleep
import urequests
import ...
0
votes
0
answers
59
views
Micropython asyncio StreamWriter only sends part of data
I'm pretty new to Python, & I'm attempting to set up an access point from a Pico W to provide info to a client (eg, an iPhone). The connection is successful, but my iPhone app only receives ...
0
votes
0
answers
77
views
CircuitPython make Android believe its connected to the internet
I am using Raspberry Pi Pico W in an AP mode and need to allow users to go to 192.168.4.1 to see a website on which they can communicate with the Raspberry.
On an iPhone everything works just fine, ...
-1
votes
2
answers
64
views
laser turns on without input
i have a setup with a microcontroller where pushing a button i attached with gpio pins turns on a laser pointer using gpio pins. this is part of a larger project including speakers and other leds and ...
1
vote
1
answer
337
views
clangd doesn't find standard libs, throws error in line #include <vector> stating "file not found"
I'm using nvim 0.11.1 in a lsp config, and got clangd installed via mason.
The project I'm working on uses the picoSDK, and clangd works inside nvim.
The problem is, that it can't seem to find the lib ...
1
vote
0
answers
141
views
Pico Hardware SDK options not available for C++
I'm playing around with the Pico SDK and the extension in VS Code and it seems that when I produce a C++ file program instead of C, a number of the hardware options are no longer available to include. ...
0
votes
1
answer
71
views
RFM69 stuck on 1024
I have an RFM69HCW connected to a raspberry pi pico like this:
running this script, I always seem to get back the wrong values.It always returns the maximum it can give.
""" Receiver &...
1
vote
1
answer
140
views
Getting C++ memory allocation pointing to same location which crashes the program
I am programming an RP2040 chip using the Pico-Arduino library. In this problem, I am using the Ardunio String class and the Adafruit_NeoPixel class. After setting up some "Strings" and a ...
2
votes
2
answers
111
views
ATtiny841 slave SPDR register
Version 1:
I am using a Raspberry Pi Pico as SPI master and an ATtiny841 as SPI slave.
Master code:
#include "pico/stdlib.h"
#include "hardware/spi.h"
#include <stdio.h>
#...
0
votes
1
answer
130
views
Bluetooth advertisement data
I built a small PoC on rp-pico using the btstack, basically rework of the standalone simple BLE service.
Like in the example, BLE uses advertisement data, and in the example there are some constant ...
0
votes
0
answers
38
views
re.search() raises recursion depth error when in thread [duplicate]
In MicroPython, re.findall() does not exist. Therefore, I made one myself:
def findAll(pattern, s, flags = 0):
found = []
while True:
m = re.search(pattern, s, flags)
if m:
...
0
votes
0
answers
75
views
Micropython is HARD
I'm having trouble either controlling the flow, or maybe my math is wrong, but I keep getting stuck in a loop. My code should be getting the temperature of a thermistor (TempF), translate that to a ...
0
votes
1
answer
295
views
Does Pico 2, utilizes SIMD-instructions or just loop-unrolling during arm_dot_prod_f32?
The title says almost everything. Does (Cortex-M33) RP2350 rasberry-pi-pico 2 utilizes any SIMD-instructions (at all) via DSP during arm_dot_prod_f32 or does it simply loop-unrolls? I know for certain ...
0
votes
1
answer
93
views
CircuitPython - Input pins dont work when not executing from Thonny
I am building a thermostat and have designed a board layout which I am intent on ordering but I want to make sure everything works before I order. After getting everything wired up on a breadboard for ...
0
votes
0
answers
94
views
Error linking CXX executable <project>.elf while compiling a C/C++ Raspberrry Pi Pico project in VS Code
I am building an IMU as a school project. This required integrating the Fusion(Madgwick) library to get roll, pitch and yaw from acceleration and gyroscope values from MPU6050. These values are first ...
0
votes
0
answers
94
views
How to Set Temperature for a Virtual Tuya Thermostat Using MicroPython? API Token Request Fails (Error 1108: URI Path Invalid)
I'm trying to control the temperature of my virtual Tuya Thermostat using MicroPython. I have already successfully tested the API using Postman. However, when I try to use the same parameters and ...
1
vote
1
answer
105
views
How to change the Bluetooth name of the Raspberry pico 2W?
Currently, I want to change the Name of the Pico 2W device displayed on the nRF Connect app. I am using Micro Pico in VsCode. I tried many things but the Name is always "N/A".
import ...
0
votes
0
answers
19
views
Why is my waveshare 7in5 b display with raspberry pico2w going into PANIC?
Im trying to send an image from a server to the pico2w board whcih is connected to a waveshare 7in5 b pico epaper display, the problem is that the server sends the image to the pico2w, it receives the ...
-3
votes
1
answer
380
views
Issue with c++ threading in a raspberry pi pico project [closed]
I am currently trying to make a little robot thing using a Raspberry Pi Pico W, and I have most things working at the moment. However, I currently need to have a way to sort of schedule things, having ...
0
votes
0
answers
45
views
Unable to connect in Win10 to my W5500-EVB-Pico2 ( RP2350 ) via SWD
I 've tried to connect via USB (debugging pins SWDIO, GND, SWCLK) to my W5500-EVB-Pico2 ( RP2350 ) using SEGGER J-Link Commander V8.12b (latest version) in Win10 (x64).
J-Link log:
SEGGER J-Link ...
3
votes
2
answers
559
views
How to access PSRAM - Pimoroni Pico Plus 2 (RP2350) | PlatformIO
I'm trying to access the PSRAM on a Pimoroni pico plus 2 but im not very skilled in C++.
I'm using platform io.
platformio.ini:
[env:rpipico2]
platform = https://github.com/maxgerhardt/platform-...
1
vote
2
answers
489
views
Waveshare RP2350 Touch Lcd 1.28 inch LVGL
Got my hand on a cheap Wavehsare RP2350 Touch LCD 1.28 inch round display, and wondered if I could run LVGL Micropython on It. I'm a newbie.
I tried the official Wavehsare documentation, and didn't ...
0
votes
0
answers
464
views
Problems importing PICO C project into VSCode using "Raspberry Pi Pico" VSCode integration
I am attempting to import this github PICO project written in C into VSCode using the "Raspberry Pi Pico" extension. VSCode is hosted on a Ubuntu computer (not a Raspberry Pi).
The result:
...
0
votes
0
answers
224
views
Issue Running Async Web Server with Multi-Core Threading on Raspberry Pi Pico W
I'm working on a project using the Raspberry Pi Pico W 2 that involves displaying data from BLE sensors on a web page, with everything running on the Pico.
My intention is to:
Run an asynchronous web ...
-1
votes
1
answer
76
views
TypeError: unsupported types for __gt__: 'int', 'NoneType' - Circuit Python [duplicate]
I took an Adafruit code example ([Rotary encoder][1]) for a rotary encoder and changed it in a way that I can control the volume of my PC with a Raspberry Pi Pico as HID.
#
# SPDX-License-Identifier: ...
-2
votes
2
answers
205
views
Problems using threading for a webserver on raspberry pi pico W [closed]
I'm trying to make a webserver display some data while the pico is collecting it from some pins. Everything works fine for making the webserver running, i'm able to access it with "static" ...
0
votes
0
answers
138
views
PICO W / Micropython websocket client can't send to PHP websocket properly
So I've been racking my brain for a few days trying to figure this one out.
In short, I have a PHP-CLI script I wrote for my project that is my websocket server. The script authenticates connections ...
1
vote
1
answer
226
views
Bidirectional communication over USB between host PC and Raspberry Pi Pico
I'm trying to achieve bidirectional communication over my Raspberry Pi Pico's built-in micro-USB port. More specifically, I'm trying to make my computer send a ping to the Pico, and the Pico receives ...
0
votes
0
answers
23
views
How to get meta data from a webradio stream in CircuitPython?
I have the following working code to stream audio from a webradio station:
(Raspberry Pi Pico on a Pimoroni Pico Demo Base. CircuitPython 9.2.1)
import time, os
import adafruit_connection_manager
...
0
votes
0
answers
95
views
VS Code, adding a source file to a C language project causes an error
I am using the Raspberry Pi Pico Extension in VS Code, running on a Pi4. I am playing with the examples provided in the RaspberryPi/pico-examples repository on GitHub... for example the hello_uart ...
1
vote
1
answer
82
views
arm-none-eabi-gdb continues instead of stepping over in no-sdk baremetal assembly
In main function after nexti instruction on bl, gdb debugger continues instead of stopping. The issue does not occur in functions called by main (e.g. I can step over functions called in ...
1
vote
0
answers
229
views
Reading Bluetooth signals from a HIDS device using aioble and micropython on a Pi Pico
I have a Raspberry Pi Pico W that I want to have perform an action when a button is pressed on a bluetooth remote control I bought.
I can read the bluetooth remote and it's services and ...
0
votes
0
answers
46
views
uasyncio.Event not resuming main loop immediately after set on Raspberry Pi Pico
I'm programming in Micropython for the Raspberry Pi Pico. In my main loop I await for an uasyncio.Event, which I successfully set from an interrupt context.
I expected the code to pause and then ...
1
vote
0
answers
73
views
Captive Portal In MicroPython doesnt work
I am trying to create an automatic captive portal using a Raspberry Pi Pico H with an ESP8266 Wi-Fi HAT. When I connect to the Wi-Fi, it works, but the user is not automatically redirected to the ...
0
votes
1
answer
67
views
Change the button value according to the state of the LED
I have a project from my college that is in Micro Python, but my question is about something related to HTML that will have to use JavaScript.
My project simulates a house that has lights controlled ...
0
votes
0
answers
330
views
Pico flash and heap - how much available and how much is used
I am learning how to program a Raspberry PicoW in C++ and I have two question about flash:
How much of the flash is my programme taking up? With AtMega programming, the compiler would display this ...
2
votes
0
answers
90
views
How can I make the multiplexing to the 4-digit 7-segment display to work?
The code bellow is meant to read the voltage value from the ADC channels present in GPIO 26 and 27. It changes from ADC channel 0 to ADC channel 1 when the pushbutton in GPIO 15 is pressed.
The ...
0
votes
0
answers
43
views
Raspberry Pi Pico with KX134 accelerometer not being recognised despite being detected
I'm using the code below to communicate between a Raspberry Pi Pico and a KX134 accelerometer connected over I2C. The device is being detected by a ping, however the program itself does not register ...
0
votes
1
answer
66
views
Arduino-cli VSCode for raspberry pi pico: Missing file PinNamesTypes.h
Short introduction
I am starting a new project with the raspberry pi pico using arduino-cli development environment and VSCode as editor.
The problem
The problem is about the VSCode C/C++ extension ...
0
votes
1
answer
469
views
I am having a very long and strange error when building Picotool 2.0.0
I am trying to build picotool 2.0.0, but I am running into a strange error. I have had to remove some of the error output as well as some of the build output as it is to long for this post:(.
PS C:\...
1
vote
1
answer
148
views
Using the DY-HV20T module with rp pico in UART
I'm trying to make this little MP3 player (dy-HV20T) work.
The module works in autonomous mode, but impossible to communicate with it in UART.
Here is the test code:
from machine import UART, Pin
from ...
0
votes
1
answer
48
views
OSError -1 while trying to send GPIO pin values
I have a short code written in micropython on pico pi W. This codes sets up a server and is mainly supposed to display a website on which you can check the states of all the GPIO pins.
Now when I go ...
0
votes
1
answer
620
views
Raspberry Pi Pico W TCP client *** panic ***
I built a reasonably basic client-server IoT setup in C++ with a Raspberry Pi 5 server and a few Raspberry Pi Pico W clients. It's nothing special, just keeps track of some temperature and voltage ...