EmbeddedRelated.com
Forums

Multi-threaded Sockets Application

Started by Jason L James November 26, 2004
Hi all,

I am in the very early stages of writing a multi-threaded
sockets application to enable me to communicate using
TCP/IP to several (upto 255) embedded Ethernet
controllers in VB.Net.

Does anyone have any suggestions for where I could
start to look for ideas for such an application?

Many thanks,

Jason.
On Fri, 26 Nov 2004 09:21:22 GMT, jason@no-spam.dive-master.org (Jason
L James) wrote:

>Hi all, > >I am in the very early stages of writing a multi-threaded >sockets application to enable me to communicate using >TCP/IP to several (upto 255) embedded Ethernet >controllers in VB.Net. > >Does anyone have any suggestions for where I could >start to look for ideas for such an application? > >Many thanks, > >Jason.
It would help a lot if we knew the target OS or kernel, socket library and compiler you plan to use. Bob McConnell N2SPP
Bob,

thatnks for the feedback.

The embedded device uses a PIC18F micro.  The host device
is Intel based.  The OS will be Windows 2K +.  The
PC based development platform is MS Visual Basic .Net.

Hope that helps.

Thanks,
Jason.

On Sat, 27 Nov 2004 03:58:42 GMT, Bob McConnell
<rmcconne@NOSPAM.lightlink.com> wrote:

>On Fri, 26 Nov 2004 09:21:22 GMT, jason@no-spam.dive-master.org (Jason >L James) wrote: > >>Hi all, >> >>I am in the very early stages of writing a multi-threaded >>sockets application to enable me to communicate using >>TCP/IP to several (upto 255) embedded Ethernet >>controllers in VB.Net. >> >>Does anyone have any suggestions for where I could >>start to look for ideas for such an application? >> >>Many thanks, >> >>Jason. > >It would help a lot if we knew the target OS or kernel, socket library >and compiler you plan to use. > >Bob McConnell >N2SPP >
Jason L James <jason@no-spam.dive-master.org> wrote:

> The embedded device uses a PIC18F micro. The host device > is Intel based. The OS will be Windows 2K +. The > PC based development platform is MS Visual Basic .Net.
If you're talking about visual basic on win2k, c.a.e isn't really the right place. If you want to talk about that PIC, then you'll probably get more help here.... --buddy
On Mon, 29 Nov 2004 13:19:39 GMT, jason@no-spam.dive-master.org (Jason
L James) wrote:

>Bob, > >thatnks for the feedback. > >The embedded device uses a PIC18F micro. The host device >is Intel based. The OS will be Windows 2K +. The >PC based development platform is MS Visual Basic .Net. > >Hope that helps. > >Thanks, >Jason. >
Last time I checked, VB will only produce single threaded applications. It cannot be used to create multi-threaded code. You need to change languages as well as news group for that target. I have done similar multi-threaded apps with VC++, and have seen code for VJ++. But I don't do MS-Windows any more. Both development and support take far more effort than it's worth. Bob McConnell N2SPP
On 2004-11-29, Bob McConnell <rmcconne@NOSPAM.lightlink.com> wrote:

>>The embedded device uses a PIC18F micro. The host device >>is Intel based. The OS will be Windows 2K +. The >>PC based development platform is MS Visual Basic .Net. > > Last time I checked, VB will only produce single threaded > applications. It cannot be used to create multi-threaded code. You > need to change languages as well as news group for that target. > > I have done similar multi-threaded apps with VC++, and have seen code > for VJ++.
I'd recommend trying out Python. Both multi-threading and socket communications are very easy to do in Python. And unless you put some effort into making it non-portable, you'll be able to run your program under Windows _or_ Linux or Linux-like systems.
> But I don't do MS-Windows any more. Both development and > support take far more effort than it's worth.
That's an understatement. ;) -- Grant Edwards grante Yow! I have a TINY BOWL in at my HEAD visi.com
Since I was developing an app that used embedded
micros that we communicated with using VB.Net I
was spreading my questions to a number of groups that
might have had some ideas.  I been forced to
buy a couple of texts to help with my answer.

Thanks,

Jason.

On Mon, 29 Nov 2004 14:16:28 +0000 (UTC), Buddy Smith
<nullset.spamtrap@dookie.net> wrote:

>Jason L James <jason@no-spam.dive-master.org> wrote: > >> The embedded device uses a PIC18F micro. The host device >> is Intel based. The OS will be Windows 2K +. The >> PC based development platform is MS Visual Basic .Net. > >If you're talking about visual basic on win2k, c.a.e isn't really the right >place. If you want to talk about that PIC, then you'll probably get more help >here.... > >--buddy >
On Tue, 30 Nov 2004 10:20:12 GMT, jason@no-spam.dive-master.org (Jason
L James) wrote:

>Since I was developing an app that used embedded >micros that we communicated with using VB.Net I >was spreading my questions to a number of groups that >might have had some ideas. I been forced to >buy a couple of texts to help with my answer. > >Thanks, > >Jason. > >On Mon, 29 Nov 2004 14:16:28 +0000 (UTC), Buddy Smith ><nullset.spamtrap@dookie.net> wrote: > >>Jason L James <jason@no-spam.dive-master.org> wrote: >> >>> The embedded device uses a PIC18F micro. The host device >>> is Intel based. The OS will be Windows 2K +. The >>> PC based development platform is MS Visual Basic .Net. >> >>If you're talking about visual basic on win2k, c.a.e isn't really the right >>place. If you want to talk about that PIC, then you'll probably get more help >>here.... >> >>--buddy >>
Jason, One last comment before I leave you. In C++, the trick you are looking for is called I/O Completion Ports. It's an MS-Windows API that allocations thread resources for I/O events like receiving data on a socket. Good Luck, Bob McConnell N2SPP