Kirk Wallace wrote:
> There is a ModBus feature in Classic Ladder, but it seems to me that an
> HAL component specifically for the ModIO peripheral would be useful.
> ModBus may be a standard, but peripherals that use ModBus vary widely.
> My thinking is that each peripheral needs its own HAL component that
> provides HAL pins covering the peripheral's features. ModBus would be
> handled in the background. Handling multiple peripherals may be an
> issue, but handling a single unit per serial port should be "easy" for
> someone comfortable with writing software. I started work on this a
> while back, but I have not had time to get back to it.
>

Hi Kirk,

There are 2 parts here. The Modbus interface basically transfers registers
or discretes between a  Master (EMC) and Slaves(ModIO). You can almost
look at it as shared memory between the master and slave. What EMC does
with the data that it receives via the interface has nothing to do with
the Modbus Standard.

EMC requires a Modbus Master module to be implementd. There are a number
of opensource projects that could be used to achieve this.

There would then need to be a way of scheduling the transfer of data
between each slave and the Master. The schedule would contain the
sub-address of the slave, the registers to be read or written, and the
rate that the transfer is to occur.

The Data from the slaves could be placed in a register array (1 array for
each transaction).


The 2nd part is device specific and is how you get EMC to interact with
the slave through the register transaction arrays. This is where the HAL
comes in to play? The idea is that if you wanted to control a discrete
output on a PLC, you would set up a transaction to write a value from the
array to the register(s) in the PLC. This would be specified at a rate
appropriate to the output, say 5Hz, 25Hz, etc. Then if EMC set the value
in the register array, it would be transferred to the PLC, turning on the
output.


Cheers,

Peter.







-------------------------------------------------
http://www.homanndesigns.com


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to