• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to open a input stream to ethernet port

 
chaitanya karthikk
Ranch Hand
Posts: 806
Java MySQL Database Spring
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all, I am Chaitanya, I am working on a RFID(Radio Frequency Identification) based application. The RFIDs are connected to a network switch.Data sent by the RFIDs are dumped on ethernet port. Can Java read data from ethernet port?

Can anyone please help me? Thank you all in advance.
 
Greg Charles
Sheriff
Posts: 3010
12
Firefox Browser IntelliJ IDE Java Mac Ruby
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Java is an applications programming language, and what you're talking about is systems programming. However, Java can bridge that gap using JNI, the Java Native Interface, which allows it to call into code written in a systems programming language like C. You could roll your own solution, or look into third-party frameworks. I found a few by Googling for "Java raw socket". There's JpCap, which is free and RockSaw, which seems to be commercial. I haven't use either though, so I can't recommend one over the other.
 
chaitanya karthikk
Ranch Hand
Posts: 806
Java MySQL Database Spring
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Greg, thanks a lot for the post. The company from which we purchased the hardware said that you can go with socket programming, the switch dumps the data read from RFID on some random port. However the details are yet to be known. I ll stay in touch here till the problem is solved.

Thanks again dude. Have a good day
 
Nivedha Kalatharan
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi chaitanya karthikk,

Then what you did to read data from ethernet port? Please tell me about it. I m in need of it.
 
Campbell Ritchie
Marshal
Posts: 52580
119
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch

You might do well to start a new thread because the OP might not come back to a 4½‑year‑old thread.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!