Questions tagged [raspberry-pi-pico]

For questions relating to the Raspberry Pi Pico microcontroller.

The Raspberry Pi Pico is a microcontroller designed by the Raspberry Pi Foundation. It supports MicroPython, CircuitPython, and C.

The first Pico version was released in 2021.

512 questions
0
votes
0 answers

MemoryError: memory allocation failed in Micropython with Raspberry pi Pico

The code saves the data from some sensors together with the date and time that the sensor is taken, what it does is tell me what was the minimum and maximum in the course of 24 hours, only that there comes a point where the memory error appears ,…
0
votes
1 answer

Why does printf work in the while loop, but not before on a raspberry pi pico?

I have installed the C/C++ SDK for the Raspberry PI Pico on a Raspberry pi 4. Then I have compiled and executed the hello world example via USB successfully. I monitor the output using minicom and so far everything works fine. However, when I add a…
Kağan Kayal
  • 2,303
  • 1
  • 19
  • 30
0
votes
0 answers

Raspberry pi pico and I2C prtocol

This is my code so far. It recognizes my IC and gets a reg addr and some random data. import machine sdaPIN=machine.Pin(0) sclPIN=machine.Pin(1) i2c=machine.I2C(0,sda=sdaPIN, scl=sclPIN, freq=400000) devs = i2c.scan() if len(devs) == 0: …
0
votes
1 answer

OSError: -6 When making simple API Call in Micropython

Below is the micropython code that is supposed to use the api.sunrise-sunset to gather the sunrise & sunset times. The program worked about 2-3 times, and now without making any changes it provides the following error: >>> %Run -c…
0
votes
0 answers

Pi Pico Won't Connect to WLAN When Plugged into Wall. Works plugged into computer

I have a Raspberry Pi Pico W with the presoldered headers. When I run the following code (main.py) through Thonny on my PC I am able to connect to the internet no problem. When I try to run it after plugging it into the wall, the LED just keeps…
0
votes
0 answers

RPi Pico behaves weird/frozen if using _thred library in uPython

I was following the book called Get Started with MicroPython on Raspberry Pi Pico and i succesfully made it to the 65th page but i cannot continue. I wrote the code just like in the book (i use VS Code and the Pico-W-Go extension not the Thonny IDE…
0
votes
0 answers

Understanding failing TCP connectioon

Setup Laptop (192.168.137.1) Pico W (192.168.137.142) Websocket is established between the Laptop and Pico W, and data is send from the Pico W to the laptop. I am using my own custom Websocket library which uses this AsyncTCP library. The…
0
votes
0 answers

NRF24L01 between Raspberry Pi 3 and Pico

I've been having trouble connecting my Raspberry Pi 3B+ and my Raspberry Pi Pico for days. I'm using this library on the Raspberry pi 3 and the official MicroPython library on the Pico. I set all the parameters the same and added…
0
votes
0 answers

How to correctly install/use RPi Pico SDK for VS Code?

I installed the 'starter pack' using the Windows Pico Installer but VS Code gives me red error squiggles wehn i open any example files. When i red about this problem, i got one solution that said i must add ${env:PICO_SDK_PATH}/** to the include…
bcseh202
  • 9
  • 5
0
votes
0 answers

How to reuse adafruit_requests session after login to web server?

Not knowing how to keep requests session after successfully performing POST with login data, with circuitpython adafruit_requests on Raspberry Pi Pico Followed this adafruit tutorial and adapted to POST json data in order to login in to a https web…
0
votes
0 answers

family code error when family code is right

This is the error I get Traceback (most recent call last): File "", line 38, in File "adafruit_ds18x20.py", line 84, in __init__ ValueError: Incorrect family code in device address. This is all of the code that is being run, its…
reet66
  • 3
  • 3
0
votes
0 answers

Raspberry Pi Pico: Reading file from BOOTSEL area using Pico-SDK

I am working with a Raspberry Pico W that has to act as a MQTT client and I am programming it against the Pico-SDK for C / C++ API. Since I am going to use the code for several Raspberry Pico W, I would like to be able to transfer a customizable…
0
votes
0 answers

uPython on Pico W match case statement

Trying to code a function to read the ADCs on my PICO W using the latest uPython version and also the latest Thonny IDE version. this is the code for the function: def getADCvalue(ADCchannel): value = 0 match ADCchannel: case 0: value =…
Enginebeat
  • 23
  • 1
  • 1
  • 7
0
votes
1 answer

How to create a ssl certificate to embed with my rapberry pi pico w using an ARM microcontroller?

I had been attempting to connect my on system code to work on cloud. For this the device (Raspberry pi) needs to have public encryption method to be able to understand the instructions that are triggered from cloud. For this I need to have a ssl…
0
votes
1 answer

LCD in CircuitPython flashing on then off

I'm trying to get an LCD display (1602 via I2C from pi pico W) to work, and my code is as follows: import busio import time from adafruit_character_lcd import character_lcd_i2c i2c = busio.I2C(board.GP15, board.GP14) lcd =…
Joshua
  • 56
  • 1
  • 4