General out signal on IO_3 on Movement-Done Commands
-
Hi everyone,
I'm working on modifying RepRapFirmware (RRF) for Duet3D and need some guidance. I want to trigger a pulse on the IO_3 pin every time a movement command (G0/G1) is executed. Does someone know how to proceed or which file do I have to modify?
Thank you so much in advance
-
@afs_uniovi before you modify the firmware, does it need to be both G0 and G1 moves or could it be just G1? Are you using an extruder in this system? If not then you could setup a virtual extruder, include it in all moves, then use
https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m571-set-output-on-extrude
potentially?What is your usecase for sending a pulse per move?
-
@T3P3Tony No, unfortunately, that option is not valid..
Perhaps my explanation was not very clear, but what I need is that for every single movement made by any of the motors being controlled, a logical "1" signal is generated exactly when that movement has finished, and then it must return to "0". The idea is to capture this signal with another data acquisition board to which various sensors are connected.Thank you so much by the way
-
what I need is that for every single movement made by any of the motors being controlled, a logical "1" signal is generated exactly when that movement has finished, and then it must return to "0".
Without context, i.e. without relating the event to a specific command, your data acquisition is no more than a platonic exercise. Maybe your goal is to develop and test this ”data acquisition board“, but to obtain meaningful data, you should simply control the Duet by setting up a HTTP client https://github.com/Duet3D/RepRapFirmware/wiki/HTTP-requests#get-rr_gcode. By this, you could even observe RRF’s object model.
Does someone know how to proceed or which file do I have to modify?
RRF is Open Source, so feel free to study the code at GitHub. But beware: RRF is a very sophisticated piece of art, so you should have more than just some basic knowledge of C/C++.