Accelerometer Usage
-
@dc42 said in Accelerometer Usage:
@staticred did you get the accelerometer working?
so i redo the howl wiring, and its pretty secure now on the board. At first it was pretty bad, but now its solid. I now used P100 instead of P0, but still getting accelerometer not found. All cables are connected as meant above.
-
@staticred Sorry meant i used P0 for the accelerometer and gcode.
-
@staticred can you confirm that you do not have a PanelDue connected? The PanelDue port is shared with IO0.
-
@dc42 Sure nothing else is connected to the board. Just the normal stuff like fans motors heaters
-
@dc42 okay so i rechecked every wire, seems to be all fine. I think its just something about wrong gcode, nothing more.
Maybe my config.g can help? https://just-paste.it/SqW7DwJd1j
GCode im using just to try the accelerometer
M956 P0 S1000 A0
-
@staticred
If you pasteM955 P0 C"io0.out+io0.in"
to the DWC gcode input box, what is the replied message?
-
@diy-o-sphere Error: M955: Accelerometer not found on specified port
-
@staticred https://imgur.com/a/p3jq7Oh this is how i hooked it up
-
I remember that I also had strange readings in the beginning, but the sensor still worked and was found with the M955 command. I have also plugged it to Io0. But I have connected all wires to the paneldue port.
-
@staticred
That is my wiring -
This post is deleted! -
@diy-o-sphere Thanks a lot man, i will try it out. I have another version of the Lis3DH sensor, stemm qt. It just has 2 ports on the side, not sure if it will effect anything, but i dont think so.
-
Sorry, had to delete my previous post. Now I noticed that you have connected the wires to the temp dautherboard. That looks right to me.
-
@diy-o-sphere Ok it now it works,
Accelerometer 0:0 with orientation 20 samples at 1344Hz with 10-bit resolution
It worked until i tried to run a test. Then DWC timed out, and now im getting no connection anymore. Same wiring. Really weird.
-
@staticred said in Accelerometer Usage:
@diy-o-sphere Ok it now it works,
Accelerometer 0:0 with orientation 20 samples at 1344Hz with 10-bit resolution
It worked until i tried to run a test. Then DWC timed out, and now im getting no connection anymore. Same wiring. Really weird.
That suggests that something is wrong with the interrupt input. Check the connection between INT0 on the LIS3DH and io0.in, and perhaps try using a different IO port.
-
@dc42 Nope no chance. I wired it to io1. Same thing. I tested all connections with a multimeter and they work. But sadly my board cant build up a connection to the accelerometer. Is there something like a debug mode, which may teaches me more about what exactly the problem is?
-
@staticred seems like it still did record some data at some point.
But it does not make sense that that is the z axis. Because the board is mounted flat on the toolhead. Really strange
-
@staticred I will re-test accelerometer with Duet 3 Mini later today or tomorrow.
What did the raw data look like, before you clicked Analyse?
-
@dc42 Thank you alot!
This is what the raw data looked like -
@staticred the raw data looks OK except for the spikes and drops, assuming that you collected that data while the machine was stationary. My guess is that those spikes/drops were where the firmware was unable to extract the data from the accelerometer fast enough. You can check this by looking at the end of the .csv file to see if there is a message about this. I think the DWC accelerometer plugin may report it too. See the notes at https://duet3d.dozuki.com/Wiki/Accelerometers#Section_Retrieving_the_data to see what you can do about it; or just try re-running it a few times to see if you can get a clean run.
The analysis isn't valid if the data contains dropouts. To get a useful analysis you need to do a suitable move while the data is being collected as described at https://duet3d.dozuki.com/Wiki/Accelerometers#Section_Using_accelerometers.