Re: Scket connection to server
- From: André Egners <andre.egners@xxxxxxxxxxxxxx>
- Date: Thu, 30 Jun 2005 22:17:52 +0200
Steve Horsley wrote:
> JudgeDread wrote:
>
>> hello python gurus
>>
>> I would like to establish a socket connection to a server running a
>> service
>> on port 29999. the host address is 10.214.109.50. how do i do this using
>> python?
>>
>> many thanks
>>
>>
>
> Off the top of my head (so there could be errors):
>
> import socket
> s = socket.Socket()
> s.connect((10.214.109.50, 29999))
> s.send("Hello, Mum\r\n")
>
> That should point you in the right direction, anyway.
>
> There is a higher level socket framework called twisted that everyone
> seems to like. It may be worth looking at that too - haven't got round
> to it myself yet.
>
> Steve
Just curious...where do these messages show up @10.214.109.50?
andre
--
Nothing is easier than being busy -
and nothing more difficult than being effective.
.
- References:
- Scket connection to server
- From: JudgeDread
- Re: Scket connection to server
- From: Steve Horsley
- Scket connection to server
- Prev by Date: Re: Controlling WinAMP (WM_COPYDATA problem)
- Next by Date: Re: saving pre-compiled scripts
- Previous by thread: Re: Scket connection to server
- Next by thread: Re: Scket connection to server
- Index(es):