CODESYS - the IEC 61131-3 automation software

Welcome to the official CODESYS Forum by 3S-Smart Software Solutions GmbH | A member of the CODESYS Group
Deutsche Version English version russian version 
It is currently Thu Dec 13, 2018 7:52 pm

All times are UTC+01:00




Post new topic  Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Wed Jun 25, 2008 4:03 pm 
Offline

Joined: Fri Jun 20, 2008 9:30 am
Posts: 2
Hello,

I try to create TCP server on WAGO 750-841 using SysLibSockets.lib.

I call following functions:
SysSockCreate
SysSockBind
SysSockListen
They all return normal results.

Than I need to accept incoming connection if available. But I don’t want SysSockAccept function to block my program.
So I call SysSockSelect function with fdRead parameter set to my socket (wrapped into SOCKET_FD_SET). Timeout set to several seconds (I tried different values from 4ms to 4s).
SysSockSelect always returns 0 (even if there is a connection).
If I remove SysSockSelect function – all works good.
Please help me.

Thanks,
Oleg


Top
   
PostPosted: Mon Jul 07, 2008 12:08 pm 
Offline

Joined: Fri Jun 20, 2008 9:30 am
Posts: 2
I have solved this problem. Now I use only SysSockIoctl to set non-blocking socket mode and don't use SysSockSelect function.


Top
   
PostPosted: Mon Jan 29, 2018 9:35 am 
Offline

Joined: Wed Oct 25, 2017 10:25 am
Posts: 14
olegf wrote:
I have solved this problem. Now I use only SysSockIoctl to set non-blocking socket mode and don't use SysSockSelect function.


Hi, I'm working on a similar project. I have a raspberry in which I need to run a TCP server where I will receive messages from clients by sockets. I can not get it to work properly, have you managed to get it to work properly? Do you have more information about the server or an example project?

Thank you very much.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 3 posts ] 

All times are UTC+01:00


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited