Python Socket Programming - need to do something while listening for connections

后端 未结 3 1470
孤街浪徒
孤街浪徒 2021-01-13 12:46

I am in the process of designing some hardware interface with python. what I need to do is as follows,

~initialize the drivers ~start the device ~create a socket at

相关标签:
3条回答
  • 2021-01-13 13:07

    You need to make all sockets non-blocking.

    0 讨论(0)
  • 2021-01-13 13:10

    Since twisted is out of question, I suggest using the socketserver module.

    For an easy start, see this example.

    0 讨论(0)
  • 2021-01-13 13:26

    Use Twisted

    An example that shows asynchronous networking with core python is here.

    0 讨论(0)
提交回复
热议问题