When Scada Comm send data to Scada Server.

Forum Home Forums Development and Integration When Scada Comm send data to Scada Server.

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #4939
    eurusyang
    Participant

    When Scada Comm send data to Scada Server,just like follow codes:

    
       byte[] buf = new byte[cmdLen];
       buf[0] = (byte)(cmdLen % 256);
       buf[1] = (byte)(cmdLen / 256);
       buf[2] = 0x03;
    

    when the cmdlen’s number more than 65536,the scada server can not receive the cmdlen.because you use two bytes to represent the length of cmdlen .overflow 2 bytes.

    When debug ScadaServer,The computer is very stuck.Why?
    and the ScadaComm runs long time,the memeory of ScadaComm become much bigger.Why?

    In ScadaServer/Comm.cs,

    
    private void ProcCommCommand(ClientInfo client, byte cmd, int cmdLen)
            {
                bool sendResp = true;    // отправить ответ на команду 
                int respDataLen = 0;     // длина данных ответа на команду 
                byte[] extraData = null; // дополнительные данные ответа
                switch (cmd)
    

    I think you can use Design Patterns to insteaed the switch method,the ProcCommCommand function is too long to beautiful.

    • This topic was modified 5 years, 2 months ago by Mikhail.
    #4942
    Mikhail
    Moderator

    when the cmdlen’s number more than 65536,the scada server can not receive the cmdlen

    Yes, this is a limitation.

    When debug ScadaServer,The computer is very stuck.Why?

    Depends on a computer hardware.

    ScadaComm runs long time,the memeory of ScadaComm become much bigger.Why?

    Can you provide memory usage chart?

    I think you can use Design Patterns to insteaed the switch method,the ProcCommCommand function is too long to beautiful.

    I agree. I hope this will be refactored in the future.

    #4944
    eurusyang
    Participant

    Dear Mikhail,
    as we all know,65535 bytes are not a lot,I need send tens of thousands of bytes to ScadaServer.I hope you can change the limit.
    My computer has 16G memory…When debug ScadaServer,also very card.
    ScadaComm runs 3 hours,ScadaComm Services is already used900M memory in task Manager.
    You are very nice and can respond to my news in time.

    #4947
    Mikhail
    Moderator

    is already used900M memory

    Seems not usual. Do you use the default configuration?

    #4948
    Mikhail
    Moderator

    I need send tens of thousands of bytes to ScadaServer

    Could you describe your system?

    #4951
    eurusyang
    Participant

    I use rapid scada in oil transmission system,there are so many data need send to scada server.I hope you can change the size.I do some change in your code to send data to server.

    #4953
    Mikhail
    Moderator

    I hope you can change the size.

    For a big system, you may need our assistance to research how Rapid SCADA works under the required load and what the bottle necks are. Changing either data formats or internal protocol may be a subject of a contract between our companies. This is a business model of our project and many other open source projects.

    #4955
    eurusyang
    Participant

    Thankes,I have changed the size.

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.