adxl345 usb

Hi there, i am trying to connect the adxl345 fly which is only usb, no pins. Anyone please can help me out?
65 Replies
blacksmithforlife
what error are you getting? You should just plug in USB and flash it using the configurator
3dRig
3dRigOP10mo ago
Hi there, well my rpi(3a) dont have extra usb port to connect the adxl so i ordered a usb hub to coonect it on my rpi. Also some people told me that i dont need to do the sudo thinging and instead ratos recognises the adxl by itsrlf, is that right?
miklschmidt
miklschmidt10mo ago
Not with a usb adxl345... Those things a basically a controlboard in themselves, RatOS doesn't natively support any of them, so you will have to go through the same steps as on every other klipper installation. They're also almost as much as an actual toolboard and you have to edit your config twice everytime you need to use them, i don't really understand the point of them. RatOS is set up for plain adxl345 boards wired via SPI like you can see in every single wiring diagram in the documentation.
blacksmithforlife
and for ADXL integrated into toolboards
miklschmidt
miklschmidt10mo ago
Yes! Not to forget 🙂
3dRig
3dRigOP10mo ago
Ok then, i have and the regular one, so i might use that one instead then
3dRig
3dRigOP10mo ago
No description
JaminCollins
JaminCollins10mo ago
they all work fine, just a question of what you have to go through to get them working
3dRig
3dRigOP10mo ago
Hi, so i decided to go with the usb adxl, so with that said i need to go through the sudo procedure? With putty software?
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
Also, i wroye these in overrifes, printer.cfg Am using vminion Instead of 100,100,20 i wrote 90,90,20
miklschmidt
miklschmidt10mo ago
not clear what you mean by "sudo procedure". You need to go and find the mcu serial for your device, ie: ls -la /dev/serial/by-id/, then configure it like i wrote in the other threads https://discord.com/channels/582187371529764864/1201204025375330365/1201997374503780385
3dRig
3dRigOP10mo ago
Ok i see So to find my serial i need to tyoe--> ls /dev/serial/by-id/* Correct?
miklschmidt
miklschmidt10mo ago
and then identify the correct one, yes this should be in the manual for whaver USB adxl controller you bought Just follow that for configuration Also i'm not sure you've read the threads i posted. The outlines of what to do and avoid are here: https://discord.com/channels/582187371529764864/859890291591217162/1162058029496283208
3dRig
3dRigOP10mo ago
Thanks, i will read everything you mentioned, and come back Ok, do i did some progress, when i ve been through the threads you send i see that people use adxlmcu.cfg, do i need to do a cfg file like this as well? Any guidencd somewhere? Or something to do that?
miklschmidt
miklschmidt10mo ago
Makes it easy to comment out, but no it's not required. The configuration in the picture you posted in your other thread is wrong, seems you haven't done the steps i outlined here https://discord.com/channels/582187371529764864/859890291591217162/1162058029496283208, nor the documentation for your particular adxl345 usb device. And this https://discord.com/channels/582187371529764864/1203404115808354377/1203404115808354377 is just a continuation of this thread, so i'm gonna lock and close that.
Discord
Discord - A New Way to Chat with Friends & Communities
Discord is the easiest way to communicate over voice, video, and text. Chat, hang out, and stay close with your friends and communities.
miklschmidt
miklschmidt10mo ago
If you want further support i'm gonna need a link to the device you've purchased and your printer.cfg
3dRig
3dRigOP10mo ago
Thanks for your reply, yes close that thread, it was before i start to understand how it works, i fixed that problem and deleted everything what i wrote for adxl Am gonna send you now the link of the device, about the printer.cfg i will upload tomorrow morning, its night here and am not on the computer right now Just found this amazing item on AliExpress. Check it out! €15.54 15%OFF | Mellow Fly-ADXL345 Accelerometer USB Board For Klipper Gemini Rspberry Pi Voron V0.1 2.4 Vzbot HevORT Ender 3 3D Printer Parts https://a.aliexpress.com/_onhmItk
miklschmidt
miklschmidt10mo ago
Aight, so this is what you want in the user overrides of your printer.cfg
[mcu usbadxl]
serial: /dev/serial/by-id/usb-Klipper_rp2040_XXXXXXXXXXXXXXXXXXXXX
### replace the above with the serial you find via:ls -l /dev/serial/by-id/

[adxl345 usbadxl]
cs_pin: usbadxl:gpio9
spi_software_sclk_pin: usbadxl:gpio10
spi_software_mosi_pin: usbadxl:gpio11
spi_software_miso_pin: usbadxl:gpio12

[resonance_tester]
accel_chip: adxl345 usbadxl
[mcu usbadxl]
serial: /dev/serial/by-id/usb-Klipper_rp2040_XXXXXXXXXXXXXXXXXXXXX
### replace the above with the serial you find via:ls -l /dev/serial/by-id/

[adxl345 usbadxl]
cs_pin: usbadxl:gpio9
spi_software_sclk_pin: usbadxl:gpio10
spi_software_mosi_pin: usbadxl:gpio11
spi_software_miso_pin: usbadxl:gpio12

[resonance_tester]
accel_chip: adxl345 usbadxl
That's it, provided you set the right serial path, you can query it via ACCELEROMETER_QUERY CHIP="usbadxl" and MEASURE_AXES_NOISE CHIP="usbadxl", and use the input shaper macros. to get the serial, open your command promp (win+r, type cmd, hit enter):
ls -la /dev/serial/by-id
ls -la /dev/serial/by-id
password is raspberry Look for the line that has usb-Klipper_rp2040 in the name, copy it and replace the serial parameter under [mcu usbadxl] in the config.
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
it doesnt recognize it for a reason but what we are looking for i found it on putty software
blacksmithforlife
you need to use the IP address instead of ratos.local it gave you the error "no such host is known"
3dRig
3dRigOP10mo ago
oh ok i will try now
blacksmithforlife
ssh pi@<your ip address here> so like ssh [email protected] for example
3dRig
3dRigOP10mo ago
am in now
blacksmithforlife
Now you can use ls ls -la /dev/serial/by-id
3dRig
3dRigOP10mo ago
yes ok i got the id i copy paste all the above and replaced my id i still get errors
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
am uploading my printer.cfg as well
3dRig
3dRigOP10mo ago
blacksmithforlife
line 328 - change from accel_chip: usbadxl345 to accel_chip: usbadxl
3dRig
3dRigOP10mo ago
No description
blacksmithforlife
/dev/serial/by-id/usb-Klipper_rp2040_E6625887D3664932-if00
sounds like this is probably incorrect
3dRig
3dRigOP10mo ago
Ok so, the accel_chip: usbadxl fixed the previous problem Is it any chance the flashing of the adxl i did to be incorrect? Or no?
blacksmithforlife
¯\_(ツ)_/¯ how did you flash it?
3dRig
3dRigOP10mo ago
According the instructions, ok then i will try it again to reflash, now we know that printer.cfg is alright so am focusing on reflashing and the id
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
i get this error now
3dRig
3dRigOP10mo ago
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
If i change the 328 line to adxl345 it seems to connect
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
When i try to use it its an error with the id
blacksmithforlife
you have to specify the toolboard, otherwise it defaults to the main MCU (octopus)
3dRig
3dRigOP10mo ago
Okay, where do i do that? Printer.cfg toolboard?
blacksmithforlife
no, in the command. As Mikel pointed out earlier ACCELEROMETER_QUERY CHIP="usbadxl"
3dRig
3dRigOP10mo ago
Ooohh i missed that, sorry
blacksmithforlife
so anytime you are doing a command with the adxl, you have to specify your toolboard one using the CHIP="usbadxl"
3dRig
3dRigOP10mo ago
another question about my id
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
i am using number 1 whats number 2 ? do i need to use that one too ?
blacksmithforlife
In linux there is this idea of a symbolic link. Meaning that a "file" just points to another file. In this case the file "usb-Klipper_rp2040_E6625887D3664932-if00" points to "/dev/ttyACM0" but to answer your question, no, you don't also need "/dev/ttyACM0"
3dRig
3dRigOP10mo ago
ok, so the id looks correct when i run ACCELEROMETER_QUERY CHIP="usbadxl" i get some values what should i do with those values ? if its giving me those values it means that everything work ok right? i mean it communicates as it should
blacksmithforlife
yeah, it is working. Now you use the ADXL - you probably want to use the macros GENERATE_SHAPER_GRAPHS and MEASURE_COREXY_BELT_TENSION
miklschmidt
miklschmidt10mo ago
it needs to be “adxl345 usbadxl”
3dRig
3dRigOP10mo ago
the accel_chip ? accel_chip: adxl345 usbadxl like this?
miklschmidt
miklschmidt10mo ago
Yes
3dRig
3dRigOP10mo ago
awesome seems to work i just run the GENERATE_SHAPER_GRAPHS so what now? py ratrig is the vminion the adxl i mounted it above hotend
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
also where do i find the graphs that are generated just now ? Resonances data written to /tmp/resonances_y_20240204_181557.csv file where is this location ? i found them
3dRig
3dRigOP10mo ago
No description
No description
3dRig
3dRigOP10mo ago
No description
3dRig
3dRigOP10mo ago
i want to thank you gentlemen for all your help, i really appreciate it, it seems to work just fine now, thank you so much
Want results from more Discord servers?
Add your server