Brother TC-225 Retrofit and Robot integration

More
15 Feb 2021 20:22 - 15 Feb 2021 20:22 #198971 by timfaber
Hi!
Let me start of by introducing myself. I’m Tim Faber, I’ve recently gotten my bachelors degree and am currently working on my masters degree both in mechanical engineering. Now I’ve always liked machining and have even build my own CNC machine some time ago. But sold it recently and found something else to be in over my head, but that’s when you learn most I guess.

I’ve recently purchased a Brother TC-225 and since it is an rather old control I would like to upgrade it to Linuxcnc using a Mesa card. In the topic of ihavenofish he did have some trouble tuning the stock drives for the axis, nevertheless I will have a go at it as well since I can always choose the more expensive route of buying new drives and motors.

Now we also have a robotic arm with (again) a outdated control, we would like to explore the possibilities of also controlling it Linuxcnc through a Mesa Card. I believe the motors and drives in the robot can be reused and take +/-10v. And thinking about the possibilities maybe for a bit too long I wondered if I could program a part in fusion merge it with program which controls the robot and load the whole file into Linuxcnc.

After some googling I came across a post of Machine Koder now I will not be replicating his work anytime soon (i think). But I came up with the idea to use V-rep as a simulation software, and export the robot movement in some way that Linuxcnc can understand it and just pass it along to the robot drives. Perhaps straight g-code? Which will obviously not make much sense to the human reading it since it will be controlling multiple axis at a time with seemingly arbitrary angle movements.

Now to sum up the main program that I would like to load into Linuxcnc (probebasic) would look something like the following:
1) Subprogram (pre-machining robot movement, generated by v-rep)
2) Subprogram (actual machining, generated by fusion 360)
3) Sub program (post machining robot movement, generated by v-rep)

Now there is a lot to figure out to see if this is even possible. And there are many question, some of which I hope the knowledgeable folks of this forum could help me answer. I’ve listed a bunch of the questions that came to mind below and will put some of the answers I have below them. To be clear, currently I have not invested/committed in any solution direction yet. All I have is the brother TC-225 and the robot.

Questions:
- What Mesa board to use?
- How many axis need to be driven?
- What is the communication with the drives of these axis?
- How many I/O are needed?
- Can we control the robot with Linuxcnc?
- Does G-code/Linuxcnc support the required number of axis?
- Can we make subprograms to control the robot?
- What language can be used in subprograms, only g-code or could we use python for some operations?
- Can we use V-rep?
- Can we use V-rep to simulate?
- Can we import 3D models ?
- Can we simulate with these 3D models?
- Can we use v-rep to export the simulations movements to something Linuxcnc can work with?

(there was some hierarchy in the questions but they disappeared here)

Now on my end there are some questions that I still need to answer since they are crucial information, like number of axis and their interfaces. But I’ve chosen to post this now anyway to hopefully get some feedback.
Now please feel free to answer some questions, add some questions to the list and share your concerns and opinions.
Last edit: 15 Feb 2021 20:22 by timfaber.

Please Log in or Create an account to join the conversation.

More
15 Feb 2021 22:03 #198992 by andypugh
LinuxCNC can control a robot directly. With the right kinematic module the G code controls the end-effector position and the kins works out the angle for each joint.

Take a look at the sim->axis-> vismach -> Puma example config.

Please Log in or Create an account to join the conversation.

More
16 Feb 2021 10:24 #199036 by timfaber
Alright that is nice! I will take a look at the puma example. Are there any other good posts that you know of that have done something similar?

Please Log in or Create an account to join the conversation.

More
16 Feb 2021 15:23 - 16 Feb 2021 15:42 #199071 by Aciera
Quite a few of those questions would have to be answered by you. :)
How many axis you need to drive depends on how many joints the robot has and how many axis the mill. Same for I/O, no idea what your machine needs to have. Coolant, safety switches, spindle, limit switches, user panel ....
You can use subprograms in GCODE but there also is a python interface.

Don't know anything about V-REP so I can't comment.

I presume the robots drives and encoders are already closed loop? if not you would need to figure out if the encoders can be read into LCNC.

Do you need the robot to do pick and place (ie machine tending) or were you envisioning machining with it?

With one instance of LCNC you can control 9 independent axis XYZABCUVW. If your mill has 3 axis and your robot has 6 axis you might be able to control both in the same code if you use trivial kinematics. If you go that way you will need to provide the angular joint position for the robot in the GCODE.
Another possibility could be to use two instances of LCNC running on different PCs and just initiate a preprogrammed move over digital IO or linuxcncrsh (remote shell connection)

I've got a 6axis robot working with LCNC:

www.forum.linuxcnc.org/38-general-linuxc...r-usability?start=10


[edit]
Just to be clear about this: While you certainly CAN control a robot using LCNC this is very much off the beaten track and along the borderlines of what is possible to achieve.
Last edit: 16 Feb 2021 15:42 by Aciera.
The following user(s) said Thank You: timfaber

Please Log in or Create an account to join the conversation.

More
16 Feb 2021 15:25 - 16 Feb 2021 15:34 #199072 by Roiki
You can control the robot with linuxcnc but its suboptimal and doesnt support all the normal functions the original controller does. If all you need is simple controls, it can be made to work for simple setups.

Its nowhere near a proper robot controller though.

Also that puma kinematics module is old, buggy and doesn’t work nearly well enough for production use.

Imo your best bet to integrate a cnc machine and a robot is to make two different controls with their own programs. Your CNC signals the robot to load a part. The robot runs a program that loads a part, then signals the cnc its done and it can start. Then when the cnc mill is finished it can signal the robot its done and it can run another program which picks up the part etc whatever you want. This is the way its commonly done with industrial robots. The integration should be easy enough for just setting up IO pins, or coded with python if you want more control(but a lot more work).
Last edit: 16 Feb 2021 15:34 by Roiki.
The following user(s) said Thank You: timfaber

Please Log in or Create an account to join the conversation.

More
13 Mar 2021 13:17 #202093 by timfaber
Thanks for the great advice, first step will be to get my brother running with linuxcnc. having some trouble connecting with the card. I can ping it but mesaflash doesn't recognize it. I'm running " Linux HuvemaCNC 4.19.0-11-rt-amd64 #1 SMP PREEMPT RT Debian 4.19.146-1 (2020-09-17) x86_64 GNU/Linux".
Now the first thing I've noticed is that my network manager looks different? no network editing options or what so ever.
I've got mesa flash 3.4.0 just (re) installed according to : github.com/LinuxCNC/mesaflash

What am i doing wrong? or should i use another distro like debian 9?

Please Log in or Create an account to join the conversation.

More
13 Mar 2021 16:24 #202109 by PCW
If you can ping the card address but mesaflash does not recognise the card
this usually means you have set the host IP address to the card IP address

So if you have set the card to 10.10.10.10, the host IP address should be
something like 10.10.10.100

Please Log in or Create an account to join the conversation.

More
13 Mar 2021 17:29 #202116 by timfaber
Well in the mean while i tried other options, got a new install and followed: forum.linuxcnc.org/9-installing-linuxcnc...easy-install?start=0
Now i run into other problems,
./install.sh
Hit:1 http://security.debian.org/debian-security buster/updates InRelease
Get:2 http://buildbot.linuxcnc.org buster InRelease [37.8 kB]
Get:3 http://buildbot.linuxcnc.org buster/2.8-rtpreempt amd64 Packages [25.7 kB]
Fetched 63.6 kB in 2s (33.7 kB/s)  
Reading package lists... Done
W: Skipping acquire of configured file 'buster/binary-amd64/Packages' as repository 'http://buildbot.linuxcnc.org buster InRelease' does not seem to provide it (sources.list entry misspelt?)
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package gdebi is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

Package wget is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'gdebi' has no installation candidate
E: Package 'wget' has no installation candidate
E: Unable to locate package linux-headers-4.19.0-9-common-rt
E: Couldn't find any package by glob 'linux-headers-4.19.0-9-common-rt'
E: Couldn't find any package by regex 'linux-headers-4.19.0-9-common-rt'
E: Unable to locate package linux-headers-4.19.0-9-rt
E: Couldn't find any package by glob 'linux-headers-4.19.0-9-rt'
E: Couldn't find any package by regex 'linux-headers-4.19.0-9-rt'
./install.sh: line 4: wget: command not found
sudo: gdebi: command not found
Executing: /tmp/apt-key-gpghome.oatQF0IZPq/gpg.1.sh --keyserver hkp://keys.gnupg.net --recv-key EF1B07FEE0EE663E
gpg: key EF1B07FEE0EE663E: "LinuxCNC Buildbot <nomail@linuxcnc.org>" not changed
gpg: Total number processed: 1
gpg:              unchanged: 1
Hit:1 http://security.debian.org/debian-security buster/updates InRelease      
Hit:2 http://buildbot.linuxcnc.org buster InRelease                            
Reading package lists... Done
W: Skipping acquire of configured file 'buster/binary-amd64/Packages' as repository 'http://buildbot.linuxcnc.org buster InRelease' does not seem to provide it (sources.list entry misspelt?)
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 linuxcnc-uspace : Depends: libboost-python1.67.0 but it is not installable
                   Depends: libmodbus5 (>= 3.1.4) but it is not installable
                   Depends: libreadline5 (>= 5.2) but it is not installable
                   Depends: libudev-dev but it is not installable
                   Depends: tk8.6 but it is not installable
                   Depends: bwidget (>= 1.7) but it is not installable
                   Depends: libtk-img (>= 1.13) but it is not installable
                   Depends: python2.7-glade2 but it is not installable or
                            python-glade2 but it is not installable
                   Depends: python2.7-imaging but it is not installable or
                            python-imaging but it is not installable or
                            python-pil but it is not going to be installed
                   Depends: python2.7-imaging-tk but it is not installable or
                            python-imaging-tk or
                            python-pil.imagetk but it is not going to be installed
                   Depends: python-gtksourceview2 but it is not installable
                   Depends: python-gst-1.0 but it is not installable
                   Depends: python-xlib but it is not installable
                   Depends: python-gtkglext1 but it is not installable
                   Depends: python-configobj but it is not installable
                   Depends: tclreadline but it is not installable
                   Depends: tclx but it is not installable
                   Depends: mesa-utils but it is not installable
                   Recommends: linuxcnc-doc-en but it is not going to be installed or
                               linuxcnc-doc
                   Recommends: python-pyqt5 but it is not installable
                   Recommends: python-pyqt5.qsci but it is not installable
                   Recommends: python-pyqt5.qtopengl but it is not installable
                   Recommends: python-pyqt5.qtsvg but it is not installable
                   Recommends: python-pyqt5.qtwebkit but it is not installable
                   Recommends: python-opencv but it is not installable
                   Recommends: python-rsvg but it is not installable
                   Recommends: python-dbus.mainloop.pyqt5 but it is not installable
                   Recommends: gstreamer1.0-tools but it is not installable
                   Recommends: python-espeak but it is not installable
                   Recommends: espeak but it is not installable
                   Recommends: pyqt5-dev-tools but it is not installable
                   Recommends: hostmot2-firmware-all but it is not installable
                   Recommends: linux-image-rt-amd64 but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
Finshed, you can reboot your PC now.
and the second method gave:
sudo apt-get -y install gdebi software-properties-common wget linux-headers-4.19.0-9-common-rt linux-headers-4.19.0-9-rt linux-image-4.19.0-9-rt-amd64
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package gdebi is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

Package wget is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'gdebi' has no installation candidate
E: Package 'wget' has no installation candidate
E: Unable to locate package linux-headers-4.19.0-9-common-rt
E: Couldn't find any package by glob 'linux-headers-4.19.0-9-common-rt'
E: Couldn't find any package by regex 'linux-headers-4.19.0-9-common-rt'
E: Unable to locate package linux-headers-4.19.0-9-rt
E: Couldn't find any package by glob 'linux-headers-4.19.0-9-rt'
E: Couldn't find any package by regex 'linux-headers-4.19.0-9-rt'

My guess something wrong with wget?
timfaber@Brother:~$ sudo apt-get install wget
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package wget is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'wget' has no installation candidate

Please Log in or Create an account to join the conversation.

More
13 Mar 2021 17:39 #202117 by timfaber
and updating apt-get gives:
timfaber@Brother:~$ sudo apt-get update
Hit:1 http://security.debian.org/debian-security buster/updates InRelease
Hit:2 http://buildbot.linuxcnc.org buster InRelease      
Reading package lists... Done                            
W: Skipping acquire of configured file 'buster/binary-amd64/Packages' as repository 'http://buildbot.linuxcnc.org buster InRelease' does not seem to provide it (sources.list entry misspelt?)

Please Log in or Create an account to join the conversation.

More
13 Mar 2021 17:45 #202118 by timfaber
I'm a big noob when it comes to Linux so all i can do is google the errors. I just want to get my machine running with probe basic and the mesa card. Not dick around with this stuff :'). if someone could tell me what distro to use or what "tutorial" to follow that would be highly appreciated :)

Please Log in or Create an account to join the conversation.

Moderators: cncbasher
Time to create page: 0.118 seconds
Powered by Kunena Forum