Hello Guest it is March 28, 2024, 03:54:34 PM

Author Topic: Might wanna build modbus controller: TCP vs USB?  (Read 6669 times)

0 Members and 1 Guest are viewing this topic.

Might wanna build modbus controller: TCP vs USB?
« on: January 01, 2009, 02:42:43 AM »
I do a lot of microcontrollers.  I am considering making a modbus controller to move away from my problematic parallel port, maybe work with a laptop, whatever.

So I could use serial modbus through the RS232 serial port or go through USB, OR TCP with an ethernet connection, right?
I probably wouldn't use RS232 at this point.  Lotsa minor reasons not to do that.

As far as USB vs ethernet, what are the pros and cons when we're talking about a CNC controller?  Will modbus eliminate the problems of losing steps if say some piece of software wakes up and decides to check for updates or whatever when Mach is running?
« Last Edit: January 01, 2009, 03:10:20 AM by MechanoMan »
Re: Might wanna build modbus controller: TCP vs USB?
« Reply #1 on: January 01, 2009, 03:16:32 PM »
Modbus is a multi drop peer to peer messaging commutation protocol and its not  fast enough to use for motion control so this Will increase
the problems with lost steps and slow machine responses  plus there is no to transmit ASCII cmds thru modbus in mach so sending part programs to motion controller will be of great challenge

So check out www.modbus.org for more facts a details

As far as software updates they all need to be turned off or they will stall and can crash your machine tool

If your plans are to build a closed loop motion controller  Ethernet is the way to go of if you would like to really make your head hurt
maybe a motion controller with bluetooh communications
Adam
Re: Might wanna build modbus controller: TCP vs USB?
« Reply #2 on: January 01, 2009, 03:33:54 PM »
Well, does Mach3 have support for a straight motion controller protocol, and is the specification published?

Yeah are individual pulses actually being send out on the modbus, rather than a motion command (50 steps on this motor with this frequency)?

I could always just send G-code to the controller via a modem protocol with on/off flow control.  That's complicated to implement because there's quite a few less common G-codes that might come up (automatic arcs, drilling cycles, etc).  Sucks since a drilling cycle is a number of moves that COULD be conveyed as simple moves.  This whole idea does bypass much of Mach3's functionality though, a lot of which is helpful.  Acceleration profile for one.  Actually at this point Mach3 probably wouldn't be involved at all if I'm just sending G-code over with a terminal program, losing all the benefits of Mach3's control panel and position tracking and all.

Ideally I'd love to find out that Mach3 had a motion control plugin that sent compressed data with a few basic commands (513 pulses on this motor with this frequency) and all the drills and auto-arcs were changed into this format, and some sort of feedback on the link that would prevent the buffer from overrunning or underruning if there were some minor differences in the time Mach3 thinks it takes to complete each task and the time the controller actually needs to complete each task.
« Last Edit: January 01, 2009, 04:24:47 PM by MechanoMan »
Re: Might wanna build modbus controller: TCP vs USB?
« Reply #3 on: January 01, 2009, 07:59:56 PM »
There some motion control plugins that have been written for galil 17xx 18xx series ,dspMC/IP motion controllers , smooth stepper  these are separate hardware devices that do all the motion control thru cmd from mach

check out the plugins under the downloads tab at the top of the page u may find some helpful information there

well as far as the sending straight g-code to an controller thats getting over my head
maybe post something over in the mach SDK forum they might have an answer for that
Adam
Re: Might wanna build modbus controller: TCP vs USB?
« Reply #4 on: January 01, 2009, 08:29:00 PM »
Well, but are those protocols documented?
I saw where there were plugins but that's not anything useful to work from;  IIRC I tried downloading some of those and found no documentation on what they did just how to install them.  Are they not documented because they want to keep them proprietary, or was the documentation just not placed with the plugin?
Re: Might wanna build modbus controller: TCP vs USB?
« Reply #5 on: January 02, 2009, 08:00:46 AM »
 MechanoMan,

The plugins do have documentation they are at the manufactures web site there are web links
where u downloaded the plugins under website next to the plugin its self
Also in the mach forum there dedicated subjects to each motion controller
Adam