Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
14 years ago

Full duplex communication on a TCP socket

Hi,

Is it possible send a character command from a client to a server if server is still sending data continuously to client?....so...I mean....during server->client data sending...?

Regards

11 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    How about reading the socket from a separate task that has a higher priority? The task should be suspended as long as no data is here, but when it comes it will suspend the send task, and you can use a share variable to control the other task.

    IIRC the Nichestack is thread safe so this should work.