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
1
vote
0 answers

Having trouble reading gps NEMA sentences using pi pico

Hi first time using forum so sorry if I did something wrong. I'm trying to make a simple gps NMEA sentence reader using a raspberry pi pico and a gps module I have hooked up to it. Here is the code I created. from machine import Pin,…
Calvin
  • 11
  • 1
1
vote
1 answer

Why can't i move my mouse and press a button at the same time in circuitpython on a tiny 2040 (runs on rp2040 just like raspberry pi pico)

i am writing something which should let me use a joystick as a Spacemouse that i want to use in fusion 360, im doing this by making the mouse move and pressing the middle mouse button and shift, and releasing it when the joystick stops moving, but…
1
vote
0 answers

Programming external QSPI flash Raspberry Pi Pico

I want to reprogram the external flash of a raspberry Pico via SWD line. This feature must be implemented in a different microcontroller, not from a Linux computer so the OpenOCD library cannot be used. I already wrote a C library that is able to…
Luca
  • 61
  • 1
  • 7
1
vote
2 answers

RPi Pico freezes on IRQ Interrupt call

I'm currently working on a small library that simplifies the use of 433MHz RF modules. The problem I'm facing right now is that when I'm trying to create an IRQ interrupt on the UART0_RX Pin (GPIO1), the Pico will call the callback function, execute…
The Origin
  • 135
  • 1
  • 10
1
vote
2 answers

Using Python and pyserial to run python scripts on a pico (RP2040)

My ultimate goal is to control a number of peripheral chips on a PCB from a GUI interface on a PC. To do so, my plan was to incorporate a RP2040 (and memory) on the PCB in order to hold all the python scripts and to program/monitor all the…
SamiH
  • 11
  • 1
  • 2
1
vote
0 answers

CMake: Multiple executables for different platforms sharing common code

I'm a CMake-beginner. Here's a problem I cannot figure out. I have a project structure that looks like this: root | common/ | include/ | public.h | src/ | file-1.c | file-2.c | win-exec/ | main.c | pico-exec/ | …
r1sc
  • 11
  • 1
1
vote
1 answer

Trouble using the UART with RPi Pico C sdk

I'm making a remote controlled machine using a pi pico to drive the motors and read some sensors, and a raspberry pi 4 to send commands to the pi pico via serial and host the web interface. I'm working on sending and receiving commands from the…
1
vote
1 answer

How can I push a file out to multiple Raspberry Pi Pico's at once?

I am looking for a DIY replacement for the $1500 Go-Box for mass provisioning Chromebooks. I have managed to replicate this by using a Raspberry Pi Pico as the "HID Emulation". However, I need this on a mass scale. I want to be able to do 20…
Nathan
  • 65
  • 1
  • 4
  • 14
1
vote
0 answers

Trouble with 1602 LCD display displaying additional decimal points using a raspberry pi pico and DHT22 sensor as a weather station

I'm still new at coding and was able to put together some code from other sources for a simple weather station I built. Everything seems to be working fine but I do get the occasional hiccup where temperature readings on the display show additional…
Fred
  • 11
  • 1
1
vote
1 answer

Is GC Broken on RPi Pico

I am using the latest stable release of micropython and below is my entire program. import gc gc.collect() print('free:{}, alloc:{}'.format(gc.mem_free(), gc.mem_alloc())) #free:187488, alloc:4576 Where did 64k of my RAM go? I know it isn't a…
OneMadGypsy
  • 4,640
  • 3
  • 10
  • 26
1
vote
2 answers

How to convert from bytearray/bytes in micropython?

I'm hashing things with uhashlib in micropython on the pi pico. Here's an example: import sys import os import uhashlib import time time_now = "blergh" hash_test = uhashlib.sha256(time_now).digest() print(time_now) print(hash_test) This…
1
vote
0 answers

How to make larger integers on MicroPython?

I'm working on a personal project on Raspberry Pi Pico. I try to make mandelbrot set explorer on it. But I have a limit right now. On my searching, I see MicroPython stores integers only 32 bits but I need more than that. Is there any modules or…
1
vote
1 answer

Terminating second thread in micropython on Raspberry Pi Pico

I use both cores of RP2040 chip. Main one runs main loop and second handles LCD display. I start second one on the thread like _thread.start_new_thread(taskLCD, (100,0.5)) where taskLCD updates LCD every half os second. Sometimes when I restart…
Alex
  • 4,457
  • 2
  • 20
  • 59
1
vote
1 answer

Why doesn't this micropython function work?

I have written a function in micropython that attempts to retrieve uname information and strip out stuff I don't want and then return a value: import os def get_uname(): my_uname = os.uname()[3] my_uname = my_uname.replace("(GNU…
Robert Baker
  • 167
  • 1
  • 1
  • 14
1
vote
2 answers

Sepreating python code in raspberry pi pico

I am unable to import class from a different file in micro python on raspberry pi pico. Eg. directory structure dir/   |__main.py   |__imports/     |_example.py filename : main.py from imports.example import ex a =…