BUG Community

Welcome! Log In

Forums BUG SDK Problem with Creating an Application... Web Service

Subscribe to Problem with Creating an Application... Web Service  8 posts, 3 voices

Log in to reply to this topic
 
Jan 25, 2008 8:13pm
User_img_not_found_05_med wimora 10 posts

I’ve been attempting to use the instructions from "Create an application that consumes a Web service" from the wiki without much success. I’ve tried it several times. Each time I’ve deleted the previous attempt and began fresh (having used the "Also delete contents under…" option when I deleted.)

I have been able to download and use the AWTTutorialforBug app and the BasicCalculator app. I’ve also successfully done the Create a Basic Application from the wiki and gotten my "Hello World :)" message in the console.

Following the directions everything seems to be fine until step 5.

5. In the New BUG Project window: In the Name field, type: LCD Helloworld In the Target section, leave Virtual BUG selected.

There is no Target section on this screen. The screen is called "New BUG Project."
It says, "Enter a project name and select modules to use" but there is no place to do that.
There are only fields for Name and Author. I fill them in.

If I click Next it goes to "Service definition"

There is no "Find BUG services" to click

If I click "Start virtual bug" the Virtual Bug pops up.
If I close the Bug popup a Virtual Bug icon appears in the Target Bug box. This I can select.

At this point a list of services appears in the lower box and I can check the IStatusBarProvider where it had been blank before.

I click it and then Finish.

The rest of the instructions I was able to follow correctly, as far as I can see.

When I’m finished the IDE shows IStatusBarProvider as "cannot be resolved by type." (I have this pasted directly below the public class line.)

In doStart() I get statusBar and IStatusBarProvider as "cannot be resolved by type" as well.

The same error with statusBar in doStop().

When I run it the Virtual Bug appears. In the lcd the time appears along with 99%.

Following the Run It! directions I stop and restart the Virtual Bug and the Debug screen appears flagging the private IStatusBarProvider statusBar; line as unresolved.

Any suggestions?

Jan 26, 2008 12:26am
Medium Bug Labs team finsprings 268 posts

Did you try adding:

import com.buglabs.status.IStatusBarProvider;

to the imports section at the top of your file?

A handy tip in Eclipse is that, if you have an error like this, you will a lightbulb/X icon in the margin to the left of the line it doesn’t like. If you click on that icon it will offer you suggestions on how to resolve the problem. In this case it will suggest the above import as one of the options.

Hope that helps.

Cheers,
Dave

Jan 26, 2008 10:56am
Medium Bug Labs team kschultz 107 posts

Wimora,

Welcome to the forums! Thanks for pointing out the snag in step 5, it definately needs to be clarified to say click Next, start a virtual bug, select services etc. Does the MotionSensor example in the Wiki work for you? This afternoon I will try out the steps in the wiki and see if I run into the same problem you are having.

Thanks,
Jan 26, 2008 2:16pm
User_img_not_found_05_med wimora 10 posts

finsprings,
Thanks! That was the issue with the IDE. No more flags so everything appears to be OK there. This is my first experience with Eclipse so I have a lot to learn on that front. Thanks for the tip.

Outside of that, when I Run It! I get nothing at all. I don’t see anything in the console either. What I’m expecting is to see the LCD in the Virtual Bug or should this be in a bigger LCD popup like the Calc or AWTTutorial?

Kevin,
I tried to document this issue as well as I could. I’ve tried it at least half a dozen times and haven’t been able to regularly recreate the "clicking on the bug to eventually get the check boxes" issue in exactly the same way. If I get a chance I’ll try again.

Also I’ll try the MOtionsensor when I can.

Thanks to both of you for your help.
Bill

Jan 26, 2008 2:22pm
Medium Bug Labs team finsprings 268 posts

If your app has dependencies you need to ‘plug in’ the modules – GPS, LCD, whatever – that your app needs before it will run. Also, if you place calls to System.out.println in your code those messages will go to the console, so you can use them for primitive tracing. There is a log API but I’m not sure how/if it works.

Jan 26, 2008 6:04pm
User_img_not_found_05_med wimora 10 posts

Had a chance to try MotionSensor.
It went well but for step 6 I had to left click instead of right click. (A very minor issue.)

When I go back to the LCD Helloworld I appear to have a "mostly working" situation but still nothing on the Virtual Bug except the time.

I’ve seen references to the log too but have no idea what to do with it.

Jan 26, 2008 9:58pm
Medium Bug Labs team kschultz 107 posts

This is a known regression, any string under 5 characters works but over 5 and the status bar does not print it.. Try it with "Hello" instead of "Hello World" and see if it works.

Thanks,
Jan 27, 2008 11:39pm
User_img_not_found_05_med wimora 10 posts

It works.
I’d read something about that somewhere but didn’t realize what it was telling me.

Log in to reply to this topic
Forums BUG SDK Problem with Creating an Application... Web Service

Powered by Community Engine

Top
Login