Go to Post This is the first (and, if this stuff keeps up, last) time FIRST has allowed high-speed projectiles in years. Please use some common sense, people. - Madison [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 Rating: Thread Rating: 3 votes, 5.00 average. Display Modes
  #1   Spotlight this post!  
Unread 19-01-2013, 11:45
Arhowk's Avatar
Arhowk Arhowk is offline
FiM CSA
AKA: Jake Niman
FRC #1684 (The Chimeras) (5460 Mentor)
 
Join Date: Jan 2013
Rookie Year: 2013
Location: Lapeer
Posts: 542
Arhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to behold
Using Network Tables

Can I send this line

ColorImage image = camera.getImage()

to a folder on the driver station?
Reply With Quote
  #2   Spotlight this post!  
Unread 19-01-2013, 11:53
BradAMiller BradAMiller is offline
Registered User
AKA: Brad
#0190 ( Gompei and the Herd)
Team Role: Mentor
 
Join Date: Mar 2004
Location: Worcester, MA
Posts: 588
BradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant future
Re: Using Network Tables

NetworkTables doesn't send large data items like images from the robot to the laptop. However, if your goal is to process the image on the driver station computer, you can connect the camera to the switch on your robot and just open it from the laptop. There are several ways of doing that. You can write a program with RoboRealm for doing the image processing. You can write your own program using some library like OpenCV or the NIVision library, or you can make a SmartDashboard plugin that does the image processing.

If you want to do the vision processing on the robot, then there are some sample Java programs for robot-side target detection in NetBeans.

Brad
__________________
Brad Miller
Robotics Resource Center
Worcester Polytechnic Institute
Reply With Quote
  #3   Spotlight this post!  
Unread 19-01-2013, 14:39
Arhowk's Avatar
Arhowk Arhowk is offline
FiM CSA
AKA: Jake Niman
FRC #1684 (The Chimeras) (5460 Mentor)
 
Join Date: Jan 2013
Rookie Year: 2013
Location: Lapeer
Posts: 542
Arhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to behold
Re: Using Network Tables

e/ Changing the focus of this thread!!

Whenever im using RoboRealms, I can add the Network Table widget to the current setup, set the ip to 10.16.84.2, set the default camera to none, but when i run the program its not going to the axis camera on the robot its booting my webcam!

Options>Video>Camera only has two settings, Nothing and my camera. (default to nothing)

Last edited by Arhowk : 19-01-2013 at 15:10.
Reply With Quote
  #4   Spotlight this post!  
Unread 19-01-2013, 15:09
SuperMario SuperMario is offline
Registered User
FRC #3692
 
Join Date: Jan 2013
Location: janesville
Posts: 9
SuperMario is an unknown quantity at this point
Re: Using Network Tables

I'm not sure what you are asking, but you can access the ip of the camera and see the feed from any computer.
Reply With Quote
  #5   Spotlight this post!  
Unread 19-01-2013, 16:56
Arhowk's Avatar
Arhowk Arhowk is offline
FiM CSA
AKA: Jake Niman
FRC #1684 (The Chimeras) (5460 Mentor)
 
Join Date: Jan 2013
Rookie Year: 2013
Location: Lapeer
Posts: 542
Arhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to behold
Re: Using Network Tables

Quote:
Originally Posted by SuperMario View Post
I'm not sure what you are asking, but you can access the ip of the camera and see the feed from any computer.
k, nevermind, thread derail again... (Forgot to add the axis intenet camera module)

how do i instantiate a network table?

cameraTable = NetworkTable.getTable("RoboRealm");

gives me an error

Illegal State Exception : network table already initialized

(if i catch the error, it does nothing)

e/ nevermind.

current problem =

Code:
public void testPeriodic() {
        enabledPeriodic();
        NetworkTable server = NetworkTable.getTable("SmartDashboard");
	try
	{
			System.out.println(server.getNumber("IMAGE_COUNT", -1.0));
	}
	catch (TableKeyNotDefinedException ex)
	{
	}

    }
continually prints -1

my robo builder setup:

Axis_Internet_Camera 10.16.84.11
Threshhold 200-255 (sat)
Fill 500
Convex Hull
set IMAGE_COUNT = /SmartDashboad/IMAGE_COUNT
Network_Tables (port 1765, ip 10.16.84.2, send : IMAGE_COUNT)

Last edited by Arhowk : 19-01-2013 at 17:24.
Reply With Quote
  #6   Spotlight this post!  
Unread 19-01-2013, 17:42
F22Rapture's Avatar
F22Rapture F22Rapture is offline
College Student, Mentor
AKA: Daniel A
FRC #3737 (4H Rotoraptors)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2012
Location: Goldsboro, NC
Posts: 476
F22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant futureF22Rapture has a brilliant future
Re: Using Network Tables

So... is there a way to have the Roborealm server process the Axis camera images, then send those images to the SmartDashboard so that we can see the processed output?
__________________
Research is what I’m doing when I don’t know what I’m doing.
- Wernher von Braun
Attending: Raleigh NC Regional
Reply With Quote
  #7   Spotlight this post!  
Unread 19-01-2013, 17:53
mitchellweb1 mitchellweb1 is offline
Registered User
AKA: Mitchell W
FRC #0190
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2009
Location: Acton, MA
Posts: 30
mitchellweb1 is an unknown quantity at this point
Re: Using Network Tables

You can try using the TableViewer to ensure that the key that you are expecting is actually in NetworkTables. You can find it in C:/Users/YOURUSERNAME/sunspotfrcsdk/tools/TableViewer-VERSION.jar
This will allow you to connect to a networktables server and view the raw entries.
Reply With Quote
  #8   Spotlight this post!  
Unread 19-01-2013, 18:41
Arhowk's Avatar
Arhowk Arhowk is offline
FiM CSA
AKA: Jake Niman
FRC #1684 (The Chimeras) (5460 Mentor)
 
Join Date: Jan 2013
Rookie Year: 2013
Location: Lapeer
Posts: 542
Arhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to behold
Re: Using Network Tables

Quote:
Originally Posted by F22Rapture View Post
So... is there a way to have the Roborealm server process the Axis camera images, then send those images to the SmartDashboard so that we can see the processed output?
what. why would you want to do that.

(yes, just have roborealm save to a file than have smartdashboard read to file)

Quote:
Originally Posted by mitchellweb1 View Post
You can try using the TableViewer to ensure that the key that you are expecting is actually in NetworkTables. You can find it in C:/Users/YOURUSERNAME/sunspotfrcsdk/tools/TableViewer-VERSION.jar
This will allow you to connect to a networktables server and view the raw entries.
Your right... the entires arent there... but IMAGE_COUNT (in no subfolder) is
Reply With Quote
  #9   Spotlight this post!  
Unread 21-01-2013, 14:06
Arhowk's Avatar
Arhowk Arhowk is offline
FiM CSA
AKA: Jake Niman
FRC #1684 (The Chimeras) (5460 Mentor)
 
Join Date: Jan 2013
Rookie Year: 2013
Location: Lapeer
Posts: 542
Arhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to behold
Re: Using Network Tables

bump...

set IMAGE_COUNT = /SmartDashboard/IMAGE_COUNT

in RoboRealm isnt working and it keeps saving to IMAGE_COUNT. What would the proper configuration be for seting IMAGE_COUNT to /SmartDashboard/IMAGE_COUNT OR can i get IMAGE_COUNT from the crio root?

(to rehash the thread)
Reply With Quote
  #10   Spotlight this post!  
Unread 21-01-2013, 15:24
MagiChau's Avatar
MagiChau MagiChau is offline
Registered User
AKA: Michael Chau
FRC #0085 (B.O.B. (Built on Brains))
Team Role: Alumni
 
Join Date: Jan 2010
Rookie Year: 2010
Location: Zeeland, Michigan
Posts: 875
MagiChau is just really niceMagiChau is just really niceMagiChau is just really niceMagiChau is just really nice
Re: Using Network Tables

Quote:
Originally Posted by Arhowk View Post
bump...

set IMAGE_COUNT = /SmartDashboard/IMAGE_COUNT

in RoboRealm isnt working and it keeps saving to IMAGE_COUNT. What would the proper configuration be for seting IMAGE_COUNT to /SmartDashboard/IMAGE_COUNT OR can i get IMAGE_COUNT from the crio root?

(to rehash the thread)
you have to set /SmartDashboard/IMAGE_COUNT = IMAGE_COUNT

The left side is for the variable you are setting. The right is for setting the value of that varaible.
Reply With Quote
  #11   Spotlight this post!  
Unread 21-01-2013, 18:02
Arhowk's Avatar
Arhowk Arhowk is offline
FiM CSA
AKA: Jake Niman
FRC #1684 (The Chimeras) (5460 Mentor)
 
Join Date: Jan 2013
Rookie Year: 2013
Location: Lapeer
Posts: 542
Arhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to beholdArhowk is a splendid one to behold
Re: Using Network Tables

Quote:
Originally Posted by MagiChau View Post
you have to set /SmartDashboard/IMAGE_COUNT = IMAGE_COUNT

The left side is for the variable you are setting. The right is for setting the value of that varaible.
... almost there....

ok i got that. it didnt work. than i sent /SmartDashboard/IMAGE_COUNT and it *almost* worked.

It sent it once. but thats it. it will NOT overwrite the values. it will create them and send them but not overwrite

using Set_Variable, i set GG = 123
i sent GG
TableViewer says GG = 123

i set GG = 234 (in RoboRealm)
i send GG
TableViewer says GG = 123

i make a new variable GG1
i set GG1 = 234
i send GG1
TableViewer says GG1 = 234, GG = 123
Reply With Quote
  #12   Spotlight this post!  
Unread 19-01-2013, 16:55
MagiChau's Avatar
MagiChau MagiChau is offline
Registered User
AKA: Michael Chau
FRC #0085 (B.O.B. (Built on Brains))
Team Role: Alumni
 
Join Date: Jan 2010
Rookie Year: 2010
Location: Zeeland, Michigan
Posts: 875
MagiChau is just really niceMagiChau is just really niceMagiChau is just really niceMagiChau is just really nice
Re: Using Network Tables

Quote:
Originally Posted by Arhowk View Post
e/ Changing the focus of this thread!!

Whenever im using RoboRealms, I can add the Network Table widget to the current setup, set the ip to 10.16.84.2, set the default camera to none, but when i run the program its not going to the axis camera on the robot its booting my webcam!

Options>Video>Camera only has two settings, Nothing and my camera. (default to nothing)
You have to use the AxisCamera module on RoboRealm. That is the only way I know of you are going to get a feed on RoboRealm.
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 11:31.

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