Go to Post Sometimes you have to eat your vegetables, do your homework, and get some sleep. Otherwise you may get sick, have bad grades, and or fall asleep during the championship. - IKE [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-2016, 19:41
iSpotix iSpotix is offline
Registered User
FRC #4049
 
Join Date: Jan 2016
Location: Pittsburgh
Posts: 27
iSpotix is an unknown quantity at this point
JFrame As Secondary GUI Possibility

I created a JFrame with a list output and radio buttons for different autonomous modes in the off season and finally had a chance to run it on the robot, but it throws a NoClassDefFoundError. Is it even possible to run a JFrame on the roborio? I'm not super experienced with how the roborio and driverstation interact but I'm fairly fluent in java. I have the JFrame class and then the robot class in one package so that I can just call JFrameClass.addSomething("") from the robot class. I don't have the code with me, but it seems like more of a compiling error than actual code.
Reply With Quote
  #2   Spotlight this post!  
Unread 11-01-2016, 21:17
JesseK's Avatar
JesseK JesseK is offline
Expert Flybot Crasher
FRC #1885 (ILITE)
Team Role: Mentor
 
Join Date: Mar 2007
Rookie Year: 2005
Location: Reston, VA
Posts: 3,637
JesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond reputeJesseK has a reputation beyond repute
Re: JFrame As Secondary GUI Possibility

Quote:
Originally Posted by iSpotix View Post
I don't have the code with me, but it seems like more of a compiling error than actual code.
This particular error means the classpath at runtime cannot find a class. It doesn't have anything to do with compiling. It's more to do with how you deploy to your environment.

JFrame itself is a GUI-based class that will initialize a display environment under the covers. Unrelated to robotics, a 'headless' server is one that doesn't have a video card output at all. Running a class that initializes a JFrame on a headless server throws a runtime error, though I don't remember the specifics.

If you're running the java.swing.JFrame class on the RobotRIO, then I suspect that's the source of your error. The JFrame class is meant to be launched from your driver's station laptop, and the control code should connect to the RoboRIO's IP/ports where your RoboRIO code is publishing data.
__________________

Drive Coach, 1885 (2007-present)
CAD Library Updated 5/1/16 - 2016 Curie/Carver Industrial Design Winner
GitHub

Last edited by JesseK : 11-01-2016 at 21:20.
Reply With Quote
  #3   Spotlight this post!  
Unread 11-01-2016, 22:31
iSpotix iSpotix is offline
Registered User
FRC #4049
 
Join Date: Jan 2016
Location: Pittsburgh
Posts: 27
iSpotix is an unknown quantity at this point
Re: JFrame As Secondary GUI Possibility

Thank you both. I forgot to mention this as a possibility as well. I think the 2016 has solved everything I was trying to do anyway but I just needed some closure.
Reply With Quote
  #4   Spotlight this post!  
Unread 11-01-2016, 21:18
Jared's Avatar
Jared Jared is offline
Registered User
no team
Team Role: Programmer
 
Join Date: Aug 2013
Rookie Year: 2012
Location: Connecticut
Posts: 602
Jared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond reputeJared has a reputation beyond repute
Re: JFrame As Secondary GUI Possibility

The roborio doesn't have a screen or possible video output, so you can't use a JFrame or any type of UI on it. I also would imagine that these classes aren't on the roborio because they cannot be used.
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 09:17.

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