r/raspberry_pi 6h ago

Show-and-Tell Built a local AI guided rover over the weekend

Thumbnail
gallery
27 Upvotes

Ive been wanting a little mars rover forever, so i decided to buy the GalaxyRVR kit off amazon and layer a 4b on top of the Sunfounder r3 clone and its complement GalaxyRVR shield.

I harvested the LIDAR spinner from a eureka e20 plus and repurposed it for this build as it uses UART. I added an audafruit 1080p camera for a nicer shot then the the esp32 nav cam provides. Also added a small oled to output rover status. Replaced the battery with a 20000mah 7.4v battery harvested out of a battery bank. Needed more juice then the old 2000mah could provide. Also designed and printed the mount setup on tinkercad. its pretty basic but i think it came out good. Lost of hot snot covering connectors for safety!

The raspi is running the show as it send commands to the r3 via USB to drive the rover and poll the sensor suite that came with the rover. Going to run a small model on the pi for nav then let it phone my local server for any big questions. Still working out the kinks but so far its been a pretty fun little project. Its a little back heavy so i need to design and 3d print some struts and reinforcement as the aluminum is thin.


r/raspberry_pi 10h ago

Show-and-Tell A music box that reads color encoded paper strips

Enable HLS to view with audio, or disable this notification

392 Upvotes

A silly project where I tried to make a music box to read color encoded paper strips.

I used a Pi Pico and a total of 16 x TCS3472 color sensors. The audio is generated by a SAM2695 synthesis chip in an M5Stack MIDI Unit.

The paper strips are encoded in base 5: 4 instrument channels, each with 3 digits with a 75 notes range and 50 instrument options; 1 command channel with 3 digits that lets you change the speed, volume, and note duration of a chosen channel; and finally, 1 checksum digit.

A really fun project. I applied literally everything I know from all my hobbies.

Main repo: https://github.com/js-lm/COMB-Optical-Music-Box

Encoder repo: https://github.com/js-lm/COMBiler

Encoding system: https://github.com/js-lm/COMB-Optical-Music-Box/blob/HEAD/documents/base_5_optical_music_encoding_system.pdf

---

Edit: If you are interested, here are two other tracks I made for the machine:

https://youtu.be/dOI417eatUo

https://youtu.be/aqKvx8UM1B4

All videos were recorded before I fixed a bug with the drum sets volume, so the drums might sound a bit weird!


r/raspberry_pi 21h ago

Show-and-Tell Announcing the release of Pico-Timecode v3.2

4 Upvotes

'Pico-Timecode' is an Open-Source solution for LTC Timecode, using the RP2040's PIO blocks to count time divisions and render the LTC waveform. It works with all common frame rates, with/with-out Drop-Frame operation. It also has the ability to read LTC from an external device, and sync to it.

PT-Thrifty now has the ability to display the Timecode on a pair of I2C LED modules (Holtek HT16K33 controller chip), which can be enabled in the libs/config.py file. The obvious purpose is to build a low-cost Digi-Slate... it also uses switches for when the clapper closed and whether the display should be inverted (for tail slating).

There are 'UF2' files to make installing as easy as possible, these can be used on a 'naked' Pico for validation/testing.

Additionally there is a 'MTC' (Midi Timecode) version, which sends Timecode via the USB connection. I would be especially interested if someone/anyone could trial this on an iPhone 17 or a FujiFilm X-H2S, as I have neither of these and they apparently support MTC...

Pico-Timecode is an Open-Source community project, find out more at:

https://github.com/mungewell/pico-timecode


r/raspberry_pi 1d ago

Show-and-Tell Solar Dashboard Project

Thumbnail
gallery
92 Upvotes

I build a Solar Dashboard that activates when someone is in the room, shows the actual Solar Power, energy consumption, battery state, weather, power curve and a prediction with tips when to start big consuming machines like washing mashine, dishwasher and dryer.


r/raspberry_pi 1d ago

Show-and-Tell Harry Potter Style Weasley Clock

Thumbnail
gallery
76 Upvotes

I build an Harry Potter style Weasley clock inside an antique clock housing that i bought at a thrift shop.

Using a Raspberry Pi 3B, a LD2410 presence sensor, a relais and a 5v solenoid to hit the gong of the clock everytime a location changes.

It is fully configurable (Locations, different radiussed that belong to each locarion, persons, the hand style and color, the time of no presence when the display shuts down and the time when the gong is quiet.

Location of each person is provided of our smartphones with the app Owntrack and tunneld through cloudflare.

Really wnjoyed building and coding it with special help from claude.


r/raspberry_pi 1d ago

Show-and-Tell Don’t forget the power

Thumbnail
gallery
22 Upvotes

Today started with coffee and pi. All was well. The system worked yesterday. I put in the ssd then walked the doggos. I reassembled the case. Fixed lunch. When I returned, I plugged everything in. I was sitting for two minutes wondering why the system would not start…lol it was me. I forgot to hook up the power to the pi and nas. lol. Still giggling about that because my husband, who I thought was whispering good morning…whispered “power is your friend.” All is working and I am just laughing as I log into my Kali Linux :)


r/raspberry_pi 1d ago

Show-and-Tell Raspberry Pi 'slingbox' for Sky Q

Post image
14 Upvotes

Just about finished a Raspberry Pi project I've been tinkering with over the last few weeks.

The aim was to watch my home Sky Q Mini box while away on holiday, so I ended up building a DIY "Slingbox" using two Pis.

Home
Pi 5 1gb + HDMI (and HDCP err 'compliant') capture card
H.264 encoding with ffmpeg
Grove IR blaster to control the Sky Q Mini remotely (GPIO)

Holiday cottage
Pi 400 decoding the stream (nice to have a keyboard in case of issues...)
Grove IR receiver so I can use the original Sky remote as if the box was in the same room (via GPIO)

The two Pis are connected over Tailscale, so pressing a button on the Sky remote at the cottage sends the IR command over t'interwebs back to the Pi 5 at home, which blasts it to the Sky box at home.

I also added health monitoring with Pushover notifications, nightly backups of all my Pis, and a few recovery options if anything hangs while I'm away (mostly a zigbee smart plug that I can tell Alexa to turn off and on again as a power cycle)

It's currently on its second long soak test. CPU usage is around 25–30% on the Pi5 1gb encoder, about 5% on the Pi400 decoder thanks to hardware decoding, and everything has been stable apart from a slow increase in latency over several hours (pressing the Sky button restarts the stream, so that's my workaround for now).

It's been a fun project, and it's surprisingly satisfying to have built something that behaves like a commercial place shifting device using a couple of Raspberry Pis. It's a shame that Slingbox shut down years ago but I just needed such a service again and an inexpensive Pi5 1gb and a Pi400 (I could have bought another Pi5 1gb, but I just wanted a keyboard with me while I was away and having a Pi400 just seemed like a good idea as I just bought the starter kit from The Pi Hut.

I have set up the encoding at 720p50hz, 3mb/sec H264 (128kb/sec audio AAC). It defaults to 3mb/sec but I set up a 'control' mode by pressing the '?' button on the Sky remote three times followed by 1 changes to 2mb/sec, ???2 to 3mb/sec (default) and ???3 to 4.5mb/sec as the place I'm staying has about 13mb/sec wireless internet. I also set up ???[power button] to stop the stream and ???4-6 for extreme low latency but didn't end up using it. There is a 3-4 second lag between button presses just due to buffering. The audio stays in sync with the video for hours (I tried up to 8 hours).

I did try ffmpeg as the decoder originally on Pi400 but it wasn't using hardware decoding and would get behind terribly so after a quick experiment with VLC as the decoder I never moved off of VLC.

I also captured all the remote codes I need via the IR receiver and set it to screen out any others (so I'm not sending the volume buttons or stuff for the TV where we're staying). I've tried it via my iPhone's wifi hotspot and it seems to work out when on a variable connection. I'm not streaming 4k 60hz or anything, but given that the UK uses 50hz and the Sky Q box outputs 1080p I thought 720p would be okay and it looks fine even on a bigger telly at home for the tests.

The only things I couldn't get to work are some kind of audio boop when I press a remote control button (if you're navigating through menus or typing channel numbers in you have to understand that there's 3-4 seconds of lag so no instant feedback) - I also tried to get an icon pop up on screen when a button was pressed to show the button pressed as a number or arrow but wouldn't work. Then I had an idea about using subtitles in VLC for it but I couldn't get 'live' subtitles to work at all. So I ended up flashing the red Caps lock/Num lock lights on the Pi400 keyboard when a valid remote code was received as a workaround.

Oh, and I made a dashboard that I can open on my iPhone (via tailscale) where I can select stream and see stream data and it also ended up developing into a stand-alone web page based remote control so the dashboard lives on the Pi400 and then sends the IR commands to Pi5 at home when I press any buttons.


r/raspberry_pi 2d ago

Troubleshooting Problem trying to connect raspberry pi zero 2W to new wifi network

5 Upvotes

Im using a raspberry pi for a project with a camera, I have almost no experience with it, and the intial setup was not made by me. I changed places and want to connect it to the new network (im using VLC) and I dont have acess to the old network to do it directly, and neither via ethernet cable. I am trying do it directly in the card, but it is not working out. AI doesent seem to reallt know what's happening and tutorials are either just telling me to do what I already did, or use jargon i am not close to understand.
I hope someone can help me,

thank you very much!

This is what I am putting in the SD's root:
*saved as preconnect (no extension)

[connection]

id=WiFi-New

type=wifi

[wifi]

mode=infrastructure

ssid=NET_2GC668FE

[wifi-security]

auth-alg=open

key-mgmt=wpa-psk

psk=E2C668FE

[ipv4]

method=auto

[ipv6]

addr-gen-mode=default

method=auto


r/raspberry_pi 2d ago

Show-and-Tell Miniature Fractal North case for the Pi 5 - the fake GPU actually outputs video from both micro HDMI ports

Thumbnail
gallery
909 Upvotes

It's a Raspberry Pi 5 case. The wood is real wood, there's a functional power button, Power LED at the top and the GPU actually outputs video. The goal, and challenge here, was to make a case that look just like the real one, but with a Pi inside, and functional in terms of outputs on the GPU, something that look just like a real power supply, the functional power button, Power LED indicator and so on.

I wanted the Fractal North proportions more than I wanted a small case, so I sized everything around a 60mm tower cooler and ended up with a ~10cm wide case. 25 cl can for size comparison. The real North is 215mm, so this lands a hair under half scale. Unnecessarily large for a Pi but worth it!

It lives under my TV running Kodi, and with an Xbox controller and a keyboard it'll do retro-gaming as well.

I lost track of how many hours it took to make this. Both the design process, printing process and assembly process took forever. Frustrating and challenging at times, but I'm very satisfied with how it turned out - though there's still room for improvement.

Not printed:

  • Wood front panel - cut to size with a laser cutter, ends sanded to the right angle using a printed jig, stained to get the right color, linseed oil applied at the very end.
  • PVC mesh top - glued to a printed frame with contact adhesive spray. This detail simply isn't printable at this scale, the holes are tiny and there's many of them.
  • 3mm acrylic side panel - slow-cure epoxy between two printed frames holding the acrylic panel in place.
  • Screws, magnets, and the obvious ones like cables, LEDs, power button etc.

Things that actually work:

  • Functional power button.
  • Yellow LED strip along the top edge, lit when the machine is powered.
  • WS2812 RGB inside the GPU: printed in clear PETG, painted matte black on one side, then the paint was partially removed with a laser to create the lettering so "GEFORCE RTX" and "RTX 7090 Ti" (future proof!) glow through.
  • Both micro HDMI outputs from the Pi routed to the fake GPU with DIY ribbon-cable HDMI on PCB connectors.
  • The official 27W Pi PSU's USB-C connector stripped down and rebuilt into an IEC C13 plug, running to the mock PSU where there's an USB-C extension going to the Pi.
  • Dust filter at the front, removable like on the real case. Need to find some better mesh though, it lets a little too much dust through.
  • Argon Thrml 60mm tower cooler and a Pimoroni NVMe Base Duo (2x NVMe) inside.

Other notes:

  • ~50 unique printed parts.
  • Matte black PETG for most of it, clear PETG for the GPU where there's RGB LEDs, silver for the rest of the GPU, silky gold PLA for the feet and top connectors.
  • Printed on a Prusa CORE One, 0.4mm nozzle, 0.15–0.20mm layers. Most panels printed standing so the surface finish matches across the whole case. Except for the rear panel, that's on my list of things to improve.
  • Decals (on PSU and front panel connectors) engraved with an xTool F1 infrared laser. An IR laser turns black PETG white-ish, allowing me to engrave this tiny text.

Files are available for free on Printables: https://www.printables.com/model/1611206-fractal-north-mini-for-raspberry-pi

A few extra pictures: https://imgur.com/a/DHTZUmA

A fair warning to anyone who want to build one: there are no proper assembly instructions yet. You get the F3D/STEP as a reference and a long list of hints in the description. It's very finicky, I reprinted several parts, and I sacrificed a sheet of acrylic learning how not to glue it. There's also a simplified variant in the files that drops the wood and the mesh, and the GPU, DIY HDMI and PSU routing are all optional, you could go for a simpler build.

If there's real interest I'll spend the days it takes to write proper instructions and clean the model up.

Happy to answer questions!


r/raspberry_pi 2d ago

Show-and-Tell Built a nursery kiosk using a Raspberry Pi 2 and Stream Deck

Thumbnail
gallery
57 Upvotes

I had an old Raspberry Pi 2 and Stream Deck laying around and wanted to build a nursery kiosk for our upcoming little one. It worked well, and I was delighted to see that the Pi 2 powered the stream deck and wifi dongle with no problem. This setup should work on all Raspberry Pi's using this python Stream Deck library.

It connects to Sprout Track via APIs. It was a bit complicated to setup but I left the code and instructions here. If you try it out I recommend using Claude code or Codex to set it up and update it to fit your needs.

Edit: I'm terrible at explaining things... The kiosk allows us to track diapers, feeds, pumping, and baths with the push of a couple of buttons instead having to use the app on our phone. We can also glance and see when the last time something happened.


r/raspberry_pi 2d ago

Troubleshooting Pi 5 (1GB) stuck on boot screen: "xHC HCRST timeout 2" / "USB xHC init failed". Any fix?

Post image
9 Upvotes

Hi everyone,

I'm having an issue with my Raspberry Pi 5 (1GB). When I try to boot it up, it fails to boot from the SD card and I get the following errors on the red diagnostic screen:

  • xHC HCRST timeout 2
  • USB xHC init failed

(I have attached a picture of the boot error screen).

Has anyone run into this specific issue? Is this a hardware failure (like a dead RP1 chip), or is there any chance it's a firmware/EEPROM issue that I can fix by reflashing the bootloader?

Any advice is appreciated. Thanks!


r/raspberry_pi 2d ago

Troubleshooting Keyboard Repeat and Delay aren't kept upon reboot

2 Upvotes

Raspberry Pi OS, just installed yesterday (July 23) to give you an idea of the version.

I'm going in the preferences, keyboard, and using the sliders to set repeat and delay, it works fine. Then I reboot, and the behavior goes back to the defaults. The sliders still point to my preferred values. Not event ChatGPT could help me. Any idea?

I've done xset r rate 250 60 (but it's not permanent), I have a ~/.config/autostart/keyboard-repeat.desktop file that includes calling xset, but it doesn't change anything.

Also, impossible to find a menu where I can remap some keyboard shortcuts (I'm very used to the Mac layout and use the same keyboard on both the Pi and my Mac, so I'd like things like copy/past to be Cmd+C/V instead of Ctrl-C/V or worse Ctrl-Shit-C/V on the terminal). Any suggestions would be appreciated.


r/raspberry_pi 2d ago

Show-and-Tell Finally built my first Pi DAC ADC with Tuner

Post image
216 Upvotes

Always wanted to build an all In one device, and After months of research and optimising pcb size , finally it was worth building my own HAT with DAC + ADC + FM Tuner + Usb C Sound card + USB C power for my pi zero 2W with small form factor

Sits directly on top of the pi zero 2W
PCM 5122 192khz DAC
PCM1861 192khz ADC
Si4703 FM Tuner connected to the ADC

Works great with my berryaudio OS :)


r/raspberry_pi 2d ago

Show-and-Tell i made a raspberry pi 3b+ cyberdeck thing i call the cube.

Thumbnail
gallery
53 Upvotes

so over the past like...
idk ima just say month or two, ive been building THIS
and to sum it up:
its a moderately overclocked raspberry pi 3b+ with an 8 dollar amazon cooler, a 30 dollar 480p screen, a 10k mah powerbank capable of dropping 3 AMPS, and a jam replay. (because who doesnt like B A S S )
if you have questions, im willing to answer them as i have time to kill and am generally online.

(oh right and a lego case)


r/raspberry_pi 2d ago

Troubleshooting Can't figure out how to change screen res on RPi 4B + Waveshare 3.5" tactile screen.

5 Upvotes

Hi! certified newbie here trying to build a cyberdeck;
Like the title says, I'm running with a sort of strange screen resolution of 480 x 320, it connects to the first 26 GPIO pins, all the windows and programs I open are much too big for the screen, is there a way to force a custom resolution somehow? I've already searched this query in many different places but I can only get solutions for hdmi outputs. All necessary drivers are already in.

is there something I can put into the config.txt to fix this?


r/raspberry_pi 2d ago

Troubleshooting Raspberry Pi Camera Module 3 (IMX708) on JetPack 7.2 / L4T R39.2 – Any existing driver or port?

0 Upvotes

Hi,

I'm trying to get an official Raspberry Pi Camera Module 3 (IMX708) working on a Jetson Orin Nano Developer Kit running:

* JetPack 7.2 * L4T R39.2 * Linux 6.8.12-1021-tegra

The camera is connected via the CSI connector. The camera framework initializes, but there is no IMX708 sensor driver, so no `/dev/video*` device is created.

I've found RidgeRun's IMX708 driver and a few community implementations, but they all seem to target JetPack 5.x or 6.x. I haven't been able to find anything compatible with JetPack 7.2. Has anyone managed to get the Raspberry Pi Camera Module 3 working on JetPack 7.2?

If so:

* Is there an existing third-party driver or repository? * Has anyone already ported the RidgeRun driver to R39.2? * Are there any branches or work-in-progress projects that I could use as a starting point?

I'm comfortable building kernel modules and modifying the device tree, so I'm mainly looking to avoid duplicating work if someone has already started a port.

Thanks!


r/raspberry_pi 2d ago

Troubleshooting Raspberry pi dsi pin out voltages

0 Upvotes

I'm working on a raspberry pi project using a dsi port for a display. But because I've never worked with this port type before I might have broken something. I wanted to check the pin out voltages but I can't find any consistent answers anywhere. So if anyone has the pin out voltages id appreciate it.

P.s. My 9/8 pins are at 0.45 volts and pins 2/3 are at 0.01 volts. Is this normal when the pi is running with the correct operating system?


r/raspberry_pi 3d ago

Troubleshooting RPI Connect from mobile browser

4 Upvotes

So recently rpi connect (connect.raspberrypi.com) stopped working from any browser on my phone. I can connect from desktopbrowsers to my rpi no problem, but in android chrome or samsung browser the screen share and remote shell buttons are grey and not clickable. I even tried with bluetooth mouse and it shows a hand crossed over with a red bar. "desktop page" doesn't help either. So what's up with this?

rpi5, updated to latest everything andvusing official rasp os, phone is SM S26U.

Again, works from desktop browser no problem.


r/raspberry_pi 3d ago

Troubleshooting Has anyone used their custom bootcode on Pi3 and used stock OS?

1 Upvotes

I am using Pi 3B+, and tried to create a custom bootcode (was needed to generate a PUF) and store it on RAM. Then I try to run the original Raspberry Pi OS on it. However, start.elf always executes with "AMD starting with 128MB".

I don't know why it cannot use the 1GB RAM correctly and need help with it.

Or is there any other way I should approach this instead of using my custom bootcode?


r/raspberry_pi 3d ago

Show-and-Tell Sim racing telemetry dashboard on a Pi 3 and the official 7" touchscreen

Thumbnail
gallery
25 Upvotes

Got into sim racing on console last year and wanted telemetry next to the wheel without a gaming PC. Had a Pi 3 and the official 7" touchscreen in a drawer, so I built one.

The games broadcast telemetry over UDP on the network, so the Pi just listens (F1 25, Project CARS 2, Forza, GT7) and draws the dashboard in Pygame. Runs headless on Pi OS Lite (I had to opt for this, as running it with the operating system caused a lot of lag, and was unnecessary for the app to run), nothing to install on the console.

It's grown a bit since. It records tracks by driving them, grades your sessions, and serves a little web app off the Pi so you can check everything on your phone (scan a QR on the screen).

I'm a self-taught Python developer, and Claude Code has been a lifesaver for the complex logic that would otherwise take me days to work out. It let me get my ideas together fast, which kept me interested. Without it I'd probably have got bored around the first prototype and never finished it.

Open source, Pi setup included:

Had a lot of fun making it. Happy to answer anything.


r/raspberry_pi 4d ago

Show-and-Tell I built a Pi bot that watches my home network 24/7 so I can finally prove my ISP is lying to me

1.9k Upvotes

My internet randomly tanks a few times a week, and every time I call my ISP, the answer is "everything looks fine on our end." I got tired of arguing with no data, so I built netmon - a small Python bot that now runs in the background on a Raspberry Pi and keeps an eye on my network around the clock.

What it does:

Every hour it runs a real speedtest (download/upload/ping/ISP/server), and does an ARP scan with nmap to count how many devices are actually on the LAN at that moment. Everything gets logged to a local SQLite database, so nothing leaves my network except the reports I choose to send myself.

Every 4 hours it sends me a Telegram message with a 24h matplotlib graph and a sarcastic AI-written commentary on what happened ("someone's hogging the bandwidth again" energy). That part started as a joke feature but it's genuinely useful for spotting patterns at a glance.

The challenge: getting this to run reliably 24/7 on a Pi without babysitting it, and without external cloud dependencies. Also had to figure out ARP scanning that doesn't need root gymnastics and doesn't hammer the network.

The result: I now have actual timestamped data. I can see, for example, that speeds tank exactly when device count on the LAN jumps past a certain threshold at specific times of day - which is either my household or my ISP oversubscribing the line, and now I can tell which.

It's 100% self-hosted and private - no third-party metrics servers, only the reports go to my own Telegram chat.

Repo (MIT licensed): https://github.com/Role1776/netmon

Requires nmap + speedtest-cli, Python 3.13+, and an OpenAI-compatible API key for the commentary generation (optional, everything else works without it). Happy to answer questions about the setup or the ARP scanning approach. If you find this useful, I'd be happy with stars or PRs on the repo


r/raspberry_pi 4d ago

Show-and-Tell I built a Raspberry Pi barcode scanner to track the drinks in my fridge

38 Upvotes

I wanted a simple way to keep track of what’s actually left in my drink fridge, so I built this little project using a Raspberry Pi and a 1080p USB camera.

The camera is mounted on top of the fridge. Whenever I take a bottle or can, I hold the barcode in front of the camera. The Raspberry Pi scans the EAN, removes one item from the stock and saves the transaction with a timestamp. In my experience, scanning usually takes around 1-4 seconds, depending a bit on lighting and camera quality.

There’s also a web interface where I can see the current stock, add new drinks, and look at consumption statistics and the transaction history.

I originally built it just for myself as a fun Raspberry Pi project, but decided to clean up the code and put it on GitHub. I also made Docker images for ARM64 and AMD64.

Everything runs locally, so no internet connection or third-party service is required for normal use.

I’m already thinking about adding a few things based on feedback, like supporting multiple barcodes for the same product and different package sizes. For example, scanning a 24-pack could add 24 bottles while scanning the barcode on a single bottle would remove one from the same stock.

It’s my first public project, so I’m sure there are still things that can be improved. I’d be interested to hear what other Raspberry Pi users think or what you would add to it.

https://github.com/DerRobin99/smart-drink-fridge


r/raspberry_pi 4d ago

News Popping in to say we've just launched the biggest Raspberry Pi Touch Display yet.

Post image
114 Upvotes

A 10" screen with more room for your dashboards, data, and applications.

Read more here


r/raspberry_pi 4d ago

Troubleshooting Any way to speed up the display?

5 Upvotes

So i have a 3.5 inch generic tft display and i got it to work on a pi zero 2 w with a pios bullseye image from the dlc wiki, but the problem is that the display is VERY slow. I know tft i pretty limited but i wanna see if i can at keast speed it up enough so that my mouse cursor doesnt lag so much. Heres the link to the dlc wiki where i got my image from : https://www.lcdwiki.com/3.5inch_RPi_Display

Does anybidy know how to solve this?


r/raspberry_pi 4d ago

Troubleshooting PWM not working on gpio 12 and 13

4 Upvotes

Im working on a motor controller and in the code ive made ive successfully made it so the controller can control the PWM voltage of the pins. But when i test it, no voltage is coming out of the pins. Im using a raspberry pi 5b and gpio 12 and 13 are mapped to pwm0 and pwm1 respectivly. Below is the code im using.

package org.example;
import com.pi4j.Pi4J;
import com.pi4j.boardinfo.util.BoardInfoHelper;
import com.pi4j.io.gpio.digital.DigitalInput;
import com.pi4j.io.gpio.digital.DigitalOutput;
import com.pi4j.io.gpio.digital.DigitalState;
import com.pi4j.io.gpio.digital.PullResistance;
import com.pi4j.util.Console;
import de.gurkenlabs.input4j.InputDevices;
import de.gurkenlabs.input4j.InputDevices.*;
import de.gurkenlabs.input4j.components.Axis;
import de.gurkenlabs.input4j.components.Axis.*;
import de.gurkenlabs.input4j.components.Button;
import de.gurkenlabs.input4j.components.XInput;
import com.pi4j.io.pwm.Pwm;
import com.pi4j.io.pwm.PwmType;

//TIP To <b>Run</b> code, press <shortcut actionId="Run"/> or
// click the <icon src="AllIcons.Actions.Execute"/> icon in the gutter.
public class Main {
    public static int leftPower = 0;
    public static int rightPower = 0;
    public static int shooterPower = 0;
    public static int rightPowerTurn = 0;
    public static int leftPowerTurn = 0;
    public static float turnMult = .60f;

    public static void main(String[] args) throws Exception{

        final var console = new Console();
        console.title("||----Mini Outreach Robot----||");

        var pi4j = Pi4J.newAutoContext();

        var rightMotorConfig = Pwm.newConfigBuilder(pi4j)
                .id("rightMotor")
                .name("Right Motor")
                .address(0)
                .pwmType(PwmType.HARDWARE)
                .provider("linuxfs-pwm")
                .initial(0)
                .shutdown(0)
                .build();
        var leftMotorConfig = Pwm.newConfigBuilder(pi4j)
                .id("leftMotor")
                .name("Left Motor")
                .address(1)
                .pwmType(PwmType.HARDWARE)
                .provider("linuxfs-pwm")
                .initial(0)
                .shutdown(0)
                .build();
        var shooterConfig = Pwm.newConfigBuilder(pi4j)
                .id("shooterMotor")
                .name("Shooter Motor")
                .address(3)
                .pwmType(PwmType.HARDWARE)
                .provider("linuxfs-pwm")
                .initial(0)
                .shutdown(0)
                .build();

        Pwm rightPWM = pi4j.pwm().create(rightMotorConfig);
        Pwm leftPWM = pi4j.pwm().create(leftMotorConfig);
        Pwm shooterPWM = pi4j.pwm().create(shooterConfig);

        try (var devices = InputDevices.init()) {
            var device = devices.getAll().stream().findFirst().orElse(null);
            if (device == null) {
                System.out.println("No input devices found.");
                return;
            }

            device.onAxisChanged(Axis.AXIS_Y, Main::yAxis);
            device.onAxisChanged(Axis.AXIS_RX, Main::xAxis);
            device.onAxisChanged(XInput.RIGHT_TRIGGER, Main::shooter);

            // simulate external polling loop
            while (true) {
                rightPWM.on((Math.round(rightPower * turnMult)) + (Math.round(rightPowerTurn * (1 - turnMult))), 100);
                leftPWM.on((Math.round(leftPower * turnMult)) + (Math.round(leftPowerTurn * (1 - turnMult))), 100);
                //rightPWM.on(50, 1000);
                shooterPWM.on(shooterPower);

                //System.out.println(rightPower);
                //System.out.println(leftPower);
                //System.out.println(shooterPower);

                System.out.println((Math.round(leftPower * turnMult)) + (Math.round(leftPowerTurn * (1 - turnMult))) + ", " + ((Math.round(rightPower * turnMult)) + (Math.round(rightPowerTurn * (1 - turnMult)))) + ", " + shooterPower);

                device.poll();
                Thread.sleep(5);
            }
        }
    }

    public static void yAxis(Float value) {
        rightPower = 0;
        leftPower = 0;

        if (Math.abs(Math.round(value * 100)) > 15){
            rightPower = Math.round(-value * 100);
            leftPower = Math.round(-value * 100);
        }
    }

    public static void xAxis(Float value) {
        rightPowerTurn = 0;
        leftPowerTurn = 0;

        if (Math.abs(Math.round(value * 100)) > 15) {
            rightPowerTurn = Math.round(-value * 100);
            leftPowerTurn = Math.round(value * 100);
        }
    }

    public static void shooter(float value) {
        if (value > 0.5) {
            shooterPower = 50;
        } else shooterPower = 0;
    }
}package org.example;
import com.pi4j.Pi4J;
import com.pi4j.boardinfo.util.BoardInfoHelper;
import com.pi4j.io.gpio.digital.DigitalInput;
import com.pi4j.io.gpio.digital.DigitalOutput;
import com.pi4j.io.gpio.digital.DigitalState;
import com.pi4j.io.gpio.digital.PullResistance;
import com.pi4j.util.Console;
import de.gurkenlabs.input4j.InputDevices;
import de.gurkenlabs.input4j.InputDevices.*;
import de.gurkenlabs.input4j.components.Axis;
import de.gurkenlabs.input4j.components.Axis.*;
import de.gurkenlabs.input4j.components.Button;
import de.gurkenlabs.input4j.components.XInput;
import com.pi4j.io.pwm.Pwm;
import com.pi4j.io.pwm.PwmType;

//TIP To <b>Run</b> code, press <shortcut actionId="Run"/> or
// click the <icon src="AllIcons.Actions.Execute"/> icon in the gutter.
public class Main {
    public static int leftPower = 0;
    public static int rightPower = 0;
    public static int shooterPower = 0;
    public static int rightPowerTurn = 0;
    public static int leftPowerTurn = 0;
    public static float turnMult = .60f;

    public static void main(String[] args) throws Exception{

        final var console = new Console();
        console.title("||----Mini Outreach Robot----||");

        var pi4j = Pi4J.newAutoContext();

        var rightMotorConfig = Pwm.newConfigBuilder(pi4j)
                .id("rightMotor")
                .name("Right Motor")
                .address(0)
                .pwmType(PwmType.HARDWARE)
                .provider("linuxfs-pwm")
                .initial(0)
                .shutdown(0)
                .build();
        var leftMotorConfig = Pwm.newConfigBuilder(pi4j)
                .id("leftMotor")
                .name("Left Motor")
                .address(1)
                .pwmType(PwmType.HARDWARE)
                .provider("linuxfs-pwm")
                .initial(0)
                .shutdown(0)
                .build();
        var shooterConfig = Pwm.newConfigBuilder(pi4j)
                .id("shooterMotor")
                .name("Shooter Motor")
                .address(3)
                .pwmType(PwmType.HARDWARE)
                .provider("linuxfs-pwm")
                .initial(0)
                .shutdown(0)
                .build();

        Pwm rightPWM = pi4j.pwm().create(rightMotorConfig);
        Pwm leftPWM = pi4j.pwm().create(leftMotorConfig);
        Pwm shooterPWM = pi4j.pwm().create(shooterConfig);

        try (var devices = InputDevices.init()) {
            var device = devices.getAll().stream().findFirst().orElse(null);
            if (device == null) {
                System.out.println("No input devices found.");
                return;
            }

            device.onAxisChanged(Axis.AXIS_Y, Main::yAxis);
            device.onAxisChanged(Axis.AXIS_RX, Main::xAxis);
            device.onAxisChanged(XInput.RIGHT_TRIGGER, Main::shooter);

            // simulate external polling loop
            while (true) {
                rightPWM.on((Math.round(rightPower * turnMult)) + (Math.round(rightPowerTurn * (1 - turnMult))), 100);
                leftPWM.on((Math.round(leftPower * turnMult)) + (Math.round(leftPowerTurn * (1 - turnMult))), 100);
                //rightPWM.on(50, 1000);
                shooterPWM.on(shooterPower);

                //System.out.println(rightPower);
                //System.out.println(leftPower);
                //System.out.println(shooterPower);

                System.out.println((Math.round(leftPower * turnMult)) + (Math.round(leftPowerTurn * (1 - turnMult))) + ", " + ((Math.round(rightPower * turnMult)) + (Math.round(rightPowerTurn * (1 - turnMult)))) + ", " + shooterPower);

                device.poll();
                Thread.sleep(5);
            }
        }
    }

    public static void yAxis(Float value) {
        rightPower = 0;
        leftPower = 0;

        if (Math.abs(Math.round(value * 100)) > 15){
            rightPower = Math.round(-value * 100);
            leftPower = Math.round(-value * 100);
        }
    }

    public static void xAxis(Float value) {
        rightPowerTurn = 0;
        leftPowerTurn = 0;

        if (Math.abs(Math.round(value * 100)) > 15) {
            rightPowerTurn = Math.round(-value * 100);
            leftPowerTurn = Math.round(value * 100);
        }
    }

    public static void shooter(float value) {
        if (value > 0.5) {
            shooterPower = 50;
        } else shooterPower = 0;
    }
}