Is Smart Dashboard really this limited?

After several years of using LabVIEW and building cool custom Dashboards, we’ve switched to Java and I’m totally frustrated by the basic nature of the Smart Dashbaord…

I’m using a USB cam so it doesn’t seem like I can use the more advanced one.

Some questions:

If I’m using iterative control mode, is there really no way I can setup a drop-down multiple choice for selecting autonomous features using the Dashboard?

I see the Command based version, but even this won’t give me basic parameter selection (like mode selections within a standard Auto program.

Can I interface a Java control program with a LabVIEW dashboard?

I don’t even seem to be able to get a basic slider I can trick into selecting delay times… Is there nothing better than this dashboard?

Phil.

I believe for choosing auto modes you can use a SendableChooser - more info in the WPI screensteps on that. However yes the Java SmartDashboard is fairly basic but you can customize items by going into edit mode (it’s in one of the dropdown menus at the top), and right clicking on different items in the Dashboard to change their appearance or parameters.

EDIT: Reread your post, and am not sure about SendableChoosers for Iterative control. I’ve always used Command Based myself to kind of neaten it up.

You can use an autonomous selector (SendableChooser) even if you are not using the Command system.

You can place any type of data in the SendableChooser, not just Commands, because SendableChooser.addObject() takes any type of Object as its second parameter. You could use numbers or strings instead and then use these to decide which autonomous to run.

The SmartDashboard does lack a slider control by default, but it fairly easy to write an extension to add this capability.
Here is the one I wrote (both files are necessary):
Slider.java
BindableSlider.java

I also attached a compiled JAR of this extension (inside a zip because CD doesn’t allow me to upload a JAR).

SliderExtension.zip (42 KB)


SliderExtension.zip (42 KB)

Hi.

Thanks for the information about the send-able chooser. I had wondered what the limitations were for the attached data. So, how does the program get access to this attached data? The normal chooser operation seems to dictate what gets run in Auto, but I just want to get access to the “chosen” parameter. The Screen Steps docs just jump over how the chooser actually works, and just shows how to use it for automatic command selection.

So, lets say I just want to chose between 6 different enum values. Assuming I can figure out how to load up the chooser, how, where and when do I access the chosen value?

I’m an experienced C++ programmer, but I’m new to Java. It’s fun, but I’m just not loving having to guess how to use these classes in the FRC code.

I’ll definitely try out your slider code.

Phil

chooser.getSelected()

Phil, if you create a new Iterative or Sample robot project you should see an example of using the SendableChooser with non-command date right there in the template.

That simple huh?

Thanks.
Phil.

BTW, is there any possibility that the USB cam viewer can be used with SmartDashboard 2.0 ?

Phil.

OK, that’s really weird. I created a new iterative project, and there it was.

How did I not see that???

Oh, well. That’s the beauty of Chief Delphi…

Thanks.

Phil.

The answer to the thread title is very simple: Yes, it is very limited. AFAIK, SmartDashboard 1.0 hasn’t really received any new features since its introduction, and it’s annoying to extend due to limited documentation.

You might check out SFX (SmartDashboard 2.0). It’s a lot shinier, and has a lot more features (including sliders and such). However, still limited documentation for extending it.

Both of them can be found in your ~/wpilib/tools directory (SmartDashboard.jar or sfx.jar) on a computer with the eclipse tools installed.

Self-promotion: Of course I’m biased, but we write our dashboards using HTML+Javascript. It’s a lot more flexible, and easier to extend as you’re only limited by your ability to create shiny javascript. Only downside is that you can’t connect to the built-in wpilib camera stuff, but that code is fairly terrible anyways. We use mjpg-streamer instead (search the forums).

If you want you can actually just use a labview dashboard with a java program. I had some success with this by using the labview networktables VIs to get values sent to the smart dashboard. I prefer this over the SmartDashboard because, like you said, it is limited, and labview offers far more control options for the dashboard.

Check out the javadocs. They aren’t quite as easy to use as screenstepslive, and they occasionally are missing some information, but they are extremely comprehensive in describing all of the classes in WPILIB

You might be interested in DotNetDash. It’s still a little feature-limited (especially since I just pushed the code publically today), but it has support for a Sendable Chooser, Digital Inputs, a graphing utility for tuning PID loops (best feature so far). It should have support for USB cameras, but I haven’t had a chance to test that (don’t have access to a roboRIO at the moment and competition isn’t the right place to test this). You can find the repository at https://github.com/robotdotnet/DotNetDash

This can be used regardless of programming language since it just seems to use network tables, right?