2.05.21
Lilscan looks promising, especially since I don't like ready-made solutions - the brain could be employed too.
https://lilscan.com
The project is in the testing stage and is based on the cooperation of Raspberry Pi 4, Pi CAM V2 NoIr module and 5W linear laser
8.05.21
I joined the beta tester team.
https://lilscan.com/docs/
for self-education :
* https://github.com/lilscan
* https://klipper.discourse.group/t/macro-creation-tutorial/30/2
* https://github.com/KevinOConnor/klipper/pull/2173/files
* https://grpc.io/docs/what-is-grpc/introduction/
* https://developers.google.com/protocol-buffers/docs/overview
==========================================
Plan (whether materializes ?)
Lilscan (Pi4 + cam + laser module).
I use a 3D printer (Klipper) to move the Object.
In the Printer.cfg file, the macro determines the kinematics of the object's and/or Lilscan module movement.
Klipper macro GCode (Module shell_command.py) launches prog. lilscan.py.
The octoprint / klipper host (PI3) runs a gRPC service that synchronizes Lilscan scanning and Object movement.
[gcode_macro scan_start]
gcode:
{% set x_s = 10 %} # set x startpoint
{% set y_s = 50 %} # set y startpoint
{% set z_s = 10 %} # set z startpoint
{% if printer.toolhead.homed_axes != "xyz" %}
G28
{% endif %}
G90 #absolut pos
G0 X{x_s} Y{y_s} Z{z_s} # go to Run position
M118 INSERT OBJECT ! # Insert scanning object !
M118 Run macro SCAN_RUN ! # run next macro !
[gcode_macro scan_run]
gcode:
{% set scan_max = 21 %} # set scan lenght
{% set scan_step = 5 %} # set scan step lenght mm
{% set r = scan_max // scan_step %} # set scan steps
{% for x in range(0,r,1) %}
G91
G0 Y-{scan_step}
M400
G4 P2000
RUN_SHELL_COMMAND CMD=lilscan_run
M400
{% endfor %}
[gcode_shell_command lilscan_run]
command: python /home/pi/scripts/lilscan.py
#timeout: 2.
#verbose: True
06.06.21The pieces are together ... the result is there: it is possible to get a 2D profile.
PI camera image freezes sometimes?
Controlling the operation of the scanner via the gRPC interface is initially a fuzzy dream ...