Jump to content

Manta M8P ADXL345 SPI1 Issues


NiLMoXiE

Recommended Posts

Has anyone managed to get an ADXL345 working on SPI1 on the Manta M8P?

I have set the adxl345 in the printer.cfg in Klipper and connected the the sensor as below but the MCU crashes on boot and reports that it cannot connect to moonraker.

[adxl345]

spi_bus: spi1

cs_pin: PB15

ADXL345 is wired as below:

SCL – PA5 SCK

SDA – PA7 MOSI

SDO – PA6 MISO

CS – PB15

VCC – 3.3V

GND – GND

In this state the ls /dev/serial/by id/ returns a no such device or folder exists.

If I disconnect the ADXL345 from the board it boots with no issues.

Can anyone shed any light on this at all?

Edited by NiLMoXiE
Spelling
Link to comment
Share on other sites

  • NiLMoXiE changed the title to Manta M8P ADXL345 SPI1 Issues
  • 2 weeks later...

Here's how I got it working on my Manta M4P. The cs_pin for the M8P may be different. I wired the M4P SPI1 connector directly to the ADXL345 board using a 6-wire cable. What helped was looking at the actual schematic for the board, which has the signal names on the SPI1 (J58) connector.

In /boot/BoardEnv.txt make sure you have the spidev1.1 overlay enabled.

printer.crt:

[adxl345]
cs_pin: PD9
spi_bus: spi1

Wiring of the SPI1 connector to the ADXL345:

SPI1 (J58) Pins 1 & 2: Unconnected

SPI1 (J58) Pin 3 -> ADXL345 CS

SPI1 (J58) Pin 4 -> ADXL345 SCL

SPI1 (J58) Pin 5 -> ADXL345 SDA

SPI1 (J58) Pin 6 -> ADXL345 SDO

SPI1 (J58) Pin 7 (3V3) -> ADXL345 VCC

SPI1 (J58) Pin 8 -> ADXL345 GND

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...