Skip to content

Commit

Permalink
qtdragon_next -add initial codebase from Jim's qtdragon github
Browse files Browse the repository at this point in the history
qtdragon_next is a temporay name.
adjust some locations of files and imports to use linuxcnc versions of library files
Modify facing and hole_enlarge to load with extra arguments
  • Loading branch information
c-morley committed Oct 17, 2023
1 parent 3d46b0d commit 89c6c0b
Show file tree
Hide file tree
Showing 223 changed files with 45,257 additions and 2 deletions.
11 changes: 11 additions & 0 deletions configs/sim/qtdragon_next/qtdragon_next_xyz/README
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
QtDragonHD sample configs

Fantastic large screen for mills/routers designed by forum personality Persei.
Optional choice of basic or versa probe screens.
Optional laser sight control
Optional toolplate Z setting
Optional auto lift spindle at pause
bolt circle and basic facing wizards



64 changes: 64 additions & 0 deletions configs/sim/qtdragon_next/qtdragon_next_xyz/core_sim_XYZAB.hal
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# core HAL config file for simulation

# first load all the RT modules that will be needed
# kinematics
loadrt [KINS]KINEMATICS
#autoconverted trivkins
# motion controller, get name and thread periods from ini file
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
# load 6 differentiators (for velocity and accel signals
loadrt ddt names=ddt_x,ddt_xv,ddt_y,ddt_yv,ddt_z,ddt_zv
# load additional blocks
loadrt hypot names=vel_xy,vel_xyz

# add motion controller functions to servo thread
addf motion-command-handler servo-thread
addf motion-controller servo-thread
# link the differentiator functions into the code
addf ddt_x servo-thread
addf ddt_xv servo-thread
addf ddt_y servo-thread
addf ddt_yv servo-thread
addf ddt_z servo-thread
addf ddt_zv servo-thread
addf vel_xy servo-thread
addf vel_xyz servo-thread

# create HAL signals for position commands from motion module
# loop position commands back to motion module feedback
net Xpos joint.0.motor-pos-cmd => joint.0.motor-pos-fb ddt_x.in
net Ypos joint.1.motor-pos-cmd => joint.1.motor-pos-fb ddt_y.in
net Zpos joint.2.motor-pos-cmd => joint.2.motor-pos-fb ddt_z.in
net Apos joint.3.motor-pos-cmd => joint.3.motor-pos-fb
net Bpos joint.4.motor-pos-cmd => joint.4.motor-pos-fb
#net Cpos joint.5.motor-pos-cmd => joint.5.motor-pos-fb
#net Upos joint.6.motor-pos-cmd => joint.6.motor-pos-fb
#net Vpos joint.7.motor-pos-cmd => joint.7.motor-pos-fb
#net Wpos joint.8.motor-pos-cmd => joint.8.motor-pos-fb

# send the position commands thru differentiators to
# generate velocity and accel signals
net Xvel ddt_x.out => ddt_xv.in vel_xy.in0
net Xacc <= ddt_xv.out
net Yvel ddt_y.out => ddt_yv.in vel_xy.in1
net Yacc <= ddt_yv.out
net Zvel ddt_z.out => ddt_zv.in vel_xyz.in0
net Zacc <= ddt_zv.out

# Cartesian 2- and 3-axis velocities
net XYvel vel_xy.out => vel_xyz.in1
net XYZvel <= vel_xyz.out

# estop loopback
net estop-loop iocontrol.0.user-enable-out iocontrol.0.emc-enable-in

# create signals for tool loading loopback
net tool-prep-loop iocontrol.0.tool-prepare iocontrol.0.tool-prepared
net tool-change-loop iocontrol.0.tool-change iocontrol.0.tool-changed

net spindle-fwd spindle.0.forward
net spindle-rev spindle.0.reverse
#net spindle-speed spindle.0.speed-out

net flood iocontrol.0.coolant-flood
net mist iocontrol.0.coolant-mist
64 changes: 64 additions & 0 deletions configs/sim/qtdragon_next/qtdragon_next_xyz/core_sim_XYZAC.hal
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# core HAL config file for simulation

# first load all the RT modules that will be needed
# kinematics
loadrt [KINS]KINEMATICS
#autoconverted trivkins
# motion controller, get name and thread periods from ini file
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
# load 6 differentiators (for velocity and accel signals
loadrt ddt names=ddt_x,ddt_xv,ddt_y,ddt_yv,ddt_z,ddt_zv
# load additional blocks
loadrt hypot names=vel_xy,vel_xyz

# add motion controller functions to servo thread
addf motion-command-handler servo-thread
addf motion-controller servo-thread
# link the differentiator functions into the code
addf ddt_x servo-thread
addf ddt_xv servo-thread
addf ddt_y servo-thread
addf ddt_yv servo-thread
addf ddt_z servo-thread
addf ddt_zv servo-thread
addf vel_xy servo-thread
addf vel_xyz servo-thread

# create HAL signals for position commands from motion module
# loop position commands back to motion module feedback
net Xpos joint.0.motor-pos-cmd => joint.0.motor-pos-fb ddt_x.in
net Ypos joint.1.motor-pos-cmd => joint.1.motor-pos-fb ddt_y.in
net Zpos joint.2.motor-pos-cmd => joint.2.motor-pos-fb ddt_z.in
net Apos joint.3.motor-pos-cmd => joint.3.motor-pos-fb
net Cpos joint.4.motor-pos-cmd => joint.4.motor-pos-fb
#net Cpos joint.5.motor-pos-cmd => joint.5.motor-pos-fb
#net Upos joint.6.motor-pos-cmd => joint.6.motor-pos-fb
#net Vpos joint.7.motor-pos-cmd => joint.7.motor-pos-fb
#net Wpos joint.8.motor-pos-cmd => joint.8.motor-pos-fb

# send the position commands thru differentiators to
# generate velocity and accel signals
net Xvel ddt_x.out => ddt_xv.in vel_xy.in0
net Xacc <= ddt_xv.out
net Yvel ddt_y.out => ddt_yv.in vel_xy.in1
net Yacc <= ddt_yv.out
net Zvel ddt_z.out => ddt_zv.in vel_xyz.in0
net Zacc <= ddt_zv.out

# Cartesian 2- and 3-axis velocities
net XYvel vel_xy.out => vel_xyz.in1
net XYZvel <= vel_xyz.out

# estop loopback
net estop-loop iocontrol.0.user-enable-out iocontrol.0.emc-enable-in

# create signals for tool loading loopback
net tool-prep-loop iocontrol.0.tool-prepare iocontrol.0.tool-prepared
net tool-change-loop iocontrol.0.tool-change iocontrol.0.tool-changed

net spindle-fwd spindle.0.forward
net spindle-rev spindle.0.reverse
#net spindle-speed spindle.0.speed-out

net flood iocontrol.0.coolant-flood
net mist iocontrol.0.coolant-mist
4 changes: 4 additions & 0 deletions configs/sim/qtdragon_next/qtdragon_next_xyz/mdi_history.dat
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
t1m6
t2m6
t1m6
t2m6
31 changes: 31 additions & 0 deletions configs/sim/qtdragon_next/qtdragon_next_xyz/on_abort.ngc
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
o<on_abort> sub


o100 if [#1 eq 5]
(machine on)
o100 elseif [#1 eq 6]
(machine off)
o100 elseif [#1 eq 7]
(estopped)
o100 elseif [#1 eq 8]
(msg,Process Aborted)
o100 else
(DEBUG,Abort Parameter is %d[#1])
o100 endif

o<on_abort> endsub
m2

These are potential abort number:

EMC_ABORT_TASK_EXEC_ERROR = 1,
EMC_ABORT_AUX_ESTOP = 2,
EMC_ABORT_MOTION_OR_IO_RCS_ERROR = 3,
EMC_ABORT_TASK_STATE_OFF = 4,
EMC_ABORT_TASK_STATE_ESTOP_RESET = 5,
EMC_ABORT_TASK_STATE_ESTOP = 6,
EMC_ABORT_TASK_STATE_NOT_ON = 7,
EMC_ABORT_TASK_ABORT = 8,
EMC_ABORT_INTERPRETER_ERROR = 9, // interpreter failed during readahead
EMC_ABORT_INTERPRETER_ERROR_MDI = 10, // interpreter failed during MDI execution
EMC_ABORT_USER = 100 // user-defined abort codes start here
166 changes: 166 additions & 0 deletions configs/sim/qtdragon_next/qtdragon_next_xyz/qtdragon.pref
Original file line number Diff line number Diff line change
@@ -0,0 +1,166 @@
[DIALOG_GEOMETRY]
AboutDialog-geometry = half
LncMessage-geometry = 633 369 340 102
ToolChangeDialog-geometry = default
basicProbeHelpDialog-geometry = default

[DIALOG_OPTIONS]
EntryDialog_play_sound = True
EntryDialog_sound_type = READY
toolDialog_play_sound = True
toolDialog_speak = True
toolDialog_sound_type = READY
fileDialog_play_sound = True
fileDialog_sound_type = READY
CalculatorDialog_play_sound = True
CalculatorDialog_sound_type = READY
MachineLogDialog_play_sound = True
MachineLogDialog_sound_type = READY
RunFromLineDialog_play_sound = True
RunFromLineDialog_sound_type = READY
KeyboardDialog_play_sound = True
KeyboardDialog_sound_type = READY

[BOOK_KEEPING]
last_loaded_directory = /home/chris/linuxcnc/nc_files/examples
last_loaded_file = /home/chris/linuxcnc/nc_files/examples/3D_Chips.ngc
style_QSS_Path = /home/chris/emc/share/qtvcp/screens/qtdragon_hd/dark_grey.qss
RecentPath_0 = /home/chris/linuxcnc/nc_files/examples/3D_Chips.ngc

[ORIGINOFFSET_SYSTEM_NAMES]
__dialogOffsetViewWidget-G54 = User System 1
__dialogOffsetViewWidget-G55 = User System 2
__dialogOffsetViewWidget-G56 = User System 3
__dialogOffsetViewWidget-G57 = User System 4
__dialogOffsetViewWidget-G58 = User System 5
__dialogOffsetViewWidget-G59 = User System 6
__dialogOffsetViewWidget-G59.1 = User System 7
__dialogOffsetViewWidget-G59.2 = User System 8
__dialogOffsetViewWidget-G59.3 = User System 9
offset_table-G54 = User System 1
offset_table-G55 = User System 2
offset_table-G56 = User System 3
offset_table-G57 = User System 4
offset_table-G58 = User System 5
offset_table-G59 = User System 6
offset_table-G59.1 = User System 7
offset_table-G59.2 = User System 8
offset_table-G59.3 = User System 9

[SCREEN_OPTIONS]
catch_errors = True
desktop_notify = True
notify_max_msgs = 10
shutdown_check = True
sound_player_on = False
MainWindow-geometry = 211 -88 1920 1056

[MCH_MSG_OPTIONS]
mchnMsg_play_sound = True
mchnMsg_speak_errors = False
mchnMsg_speak_text = True
mchnMsg_sound_type = ATTENTION

[USR_MSG_OPTIONS]
usermsg_play_sound = True
userMsg_sound_type = ATTENTION
userMsg_use_focusOverlay = True

[SHUTDOWN_OPTIONS]
shutdown_play_sound = True
shutdown_alert_sound_type = READY
shutdown_exit_sound_type = LOGOUT
shutdown_msg_title = Do you want to Shutdown now?
shutdown_msg_focus_text =
shutdown_msg_detail =

[NOTIFY_OPTIONS]
notify_start_greeting = False
notify_start_title = Welcome
notify_start_detail = This option can be changed in the preference file
notify_start_timeout = 5

[FILEMANAGER_JUMPLIST]

[SCREEN_CONTROL_LAST_SETTING]
gcodegraphics-user-view = p
gcodegraphics-user-zoom = 10.0
gcodegraphics-user-panx = 0.0
gcodegraphics-user-pany = 0.0
gcodegraphics-user-lat = 0.0
gcodegraphics-user-lon = 0.0
adj_maxv_ovr-hi-value = 75
adj_maxv_ovr-low-value = 25
adj_rapid_ovr-hi-value = 75
adj_rapid_ovr-low-value = 25
adj_spindle_ovr-hi-value = 75
adj_spindle_ovr-low-value = 25
adj_linear_jog-hi-value = 75
adj_linear_jog-low-value = 25
adj_angular_jog-hi-value = 75
adj_angular_jog-low-value = 25
adj_feed_ovr-hi-value = 75
adj_feed_ovr-low-value = 25

[CUSTOM_FORM_ENTRIES]
Tool to load = 0
Laser X = 100.0
Laser Y = -20.0
Sensor X = 10.0
Sensor Y = 10.0
Camera X = 10.0
Camera Y = 10.0
Work Height = 20.0
Touch Height = 40.0
Sensor Height = 40.0
Search Velocity = 40.0
Probe Velocity = 10.0
Max Probe = 10.0
Retract Distance = 10.0
Z Safe Travel = 10.0
Eoffset count = 0
External offsets = False
Reload program = False
Reload tool = False
Use keyboard = False
Use tool sensor = False
Use tool touchplate = False
Run from line = False
Use virtual keyboard = False
Use camera = False
Use alpha display mode = False
Inhibit display mouse selection = True
Probe X = 0.0
Probe Y = 0.0
Sensor Location X = 20.0
Sensor Location Y = 20.0
Rotary Height = 10.0
Max Spindle Power = 0
Spindle Delay = 2
Use MPG jog = False
Use MDI Keyboard = False
Use program joypad = False

[PROBE OPTIONS]
Probe tool = 0
Probe diameter = 4
Probe rapid = 10
Probe feed = 10
Probe search = 10
Probe max travel = 10
Probe max z = 2
Probe extra depth = 0
Probe step off = 10
Probe xy clearance = 10
Probe z clearance = 10
Probe edge width = 10
Calibration offset = 0
Cal x width = 0
Cal y width = 0
Cal diameter = 0
Adjust X = 0.0
Adjust Y = 0.0
Adjust Z = 0
Adjust angle = 0
Cal offset = 0

Loading

0 comments on commit 89c6c0b

Please sign in to comment.