Go to Post Corrected, math isn't my strong point (I went to art school for a reason) - KelliV [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 11-01-2011, 16:43
vinnie's Avatar
vinnie vinnie is offline
Registered User
FRC #3309 (Friarbots)
Team Role: College Student
 
Join Date: Oct 2010
Rookie Year: 2010
Location: Los Angeles / Anaheim
Posts: 107
vinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond repute
InetAddress

For the past couple weeks I have been working on a custom dashboard and a communication class to go along with it. I was able to use my class in Java SE projects, but I tried to use it in an FRC project and I cannot compile it because it says that InetAddress cannot be found. I tried importing java.net.InetAddress but it did not work either because of the limited classes we have in FRC. Any suggestions on what I should do?
Reply With Quote
  #2   Spotlight this post!  
Unread 11-01-2011, 19:16
Patrick Chiang Patrick Chiang is offline
Programming
FRC #3070 (Team Pronto)
Team Role: Mentor
 
Join Date: Feb 2009
Rookie Year: 2009
Location: Seattle
Posts: 162
Patrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to all
Re: InetAddress

Aside from copying a large portion of the Java libraries onto your project, there's probably little you can do. Last year, we wanted to use some math functions from the native Java libraries, but couldn't figure how to do it, so we just copied entire files from there into our project.

If you're making a custom dashboard, can't you make it a standard Java project?
Reply With Quote
  #3   Spotlight this post!  
Unread 11-01-2011, 20:08
vinnie's Avatar
vinnie vinnie is offline
Registered User
FRC #3309 (Friarbots)
Team Role: College Student
 
Join Date: Oct 2010
Rookie Year: 2010
Location: Los Angeles / Anaheim
Posts: 107
vinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond reputevinnie has a reputation beyond repute
Re: InetAddress

I used NetBeans on another computer to make a Java SE Project that would be the graphical interface on the driver computer, that worked perfectly. I also wrote a class that would allow the robot to communicate with the computer and it worked fine on the PC, but I tried to import the jar that contains the library into my FRC project, but it keeps saying that my package (org.serviterobotics.comm), doesn't exist. So that is why I tried to use InetAddress to see if I could compile my classes with the rest of the project. As for your workaround, could you please tell me exactly what files you copied and where you copied them to, I thought of doing this but wasn't sure what to copy. Thank you
Reply With Quote
  #4   Spotlight this post!  
Unread 12-01-2011, 00:07
Patrick Chiang Patrick Chiang is offline
Programming
FRC #3070 (Team Pronto)
Team Role: Mentor
 
Join Date: Feb 2009
Rookie Year: 2009
Location: Seattle
Posts: 162
Patrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to all
Re: InetAddress

It looks like InetAddress relies on a lot of other stuff so I doubt copying it over would work. When we did tried to copy the math functions last year, it worked because most of it had to do with some basic, self contained math. So I don't know...

Sorry, but maybe someone else can help you.
Reply With Quote
  #5   Spotlight this post!  
Unread 12-01-2011, 12:44
derekwhite's Avatar
derekwhite derekwhite is offline
Java Virtual Machine Hacker
no team (FIRST@Oracle)
Team Role: Programmer
 
Join Date: May 2009
Rookie Year: 2009
Location: Burlington, MA
Posts: 127
derekwhite is on a distinguished road
Re: InetAddress

For network communication from your FRC robot, you can use the "Generic Connection Framework" in Java ME.

See http://developers.sun.com/mobility/m...ericframework/ for an article in the GCF.

Also look at a presentaion "Java For FRC" that contains hints on more advanced topics for Java on your rorbot.

http://www.usfirst.org/uploadedFiles...FRCKickoff.pdf
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 10:26.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi