Hello Guest it is March 28, 2024, 04:48:07 AM

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - DazTheGas

91
Mach4 General Discussion / Re: Functions vs Actions
« on: March 23, 2018, 03:21:54 PM »
1. Define a key and leave its function blank
2. From mach4 - config - inputs, assign that key to an input signal
3. Use the SigLib for that signal

DazTheGas

92
Mach4 Plugins / Re: mcX360 Plugin for Lua
« on: March 18, 2018, 04:19:08 AM »
This was made for an XBox controller only.

DazTheGas

93
When probing from the MDI or from a GCodeExecute command Mach4 has a state of MRUN_PROBE (202) so you could do what you want from the SigLib,  "if probe is active and the controller state is not MRUN_PROBE then disable machine".

Code: [Select]
[mc.ISIG_PROBE] = function (state)
if machState ~= 202 then
mc.mcCntlEnable(inst, 0)
end
end

DazTheGas

94
Here you go

Quote
3664 - 3692
Core: Add option to check probe signal before a G31.  Otherwise, do like Fanuc.  Default is to check.
Core: Add option to check probe signal before a G31.  Otherwise, do like Fanuc. 
Core: Run G84.2/3 as trun cycles for the lathe interpreter. 
Core: Added the toolpath line width code to the Lathe and Tangential display's .
Core: Commit jog patch from Mach Motion.
Core: Clean up Brian's custom OEM G code stuff.
Mach4GUI: Updates for OEM versions.
Core: Changed it so only the axis lines have the width changed based on the Axis Line width. The rest of the features are done using the Path Line width .
CoreConf: Made the settings so they will change the state of the Apply button.
Core: Added a place to change the width of the lines in the toolpath in the config dialog.
Core: Update for the screw up with the license for the OEM Subs like G65.
Core: Apply AxisPlanner.cpp patch.
Mach4GUI: Add option for buttons to raise the up event if the mouse is moved off of the button.
Mach4GUI: Undo all lost focus/gain focus events.
License: Added some more features to the license Generator
Core: Added the OEM Subs to allow the OEM's to make Gcodes.
Core: Add shutdown message.
Core: Fix feed hold while probing.
Mach4GUI: Correct event handler for generic timers.
Plugins:  Wait on the event loop to start.  Prevents a plugin from hanging when Mach is starting.
Core: Code cleanup.
Core: Set the line width to the Smooth line setting rather than the AntiAliased, Test for Mach Motion
Build: buildrelease-vc12.bat now uses the windows defined NUMBER_OF_PROCESSORS environment variable. 
Build: Add a list of build requirements.
Mach4GUI: Added /m command line switch to Mach4GUI that starts with the menu hidden.
Mach4GUI: Video used to Start Mach4GUI for OEM's
Core: Isolate profile write memory alloc/dealloc. 
Core: Added mutex to config flush.   
CoreConf: Fixed plugin deletion.

3654-3663
Mach4GUI: Lost/Gain focus events on selected screen elements.
PMC: Add core value reads/writes via scr API.
Core: OpenGL Milltoolpath changed to better support newer graphics cards. Trying to get smoother and better minimum line with by using the newer calls. OpenGL 1.1 or greater so no pushing to far
Core: Allow homing of an out of band axis in any state (coordinated axis must be in idle)
Mach4GUI: Implement in situ DRO expression calculator.
Mach4GUI: Add screen based timers.
Mach4GUI: Added scr.IsLoaded() API.
Mach4GUI: Prevent crashing is if the screen specified in the profile does not exist.
Mach4GUI: Fix hang while closing caused by mcLuaPanels.

3644-3653
Build: Include machipc and screenipc Lua modules in the build process.
LuaModules: Include mcIpc function bindings.
LuaModules: Include scIpc function bindings.
Core: Add screenipc Lua module. 
Core: Add machipc Lua module. 

3631-3643
Mach4GUI: Fix in screen editor crash on scr.EditorLoadFile().
Mach4GUI: Fix register updating mcTextCtrl.
Core: Add mcFeature*() APIs.
Core: Prevent stepping into encrypted subs.
Core: Add support for encrypted G code subs.
Mach4GUI: Try and fix LUA panel closing issues. 
Mach4GUI: Added scr API calls for turning the AUI bar at the top off and a call to use some of the functions to do the commands in the bar.
Mach4GUI: Add EditorLoadFile() in the scr API.
Core: Fix auxiliary positions for user coordinates.
mcLua: Fix override bindings.
Core: Implement auxiliary position that DROs and tool paths may use, if required.
Core: Do not allow motion with G28.1 when loading a file.

3523-3630
Mach4GUI: More efficient fix for the advgui toggle button image not clearing if the image has a transparency.
Mach4GUI: Fix advgui toggle button image not clearing if the image has a transparency. 
Mach4GUI: Add scr.EditorGetFileName()
Core: Fix register hang.
Mach4GUI: Fix debug assertion with fonts. 
Mach4GUI: Fix mcTextCtrl LUA memory leak.
Core: Newline consistency.
Core: Registers are no longer capped for string lengths.
Core: Reduce memory requirements.
Core: Fix MST blocking for conditional Macro B statements (IF/WHILE).
wxWidgets: Fix GDI handle error in tool tips.
Core: Make IPC base port configurable.  It now defaults to 48000 and can be set with Preferences/BaseIpcPort in the profile.
mcLuaEditor: Prevent thread messages at shutdown by preventing multiple call to shut down the debugger threads.
Mach4GUI: Make popup alpha keyboard work with text controls.
Core: Dummy motor on axes are now automatically removed if a real motor is mapped to that axis.
Mach4GUI: Remove "Text" from uninitialized static text controls.
Mach4GUI: Add scrGetCtrlType() scrAPI.
Mach4GUI: Add scr API calls to get parent and children of a control.
Mach4GUI: Fix over-converting units (mm/in) in DROs.
Modbus: Use registry to enumerate com ports in Windows.
Core: log mcSignalWait() API
LicenseApp: Add OEMIcon16
Update wxNumberFormater to 3.1.0
Mach4GUI: Fix header define.
Mach4GUI: Build with new wxPropertyGrid.
Mach4IPC: Add memory leak checking.
wxWidgets: Upgrade wxPropertyGrid to 3.1.0
Mach4GUI: Lua Panel improvements.
Mach4GUI: Add background image scale methods to mcPage, mcGroup, and mcNotebookPage.
mcLuaEditor: Debugger update. 
mcLuaEditor: Fix crash at end of debugging session.
Core: Make IPC errors graceful. Shorten IPC connection timeout when executing on the local host.
mcLuaEditor: Auto load needed files during debugging.
mcLuaEditor: Use the graceful IPC error handling.
Core: Added a call in the Gcode interpreter for a Stop function Comp position.  Vars are now flushed when a Stop is issued.  Reset will set comp back to OFF and flush all vars
Mach: Add BuildingBlocks CCDK libraries.
Core: Fix for cutter comp with full circles
Core: Probe number added for DEV_TYPE_PROBE2
Mach4GUI: Fix DRO editing when it is mapped to a G code.
Core:  Fix the bug introduced when adding the mutex on the G code file operations.
Core: Added a mutex to protect the memory mapped file operations. 
Core: Added code to allow Gcode from a script with a probe move to run after the G31 Command. It would stop before and not execute anything after if it was part of the same string (multi line)
Core: Added the tools to allow more than one tool call on a line of Gcode for Drill bank heads in Industrial.
Core: Added a way to put scripts in to the config menu to help with support.
Sim: Fix mcNativeParentHelper.h with regards to the size message.
Mach4GUI: Fix Plugin Panel Window Messages.
Build: PDBs to SDK
Mach4GUI: Fix static text label/register bug.
Mach4GUI: Add G code variables to static text labels.
Core:  General cleanup to find Axis NAN problem. 
Sim: New plugin panel interface implemented.  MUCH easier!

3486-3522
Core: New plugin panel interface implemented.  MUCH easier!
Mach4GUI: New plugin panel interface implemented.  MUCH easier!
Sim: New plugin panel interface implemented.  MUCH easier!
Core: Added the over ride for the mcMpgGetShuttlePercent(int, * percent function)
Core: Added the code to set the default toolpath to be the selection that the user would like. Now the defaut is the selection Shuttle mode now has API calls to set the velocity.
Core: Adjustments to cut recovery.
Core: Finalize cut recovery check routines.
Core: Add Cut Recovery output signal.
Core: Update operator= for PmPoint.
Mach4GUI: Disable OK button on Cut Recovery dialog until machine is in position.
Mach4GUI: Add cut recover cancel button code.
Core: Needed to add a new dot product for all 6 axis
Core: Added more code to test if the point is on the Arc. The code is in for testing but is not used in the check.
Core: Fix StateInterface with regards to cut recovery.
Core: Stubbed out point on line check.   
Core: Added overloaded operators to PmCartesian.
Core: Added a test to see if the point is on the arc. This is a simple test to see if it has the same Rad first. The next test is to do an angle check.
Mach4GUI: update Tracking Buffer
Sim: Add SIZE and REFRESH plugin panel messages.
Core: Implement CutRecovery.
Mach4GUI: Make wxBitmapButton
Core: Implement TrackingBuffer in CyclePlanner().
Core: Add TrackingBuffer class.
Mach4GUI: Try to prevent a NULL brush and a NULL graphics path in wxGradientButton.
Core: Retract no longer tries to move disabled axes.
Core: mcSignalWait() can not use all signals instead of just GP inputs and outputs.
Mach4GUI: Enable crash reports.
Build: include PDB files in SDK.
Mach4GUI: Fix state label flicker.
Installer:  Fix build script to include screen designer docs in the SDK.

3475-3485
Build: Include screen designer docs.
CoreConf: Added a popup dialog to tell the user they have selected units for setup and default that are not the same. This has caused issues in the past and should help support.
Core: Prevent mcProfileSave/Flush() from working before MSG_CONFIG_END.  They return MERROR_NOT_NOW if used before MSG_CONFIG_END.
Mach4GUI: Fix disk logging file name.
Mach4GUI: Dro values are now forced to update on startup. Default was zero for the value and now we have it set to an unset value.
Core: Add shadow variables for old style Fanuc offsets. 
Core: Added a bool to the TpAddTc function that allows the goal position not to be set. Also made where we set the last position before the Gcode move was sent in all functions to make it consistent for all moves.
Core: Change the position the planner uses as the start of the move to account for rotation...
Mach4GUI: Enable logging to a file.
Core: Added a check to see if the PCID is the same in the license file as the PC. We now show an error and don't load the license if they don't match
Core: Get the start of the move set when every TC is initialized

3468-3474
Mach4GUI: Add unhandled exception report generator.
Core: Add unhandled exception catcher.
Core: Fix starting position for dwells.
Mach4GUI: Fix debug assertions in mcStaticBitmap.
Core: mcMotorGetPos() no longer truncates the double to an integer.
Router Screen: Fix update scripts in the DROs.

3419-3468
Core: Problem with G28 and the Z axis .. The code was changed to not need the ! (Not) operator and one was missed
Core: G code check for moving a disabled axis. Core: G code error strings are now translatable.
Mach4GUI: Fix bitmap button enabled/disabled discrepancies when launching dialogs from the button down event.
Core: Retain signal user descriptions.
Mach4GUI: Run From Here dialog caused hang on exit.
mcSerial: mcPluginUnload() was never called. (not exported from plugin).
Core: protect the tc queue with a mutex.
Mach4GUI: Make the static bitmap accept new images at runtime.
Mach4GUI: Fix bitmap button disabled image problem.
Core: Start spindle changed timer in the main thread.
Core: Correctly implement wxFileConfig in Load/SaveFixtureTable().
Core: Fix default var screwup on mcStaticText.
Mach4GUI: Small typo for the inc jogging with the KB
Core: Send MSG_TIMEOUT to plugins.
Core: Changes made to the tangential interpreter to allow the user to set the amount they don't care about the blade being in position... for example if the blade is out 1.5 deg when it starts is that Okay ?
Mach4GUI: Change base class of mcBitmapButton from wxBitmapButton to wxWindow.
mcShuttle: Fix the Shuttle pro being on something other than Encoder Number 0 or 1
Core/IPC: Add mcIpcGetLastErrorMessage() and mcIpcGetLastErrorCode() to facilitate IPC debugging in the LUA environment.
Mach4GUI: Streamline control update and edit scripts.  Info in Mach 4 screen editor manual.
Core: Make the SETVN ranges settable.
CoreConf: Make the SETVN ranges settable.

3418-3403
Core: Add mcAxisRemoveOverrideAxisSync() API call
Core: Prevent MPG in feed hold state!
Docs: Update and clear up override axis API functions.
Core: Fix mcAxisRemoveOverrideAxis();
mcKeyboard: Look at Keyboard plugin to see if anything changed.  There was one change having to do with c# compat.  This change was improved.
Sim: Add output register for PMC testing.
PmcEditor: Fix register read writes so that they allow floating point numbers.
PMCEditor: Correct parameter for write (-> bool read = false) for SetPmcDevs in ShowRegisterDialog().
mcSerial Plugin:Added some tools to allow polling of the port. More of a test than anything
Core: Need to get the ABS of the angle when checking.. Killed moves in the reverse direction.
Core: Fix for Tangential interpreter stopping on moves that don't move the A axis
Mach4GUI: Keep bitmap button from shrinking when the down event script is used incorrectly.
Mach4GUI: Correct angular meter control mapping.
Mach4GUI: Wire the DRO codes to the angular meter control.
Mach4GUI: Make angular meters available in Hobby.

3402-3384
Mach4GUI: Add bezel and face image capability to the angular meter control.
Mach4GUI: The needle will now not move passed the meter start and end ranges.  However, the digital value will still show a value that is over or under the meter ranges.
Mach4GUI: Fix angular meter disposal of the graphics context.
Mach4GUI: Init meter control to sane values.
Mach4GUI: Add angular meter control.
Core: Header comment spelling correction.
Mach4GUI: Add angular meter control.
Core: Add mcCntlconfigStopEx()
Mach4GUI: Font resize bug.
Mach4GUI: Add font property to notebook control.
Mach4GUI: New font mechanism implemented.
Core: Allow 2 consecutive comp moves moves with the same vector.
Core: Fix G68 with cutter comp.
Mach4GUI: Add a font handling class.
Mach4GUI: Get rid of unpainted pixel line on some scaled buttons.

DazTheGas

95
This has been looked at many times before and posted here, but IMHO the most efficient is to use a function like what Bryanna posted and then on first run of PLC run the function so softlimits are on from the start, When homing an axis softlimits are ignored so it doesnt hurt to switch them on before homing. ( I have tested this on my own machine with ESS )

You will notice with the current RefAllHome that if you canx the homing for any reason then it still says your homed, when your not. So if the operator is not careful then he/she could be crashing the machine.
I have many fallbacks to make sure softlimits are on like my cycle start button checks for this and warns me. I you noticed the code I posted it adds a simple check to see if the controller is enabled at the end of the coroutine, if not then it must of been aborted or something went wrong so a different dialog is displayed so I wont crash my machine (AGAIN!) ;-)

DazTheGas

96
Underneath the coroutine.yield line you can add something like this

Code: [Select]
if mc.mcSignalGetState (mc.mcSignalGetHandle mInst, mc.OSIG_MACHINE_ENABLED)) == 1 then
    mc.mcSoftLimitSetState(mInst, mc.X_AXIS, mc.MC_ON)
    mc.mcSoftLimitSetState(mInst, mc.Y_AXIS, mc.MC_ON)
    mc.mcSoftLimitSetState(mInst, mc.Z_AXIS, mc.MC_ON)
    wx.wxMessageBox("Machine is Homed and SoftLimits Enabled", "Homing Sequence",4)
else
    wx.wxMessageBox("Homing Aborted", "Homing Sequence",4)
end

DazTheGas

97
Mach4 General Discussion / Re: Home Signal
« on: February 19, 2018, 05:32:55 PM »
So ive been back and reread the 1st post and if I have got it right, you want to use the same profile but have 2 different kinds of homing so you can leave an Axis out. If so it can be done like Steve says.
You can add another button and say which Axis to ref, ive just tested this and it is fine apart from both Axis will home at same time.

Code: [Select]
local mInst = mc.mcGetInstance()
mc.mcAxisHome(mInst, mc.Z_AXIS)
mc.mcAxisHome(mInst, mc.X_AXIS)

To ref individually and have dro`s moving then you would need to wrap this in a coroutine.

DazTheGas

98
Mach4 General Discussion / Re: Home Signal
« on: February 19, 2018, 01:16:44 PM »
When ever anything config wise is being done then mach4 needs to be in a config state, this will send a MSG_CONFIG_START to plugins, on exiting the config state MSG_CONFIG_END is sent to plugins. It is here where plugins do there housework etc, so without these msg's a plugin doesnt know anything has changed. There are commands ie mc.mcCntlConfigStart etc but wether they work or not??

DazTheGas

99
Mach4 General Discussion / Re: Lua programming of voltage meter
« on: February 19, 2018, 10:23:44 AM »
Try a different way,

1.  Add LED to screen.
2. Assign it to an output thats not being used IE Output 63
3. Turn On and Off using mc.mcSignalSetState (mc.mcSignalGetHandle ( inst ,mc.OSIG_OUTPUT63  ), 1) = ON and mc.mcSignalSetState (mc.mcSignalGetHandle ( inst,mc.OSIG_OUTPUT63  ), 0) = OFF

I have many LED`s setup in this way.

DazTheGas

100
Mach4 General Discussion / Re: Lua programming of voltage meter
« on: February 19, 2018, 08:45:29 AM »
Think that should be if value ~= 0 then turn on LED

DazTheGas