|
|
It would be very useful if one could specify in the Run dialog which modules are plugged into the VirtualBUG. It gets really tedious having to select them every time you run it when developing an app. There’s already places to set the GPS and image data, so maybe extending that to have check boxes for the already-connected modules would do the trick. Any thoughts? |
|
|
Hi finsprings, Issue has been added (http://bugcommunity.com/bugzilla/show_bug.cgi?id=87) for your proposal. |
|
|
I agree, it becomes a bit repetitive to wait for the bug to load and then have to click, choose your module, choose ok, especially when doing so numerous times an hour for multiple hour. |
|
|
This feature has been implemented and is available in the latest integration build that can be downloaded here: http://buglabs.net/sdk |
|
|
That's great Alex! So, I uninstalled Dragonfly and modified my repository setting to be .../integration/current and reinstalled Dragonfly (Update Installed only seems to search for Eclipse stuff). However, I don't see any way to choose which modules are selected. The Run dialog just has the GPS and Images settings as it always has, and the selection dialog you get when adding a module looks the same too. I looked at the bug report and you say , but I don't know what the means. So I'm probably just being dumb here, but where do I make my module selections sticky? |
|
|
Ah, sorry should have provided some how-to. So, this is how module persistence works: In Virtual BUG Configuration under Concierge tab, in properties section there is a property com.buglabs.osgi.cm.storage. This property defines where different information about BUG is persisted and retrieved. So currently it is at $ECLIPSE_HOME/bug-configuration. This directory is needed because framework defines its own storage directory ($ECLIPSE_HOME/storage). However, by default this directory is wiped out on every restart (in our world it’s Virtual BUG) and in case where user wants clear state of the platform but not of the storage directory it would be a little bit confusing for the user. So, if you define com.buglabs.osgi.cm.storage property, that would be used for persistence, otherwise storage directory would be used. But I suggest for now define com.buglabs.osgi.cm.storage property. When this property is set, every time you launch Virtual BUG and add modules, this information will be persisted in directory defined by com.buglabs.osgi.cm.storage. So, if you launch Virtual BUG, add GPS and LCD module, restart Virtual BUG, GPS and LCD modules will automagically reappear. Currently, there are no means of clearing custom storage directory, if you need to, you can go to $ECLIPSE_HOME/$com.buglabs.osgi.cm.storage and delete .bin files that represent persisted state. For modules this file is com.buglabs.bug.emulator.awt.bin. If you have any questions or suggestions, please let us know. thanks! |
|
|
One more thing. On information about Configuration Admin please refer to this post: http://bugcommunity.com/forums/viewtopic.php?t=208 |
|
|
I might be missing something here in Alex's technical discussion, but after I upgraded to the new SDK it just worked without any configuration/code changes. The BUG pops up initially with no modules, and then in my case I put in two, edited some code, and when I hit Run As->Virtual Bug it started up again with the two modules already plugged in. If you empty the modules by right clicking on the plugs and choosing "empty", it will start up again the way it used to. I too was expecting some kind of check box in the Run As dialog, but I think this is more intuitive, new users who didn't know about the limitation before would probably expect it to show them the moduels they had before without clicking and checkboxes, I'm pleased though, the time used to really add up before every time you ran a program. Thanks Alex. |
|
|
You are right Kevin, everything works "out of the box." I just wanted to clarify the use of com.buglabs.osgi.cm.storage because it mimics OSGi’s default storage directory but is not bound by how platform treats the storage directory. In addition a user might want to change what this property defines to something like tmp/myStorage/configuration or whatever makes sense for him. |
|
|
It wasn’t working for me until I defined com.buglabs.osgi.cm.storage, but now it is working great! Thanks for this Alex; it’s going to be a big time saver, as often as I have to restart the VirtualBug while trying to get my code to work :-) |
|
|
Excellent! Glad it worked out for you. But, You don't have the property set in Virtual BUG Launch Configuration? You would not have that property set if you were launching from custom Concierge Launch Configuration. |
|
|
I opened the Run As dialog, selected Virtual Bug and all that first tab shows in the GPS and Image stuff. I clicked on the Concierge tab and it wasn't in the Property Name list, so I added it. Once I did that and ran I could see it create the .bin file in the directory I specified and it retained my module selections across launches. Are you saying that it should already have been in that list? |
|
|
Ok, I know what happened here. When you updated your current SDK the new code that defines storage property was installed. However, since you had old launch configuration it did not update that configuration. If you create new launch configuration off root Virtual BUG, com.buglabs.osgi.cm.storage property will be there. I believe Eclipse platform follows the same convention where old launch configurations are not updated, you just have to create new ones. Hope this helps |