So I have my RPi Zero 2 connected to my printer board directly via uart (uart 3 on atmega2560 and uart 0 on rpi). I have used this for some time with octoprint and marlin and it was working. I know that the default bootloader doesn’t support uploading firmware on uart 3 so I have tried to flash it with optiboot set to uart 3. Then I tried setting up klipper but I just can’t get it to connect. Even avrdude can’t upload to it. I tried so many things but nothing worked so I would be happy if somebody would help me. There was one time that I was able to upload to it and then connect to it but then I connected the screen to the mcu (was disconnected becouse I needed access to the spi so I can upload the bootloader) and connected relays for psu control and now it can’t connect again (maybe its becouse I just restarted it and isn’t connected with the screen or relays). I tried reflashing the atmega2560 with bootloader again and then flashing it with klipper but it just doesn’t communicate.
My issue 2 - Solved:
I want to set my BLTouch sensor pin to the same pin as z-min but it does’t let me do that.
I was able to connect to it once after I installed relays for psu controll but then I turned it off with those relays and I can’t upload or connect to it again I don’t get it. I have tried reflashing the bootloader with uspasp again and I can’t just connect to it with the RPi. Someone please help this is nightmare.
I think that the problem has to be on the rpi side not with the printer board.
The communication was working until I removed octoprint and put klipper with mainsail and moonraker on it. There is something wrong with the serial. I was using /dev/ttyS0 before but now I can only /dev/ttyAMA0 becouse it changed it to serial1:
lrwxrwxrwx 1 root root 7 Sep 26 17:49 /dev/serial0 → ttyAMA0
lrwxrwxrwx 1 root root 5 Sep 26 17:49 /dev/serial1 → ttyS0