Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Libraries does not show up in Library Browser with robotology-superbuild on Ubuntu 20.04 with MATLAB R2020b #219

Closed
traversaro opened this issue May 26, 2021 · 8 comments

Comments

@traversaro
Copy link
Member

traversaro commented May 26, 2021

I installed via robotology-superbuild with apt dependencies the library on Ubuntu 20.04 with MATLAB R2020b, and the library does not appear on the Library Browser:
Screenshot_2021-05-26_14-49-04

Note that MATLAB Whole-Body Simulator and Whole-Body Controllers instead appear correctly.

The output of path command is;

>> path

		MATLABPATH

	/home/straversaro/Documents/MATLAB
	/home/straversaro/src/isaac_ws/robotology-superbuild/build/install/mex
	/home/straversaro/src/isaac_ws/robotology-superbuild/build/install/mex/+wbc/simulink
	/home/straversaro/src/isaac_ws/robotology-superbuild/build/install/mex/+wbc/examples
	/home/straversaro/src/isaac_ws/robotology-superbuild/build/install/share/WBToolbox
	/home/straversaro/src/isaac_ws/robotology-superbuild/build/install/share/WBToolbox/images
	/home/straversaro/matlab
	/tmp/Editor_evwvv
traversaro added a commit to robotology/robotology-superbuild that referenced this issue May 27, 2021
* Do not update WB-Toolbox until robotology/wb-toolbox#219 is fixed
* Manually update icub-firmware e icub-firmware-build
@traversaro traversaro changed the title Libraries does not show up in Library Browser Libraries does not show up in Library Browser with robotology-superbuild on Ubuntu 20.04 May 27, 2021
@traversaro
Copy link
Member Author

As a first step, I will implement import_library script in #214 and run an import_library/export_library cycle to check if this fixes something.

@traversaro
Copy link
Member Author

With the latest robotology-superbuild Stable branches (cloned this morning) I started debugging the issue.

I only installed WBToolbox (via make WBToolbox, on a clean superbuild) and the issue is indeed still there:
Screenshot_2021-05-28_08-56-39

By opening the library it seems that EnableLBRepository is enabled:

>> gcs

ans =

    'WBToolboxLibrary'

>> get_param(gcs, 'EnableLBRepository')

ans =

    'on'

@traversaro
Copy link
Member Author

I added a print in slblocks.m to check if that file is correctly found, and it is:

% Copyright (C) 2018 Istituto Italiano di Tecnologia (IIT). All rights reserved.
% This software may be modified and distributed under the terms of the
% GNU Lesser General Public License v2.1 or any later version.

function blkStruct = slblocks

fprintf('Running slblocks for WBToolbox\n')

% Name of the .mdl file
Browser.Library   = 'WBToolboxLibrary';
Browser.Name      = 'WholeBodyToolbox';
Browser.IsFlat    =  0;

blkStruct.Browser =  Browser;

And indeed when I refresh the library, on the Matlab command line the message is printed (once):

>> 
Running slblocks for WBToolbox
>> 

@traversaro
Copy link
Member Author

traversaro commented May 28, 2021

I tried to save the .slx again with MATLAB as a 2020b slx, and indeed now it is loaded in the Library Browser. Interesting, when it is working the code in the slblocks.m file is executed two times:

>> 
Running slblocks for WBToolbox
Running slblocks for WBToolbox
>> 

@traversaro
Copy link
Member Author

I tried to manually export the working .slx as R2014b, and indeed it is not working again. I will try to export it via export_libraries and check instead in that case.

@traversaro
Copy link
Member Author

traversaro commented May 28, 2021

I re-exported as R2014b on Linux as well, and it is continuing not to work. So I suspect something effectively changed on them model at some point. I am trying to backtrack (to quickly debug that, slLibraryBrowser from MATLAB directly launches the library browser):

  • v5.3 : Working
  • f321ab55da309de0f1b9c279de360aebf1cfc9e5 : Working
  • d9b0633fb289b594170ae270502c7b5d8cbe5372 : Not Working

Based on this, the issue was introduced for some reason in #211 .

@traversaro
Copy link
Member Author

traversaro commented May 28, 2021

Based on this, the issue was introduced for some reason in #211 .

My theory is that the new holder block for some reason (it uses some option not present in 2014b?) creates problems to the load of the library when the library is encoded in 2014b, as they are not problems if I encode it as 2020b . To verify this, I will try to export it to various versions and check when it works.

@traversaro
Copy link
Member Author

To verify this, I will try to export it to various versions and check when it works.

I tried with R2016b, and indeed it works. I think that to quickly fix the issue, this could be a nice solution.

@traversaro traversaro changed the title Libraries does not show up in Library Browser with robotology-superbuild on Ubuntu 20.04 Libraries does not show up in Library Browser with robotology-superbuild on Ubuntu 20.04 with MATLAB R2020b May 28, 2021
traversaro added a commit that referenced this issue May 28, 2021
Furthermore, modify the matlab/export_library.m file to export that
file as 2016B.

Fix #219
Nicogene pushed a commit to Nicogene/robotology-superbuild that referenced this issue Feb 14, 2022
* Do not update WB-Toolbox until robotology/wb-toolbox#219 is fixed
* Manually update icub-firmware e icub-firmware-build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant