Industrial Communications

cancel
Showing results for 
Search instead for 
Did you mean: 

Modbus RTU with Compact Fieldpoint

I have a Compact Fieldpoint cFP-1804 that I'm trying to communicate with over Modbus RTU.

I'm running Labview 2012 and I can communicate with it in MAX and with the Labview Measurement I/O vi's so I know it connected and talking.

I upgraded the firmware to 6.08 and anything above 6.03 supposed to work with Modbus.

I have the Com Port opened with 38400 baud, 8 bits, 1 stop bit, no parity and no flow control which is exactly as specified in the cFP quick start guide.

 

 

Additionally, the system works perfectly with Modbus TCP. I can easily get data from the unit so I know I'm talking to a valid address and requesting the correct number of bytes.

I was unsure of the correct slave address to use, but this thread says the default is 1. I stepped through all 255 choices just to make sure, no luck.

 

All attempts to communicate over Modbus RTU result in a timeout with no response. What am I overlooking? Does version 6.08 firmware even work with Modbus RTU? What am I overlooking? 

—Ben
Prevent your computer from sleeping programmatically!
Use Power Requests
Download from GitHub

0 Kudos
Message 1 of 10
(6,990 Views)

Hi Ben, 

 

I assume you found the resources here and here. I suspect the serial setup. You can try a serial out startup, as explained in the first link and make sure your serial connection is correct. 

 

Modbus RTU should work with 6.0.8

Jesse Dennis
Engineer
INTP
0 Kudos
Message 2 of 10
(6,975 Views)

Jesse, 

     Thanks for the quick reply. 

     Yes, I have both of those resources. I suspect my serial setup too but can't determine what it might be. The Quick Start guide states on pages 15 and 24 that the unit needs 1 start bit, 1 stop bit, 8 data bits, no parity and no flow control. As you can see from my attached screenshot I do have those parameters set correctly. I also believe that I have the wiring correct because the unit communicates with MAX. 

     I also know that I have the modbus command being built correctly because it works with Modbus TCP. 

     I'll try the console out later today and let you know how it works. 

 

--Ben

—Ben
Prevent your computer from sleeping programmatically!
Use Power Requests
Download from GitHub

0 Kudos
Message 3 of 10
(6,966 Views)

I logged teh output from the console: 

 

cFP-180x Boot


Copyright 2005 National Instruments Corporation

 

 

CPU: National Instruments Coronado
OS Version: VxWorks5.5.1
BSP version: 1.0/0
Creation date: Sep 12 2005, 15:59:44

Boot ROM v1.00.0009

 

Press any key to stop auto-boot...
1 0
auto-booting...


boot device : rom
unit number : 0
processor number : 0
host name : lvrt
file name : vxWorks
flags (f) : 0x8

Booting firmware from ROM, CRC = e5a0ab5d
5454192
Starting at 0x10000...

Serial console active -- not starting industrial protocols on serial port
Initializing network...
Attaching interface lo0...done
Attached TCP/IP interface to motfec unit 0
Device 1 - MAC address: 00:80:2F:10:96:0E - 10.0.0.3 (primary)

 

Clearly my serial settings are correct. Is it possible my hardwareis so old that if doesn't support Modbus?

 

--Ben

—Ben
Prevent your computer from sleeping programmatically!
Use Power Requests
Download from GitHub

0 Kudos
Message 4 of 10
(6,956 Views)

I just made a test project to try the built in IO Server Modbus. 

Once again, it works perfectly with Ethernet/TCP and fails completely with Serial/RTU.

 

 

 

—Ben
Prevent your computer from sleeping programmatically!
Use Power Requests
Download from GitHub

0 Kudos
Message 5 of 10
(6,932 Views)

Hi Ben,

 

According to the help documentation as long as you have the firmware 6.03 or higher cFP-180x can function as a Modbus slave device. Please look at this post for more information. 

 

Regards

Arham H
Applications Engineer
National Instruments
0 Kudos
Message 6 of 10
(6,930 Views)

Yes, as I stated in my original post I have version 6.08 and I also linked to the exact same thread that you just did. 

 

 

—Ben
Prevent your computer from sleeping programmatically!
Use Power Requests
Download from GitHub

0 Kudos
Message 7 of 10
(6,925 Views)

Hi Ben,

 

Have this worked in the past? What version of LabVIEW are you using? Have you tested it in a different version?

 

Regards,

steve.bm
AE | NI
0 Kudos
Message 8 of 10
(6,903 Views)

I'm using a Windows 7 Professional 64bit machine and I'm running Labview 2012 32bit. 

 

I upgraded my cFP unit from 6.01 to 6.08 just a few days ago.  This is my first attempt at talking to a cFP unit with Modbus but I know Modbus works in general since I can talk to other things with Modbus RTU. 

 

I have not tetsed the cFP with a different version of Labview but I have tested Modbus in general with earlier versions of Labview. 

 

Thanks, 

 

--Ben

—Ben
Prevent your computer from sleeping programmatically!
Use Power Requests
Download from GitHub

0 Kudos
Message 9 of 10
(6,899 Views)

Hi Ben,

 

Could you do a quick test and try this application with Modbus, the cFP and LabVIEW 2013? You can download a trial version here.

 

Regards,

steve.bm
AE | NI
0 Kudos
Message 10 of 10
(6,886 Views)