Welcome to Dream.In.Code
Getting C# Help is Easy!

Join 132,688 C# Programmers for FREE! Get instant access to thousands of C# experts, tutorials, code snippets, and more! There are 1,289 people online right now. Registration is fast and FREE... Join Now!




Ethernet Communiction

 
Reply to this topicStart new topic

Ethernet Communiction, Need Help for Ethernet programming

cdeveloper
post 4 Jun, 2008 - 02:02 AM
Post #1


New D.I.C Head

*
Joined: 3 Jun, 2008
Posts: 5


My Contributions


Hi Everybody,
I want a help from you in Ethernet programming. Now I am conducting a project which have to communicate computer and a pic microcontroller through Ethernet, so I need to develope a PC interface which catch incoming data and can send user data to device through Ethernet. Device can communicate only ethernet, it does not support any higher layers like SLIP, ARP or IP.
My Network adapter is Realtek 8139 Fast Ethernet Adapter,driver is RTL8139.sys and Operating System Windows Xp.
I have no idea to access ethernet in PC, So I want your help in the following sections


1. The code using Ethernet access in PC which written anyone of the language C,C++, MFC and DotNet.
2. require any changes in my network adapter or driver?.

I am waiting for your valueable help and advice for solve this situation.

Thanks in advance,

cdeveloper.
User is offlineProfile CardPM

Go to the top of the page

rgfirefly24
post 4 Jun, 2008 - 03:51 AM
Post #2


D.I.C Regular

Group Icon
Joined: 7 Apr, 2008
Posts: 330



Thanked 5 times

Dream Kudos: 150
My Contributions


QUOTE(cdeveloper @ 4 Jun, 2008 - 03:02 AM) *

Hi Everybody,
I want a help from you in Ethernet programming. Now I am conducting a project which have to communicate computer and a pic microcontroller through Ethernet, so I need to develope a PC interface which catch incoming data and can send user data to device through Ethernet. Device can communicate only ethernet, it does not support any higher layers like SLIP, ARP or IP.
My Network adapter is Realtek 8139 Fast Ethernet Adapter,driver is RTL8139.sys and Operating System Windows Xp.
I have no idea to access ethernet in PC, So I want your help in the following sections


1. The code using Ethernet access in PC which written anyone of the language C,C++, MFC and DotNet.
2. require any changes in my network adapter or driver?.

I am waiting for your valueable help and advice for solve this situation.

Thanks in advance,

cdeveloper.



to answer your first question
Dream.In.Code has a policy by which we prefer to see a good faith effort on your part before providing source code for homework assignments. Please post the code you have written in an effort to resolve the problem, and our members would be happy to provide some guidance. Be sure to include a description of any errors you are encountering as well.

Please post like this:

Thank you for helping us helping you.
User is offlineProfile CardPM

Go to the top of the page

eclipsed4utoo
post 4 Jun, 2008 - 04:48 AM
Post #3


D.I.C Regular

Group Icon
Joined: 21 Mar, 2008
Posts: 314



Thanked 17 times

Dream Kudos: 25
My Contributions


if your device is going to use ethernet, then it will most likely have an IP address. you can use a Socket to communicate to that IP address and send commands and receive the data that is returned.

here are some links for you to look through...

MSDN - System.Net.Sockets
http://www.devarticles.com/c/a/C-Sharp/Soc...ng-in-C-Part-I/
http://www.devarticles.com/c/a/C-Sharp/Soc...-sharp-Part-II/
User is offlineProfile CardPM

Go to the top of the page

baavgai
post 4 Jun, 2008 - 05:04 AM
Post #4


Dreaming Coder

Group Icon
Joined: 16 Oct, 2007
Posts: 1,967



Thanked 96 times

Dream Kudos: 475

Expert In: C, C++, Java, C#, ASP.NET, PHP, Perl, Python, Oracle, SQL Server, MySql, HTML, JavaScript, Lua

My Contributions


Just an FYI, unless you're programming a router or something, you aren't going to programming "Ethernet", and even they it's debatable. You'll be working with a network protocol, probably TCP.
User is online!Profile CardPM

Go to the top of the page

VbProgrammer08
post 4 Jun, 2008 - 05:45 AM
Post #5


New D.I.C Head

*
Joined: 31 May, 2008
Posts: 9

Ah, I was replying to this while it was posted in the Vb.NET section, but it got moved in the middle of my post.

Hints:
1. I heard that a Winsock extension called Trumpet has Ethernet connectivity. (I'm sure it has a price tag on it though).

2. I have used the Winsock library (not the Trumpet extension) before on VC++, and it works above a satisfactory level. Only problem is that it couldn't request and send data simultaneously. Not sure of C# though.
User is offlineProfile CardPM

Go to the top of the page

Fast ReplyReply to this topicStart new topic
Time is now: 11/23/08 07:27AM

Live C# Help!

C# Tutorials

Reference Sheets

C# Snippets

Bye Bye Ads

Free DIC T-Shirt

T-Shirt Example

Related Sites

Monthly Drawing

Thumb Drive

Partners

Top Contributors

Top 10 Kudos This Month