Home › Forums › TinyG › TinyG Support › Unusual use of TinyG (2 Dimensions)
- This topic has 2 replies, 2 voices, and was last updated 5 years, 2 months ago by MonkeyManGuy.
-
AuthorPosts
-
October 22, 2019 at 2:06 pm #11626MonkeyManGuyMember
I am searching for advice on how I can create a UI and Gocde that will enable me to run only 2 stepper motors from the TinyG. The machine I have created will polish the inside of paintball gun barrels. This involves pushing a rod in and out of the barrel several thousand times and rotating it each time its been retracted
I have 1 stepper motor connected to a belt drive for the X-Axis, and a second connected to the rod for rotation (y-axis for now).
Something along the lines of this should get the job done:
g0 x100
g0 x0
g1 y2
g0 x100
g0 x0
g1 y4
g0 x100………etcI need to learn how to attach these lines of code and get the TinyG to execute 1 line & then move to the next. Apperantly this is not done by seperating them with commas! lol
Next up is getting the process repeat for a set # of times and the ability to set the length of X travel a single time at the begining (to match the barrel length).
Does anyone have suggestions as to how to achomplish this?
October 22, 2019 at 3:08 pm #11627ZootalawsMemberYou don’t need to create a UI – there’s plenty out there to use.
Do you want to dedicate a computer to the job, or use a microcontroller or SBC like an ESP32 or Raspberry Pi?
If it was me, I’d buy a cheap Orange Pi clone and run some sort of GCode sender, like UGS: https://winder.github.io/ugs_website/
Load your Raspberry OS, load UGS, connect, send.
Doesn’t get much easier than that.
I would question the use of a TinyG for such a trivial task. A $10 Arduino shield would do the same job.
- This reply was modified 5 years, 2 months ago by Zootalaws.
October 22, 2019 at 6:12 pm #11629MonkeyManGuyMemberZootalaws, thanks for the reply. Ill look into UGS for my Raspberry Pi.
When searching I actually didnt see any Shields that would handle the 2 amps I need for the main motor. Theres a chance Ill have to upgrade that motor even so.
Further development will involve running 2 machines from this TinyG to utilize the other 2 motor ports, as well as getting the rod to twist while traveling on the X-axis, and having this twist slowly fade away over a few thousand repititions. Until it finishes on a straight line.
Theres also a feature I built in that will allow it to sense the pressure being applied to the rod; as if it drops too low the machine must halt for an adjustment. This could allow software to develop a map of the inside the barrel, where the internal diameter begins restricting or enlarging.
More complexity is certianly in the works for this TinyG. Im taking it 1 step at a time.
-
AuthorPosts
- You must be logged in to reply to this topic.