Aerospace Blockset for Xcos  

Aerospace Blockset for Xcos Commit Details

Date:2016-05-12 16:35:47 (1 year 8 months ago)
Author:Clément David
Branch:master
Commit:af568664e3b6f4a3ae38c429059e7ca2e6cc6a5f
Parents: b6c76ae292fbf88881669590ab853d5074abe34e
Message:Fix for Scilab 6

Changes:
Mbuilder.sce (1 diff)
Mmacros/AB_eph_planet.sci (1 diff)
Mmacros/AB_mod_atmUS76.sci (2 diffs)
Mmacros/AB_mod_geomagField.sci (1 diff)
Mmacros/AB_mod_moonSun.sci (1 diff)

File differences

builder.sce
2525
2626
2727
28
28
2929
3030
3131
// =============================================================================
if ~isdef('tbx_build_loader') then
error(msprintf(gettext('%s module not installed."), 'modules_manager'));
error(msprintf(gettext("%s module not installed."), 'modules_manager'));
end
macros/AB_eph_planet.sci
2828
2929
3030
31
31
3232
3333
3434
block.outptr(2) = eod_vel;
case 4 then
// Initialization
if block.nin<>1 or block.nout<>2 then
if block.nin<>1 | block.nout<>2 then
error('Incorrect number of block inputs or output for calling CL_mod_moonSun function');
set_blockerror(-1);
end
macros/AB_mod_atmUS76.sci
2121
2222
2323
24
24
2525
2626
2727
......
3131
3232
3333
34
34
3535
3636
3737
select flag
case 1 then
// Output computation
if (block.inptr(1) < 0) or (block.inptr(1) > 1000000)
if (block.inptr(1) < 0) | (block.inptr(1) > 1000000)
set_blockerror(-1);
error(msprintf(gettext("\t%s\t: Altitude must be between 0 and 100 000 meters"), block_label));
else
;
case 4 then
// Initialization
if block.nin<>1 or block.nout<>3 then
if block.nin<>1 | block.nout<>3 then
set_blockerror(-1);
error(msprintf(gettext("\t%s\t: Incorrect number of block inputs or output for calling CL_mod_atmUS76() function"), block_label));
end
macros/AB_mod_geomagField.sci
2424
2525
2626
27
27
2828
2929
3030
pos_ECF = block.inptr(1);
t_cjd = block.inptr(2);
altitude = sqrt(pos_ECF(1)^2 + pos_ECF(2)^2 + pos_ECF(3)^2);
if (altitude < 0) or altitude > 42000000)
if (altitude < 0) | (altitude > 42000000)
set_blockerror(-1);
messagebox("Altitude must be between 0 and 42 000 000 meters for IGRF model to give precise values", block_label, "error");
else
macros/AB_mod_moonSun.sci
3535
3636
3737
38
38
3939
4040
4141
end
case 4 then
// Initialization
if block.nin<>1 or block.nout<>1 then
if block.nin<>1 | block.nout<>1 then
error('Incorrect number of block inputs or output for calling CL_mod_moonSun function');
set_blockerror(-1);
end

Archive Download the corresponding diff file

Branches