filipdam
August 2, 2024, 09:10

Errno 9

Hi, im currently coding program that would display on my 2.13inch e-paper through Raspberry Pi zero 2W info from MQTT. It partially works because it displays all 3 values i want but they are static they are not updating. And i keep getting OSError: [Errno 9] Bad file descriptor.
justaccsolol
August 2, 2024, 01:06

Rpi Bluetooth

So I use a pi zero 2w, i tried using the GUI version and I was able to pair & connect to my phone however when i tried with the lite ver of rpi OS it now gives me an error I'm able to pair but not to connect I have ran out of ideas The error is org.bluez.error.failed
filipdam
August 1, 2024, 14:34

Display not working

I am trying to setup a 2.13inch Touch e-Paper on my Raspberry Pi4 and the display does not seem to be working. I have followed everything in this manual here https://www.waveshare.com/wiki/2.13inch ... HAT_Manual but it still does not seem to be working. When I touch the E-paper I can see inputs on my terminal which says that the E-paper is responding but the screen is not lighting up.
ashlin4010
July 31, 2024, 22:39

CM4 Libcamera with a custom device tree

I have been trying to get Libcamera to work on a cm4 system for a few days now with no success. My main issue is I have been unable to get i2c0 to show up or any muxed version of it (i2c10...) As far as I can tell my device tree is about right, I would have expected to have seen some effect with all the things I have tried. Looking for some info. What are the requirements of Libcamera, kernel module, does it expect to find a cam on i2c10 or does it check them all? How does the VideoCore and bcm2711 share BSC0 (i2c0)? What if any dtb does the VideoCore need, what is its default? What setting in config.txt may override my dtb or change the way the hardware is working? I should say the device tree is just a flattened version of the devices tree, overlays have been added inline.
goingfrickincraycray
July 30, 2024, 22:46

macro / steam deck with raspberry pi pico

Hey guys, I have a raspberry pi pico and im trying to make a macro / steam deck type thing where when you press a button it does a certain action. Would anyone be able to help me code this / get the materials for it?
captan220708
July 30, 2024, 16:46

Bluetooth not working, not scanning any devices (Rpi4)

I have bought a raspberry pi 4 from a store, its been 1.5 years by now i usually dont use rpi much but when i need it like for some projects and research related things... toady i wanted to use my Bluetooth of my rpi for many reasons like sharing some python files from my PC to rpi and basically connecting my headphones... i tried many times like changing the OSs and connecting external USB blutooth BUT IT JUST DONT SHOW ANYTHING! whenever i click on Add devices then a windows popups showing that it is scanning the nearby devices... like literally i have many Bluetooth devices near me and it is all showing in my phone and the PC but the that "Scanning Devices" window is blanck! Please help!

freeze
July 30, 2024, 11:57

Raspberry Pi Zero W not booting with a pre-installed SD card?

Hi there, I purchased a Raspberry Pi Zero W starter kit from The Pi Hut which came with a pre-installed OS on a SD card. However when I try to boot all I get is a rainbow screen and 7 blinking green flashes. Apparently the flashes mean "Kernel image not found" but as I say it's a pre-installed card that came with it so it seems unlikely the OS is installed wrong. Any help would be much appreciated! 🙏
koukatsuwu
July 30, 2024, 04:55

(Arduino) Trying to send a web request with OpenAI API

cpp
# include <WiFi.h>

char  ssid = "";
char  password = "";
char * key = "Bearer "; 
//pretend these were filled out

void setup() {
    Serial.begin(9600);
    if (!Serial) { delay(5000); }
    Serial.print("Connecting to WiFi\n");
    WiFi.begin(ssid, password);
    while (WiFi.status() != WL_CONNECTED) { continue; }
    Serial.print("Connected!\n");
    WiFiSSLClient client;
    Serial.print("Connecting to OpenAI\n");
    if (!client.connectSSL("api.openai.com", 443)) {
        Serial.print("Connection failed!");
        return;
    }
    Serial.print("Connected!\n");
    String payload = "{\
model: gpt-3.5-turbo,\
messages: [{\
role: system,\
content: Why is grass green?\
}]\
}";
    client.println("POST /v1/chat/completions HTTPS/1.0");
    client.println("Host: api.openai.com");
    client.println("Content-Type: application/json");
    client.print("Content-Length: ");
    client.println(payload.length());
    client.print("Authorization: ");
    client.println(key);
    client.println();//separate data from headers
    client.println(payload);
    while (client.available()) {
        char c = client.read();
        Serial.print(c);
    }
    if (!client.connected()) {
        Serial.print("disconnected\n");
        client.stop();
    }
}
This is the code I'm using ^^ I've tried a ton of stuff but I only ever get an error code 400.... For reference, here's the request working
bash
curl https://api.openai.com/v1/chat/completions   -H "Content-Type: application/json"   -H "Authorization: $KEY"   -d '{
    "model": "gpt-3.5-turbo",
    "messages": [
      {
        "role": "system",
        "content": "Why is grass green?."
      }
    ]
  }'
^^ the above command actually returns a ChatGPT-generated response
wille____
July 29, 2024, 17:02

Control a led lamp using my phone with Bluetooth on rasp4

How can I control a led lamp connected to raspberry pi 4b using the Bluetooth on my phone?
ihatenetworkchuck
July 28, 2024, 21:55

make[1]: *** /lib/modules/6.1.21-v8+/build: No such file or directory. Stop.

make -C /lib/modules/6.1.21-v8+/build M=/home/dietpi/r8152-2.16.3 modules
make[1]:  /lib/modules/6.1.21-v8+/build: No such file or directory.  Stop. 
make:  [Makefile:24: modules] Error 2
shabzup
July 28, 2024, 14:44

Smart glasses project using raspberry pi zero wh

Hey, I am struggling with connecting and accessing my raspberry pi zero wh with ssh, i have done all the steps correctly but it does not connect to my wifi network, I have tried both 2.4GHz and 5GHz networks with a dual band wifi router
mathewb_06264
July 28, 2024, 14:21

tv tunner

Hi there is there anyone her who know anything about tv tunners.I would like to connect one to a cm4.
pweppapig2
July 28, 2024, 05:17

Pi 4B not booting

Hey! So I've gone through the troubleshooting sticky guide and I can't seem to figure out what's wrong with my pi. I'm getting 4 slow green blinks and then 7 fast ones which supposedly indicates that kernel.img is not found but I've properly formatted and then flashed my SD card MULTIPLE times with different OS's using the Raspberry pi imager. I have put the correct version of the OS (64 bit) so I'm lost now. What is wrong?
h_0_p
July 27, 2024, 22:11

Auto-Forcing the cursor to move to lower corner

I have a project that runs a python script when the pi boots up. When it boots, it checks how many days left until Halloween, and displays an image on the screen to reflect how many days left. It also spins 2 stepper motors ...This part works. The issue I am having is the cursor is displayed right smack in the middle of the screen, and I need it moved out of the way. This is going to run on its own with no mouse/kb installed. I've tried using the following methods:
python
pyautogui
  - attempt to move the cursor using pyautogui.moveTo(screen_width - 1, screen_height - 1)
xdotool via subprocess
  - subprocess.run(["xdotool", "mousemove", str(screen_width - 1), str(screen_height - 1)])
  - also tried to execute xdtool before initializing pygame:
      subprocess.run(["xdotool", "mousemove", "1919", "719"])
pynput
  - mouse.position = (screen_width - 1, screen_height - 1)
evdev
  - ui.write(e.EV_REL, e.REL_X, screen_width - 1)
    ui.write(e.EV_REL, e.REL_Y, screen_height - 1)
    ui.syn()
Nothing seems to make the cursor move out of the way - I am trying to move it to the lower right of the screen where it will be hidden. Any input is greatly appreciated.
spidertravler
July 27, 2024, 03:45

raspberry pi gadget mode

need assitance thanks
maric4648
July 26, 2024, 20:21

Raspi 5 not booting, 4 green blinks, no video

when i first booted my SD card that used to work on my rpi3 it got stuck at uboot, a little reading later i decided to just make the recommended SD with rpi-imager black screen only, 4 pulses (the last one is a bit clipped so maybe its 3+1 short?) booting without a card has the same behavior, nothing is shown on screen (not even the diag stuff?) i overwrote the sdcard that got stuck at uboot but i am at least 90% certain that my (only) microhdmi to hdmi cable didn't break any next steps? i couldn't find the blinking patterns for rpi5
lloyd.b
July 26, 2024, 12:41

NUT Server scanner On Pi Lacks Device Info

G'day All, This is a strange one and I'm not sure exactly where it belongs but I think it's more of a Raspberry Pi thing than a NUT thing. (Hopefully). The story so far...I have three UPS's and two of them are identical. The trouble is they do not have any unique information to differentiate between them. I can bypass this on Ubuntu because the nut-scanner utility reports a device ID (based on the port) which I can use to differentiate when writing the config. Alas, Bookworm (and Bullseye) do not seem to provide this information to nut-scanner. It does work if I install Ubuntu server on the Pi but that makes using the GPIO pins difficult and I'd really rather use Bookworm. The difference is that Ubuntu reports like this: [nutdev3] driver = "nutdrv_qx" port = "auto" vendorid = "0665" productid = "5161" product = "USB to Serial" vendor = "Cypress Semiconductor" bus = "002" device = "002" busport = "001" and Bookworm shows the same but without the device or busport entries. I can do without the busport entry but device would be fine. I've tried manually specifying the device ID from the results of lsusb but it doesn't work as I don't think it's aware of a device ID. Is this to do with the implementation of the usb lib stuff in Bookworm or would I need to install something extra on-top? I've scoured google and forums but to no avail as it seems people running it on Rpi have UPS's with serial numbers or other self-defining features. Would be grateful for a poke in the right direction. Cheers, Lloyd.
wille____
July 26, 2024, 11:32

transmit 433mhz signal with raspberry pi pico

Is it possible to use a Elecbee CC1101 Modul 433Mhz to transmit and receive a 433 mhz signal with the pico?
pipsqueeeek
July 26, 2024, 04:31

Emergency Shutdown Code

so I'm starting this project where I will use my raspberry pi 4b outside and leave it for 2 weeks minimum running on a solar panel. what bothers me the most is that if the battery suddenly runs out of power and improperly shutdown my raspberry pi it has a high chance of corrupting my raspberry pi. does anyone have suggestions on how I might make this work?
adrenasystem
July 26, 2024, 04:24

LF Help w/Programming Pi

Hi all! I'm looking for help on what to do to program my raspberry pi, I want to make some network security with it. Like auto closing ports, making sure our network has better encryption, defense against attacks.. what Pi do I get, where do I start? Needing some help.
m1gdal
July 25, 2024, 16:08

Simple KeyBoard project with RP2040

Hi, I'm creating a small USB stick project that will type a phrase on the screen when plugged into a USB port. I'm targeting the RP2040 or ATmega32U4. I'm more for the first one, but I'm curious if it would work well (or work at all).
doom5day
July 25, 2024, 03:44

moisturize sensor working with rasberry pi 5

any one know how to get a capacitive soil moisturize sensor working with rasberry pi 5? No clue how to program it
darthcheadle
July 25, 2024, 02:18

ultrasonic sensor not working

My ultrasonic sensor is not working with my raspberry pi

mendo2306
July 25, 2024, 01:55

Reboot problem?

Does anyone know why this happens and how to fix it? https://youtu.be/-5SVFRufPoo?si=aspKoLSH4dIbhkDz
rybeardawg
July 24, 2024, 01:58

PC Case Display - Looking for Advice

Hello! Overview I'm starting a project where I put computer thermals/vitals/stats and videos onto a display within my computer case and hoping to get any advice or pointers. Microcontroller I am between the RPI 4 Model B and the RPI Zero W. I will probably get the RPI 4 model B as it has a Mipi DSI interface and the RPI Zero W would require a converter. I want something with Wi-Fi so I can run an API from my desktop where the info it needs can be retrieved from there. Alternatively, I can use serial communication through the USB port but I think less wires and ports taken is ideal. Display Ideally, I'd like a display about 12" x 4" with a resolution around 1920x515. Can anyone recommend me something like this? When I've gone looking, I've only come across options with interfaces I don't think are compatible. Thank you for any advice!!
thunder07337
July 23, 2024, 23:05

Not sure if Zero W is loading the Raspberry Pi OS

You have misunderstood the instructions. It's about communicating with the Pi via the USB port instead of WiFi. It doesn't say anything about installing the OS on a USB stick.
catguy12321
July 23, 2024, 16:47

Pin busy

I'm trying to connect a RFM95W LoRa module and a button to a raspberry pi, but it returns a GPIO Busy error at CE1. I tried rebooting but still doesn't work. error message:
bash
Traceback (most recent call last):
  File "/home/raspberry/radio.py", line 11, in <module>
    CS = DigitalInOut(board.CE1)
         ^^^^^^^^^^^^^^^^^^^^^^^
  (redacted traceback stuff)
  File "/usr/lib/python3/dist-packages/lgpio.py", line 458, in _u2i
    raise error(error_text(v))
lgpio.error: 'GPIO busy'
code:
python
import time
import busio
from digitalio import DigitalInOut, Direction, Pull
import board
import adafruit_rfm9x

btnA = DigitalInOut(board.D17)
btnA.direction = Direction.INPUT
btnA.pull = Pull.UP

CS = DigitalInOut(board.CE1)
RESET = DigitalInOut(board.D25)
spi = busio.SPI(board.SCK, MOSI=board.MOSI, MISO=board.MISO)

iter = 0

def send_data():
    global iter
    print("send %s"%iter)
    iter+=1

def get_data():
    global iter
    print("get %s"%iter)
    iter+=1

def main():
    try:
        while True:
            if not btnA.value:  # Button pressed
                send_data()
            else:
                get_data()
    except KeyboardInterrupt:
        pass

if __name__ == '__main__': 
    main()
iamnotmega_
July 23, 2024, 12:07

pi stopped working after dropping

i once dropped my pi on the floor and after it just refused to give an hdmi output. the case fan did spin when i had it connected, but when i tried to ssh into my pi, it said connection timed out. please help
leotgyt
July 22, 2024, 21:33

Pi 400 WLAN Adapter not detected

So, my Raspberry Pi 400 seems to be ignoring the integrated wlan0 adapter, showing only eth0 and lo in ifconfig. In the raspi-config menu, country locale setting fails with error "There was an error running option L4 WLAN Country" Although I have been trying out create_ap (hotspot, installed through pi apps) and rfkill, I don't think I've done damage. Any recommendations? Thanks in advance 🙃
gonzmacben
July 22, 2024, 18:18

Help with Installing GUI on Ubuntu server (24.04 LTS, Raspberry PI 5)

I got my first raspberry pi earlier this month and I am new to the hobby. I plan to use my PI with the usb c gadget functionality so I can connect it to my iPad pro and turn it into a "mini laptop" so I can work with ROS2, so far I managed to establish the ethernet connection but I haven't been able to install the GUI properly. I tried to use tigervnc and installed the ubuntu desktop minimal but the logs indicate that there are some problems with gnome I managed to create a vnc over ssh tunnel and the only thing I see is the white screen with the "Oh no! Something went wrong" message. I recently tried to install lightdm but it doesn't seem to work, the installation came with errors and I tried to fix it but it looks like it's just not compatible with my version. Has anyone managed to get the ubuntu 24.04 gui working on a Raspberry pi 5?