MIAC - MODBUS

For MIAC users to discuss projects, applications, and any other issues related to the MIAC unit.

Moderators: Benj, Mods

Post Reply
SAutoMotive
Posts: 5
Joined: Thu Jul 31, 2014 2:21 pm
Has thanked: 1 time
Been thanked: 1 time
Contact:

MIAC - MODBUS

Post by SAutoMotive »

Good evening all,

Maybe a bit stupid question, but I am struggeling a bit with using the FC7 and a new dsPIC MIAC(without wireless/bluetooth).
Till now I was working with CANbus communication and that works very fine. (both standard and extended messages)

Now I want to communicate onto the RS232 with MODBUS RTU, but I cannot get this working...
MODBUS is quite new to me, I am working in the automotive world and there is everthing about CANbus, no MODBUS.
(hope that you will help me starting with this stuff...)

I am looking for a very simple example to get a MIAC communicating onto Modbus, both as slave and as master.
Have found the examples on the Flowcode Wiki, but I think I made some mistakes is setting up the communication, because I cannot find any data with my laptop onto the RS232 output of the MIAC.(using the CAS MODBUS scanner)

To be sure about the connections/jumpers inside the MIAC:
On page 11 of the datasheet is a picture of the jumpers inside, which one is correct for MODBUS on RS232?
http://www.matrixtsl.com/resources/file ... C-60-3.pdf

Connecting the RX, TX and GND is enough to get the MODBUS working, isn't it? I can't find a proper answer if I need the CTS and RTS also...

Thanks in advance!!

User avatar
LeighM
Matrix Staff
Posts: 2178
Joined: Tue Jan 17, 2012 10:07 am
Has thanked: 481 times
Been thanked: 699 times
Contact:

Re: MIAC - MODBUS

Post by LeighM »

Hi,
Yes, RTS/CTS are not used by the Modbus component, so the default link settings, giving RS232 and RS485 interfaces, should be used...
default_links.jpg
default_links.jpg (21.79 KiB) Viewed 8288 times
For RS232 use hardware UART(0) Channel 1 on Port E pins 0 and 1
rs232master.jpg
rs232master.jpg (28.99 KiB) Viewed 8288 times
Hope that helps,
Leigh

SAutoMotive
Posts: 5
Joined: Thu Jul 31, 2014 2:21 pm
Has thanked: 1 time
Been thanked: 1 time
Contact:

Re: MIAC - MODBUS

Post by SAutoMotive »

Hi Leigh,

Thanks for your answer!
These settings are used in my test projects...

To be sure, which pin is used for the GND connection?
Just the normal GND of the MIAC or the 0R of the inputs, does this matter?

Could you give some advise in what kind of MODBUS logger/monitoring software works well?

User avatar
LeighM
Matrix Staff
Posts: 2178
Joined: Tue Jan 17, 2012 10:07 am
Has thanked: 481 times
Been thanked: 699 times
Contact:

Re: MIAC - MODBUS

Post by LeighM »

To be sure, which pin is used for the GND connection?
Just the normal GND of the MIAC or the 0R of the inputs, does this matter?
Use the normal GND (0R is for analog inputs ground)
Could you give some advise in what kind of MODBUS logger/monitoring software works well?
I've no recommendations on that, but I'm sure there are others on the forum that have :D

EtsDriver
Posts: 444
Joined: Tue Apr 15, 2014 4:19 pm
Location: Kajaani, Finland
Has thanked: 345 times
Been thanked: 227 times
Contact:

Re: MIAC - MODBUS

Post by EtsDriver »

I use mbpoll for debugging/logging modbus data.
http://www.modbustools.com/modbus_poll.html
Ill just keep the good work up!

User avatar
Steve001
Valued Contributor
Valued Contributor
Posts: 1189
Joined: Wed Dec 31, 2008 3:37 pm
Has thanked: 460 times
Been thanked: 523 times
Contact:

Re: MIAC - MODBUS

Post by Steve001 »

Success always occurs in private and failure in full view.

SAutoMotive
Posts: 5
Joined: Thu Jul 31, 2014 2:21 pm
Has thanked: 1 time
Been thanked: 1 time
Contact:

Re: MIAC - MODBUS

Post by SAutoMotive »

Hi Steve,

Thanks!

Yesterday I found this program and it was very useful!

Post Reply