Comments (9)
For sure, but at the time the library was written it was an high value to negotiate with the CPU to receive a less or equal value. For my opinion, with the 1500, it need to increase the size of PDU, because of larger objects too. It is an endless question, but the library will not change his behavior.
from python-snap7.
Why do you need to extend the PDU size ?
I can be interesting to use your ctor but it need some rework, I will look at it next week.
Moreover, it differ from the base snap7 ctor behavior not sure it will be accepted !
from python-snap7.
Why do you need to extend the PDU size ? I can be interesting to use your ctor but it need some rework, I will look at it next week. Moreover, it differ from the base snap7 ctor behavior not sure it will be accepted !
I need a large PDU to do data acquisition of large db with hightest speed (DAQ rate).
I dont know what is ctor.
from python-snap7.
Ok,
Normaly the PDU size is negotiated with the PLC, As for my knowledge a 1500PLC need to negotiate with HIS size (960).
What is your CP paramaters ? Do you change something on TIA Portal about the size of the PDU, if yes, please share some screenshots?
CTor : It's just shorthand for "constructor" - and it's what the constructor is called in Intermediate Language, too.
from python-snap7.
Ok, Normaly the PDU size is negotiated with the PLC, As for my knowledge a 1500PLC need to negotiate with HIS size (960). What is your CP paramaters ? Do you change something on TIA Portal about the size of the PDU, if yes, please share some screenshots?
CTor : It's just shorthand for "constructor" - and it's what the constructor is called in Intermediate Language, too.
CP parameters ? I just did a regular snap-python db_read(). On plc side just normal security configuration to allow snap7 communication.
ok about Ctor.
from python-snap7.
CP stands for Communication Processor, it is the "component" that handle the S7 protocol before processing (with the params like type of packet/Protocol, PDU, ...), historicaly it is to have the flexibility to handle other protocols with adding an CP Card (PROFIBUS-DP, OPC, OPCUA, PROFINET), like the CP-1542 to handle PROFIBUS DP on the 1500 Family.
If you don't use any CP card, you use the built in CP "component" from your 1500 PLC, this "component" negotiated with your external device. They commicate through S7 Protocol in your case, and will define the PDU size of their communication.
It is known issue in the low-lewel base library, see the answer of the maintainer of snap7
Your code is working but it is more like a "hot fix" until there is a change in the base snap7 package
from python-snap7.
CP stands for Communication Processor, it is the "component" that handle the S7 protocol before processing (with the params like type of packet/Protocol, PDU, ...), historicaly it is to have the flexibility to handle other protocols with adding an CP Card (PROFIBUS-DP, OPC, OPCUA, PROFINET), like the CP-1542 to handle PROFIBUS DP on the 1500 Family.
If you don't use any CP card, you use the built in CP "component" from your 1500 PLC, this "component" negotiated with your external device. They commicate through S7 Protocol in your case, and will define the PDU size of their communication.
It is known issue in the low-lewel base library, see the answer of the maintainer of snap7
Your code is working but it is more like a "hot fix" until there is a change in the base snap7 package
??? I dont see any issue about negociating PDU size...
from python-snap7.
The negotiated PDU Size is send by the PLC, if they ask for 480, the PLC will accept it because it has the capability to do it.
If you want more you need to declare it with a SetParam
request, but, for me the 480 bytes values was for the old CPU 300/400, today the 1500 can do more, but the library didn't change this default value when negotiating with 1500 CPU's
from python-snap7.
The negotiated PDU Size is send by the PLC, if they ask for 480, the PLC will accept it because it has the capability to do it.
If you want more you need to declare it with a
SetParam
request, but, for me the 480 bytes values was for the old CPU 300/400, today the 1500 can do more, but the library didn't change this default value when negotiating with 1500 CPU's
Ok I understand but no where says that the default PDU size sould be the maximum.
from python-snap7.
Related Issues (20)
- Can not use this library to read timers of simatic S7-200 smart PLC HOT 2
- Redundant 400-H get_cpu_state() returning incorrect value.
- Add python 3.12 support, build wheels HOT 2
- RuntimeError: b' ISO : An error occurred during recv TCP : Connection timed out'
- Error in util.Set_String and util.Get_String
- as_db_read() doesnt work
- Wrong values set_lreal
- db[0]['x']=22.33 raises ValueError HOT 2
- Improve doc for area_read in client HOT 2
- Communication between PLC and PC HOT 1
- Can't read from S210 Drive
- Get data block layout
- TypeError: '_ctypes.PyCArrayType' object is not subscriptable HOT 1
- Make client and server a contextmanager HOT 1
- Drop Python 3.8 from metadata and doc HOT 1
- Drop Snap7Library singleton and use python functools caching HOT 1
- version 1.4 broken on python 3.8 HOT 2
- Snap7Exception is not used HOT 1
- Replace `OrderedDict` with the built-in `dict` HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from python-snap7.