inacio89

Forum Replies Created

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • in reply to: Need Help Building Wire Bot #6850
    inacio89
    Member

    Hey Guys,

    Everything has arrived! I connected the power supply to the TinyG, as well as, all four motors. I first ran the python code from Riley for three motors and it ran fine. I had to modify some of the code from python 2 to 3, but it works fine with three motors now.

    The issue I am having is zeroing the forth motor. I am able to control all four motors using the “G0 X Y Z A” command, but the 4th motor lets out a lot of line in the beginning of each program. Once it lets out a bunch of line, it runs fine, which is why I think the issue has to do with zeroing.

    I am sure that something is wrong with my gcode, I just do not the proper method of zeroing the 4th axis.

    def Zero(self):
            """This is the zeroing function.  This function
            once ran, should return the length of line to (0,0,0) from each vertex"""
            
            print("Zeroing Function Called")
            value = self.baseEQ(self.ZER0)
            print("G92 X%s Y%s Z%s A%s\n" % (value[0],value[1],value[2],value[3]))
            self.s.write(bytes("G92 X%s Y%s Z%s A%s\n" % (value[0],value[1],value[2],value[3]), 'UTF-8')) #this line sends Gcode commands to tinyG
    in reply to: Need Help Building Wire Bot #6816
    inacio89
    Member

    cmcgrath5035, yes, I need four independent linear moves.

    I found this on the synthetos website: https://www.synthetos.com/grblshield-wirebot/

    It outlines pretty much what I am attempting to do, except I would like to control four stepper motors instead of three and I am using a a tinyG instead of a grblshield. Riley wrote a Python program that reads Gcode files, transforms them into X,Y and Z wirebot coordinates and sends commands to grbl. The grbl is connected to an Arduino which then communicates with the stepper motors.

    The math is the same as what I did. As you stated, I inputted the equations into an excel sheet with three inputs (x,y,z), which output the length of wire for each motor.

    What I do not understand is how does this Python program communicate with the grbl? Can this python program communicate directly with my tinyG without modifying the code? I do not know how to code in Python.

    Thanks for your help.

Viewing 2 posts - 1 through 2 (of 2 total)