How to configure Himing switches in tinyg2?

Home Forums TinyG TinyG Support How to configure Himing switches in tinyg2?

Tagged: , , ,

Viewing 15 posts - 1 through 15 (of 37 total)
  • Author
    Posts
  • #8990
    Buckman117
    Member

    The long and short of it I have built a mill. I have achieved proper movement of all three axes and now need to accomplish spindle control and home\limit switches. It seems that I am missing something when using my current configuration with normally open switches. The switches are only normally open as they are industrial induction prox switches that run on 12v and I have used voltage dividers to bring the voltage signal down to 3.0 volts. I have tested using a jumper wire directly from the 3.3volt rail during a homing cycle to see if I can get any response. I am using the gshield settings when compiling. Below is the settings I am compiling with. Can anyone help me configure the homing settings? Thank you very much in advance for the help. Tinyg2 moves my machine much better than grbl and I would really like to use it.

    // ***> NOTE: The init message must be a single line with no CRs or LFs
    #define INIT_MESSAGE “Initializing configs to default settings”

    //**** GLOBAL / GENERAL SETTINGS ******************************************************

    // Machine configuration settings (See motors and axes for globals related to those objects)

    #define JUNCTION_ACCELERATION 100000 // centripetal acceleration around corners
    #define CHORDAL_TOLERANCE 0.01 // chordal accuracy for arc drawing (in mm)

    #define SOFT_LIMIT_ENABLE 1 // 0=off, 1=on
    #define HARD_LIMIT_ENABLE 1 // 0=off, 1=on
    #define SAFETY_INTERLOCK_ENABLE 0 // 0=off, 1=on

    #define SPINDLE_ENABLE_POLARITY 1 // 0=active low, 1=active high
    #define SPINDLE_DIR_POLARITY 0 // 0=clockwise is low, 1=clockwise is high
    #define SPINDLE_PAUSE_ON_HOLD true
    #define SPINDLE_DWELL_TIME 1.0

    #define COOLANT_MIST_POLARITY 1 // 0=active low, 1=active high
    #define COOLANT_FLOOD_POLARITY 1 // 0=active low, 1=active high
    #define COOLANT_PAUSE_ON_HOLD true

    // Communications and reporting settings

    #define TEXT_VERBOSITY TV_VERBOSE // one of: TV_SILENT, TV_VERBOSE
    #define COMM_MODE JSON_MODE // one of: TEXT_MODE, JSON_MODE

    #define XIO_EXPAND_CR false // serial IO settings (AVR only)
    #define XIO_ENABLE_ECHO false
    #define XIO_ENABLE_FLOW_CONTROL FLOW_CONTROL_XON // FLOW_CONTROL_OFF, FLOW_CONTROL_XON, FLOW_CONTROL_RTS

    #define JSON_VERBOSITY JV_MESSAGES // one of: JV_SILENT, JV_FOOTER, JV_CONFIGS, JV_MESSAGES, JV_LINENUM, JV_VERBOSE
    #define JSON_SYNTAX_MODE JSON_SYNTAX_STRICT // one of JSON_SYNTAX_RELAXED, JSON_SYNTAX_STRICT

    #define QUEUE_REPORT_VERBOSITY QR_OFF // one of: QR_OFF, QR_SINGLE, QR_TRIPLE

    #define STATUS_REPORT_VERBOSITY SR_FILTERED // one of: SR_OFF, SR_FILTERED, SR_VERBOSE
    #define STATUS_REPORT_MIN_MS 200 // milliseconds – enforces a viable minimum
    #define STATUS_REPORT_INTERVAL_MS 250 // milliseconds – set $SV=0 to disable
    #define STATUS_REPORT_DEFAULTS “line”,”posx”,”posy”,”posz”,”posa”,”feed”,”vel”,”unit”,”coor”,”dist”,”admo”,”frmo”,”momo”,”stat”
    // Alternate SRs that report in drawable units
    //#define STATUS_REPORT_DEFAULTS “line”,”vel”,”mpox”,”mpoy”,”mpoz”,”mpoa”,”coor”,”ofsa”,”ofsx”,”ofsy”,”ofsz”,”dist”,”unit”,”stat”,”homz”,”homy”,”homx”,”momo”

    // Gcode startup defaults
    #define GCODE_DEFAULT_UNITS INCHES // MILLIMETERS or INCHES
    #define GCODE_DEFAULT_PLANE CANON_PLANE_XY // CANON_PLANE_XY, CANON_PLANE_XZ, or CANON_PLANE_YZ
    #define GCODE_DEFAULT_COORD_SYSTEM G54 // G54, G55, G56, G57, G58 or G59
    #define GCODE_DEFAULT_PATH_CONTROL PATH_CONTINUOUS
    #define GCODE_DEFAULT_DISTANCE_MODE ABSOLUTE_MODE

    // *** motor settings ************************************************************************************

    #define MOTOR_POWER_MODE MOTOR_POWERED_IN_CYCLE // default motor power mode (see cmMotorPowerMode in stepper.h)
    #define MOTOR_POWER_TIMEOUT 3600 // motor power timeout in seconds
    #define MOTOR_POWER_LEVEL 1.000 // default motor power level 0.00 – 1.00 (ARM only)

    #define M1_MOTOR_MAP AXIS_X // 1ma
    #define M1_STEP_ANGLE 1.8 // 1sa
    #define M1_TRAVEL_PER_REV 5 // 1tr
    #define M1_MICROSTEPS 8 // 1mi 1,2,4,8,16,32
    #define M1_POLARITY 0 // 1po 0=normal, 1=reversed
    #define M1_POWER_MODE MOTOR_POWER_MODE // 1pm
    #define M1_POWER_LEVEL MOTOR_POWER_LEVEL // 1pl

    #define M2_MOTOR_MAP AXIS_Y
    #define M2_STEP_ANGLE 1.8
    #define M2_TRAVEL_PER_REV 5
    #define M2_MICROSTEPS 8
    #define M2_POLARITY 1
    #define M2_POWER_MODE MOTOR_POWER_MODE
    #define M2_POWER_LEVEL MOTOR_POWER_LEVEL

    #define M3_MOTOR_MAP AXIS_Z
    #define M3_STEP_ANGLE 1.8
    #define M3_TRAVEL_PER_REV 5
    #define M3_MICROSTEPS 8
    #define M3_POLARITY 1
    #define M3_POWER_MODE MOTOR_POWER_MODE
    #define M3_POWER_LEVEL MOTOR_POWER_LEVEL

    #define M4_MOTOR_MAP AXIS_A // 1ma
    #define M4_STEP_ANGLE 1.8 // 1sa
    #define M4_TRAVEL_PER_REV 360 // 1tr degrees moved per motor rev
    #define M4_MICROSTEPS 8 // 1mi
    #define M4_POLARITY 0 // 1po
    #define M4_POWER_MODE MOTOR_POWER_MODE // 1pm
    #define M4_POWER_LEVEL MOTOR_POWER_LEVEL // 1mp

    #define M5_MOTOR_MAP AXIS_B
    #define M5_STEP_ANGLE 1.8
    #define M5_TRAVEL_PER_REV 360 // degrees moved per motor rev
    #define M5_MICROSTEPS 8
    #define M5_POLARITY 0
    #define M5_POWER_MODE MOTOR_POWER_MODE
    #define M5_POWER_LEVEL MOTOR_POWER_LEVEL

    #define M6_MOTOR_MAP AXIS_C
    #define M6_STEP_ANGLE 1.8
    #define M6_TRAVEL_PER_REV 360 // degrees moved per motor rev
    #define M6_MICROSTEPS 8
    #define M6_POLARITY 0
    #define M6_POWER_MODE MOTOR_POWER_MODE
    #define M6_POWER_LEVEL MOTOR_POWER_LEVEL

    // *** axis settings ***

    #define JERK_MAX 10000 // that’s “20,000,000” mm/(min^3)
    #define JUNCTION_DEVIATION_XY 0.0254 // larger is faster
    #define JUNCTION_DEVIATION_Z 0.0254 // larger is faster
    #define JUNCTION_DEVIATION_ABC 0.0254 // larger is faster

    #define X_AXIS_MODE AXIS_STANDARD // xam see canonical_machine.h cmAxisMode for valid values
    #define X_VELOCITY_MAX 2540 // xvm G0 max velocity in mm/min
    #define X_FEEDRATE_MAX X_VELOCITY_MAX // xfr G1 max feed rate in mm/min
    #define X_TRAVEL_MIN 0 // xtn minimum travel – used by soft limits and homing
    #define X_TRAVEL_MAX 610 // xtm maximum travel – used by soft limits and homing
    #define X_JERK_MAX JERK_MAX // xjm
    #define X_JERK_HIGH_SPEED X_JERK_MAX // xjh
    #define X_JUNCTION_DEVIATION JUNCTION_DEVIATION_XY // xjd
    #define X_HOMING_INPUT 1 // xhi number of the input to ise for homing, or 0 for off
    #define X_HOMING_DIR 0 // xhd 0 to search to minimum, 1 to search to maximum
    #define X_SEARCH_VELOCITY 1000 // xsv move in negative direction
    #define X_LATCH_VELOCITY 10 // xlv mm/min
    #define X_LATCH_BACKOFF 5 // xlb mm
    #define X_ZERO_BACKOFF 1 // xzb mm

    #define Y_AXIS_MODE AXIS_STANDARD
    #define Y_VELOCITY_MAX 2286
    #define Y_FEEDRATE_MAX Y_VELOCITY_MAX
    #define Y_TRAVEL_MIN 0
    #define Y_TRAVEL_MAX 550
    #define Y_JERK_MAX JERK_MAX
    #define Y_JERK_HIGH_SPEED Y_JERK_MAX
    #define Y_JUNCTION_DEVIATION JUNCTION_DEVIATION_XY
    #define Y_HOMING_INPUT 4
    #define Y_HOMING_DIR 1
    #define Y_SEARCH_VELOCITY 1000
    #define Y_LATCH_VELOCITY 10
    #define Y_LATCH_BACKOFF 5
    #define Y_ZERO_BACKOFF 1

    #define Z_AXIS_MODE AXIS_STANDARD
    #define Z_VELOCITY_MAX 2286
    #define Z_FEEDRATE_MAX Z_VELOCITY_MAX
    #define Z_TRAVEL_MIN 0
    #define Z_TRAVEL_MAX 175
    #define Z_JERK_MAX JERK_MAX
    #define Z_JERK_HIGH_SPEED Z_JERK_MAX
    #define Z_JUNCTION_DEVIATION JUNCTION_DEVIATION_Z
    #define Z_HOMING_INPUT 6
    #define Z_HOMING_DIR 1
    #define Z_SEARCH_VELOCITY 1000
    #define Z_LATCH_VELOCITY 10
    #define Z_LATCH_BACKOFF 5
    #define Z_ZERO_BACKOFF 1

    // Rotary values are chosen to make the motor react the same as X for testing
    /***************************************************************************************
    * To calculate the speeds here, in Wolfram Alpha-speak:
    *
    * c=2*pi*r, r=0.609, d=c/360, s=((S*60)/d), S=40 for s
    *
    * Change r to A_RADIUS, and S to the desired speed, in mm/s or mm/s/s/s.
    *
    * It will return s= as the value you want to enter.
    *
    * If the value is over 1 million, the code will divide it by 1 million,
    * so you have to pre-multiply it by 1000000.0. (The value is in millions, btw.)
    *
    * Note that you need these to be floating point values, so always have a .0 at the end!
    *
    ***************************************************************************************/

    #define A_AXIS_MODE AXIS_RADIUS
    #define A_RADIUS (M1_TRAVEL_PER_REV/(2*3.14159628))
    #define A_VELOCITY_MAX ((X_VELOCITY_MAX/M1_TRAVEL_PER_REV)*360) // set to the same speed as X axis
    #define A_FEEDRATE_MAX A_VELOCITY_MAX
    #define A_TRAVEL_MIN -1 // min/max the same means infinite, no limit
    #define A_TRAVEL_MAX -1
    #define A_JERK_MAX (X_JERK_MAX*(360/M1_TRAVEL_PER_REV))
    #define A_JERK_HIGH_SPEED A_JERK_MAX
    #define A_JUNCTION_DEVIATION JUNCTION_DEVIATION_ABC
    #define A_HOMING_INPUT 0
    #define A_HOMING_DIR 0
    #define A_SEARCH_VELOCITY 600
    #define A_LATCH_VELOCITY 100
    #define A_LATCH_BACKOFF 5
    #define A_ZERO_BACKOFF 2

    #define B_AXIS_MODE AXIS_RADIUS
    #define B_RADIUS (M1_TRAVEL_PER_REV/(2*3.14159628))
    #define B_VELOCITY_MAX ((X_VELOCITY_MAX/M1_TRAVEL_PER_REV)*360)
    #define B_FEEDRATE_MAX B_VELOCITY_MAX
    #define B_TRAVEL_MIN -1
    #define B_TRAVEL_MAX -1
    #define B_JERK_MAX (X_JERK_MAX*(360/M1_TRAVEL_PER_REV))
    #define B_JERK_HIGH_SPEED B_JERK_MAX
    #define B_JUNCTION_DEVIATION JUNCTION_DEVIATION_ABC
    #define B_HOMING_INPUT 0
    #define B_HOMING_DIR 0
    #define B_SEARCH_VELOCITY 600
    #define B_LATCH_VELOCITY 100
    #define B_LATCH_BACKOFF 5
    #define B_ZERO_BACKOFF 2

    #define C_AXIS_MODE AXIS_RADIUS
    #define C_RADIUS (M1_TRAVEL_PER_REV/(2*3.14159628))
    #define C_VELOCITY_MAX ((X_VELOCITY_MAX/M1_TRAVEL_PER_REV)*360)
    #define C_FEEDRATE_MAX C_VELOCITY_MAX
    #define C_TRAVEL_MIN -1
    #define C_TRAVEL_MAX -1
    #define C_JERK_MAX (X_JERK_MAX*(360/M1_TRAVEL_PER_REV))
    #define C_JERK_HIGH_SPEED C_JERK_MAX
    #define C_JUNCTION_DEVIATION JUNCTION_DEVIATION_ABC
    #define C_HOMING_INPUT 0
    #define C_HOMING_DIR 0
    #define C_SEARCH_VELOCITY 600
    #define C_LATCH_VELOCITY 100
    #define C_LATCH_BACKOFF 5
    #define C_ZERO_BACKOFF 2

    //*** Input / output settings ***

    /*
    INPUT_MODE_DISABLED
    INPUT_ACTIVE_LOW aka NORMALLY_OPEN
    INPUT_ACTIVE_HIGH aka NORMALLY_CLOSED

    INPUT_ACTION_NONE
    INPUT_ACTION_STOP
    INPUT_ACTION_FAST_STOP
    INPUT_ACTION_HALT
    INPUT_ACTION_RESET

    INPUT_FUNCTION_NONE
    INPUT_FUNCTION_LIMIT
    INPUT_FUNCTION_INTERLOCK
    INPUT_FUNCTION_SHUTDOWN
    INPUT_FUNCTION_PANIC
    */

    // Xmin on v9 board
    #define DI1_MODE NORMALLY_OPEN
    #define DI1_ACTION INPUT_ACTION_NONE
    #define DI1_FUNCTION INPUT_FUNCTION_NONE

    // Xmax
    #define DI2_MODE NORMALLY_OPEN
    #define DI2_ACTION INPUT_ACTION_NONE
    #define DI2_FUNCTION INPUT_FUNCTION_NONE

    // Ymin
    #define DI3_MODE NORMALLY_OPEN
    #define DI3_ACTION INPUT_ACTION_NONE
    #define DI3_FUNCTION INPUT_FUNCTION_NONE

    // Ymax
    #define DI4_MODE NORMALLY_OPEN
    #define DI4_ACTION INPUT_ACTION_NONE
    #define DI4_FUNCTION INPUT_FUNCTION_NONE

    // Zmin
    #define DI5_MODE NORMALLY_OPEN // Z proble
    #define DI5_ACTION INPUT_ACTION_NONE
    #define DI5_FUNCTION INPUT_FUNCTION_NONE

    // Zmax
    #define DI6_MODE NORMALLY_OPEN
    #define DI6_ACTION INPUT_ACTION_NONE
    #define DI6_FUNCTION INPUT_FUNCTION_NONE

    // Amin
    #define DI7_MODE NORMALLY_OPEN
    #define DI7_ACTION INPUT_ACTION_NONE
    #define DI7_FUNCTION INPUT_FUNCTION_NONE

    // Amax
    #define DI8_MODE NORMALLY_OPEN
    #define DI8_ACTION INPUT_ACTION_NONE
    #define DI8_FUNCTION INPUT_FUNCTION_NONE

    // Safety line
    #define DI9_MODE NORMALLY_OPEN
    #define DI9_ACTION INPUT_ACTION_NONE
    #define DI9_FUNCTION INPUT_FUNCTION_NONE

    /*** Handle optional modules that may not be in every machine ***/

    #define P1_PWM_FREQUENCY 100 // in Hz
    #define P1_CW_SPEED_LO 2000 // in RPM (arbitrary units)
    #define P1_CW_SPEED_HI 24000
    #define P1_CW_PHASE_LO 0.13 // phase [0..1]
    #define P1_CW_PHASE_HI 0.17
    #define P1_CCW_SPEED_LO 0
    #define P1_CCW_SPEED_HI 0
    #define P1_CCW_PHASE_LO 0.1
    #define P1_CCW_PHASE_HI 0.1
    #define P1_PWM_PHASE_OFF 0.1

    // *** DEFAULT COORDINATE SYSTEM OFFSETS ***

    #define G54_X_OFFSET 0 // G54 is often set to all zeros
    #define G54_Y_OFFSET 0
    #define G54_Z_OFFSET 0
    #define G54_A_OFFSET 0
    #define G54_B_OFFSET 0
    #define G54_C_OFFSET 0

    #define G55_X_OFFSET 610/2 // use (X_TRAVEL_MAX/2) to set g55 to middle of table
    #define G55_Y_OFFSET 550/2 // use (Y_TRAVEL_MAX/2) to set g55 to middle of table
    #define G55_Z_OFFSET 175
    #define G55_A_OFFSET 0
    #define G55_B_OFFSET 0
    #define G55_C_OFFSET 0

    #define G56_X_OFFSET 0
    #define G56_Y_OFFSET 0
    #define G56_Z_OFFSET 0
    #define G56_A_OFFSET 0
    #define G56_B_OFFSET 0
    #define G56_C_OFFSET 0

    #define G57_X_OFFSET 0
    #define G57_Y_OFFSET 0
    #define G57_Z_OFFSET 0
    #define G57_A_OFFSET 0
    #define G57_B_OFFSET 0
    #define G57_C_OFFSET 0

    #define G58_X_OFFSET 0
    #define G58_Y_OFFSET 0
    #define G58_Z_OFFSET 0
    #define G58_A_OFFSET 0
    #define G58_B_OFFSET 0
    #define G58_C_OFFSET 0

    #define G59_X_OFFSET 0
    #define G59_Y_OFFSET 0
    #define G59_Z_OFFSET 0
    #define G59_A_OFFSET 0
    #define G59_B_OFFSET 0
    #define G59_C_OFFSET 0

    /*** User-Defined Data Defaults ***/

    #define USER_DATA_A0 0
    #define USER_DATA_A1 0
    #define USER_DATA_A2 0
    #define USER_DATA_A3 0
    #define USER_DATA_B0 0
    #define USER_DATA_B1 0
    #define USER_DATA_B2 0
    #define USER_DATA_B3 0
    #define USER_DATA_C0 0
    #define USER_DATA_C1 0
    #define USER_DATA_C2 0
    #define USER_DATA_C3 0
    #define USER_DATA_D0 0
    #define USER_DATA_D1 0
    #define USER_DATA_D2 0
    #define USER_DATA_D3 0

    #8992
    cmcgrath5035
    Moderator

    For starters, read this wiki item a couple of times

    The operation of Homing and Limits is same in G2, but G2 now supports NC/NO selection on a per switch basis.

    Special note – soft limits are only enforced when a machine has been previously homed.

    I think what you are saying is that your switches ar NO proximity switches, nominally 12V in ‘OPEN’ state, with voltage divider networks to reduce the 12V to 3V. I’ll assume you took into account the pull-up resistors(to 3.3v) on the tinyG board. what do you measure at tinyG2 in the NO state; 3V?

    With classic microswitches, NO was not ‘preferred’ due to noise susceptibility.
    But chances are that the impedance of your voltage divider significantly reduces noise susceptibility.

    I have played with capacitive NC proximity switches, force them to operate by holding a piece of aluminum close to them(rather than mess with forcing voltage with wire)

    Is the settings.h file you are compiling with changed from the default Gshield settings?
    What have you changed? It is very difficult to spot differences.
    What version of tinyG2 have you compiled to (what version number)?
    Or, what is the value of $fb?

    What are you trying to test, Homing, hard limits, soft limits?

    #8995
    Buckman117
    Member

    Thank you for the fast response. I think you are right with the pull up resistors. when I used a jumper to short the input pin to ground I got a response out of the machine. Do you by any chance know if it is possible to reconfigure the pull up resistors to pull down?

    The limit switch signal reads 0V when no metal is put in front and 12V when metal is if front.

    #8997
    Buckman117
    Member

    I am trying to get homing and soft limits

    #8998
    Buckman117
    Member

    Also another important detail i am not using a gshield board just the pinout.
    I am unable to use gshield because the motors and size of the machine require 4.2 amp steppers. so currently i have 6 pins in use for step and direction. 2 more for spindle pwm and enable. and the remaining 3 for Xmin Ymax and Zmax.

    #8999
    cmcgrath5035
    Moderator

    The limit switch signal reads 0V when no metal is put in front and 12V when metal is if front.

    That sounds like NC to me.

    But, then, why did a grounding wire change anything? switches should be NC state (if away from metal).
    ???

    I do hope your voltage dividers will keep voltage at tiny G inputs <3.3V.
    Otherwise, quick death. A better interface for these switches is a diode allowing switch to pull tinyG input low but blocking the high voltage from switch. I’ll try to dig up the schematic.

    #9000
    cmcgrath5035
    Moderator

    Ah so, more input.

    Also another important detail i am not using a gshield board just the pinout.
    I am unable to use gshield because the motors and size of the machine require 4.2 amp steppers. so currently i have 6 pins in use for step and direction. 2 more for spindle pwm and enable. and the remaining 3 for Xmin Ymax and Zmax.

    First , my bad, I started thinking you had tinyGV8.
    I am not sure what Gshield has for pull-up conditioning, if any.
    I do not believe the DUE has anything either, just raw access to the I/O port.

    So now I am confused again, did you mean Xmin, Ymin, Zmax?

    #9005
    Buckman117
    Member

    No due to how the machine moves and it’s location in the room i need it to be ymax. I got it figured out just had to use some nchannel fets to with the signal wires of the switches going to the gates of the fets and then they would pull the io pin of the due to ground I’ll see if i can get a video uploaded shortly to explain. thanks for your help.

    #9007
    cmcgrath5035
    Moderator

    OK, good luck and please do send along your switch interface solution when complete, many folks are using these prox switches.

    I do suggest you test homing the X axis by itself first, that should work.

    Not clear to me how you can Home to Ymax or what you will end up with as a Y coordinate. TinyG is homing is ‘hard coded’ to Ymin, not sure if that is changed in tinyG2.

    #9011
    Buckman117
    Member

    Video Response

    above is the video response showing why I needed Ymax

    #9012
    Buckman117
    Member

    Text response for those who don’t want to watch the video.
    each induction limit switch has 3 wires 12V, Ground, and signal.
    I found that I needed to connect a n channel fet with the signal coming off of the switch connected to the gate and the input pin connected to the drain and the source connected to ground.

    #9013
    cmcgrath5035
    Moderator

    Nice looking machine!

    I had audio off, perhaps the “need” for Ymax homing was apparent there.
    Since you have a custom implementation of a classic X-Y-Z milling machine,
    it is not obvious why you need to home to Ymax, unless it is just to move the gantry away from you when homed.

    My read of the G28.2 homing cycle command is that is finds Y home by searching in the negative or “move from positive toward zero” direction until it finds the limit switch, then backs off and sets Y=0 at that point. My further interpretation is that when homing Y axis, only the Ymin port is being monitored by the hardware.
    That may be incorrect on my part, I have not played with homing yet.

    FET circuit – If Interpreted correctly, you are using the FET as an inverter, gate controlled by output from prox switch. So if the prox is NC, you invert it so tinyG2 sees a NO switch. You might want to consider a resistor pull-up(2.7K?) on the port pins (to 3.3V), I believe the on-chip pull up on the DUE is rather high impedance. And maybe a 0..22uf to ground, for noise immunity.
    That would be similar to how tinyG conditions ports
    Can you please report the FET specifics you are using (device code)?
    Someone reading may wish to follow you lead.

    #9024
    Buckman117
    Member

    I believe you are correct. I think I could have used a big pull down resistor natively but I had bs170 fets on hand so I used them.

    #9027
    Buckman117
    Member

    Also thanks for the compliment building the machine took almost 6 months of planning and 4 months of work to do the machining. I can’t wait until I learn how tinyg want it’s gcode files. It seems to want to shift the g54(work) zero as it moves. I say this because when tell the machine to return to part zero it is in different locations depending on where i stop the program. and it is shifting the zero in all 3 dimensions. I sent the same file with Chilipepper and coolterm and got identical results…. but they were not what I told it to do I think….
    What I Thought I Sent
    What I got instead…

    I know that it isn’t missing steps because the first time it crashed it bent the 3 1/4-20 bolts that were holding the workpiece down and stalled the 3hp spindle as it buried the cutter luckily the stickout was less than the total thickness and so it saved the bed and the tool.
    I was trying to make toeclamps.
    I did get the first program to run through flawlessly. It had the more “complicated” program in my opinion because it had Arcs in ijk and R but it executed flawlessly. I was really shocked to find that I couldn’t get this program to run. Used Inventor HSM with the tinyg post processor to generate the Gcode. Worked the first time not the second. the gcode file looks right.
    Toeclamps gcode file

    Thanks again for any help.

    #9031
    cmcgrath5035
    Moderator

    It will take me a bit to look at your files – I am on the road.
    I am not surprised you were able to bend bolts – your drive set up does look a bit “torquey” :).

    Does the CP DRO (digital read out) say 0,0 but the position is off, or does the DRO report an accurate, but incorrect position when you send it to G54 zero?

    TinyG does not intentionally change G54 zero. If G54 offsets (from G53) are (0,0), then position drift in spindle position relative to G53 (0,0) could be caused by (in no particular order)
    1. Stepper slips
    2. Belt or drivetrain slips – are your stepper to LEAD screw couplings tight?
    3. Rogue changes to the G54 x and Y offset parameters
    4. Gcode commands that tinyG cannot interpret/sees as error.
    5. Other……

    Most reason 4 errors seem to be related to G2 and G3 ARCs, if you can regenerate Gcode without them and things work better, that could be useful input.

Viewing 15 posts - 1 through 15 (of 37 total)
  • You must be logged in to reply to this topic.