#MCU 'rpi' error during config: Unable to open spi device

110 messages Β· Page 1 of 1 (latest)

eager bough
#

trying to get 2x adxl345 running on rapberypi 3b but get error MCU 'rpi' error during config: Unable to open spi device ,spi driver enabled

eager bough
eager bough
#

is there a developer that can look in my logs πŸ₯°

warm stag
#

Nope as we are mainsail, and not Klipper or rPI Foundation.And by the way your tags are writing that is purely a Klipper setup issue.

#

It is also very hard to check as you did not link the source of your guide you used

eager bough
#

since mainsail gives a error i tagged it mainsail, the klipper tag was wrong sorry about that

warm stag
#

Mainsail is always the deliverer of all messages. So please shoot the sender not the deliverer πŸ˜‰

eager bough
#

but there is no klipper discord?

lost steppe
eager bough
#

😫

lost steppe
#

thx for fixing the tag

eager bough
#

totaly lost with linux realy

#

no probs

#

meteyou the above pictures i dont get i ask in config to open spi5-1cs and spi6-1cs but the only ports that are open are spidev0.0 and spidev0.1 iam sorry to ask you guys this but otherwise i will never get this fixed

#

dont get the parameter dtparam=spi=on must it be on the work or does it need to be dtparam=spi=off

lost steppe
#

i can check it, when i'm at home. i have done the same think for 2-3 weeks and i think a have some docs about this...

eager bough
#

thank you meteyou really appreciate it

#

how can i check on what code iam on like the guy tells in the txt?

warm stag
#

open Mainsail -> System Tab -> there you see your linux mcu and the klipper version when you build it

eager bough
#

now the question is am i using old mcu code before 21/9/22 or after

#

if before i need to use symlinks if after i dont need symlinks

warm stag
#

I do not see your Linux mcu at all

#

Do not sounder mine is dirty as I have test code in my repo

eager bough
#

v0.10.0-620-g11dd273b

warm stag
#

ok as this is a task of minutes do the following

#

ssh in the PI

#
make clean
make menuconfig```
#

select linux as microcontroler all other options default. Quite and save

#

make flash

#

and then we are sure you have the latest version

eager bough
#

thx alexz i think it update to the newest now Version: v0.11.0-87-g0407c24c

warm stag
#

you can see that number but now it should be latest

eager bough
#

in mainsailos it is still stated as version v0.10.0-620-g11dd273b

#

i rebooted the rpi after the make flash command..

warm stag
#

Make an force refresh of your browser

eager bough
#

i did that also back restarted the pi but under host there is no version stated as before

#

Build file /home/pi/klipper/klippy/../out/klipper.dict(9212): Mon Jan 30 17:57:30 2023
Last MCU build version: v0.11.0-87-g0407c24c
Last MCU build tools: gcc: (Raspbian 8.3.0-6+rpi1) 8.3.0 binutils: (GNU Binutils for Raspbian) 2.31.1
Last MCU build config: ADC_MAX=4095 CLOCK_FREQ=50000000 MCU=linux PCA9685_MAX=4096 PWM_MAX=32768 STATS_SUMSQ_BASE=256
Build file /home/pi/klipper/klippy/../out/klipper.elf(582512): Mon Jan 30 17:57:43 2023

warm stag
#

You are in shutdown but yes know you are on latest

eager bough
#

ok then now i know that i dont need symlinks

#

still spi0 c1 and spi0 c0 showing in gpioinfo

#

this is whats in boot/config.txt

warm stag
#

I did not read it yet, still not at home

eager bough
#

😘 no problem realy thank you for trying to help even when its a klipper thing, looking forward to your replaiy when you looked at it

warm stag
#

The description is for a pi4

eager bough
#

the pi3b v2 has the same gpio

warm stag
#

You have spi=on in there 2 times

eager bough
#

ok i will remove one

warm stag
#

No pi3 here to text it myself

eager bough
#

i removed spi=on still same output

warm stag
#

Γ„hnlich

dtoverlay=spi5-1cs
dtoverlay=spi6-1cs```
#

Compare it to your until you find the difference πŸ˜‰

#

Spoiler look at the first line of the 3

eager bough
#

dtparam=spi=off results in above

warm stag
#

ls /dev/*spi*

#

But on results in (pi4)

eager bough
#

is i2c arm on also needed for only spi

warm stag
#

No normally not

eager bough
#

ok then the symlink way

#

can you tell me how i can do that ?

warm stag
#

Nope but why do you not simple use spi0 and1

eager bough
#

if i use like you say can i still connect like this below

#

this is how it is wired now

warm stag
#

Yes he is taking about an pi4 and I showed you that it is working on a pi4

#

I have no pi3 laying around here so I can not crosscheck

eager bough
#

πŸ˜‰

#

do a pinout on your rpi4

#

what can be a problem is the bluetooth on my 3b v1.2

#

On the Raspberry Pi Model 3B the hardware-based serial/UART device /dev/ttyAMA0 has been re-purposed to communicate with the the built-in Bluetooth modem and is no longer mapped to the serial RX/TX pins on the GPIO header. Instead, a new serial port "/dev/ttyS0" has been provided which is implemented with a software-based UART (miniUART). This software-based UART ("/dev/ttyS0") does not support PARITY and some have experienced some stability issues using this port at higher speeds. If you don't need Bluetooth functionality, you can disable the BT modem and configure the RPi to use a device-tree overlay to re-map the hardware-based serial UART ("/dev/ttyAMA0") back to the GPIO header pins for TX/RX. See the instructions on this page for details on how to configure the device-tree overlay and disable the bluetooth modem/service:

warm stag
#

UART != SPI

#

Yes both share a 40 pin connector but that does not mean you have the same capabilities on the bus side

eager bough
#

@lost steppe do you maybe have a idea before i give up?

eager bough
#

Raspberry Pi Zero, 1, 2 and 3 have three SPI controllers:

SPI0, with two hardware chip selects, is available on the header of all Raspberry Pis; there is also an alternate mapping that is only available on Compute Modules.

SPI1, with three hardware chip selects, is available on all Raspberry Pi models except the original Raspberry Pi 1 Model A and Model B.

SPI2, also with three hardware chip selects, is only available on Compute Module 1, 3 and 3+.

On the Raspberry Pi 4, 400 and Compute Module 4 there are four additional SPI buses: SPI3 to SPI6, each with 2 hardware chip selects. These extra SPI buses are available via alternate function assignments on certain GPIO pins - see the BCM2711 ARM Peripherals datasheet.

Chapter 10 in the BCM2835 ARM Peripherals datasheet describes the main controller. Chapter 2.3 describes the auxiliary controller.

#

raspi3 only has spi0 spi1 spi2

#

rasp4 has spi3 to spi6

eager bough
#

my mcu is on v0.10 and mcu rpi is on v0.11 is this normal alexz

warm stag
#

Yes we only updated the Linux mcu and not you physical printer board

#

They can have different versions

#

So that means you can not activate 5 and 6

eager bough
#

Error on 'ACCELEROMETER_QUERY': missing CHIP

#

i only conected 1 chip

eager bough
#

also found this post to

#

There is were no SPI2 to SPI6 interfaces before the Raspberry 4 (and Compute Module). So one should not be surprised if the installation of any of these fail on a Raspberry Pi 3 B or earlier model.

eager bough
#

discord of klipper is a mess pfff they dont have a separet support section 😩

eager bough
#

@warm stag thx for your help my problem is fix 😘

#

may i ask 1 thing from februari the printer.cfg needs the load bed mesh command but iam unsure if this command is right in my cfg file

#

why is it red and will it work this way ?