Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Serial Comunications with MODBUS protocol

Status
Not open for further replies.

protectt

Newbie level 1
Joined
Sep 17, 2002
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
10
Serial Comunications

Friends,

I am starting at the universe of microcontroller. I need developer a equipment to comunicate with a pc using a modbus protocol in an rs-485 network. Can Somebody help me??

Cleber 8O
 

use kind of mcu with uart (i prefer avr), then just connect uart output via level convertor (ex maxim) to rs485 equipment.

regards

cancel
 

if it is an easy application you can use pSOC by Cypressmicro, they have an appliction note on LIN bus that can be helpful.

Bye
 

Re: Serial Comunications

About RS485 network, you need a master and some slaves. You can use UART and an IC as SN75176 or Max485 to convert voltage level...
 

Re: Serial Comunications

It looks like your PC doesn't support the RS-485 standard. The simplest way to go would be to use an additional PCI card with RS-485 ports or, if you want to utilize available COM-port,to attach a RS-232-to-RS-485 converter. There are several types of converters some of which use the CTS line to switch between transmission and reception, but you can find converters which automatically performe this action and are also self powered.
Example: **broken link removed**
Regards,
IanP
 

Re: Serial Comunications

Provided you are prepared to write code from scratch you can implement the modbus protocol on almost any micro. It will help if you have a hardware UART, but with enough speed you could even do that in software. Obviously your hardware will need to include RS485 drivers and the ability to enable the enable the driver when your system is accessed.

Look for the specifications on http://www.modbus.org It even includes how to generate the checksum in C in one of the documents (MODBUS over Serial Line, Specification & Implementation guide V1.0).

I have scratched around recently and found that there are no app notes for the PIC on the Microchip web site, but I am sure a google search will yield some results. There must be plenty for the 8051 if you do a google search as well. There is certainly some discussion on the http://www.8052.com forum if you search for it.

The rabbit micro (**broken link removed**)comes with a modbus library, but I didn't end up using it and wrote my own.

As I said earlier, you can use any micro for this. Choose your micro and then search if there are any references to it and MODBUS on the web.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top