Re: [twsocket] SocketRcvBufSize for Listen sockets

2011-09-23 Thread Arno Garrels
Angus Robertson - Magenta Systems Ltd wrote:
 In WSocket, SocketRcvBufSize and SocketSndBufSize are currently only
 set in Dup and Connect, not in Listen.
 
 For UDP, this means SetSocketRcvBufSize and SetSocketSndBufSize always
 get called even if the buffer is already the correct size, since it's
 not checked.

Can you help me? I currently don't find the location in source?
Where does it happen?  
 
-- 
Arno Garrels
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] PCSensor server/ Simple client-server

2011-09-23 Thread Wilfried Mestdagh
Hi,

 to the target server, I need to send just two bytes, 0xBB and
 0x83

You only need the HttpCli if you use HTTP protocol. Your device does not. It
uses his own protocol (receiving 2 bytes - sending results). So you need to
develop a simple TCP client program using TWSocket.

If you need to send the first item after the device gives you some welcome
data then you have to examine that in OnDataAvailable and send from there.
If it does not you send the 2 bytes in the OnSessionConnected event.

Just fire some more questions if you need it :)

-- 
mvg, Wilfried
http://www.mestdagh.biz
http://www.comfortsoftware.be
http://www.expertsoftware.be

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] SocketRcvBufSize for Listen sockets

2011-09-23 Thread Angus Robertson - Magenta Systems Ltd
  For UDP, this means SetSocketRcvBufSize and SetSocketSndBufSize 
  always get called even if the buffer is already the correct size,
  since it's not checked.
 
 Can you help me? I currently don't find the location in source?
 Where does it happen?  

I meant in my program, since with Listen SocketRcvBufSize always returns
0, but with connect and dup it returns the current size. 

Angus

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] PCSensor server/ Simple client-server

2011-09-23 Thread Angus Robertson - Magenta Systems Ltd
 Not a WEB server, not a TELNET server, but still a 
 server, if only a simple one.
 
 HttpTst, and the program I derived from it, as I understand things, 
 sends a proper HTTP Get to the system of your choice. 

Your box is almost certainly both a web server (how you got and set
configuration information) and a telnet server.  Telnet simply means
lines of data to and from the server, and is the basis of HTTP, FTP, SMTP
and the rest.  Those protocols simply use a different port to 'telnet'
but the same textual interaction.  

Using HTTP components is totally wrong.  

If, using a telnet client, you don't get an open connection on port 5200,
there is a deeper problem.  

You may be easier using standard applications, like my ComCap tool which
uses ICS, it is designed for capturing data from devices such as yours,
often hundreds at the same time, and will send a command to wake them up,
as you need. 

http://www.magsys.co.uk/comcap/

Angus





--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] PCSensor server/ Simple client-server

2011-09-23 Thread TK Boyd
Angus, Wilfried...

Many thanks!

 You need to develop a simple TCP client program using TWSocket...

Thank you for pointing me at the right demo to work from Oh! And 
in looking around for that, I found the link Click here for a primer 
text about TCP... Apologies, everyone, for not seeing that before 
now.

Would the demo Client5: A basic client program using TWSocket 
component. seem to you who know like an alternative good starting 
point for my efforts?

 Using HTTP components is totally wrong.  

Thank you... It is a relief to learn I don't need to fight that 
particular fight at this stage. What a newbie does NOT need to worry 
about is almost as helpful as what IS needed!

 Your box is almost certainly both a web server and a telnet 
server...

Because that's how most things are made? This is a wonder out of 
China, remember.

Not to argue with the experts, but just some of the tests I did that 
made me think, hmm... maybe not the usual here...

Pointed my browser at 192.168.0.241:5200... got can't connect... and 
yet SmartSniff sees communication to and from there... across two 
sockets, if I use the mfg's software... which works... it just 
doesn't do the things I want to!

ping 192.168.0.241 gets replies
ping 192.168.0.241 5200 says could not find host on...

Telnet...

I can get into Telnet, but

o 192.168.0.241 5200 fails, as does
o 192.168.0.241

The first hangs the DOS window, the latter comes back promptly with 
Could not open connection...

(I set the IP address, and got the config data with the mfg's 
software.)

 Telnet simply means lines of data to and from the server, and is 
the basis of HTTP, FTP, SMTP and the rest.  Those protocols simply 
use a different port to 'telnet' but the same textual interaction.  

Helpful, thank you... I stuggle... but I learn!

 If, using a telnet client, you don't get an open connection on port 
 5200, there is a deeper problem.  

When I described my Telnet experiences, I was talking about using the 
bog standard DOS telnet command, inside a Windows command, or 
DOS window.

Deeper problem... happily, the device DOES seem to work 
consistently under the mfg's software...


I'll go away and study the latest advice, and dig into some stuff 
someone else has kindly sent off-list and hopefully announce 
SUCCESS... or at least come back with better(?) questions?? I am a 
lot more clear on the issues that I was when I started... thank you 
all for your help! I knew that promoting ICS at my Delphi tutorials 
all these years was Right Thinking.




http://facebook.com/SheepdogSoftware  TK Boyd's site with
freeware and shareware for kids, parents, schools... and others.
You don't have to be a Facebook member to access the site.

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] PCSensor server/ Simple client-server

2011-09-23 Thread Wilfried Mestdagh
Hi,

 Would the demo Client5: A basic client program using TWSocket
 component. seem to you who know like an alternative good starting
 point for my efforts?

The good starting point is: do not copy! - Study example; then start from
nothing - zero - null !

-- 
mvg, Wilfried
http://www.mestdagh.biz
http://www.comfortsoftware.be
http://www.expertsoftware.be

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] PCSensor server/ Simple client-server-SOLVED!

2011-09-23 Thread TK Boyd
Hurrah! Thank you everyone!

The ICS demo CliDemo1 did the job for me!! But I never would have 
got all the parts of the puzzle assembled without your help... There 
was a lot more to get right than just deciding which demo had the 
right elements.

Now I can move forward with helping some good engineers working hard 
in a second language to get their product understood by a wider 
audience... thanks to you!

(I still have lots to learn in this area, so, despite immediate wants 
(needs) having been met, if you still have comments on ignorance 
revealed in earlier posts, don't hesitate to put me straight.)

Regards,

Tom

http://facebook.com/SheepdogSoftware  TK Boyd's site with
freeware and shareware for kids, parents, schools... and others.
You don't have to be a Facebook member to access the site.

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be