2/20/2018 9:49 PM | |
Posts: 1 Rating:
|
Hi all. I have found totorial on youtube how to read values from pac 3200 to siemens s7 1200. When I use example from that tutorial I can only read 3 voltages (L1 L2 L3), but how can I read all values (voltages,current,working time, etc...) from that device? And can you explain me why is he using M20 M24 M28? What I need to change so that I can read all values? Here is the video from youtube because I can't upload multiple images https://www.youtube.com/watch?v=5O_JGhXiDgs&t=340s Thank you all Attachment0-02-04-1364d5c4dab4817c958b889e01856fa50456d23a7aa4d4ea5e78bbc59fef3e87_full.jpg (728 Downloads) |
Last edited by: Jen_Moderator at: 2/21/2018 11:06:38 AMInserted video. |
|
2/20/2018 11:43 PM | |
Joined: 9/27/2006 Last visit: 9/4/2024 Posts: 12282 Rating:
|
Hello rifetgazdic; The answer to your questions is simple: you are reading 3 variables and placing the values in %MD 20, %MD24 and %MD28 because that is the way the Youtube presenter has programmed it. Look at the screenshot below, and forgive the picture, it was captured from the video you pointed to, with low resolution unfortunately. Note these 3 parameters: - MB_DATA_ADDRESS = 40002 (points to your start register in the Modbus registers of the PAC 3200) - MB_DATA_LENGTH = 6 (every register occupies 2 words, so this is for 3 FLOAT values) - MB_DATA_PTR = P#M20.0 BYTE12 (this is where you will place the selected values in the PLC, written as an ANY pointer: starting at address %MD20, with 3 consecutive REAL (float) registers: each float occupies 4 bytes, so a length of 12 bytes). So if you want to modify the number of registers read and the location the will be addressed in the PLC, you must change those parameter values. Here is the Modbus register mapping for the PAC3200: Semtron PAC3200 See section 3..9.3 for the Modbus register mapping Hope this helps, Daniel Chartier
|
Last edited by: dchartier at: 2/21/2018 12:05:36 AMLast edited by: dchartier at: 2/21/2018 11:27:05 PM |
|
This contribution was helpful to
2 thankful Users |
Follow us on