Umstieg von Codesys 2.3 auf 3.5

Begonnen von martin.k, 14. Dezember 2023, 22:04:55

Vorheriges Thema - Nächstes Thema

0 Mitglieder und 1 Gast betrachten dieses Thema.

martin.k

Hallo liebe Freunde der Nullen und Einer.

Ich muss notgedrungen von Codesys 2.3 auf 3.5 umsteigen.
Da es keine Network-Lib für die 3.5er Version gibt, stehe ich jetzt vor vielen Zeilen Code von dem ich nichts verstehe und nicht portieren kann.

Gibts vielleicht eine kleine Anleitung? Oder kann jemand ein paar Zeilen zu dem Thema UMSTIEG schreiben?
z.B. Ersetzen von IP_C durch Codesys 3.5 bla bla bla?

Danke sagt
Martin

martin.k

Hallo,

auf den Webseiten von Codesys konnte ich eine Oscat_Network.lib finden welche für Codesys 3.5 erstellt ist (Datei *.package! !).
Damit konnte ich mein Programm wieder zum laufen bekommen.

Danke an alle die sich hierzu Gedanken gemacht haben.

Gruß
Martin

mg

... leider gibt es die Network derzeit das nur für die 32 Bit Controller. Für 64 Bit dzt anscheinend nicht funktionsfähig. Vielleicht reicht es wenn man nur die syslibfile32 gegen die syslibfile ersetzt und die syslibsocket32 gegen die syslibsocket. Aber das weiß ich nicht. Wäre schön wenn Pewit oder Hugo Mal was dazu sagen. (zB
Wago PFC 200 geht, Wago PFC 300 geht nicht.)

peewit

für codesys 3.x gibt es direkt im codesys store ein portierung

mg

... die "Portierung" ... betrifft das nun die 64bit Version.
Ich kann nichts finden.

AntonZan

mg, I apologise for replying in English rather than German (and a bit late as well).

As of now there is no port to 64-bit controllers for the Oscat libraries that I know of. Most of the OSCAT_BASIC library will work on both 32-bit as well as 64-bit controllers. Only the _BUFFER_CLEAR() and _BUFFER_INIT() functions are very specifically optimised for 32-bit alignment of bytes and will not work correctly on 64-bit.

You are correct in pointing out that the OSCAT_NETWORK library for CoDeSys uses SysFile23 and SysSocket23 which are both only available for 32-bit. System libraries SysFile and SysSocket indeed have similar functionality and work on both 32-bit (PFC200) as well as 64bit (PFC300) controllers. In addition they would require CmpErrors for standard enumerated error codes rather than the Oscat specific error codes of the existing network library. While there are similarities between SysFile23/SysSocket23 and SysFile/SysSocket, the differences are sufficient to require many small changes as well as some decent testing to verify correctness.

The function blocks FILE_SERVER(), IP_CONTROL() and IP_CONTROL2() need significant modifications for porting to the use of the other libraries. Other parts of the code may require additional modifications. I have found this to be the case for the D_LOG_STORE_FILE_xxxx function blocks for logging to files. Limited resources have stopped me doing further work  on this.