Creating HMI With MS Excel and HINET Modbus DDE Server

H

Thread Starter

Heru Iqbal

Not difficult to create HMI applications using Microsoft Excel and HINET Modbus DDE Server.
The steps are ]:

<b>MODERATOR'S NOTE: If you do this please let us know how it works. Thank you</b>

1. Download HINET Modbus DDE Server application here -> https://dl.dropboxusercontent.com/u/3351822/HINETIOServer.rar

2. Extract the two files (HINET.exe and HINET.mdb) into a folder.

3. Run HINET.exe

4. Enter the Serial Number of the product Hinet you use, then click the Verify button.

Figure: https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_01.jpg

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_02.jpg

5. Fill in your details on the Company Name , Contact Person , User Name and Password , then click the save button.

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_03.jpg

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_04.jpg

6. Next.. click the Configure menu , and select the sub-menu "DDE Topic Definition"

Figure :
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_05.jpg

7. After that , enter the User Name and Password that you created before.

Figure :
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_06.jpg

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_07.jpg

8. Next... click the 'New' button.

Figure :
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_08.jpg

9. After that, input the details of the configuration of a Modbus Slave device that you want to poll.

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_09.jpg

10. And then, create a DDE Item Name Tag , complete with modbus address, data type and length, one by one..

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_10.jpg

11. When it is filled , then click OK. So application back to DDE Topic Definition Window. If you have finish, then click 'DONE'.

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_11.jpg

12. Furthermore .. Run Microsoft Excel and create a new Worksheet.

13. In the Formula Bar , complete with DDE functions like the example below:
= HINET|omni!year

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_12.jpg

14. After that, go back to take another DDE Item name tag that has your configuration in HINET Modbus DDE Server.

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_14.jpg

15. Now you can monitor a real-time data that is in the Modbus device usin Microsoft Excel and HINET Modbus DDE Server

Figure:
https://dl.dropboxusercontent.com/u/3351822/HINET_Frame_13.jpg

Thank you for your attention.
 
H
<b>MODERATOR'S NOTE:</b> If you do this please let us know how it works. Thank you

Thank you Mr. Moderator.

I'm sorry if my english not good, so i will explain to you with my language BAHASA INDONESIA.

<b>Moderator's second note:</b> put this through Google translate and am posting the translation first.

Hinet DDE Server is a modbus master application that I developed using the language of BORLAND DELPHI 5 .

As for storing the data required TAG ITEMS user, I use MS - &#8203;&#8203;ACCESS as database.

When the user is finished configuring the TAG ITEMS, then the program will automatically compile FRAME - FRAME MODBUS REQUEST .

Examples of Tag Items made &#8203;&#8203;by user:

Tag Item Name: hour
Address: 3867
Length: 1
Data Type: Integer 16 -bit signed

Tag Item Name: minute
Address: 3868
Length: 1
Data Type: Integer 16 -bit signed

Tag Item Name: second
Address: 3869
Length: 1
Data Type: Integer 16 -bit signed

Tag Item Name: month
Address: 3870
Length: 1
Data Type: Integer 16 -bit signed

Tag Item Name: day
Address: 3871
Length: 1
Data Type: Integer 16 -bit signed

Item Name Tag: year
Address: 3872
Length: 1
Data Type: Integer 16 -bit signed

Then this program will develop into 1 MODBUS FRAME REQUEST:
1B 0F 00 00 00 06 05 03 0F 00 06 1B

If you notice, I made use of 2 bits Frame TRANSACTION INDENTIFER into the address register. It is useful for me to know what the address registers are answered by the MODBUS SLAVE .

Sample answers I received from the Modbus Slave:
1B 0F 00 00 00 0F 05 03 0C 00 17 00 05 00 34 00 0A 00 0E 00 0E

2 this is the first bit as my reference to know the Address Register is sent by the Modbus Slave.

After receiving an answer from the Modbus Slave, the data I store in the array to be sent via DDE to the user.

all TAG ITEMS user requested, I sent it to MODBUS SLAVE via TCP/IP in one single shipment only every 1000 ms using MODBUS REQUEST FRAME 1.

Example Request that I send to Modbus Slave:
1B 0F 00 00 00 06 05 03 0F 00 06 1B 1B SW 00 00 00 06 01 03 00 06 SW 1B 1C 21 00 00 00 06 01 03 1C 21 00 06 13 F5 00 00 00 06 01 03 13 F5 00 04

Hence my reason why I was using FRAME TRANSACTION Identifer as a code address registers, so the answer sent by the Modbus Slave addresses can be determined easily registers.

Similarly, I can explain, Thank you for your attention .

Regards ,
Heru Iqbal

<b>Original Indonesian follows</b>

HINET DDE Server adalah sebuah aplikasi modbus master yang saya kembangkan dengan menggunakan bahasa pemogramman dari BORLAND DELPHI 5.

Adapun untuk menyimpan data-data ITEM TAG yang dibutuhkan user, maka saya menggunakan MS-ACCESS sebagai databasenya.

Ketika user selesai mengkonfigurasi ITEM-ITEM TAG, maka program ini secara otomatis akan menyusun FRAME-FRAME MODBUS REQUEST.

Contoh Item-Item Tag yang dibuat user :

Item Tag Name : hour
Address : 3867
Length : 1
Data Type : Integer 16 bit signed

Item Tag Name : minute
Address : 3868
Length : 1
Data Type : Integer 16 bit signed

Item Tag Name : second
Address : 3869
Length : 1
Data Type : Integer 16 bit signed

Item Tag Name : month
Address : 3870
Length : 1
Data Type : Integer 16 bit signed

Item Tag Name : day
Address : 3871
Length : 1
Data Type : Integer 16 bit signed

Item Tag Name : year
Address : 3872
Length : 1
Data Type : Integer 16 bit signed

Maka program ini akan menyusun menjadi 1 MODBUS FRAME REQUEST :
0F 1B 00 00 00 06 05 03 0F 1B 00 06

Jika anda perhatikan, saya memanfaatkan 2 bit Frame TRANSACTION INDENTIFER menjadi address register. Hal ini berguna buat saya untuk mengetahui address register apa yang dijawab oleh MODBUS SLAVE.

Contoh jawaban yang saya terima dari Modbus Slave:
0F 1B 00 00 00 0F 05 03 0C 00 17 00 05 00 34 00 0A 00 0E 00 0E

2 bit pertama inilah sebagai acuan saya untuk mengetahui Address Register yang dikirim oleh Modbus Slave.

Setelah mendapat jawaban dari Modbus Slave, data-data tersebut saya simpan ke dalam Array untuk dikirim via DDE kepada user.

semua ITEM-ITEM TAG yang diminta user, saya kirim ke MODBUS SLAVE via TCP/IP hanya dalam satu kali pengiriman saja setiap 1000 ms dengan menggunakan 1 FRAME MODBUS REQUEST.

Contoh Request yang saya kirim ke Modbus Slave :
0F 1B 00 00 00 06 05 03 0F 1B 00 06 1B BD 00 00 00 06 01 03 1B BD 00 06 1C 21 00 00 00 06 01 03 1C 21 00 06 13 F5 00 00 00 06 01 03 13 F5 00 04

Oleh karena itu lah alasan saya kenapa saya menggunakan FRAME TRANSACTION IDENTIFER sebagai kode address register, agar jawaban yang dikirim oleh Modbus Slave dapat diketahui dengan mudah addres registernya.

Demikian yang bisa saya jelaskan, Terima kasih atas perhatiannya.

Salam,
Heru Iqbal
 
Top