CODESYS - the IEC 61131-3 automation software

Welcome to the official CODESYS Forum by 3S-Smart Software Solutions GmbH | A member of the CODESYS Group
Deutsche Version English version russian version 
It is currently Mon Sep 16, 2019 4:01 am

All times are UTC+01:00




Post new topic  Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Thu Jan 08, 2015 8:31 am 
Offline

Joined: Tue Nov 04, 2014 3:45 pm
Posts: 21
Hello

I have a "big" Problem. ;-)
I would like to use the MAX485 for Modbus RTU on the UART Port (GPIO14 and 15). Everything is fine but for the MAX485 I need to change the direction (transmit or receive) with a pin.
If this GPIO pin is high i can send through the MAX485. If this GPIO Pin is low than the MAX485 can receive.

Now i have the Problem that canĀ“t get any direction variable from the Modbus library to toggle this Pin so im stuck at the moment.

Has someone maybe any idea

Greetings Christoph


Top
   
PostPosted: Thu Jan 08, 2015 8:59 pm 
Offline
Site Admin

Joined: Mon Sep 05, 2005 9:42 am
Posts: 3447
Hello Christoph,

I'm not really sure, but using MAX 485 on the tty is not really possible without having
handshake pins to give the direction. To workaround this by a kind of own implemented mechanism
will not lead to a reliable solution.
I would recommend to use a ready to use USB to RS485 Adapter instead implement this with a huge effort.

Maybe I am totally wrong and someone could give us a hint how to solve this with a MAX485 circuit.

Best Regards
Edwin


Top
   
PostPosted: Fri Jan 09, 2015 5:52 am 
Offline
Site Admin

Joined: Mon Sep 05, 2005 9:42 am
Posts: 3447
Hi Christoph,

maybe this links give more information at least an better explanation:

http://www.raspberrypi.org/forums/viewt ... 85#p514164
https://github.com/mholling/rpirtscts

Regards
Edwin


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 3 posts ] 

All times are UTC+01:00


Who is online

Users browsing this forum: No registered users and 8 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited