From 5301c7dd5645ad95de37038ccc72aaa3541f2540 Mon Sep 17 00:00:00 2001 From: jofret Date: Thu, 17 Jun 2010 10:07:35 +0000 Subject: Add demos --- scilab2c/demos/Filter.dem.sce | 18 ++++++++++++++++++ scilab2c/demos/LinearRegression.dem.sce | 19 +++++++++++++++++++ scilab2c/demos/Symbols.dem.sce | 20 ++++++++++++++++++++ scilab2c/demos/TrigonometricIdentity.dem.sce | 9 ++++++++- scilab2c/demos/alldemos.dem.sce | 17 ----------------- scilab2c/demos/scilab2c.dem.gateway.sce | 21 +++++++++++++++++++++ scilab2c/etc/scilab2c.start | 2 +- 7 files changed, 87 insertions(+), 19 deletions(-) create mode 100644 scilab2c/demos/Filter.dem.sce create mode 100644 scilab2c/demos/LinearRegression.dem.sce create mode 100644 scilab2c/demos/Symbols.dem.sce delete mode 100644 scilab2c/demos/alldemos.dem.sce create mode 100644 scilab2c/demos/scilab2c.dem.gateway.sce diff --git a/scilab2c/demos/Filter.dem.sce b/scilab2c/demos/Filter.dem.sce new file mode 100644 index 00000000..a0484ece --- /dev/null +++ b/scilab2c/demos/Filter.dem.sce @@ -0,0 +1,18 @@ +// +// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab +// Copyright (C) 2010-2010 - DIGITEO - Bruno JOFRET +// +// This file must be used under the terms of the CeCILL. +// This source file is licensed as described in the file COPYING, which +// you should have received as part of this distribution. The terms +// are also available at +// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt +// +// +lines(0); + +global SCI2CHOME +editor(SCI2CHOME+"/tests/unit_tests/test004_Filter/scilabcode/main.sci"); +editor(SCI2CHOME+"/tests/unit_tests/test004_Filter/scilabcode/high_pass.sci"); + +scilab2c(SCI2CHOME+"/tests/unit_tests/test004_Filter/scilabcode/main.sci", TMPDIR, SCI2CHOME+"/tests/unit_tests/test004_Filter/scilabcode/"); \ No newline at end of file diff --git a/scilab2c/demos/LinearRegression.dem.sce b/scilab2c/demos/LinearRegression.dem.sce new file mode 100644 index 00000000..5c3a20c2 --- /dev/null +++ b/scilab2c/demos/LinearRegression.dem.sce @@ -0,0 +1,19 @@ +// +// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab +// Copyright (C) 2010-2010 - DIGITEO - Bruno JOFRET +// +// This file must be used under the terms of the CeCILL. +// This source file is licensed as described in the file COPYING, which +// you should have received as part of this distribution. The terms +// are also available at +// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt +// +// + +lines(0); +global SCI2CHOME +editor(SCI2CHOME+"/tests/unit_tests/test001_LinearRegression/scilabcode/mainfunction.sci"); + +scilab2c(SCI2CHOME+"/tests/unit_tests/test001_LinearRegression/scilabcode/mainfunction.sci", TMPDIR); + +editor(TMPDIR+"/main.c"); \ No newline at end of file diff --git a/scilab2c/demos/Symbols.dem.sce b/scilab2c/demos/Symbols.dem.sce new file mode 100644 index 00000000..5339b988 --- /dev/null +++ b/scilab2c/demos/Symbols.dem.sce @@ -0,0 +1,20 @@ +// +// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab +// Copyright (C) 2010-2010 - DIGITEO - Bruno JOFRET +// +// This file must be used under the terms of the CeCILL. +// This source file is licensed as described in the file COPYING, which +// you should have received as part of this distribution. The terms +// are also available at +// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt +// +// + +lines(0); + +global SCI2CHOME +editor(SCI2CHOME+"/tests/unit_tests/test002_Symbols/scilabcode/mainfunction.sci"); + +scilab2c(SCI2CHOME+"/tests/unit_tests/test002_Symbols/scilabcode/mainfunction.sci", TMPDIR); + +editor(TMPDIR+"/main.c"); \ No newline at end of file diff --git a/scilab2c/demos/TrigonometricIdentity.dem.sce b/scilab2c/demos/TrigonometricIdentity.dem.sce index 36d59ee5..a2c47c1e 100644 --- a/scilab2c/demos/TrigonometricIdentity.dem.sce +++ b/scilab2c/demos/TrigonometricIdentity.dem.sce @@ -10,5 +10,12 @@ // // +lines(0); + global SCI2CHOME -xpad(SCI2CHOME+"/tests/unit_tests/test000_TrigonIdentity/scilabcode/mainfunction.sci"); \ No newline at end of file +editor(SCI2CHOME+"/tests/unit_tests/test000_TrigonIdentity/scilabcode/mainfunction.sci"); + +scilab2c(SCI2CHOME+"/tests/unit_tests/test000_TrigonIdentity/scilabcode/mainfunction.sci", TMPDIR); + +editor(TMPDIR+"/main.c"); + diff --git a/scilab2c/demos/alldemos.dem.sce b/scilab2c/demos/alldemos.dem.sce deleted file mode 100644 index c0f0e812..00000000 --- a/scilab2c/demos/alldemos.dem.sce +++ /dev/null @@ -1,17 +0,0 @@ -// -// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab -// Copyright (C) 2010-2010 - DIGITEO - Bruno JOFRET -// -// This file must be used under the terms of the CeCILL. -// This source file is licensed as described in the file COPYING, which -// you should have received as part of this distribution. The terms -// are also available at -// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt -// -// - -demopath = get_absolute_file_path("alldemos.dem.sce"); - -subdemolist = ["Trigonometric Identity" , "TrigonometricIdentity.dem.sce"]; - -subdemolist(:,2) = demopath + subdemolist(:,2); \ No newline at end of file diff --git a/scilab2c/demos/scilab2c.dem.gateway.sce b/scilab2c/demos/scilab2c.dem.gateway.sce new file mode 100644 index 00000000..71372e25 --- /dev/null +++ b/scilab2c/demos/scilab2c.dem.gateway.sce @@ -0,0 +1,21 @@ +// +// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab +// Copyright (C) 2010-2010 - DIGITEO - Bruno JOFRET +// +// This file must be used under the terms of the CeCILL. +// This source file is licensed as described in the file COPYING, which +// you should have received as part of this distribution. The terms +// are also available at +// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt +// +// + +demopath = get_absolute_file_path("scilab2c.dem.gateway.sce"); + +subdemolist = ["Trigonometric Identity" , "TrigonometricIdentity.dem.sce"; + "Linear Regression" , "LinearRegression.dem.sce"; + "Symbols", "Symbols.dem.sce"; + "High Pass Filter", "Filter.dem.sce"; + ]; + +subdemolist(:,2) = demopath + subdemolist(:,2); \ No newline at end of file diff --git a/scilab2c/etc/scilab2c.start b/scilab2c/etc/scilab2c.start index 5189f41d..1f7348a6 100644 --- a/scilab2c/etc/scilab2c.start +++ b/scilab2c/etc/scilab2c.start @@ -39,7 +39,7 @@ end if or(getscilabmode() == ["NW";"STD"]) then mprintf("\tLoad demos\n"); - pathdemos = pathconvert(root_tlbx + "/demos/alldemos.dem.sce",%f,%t); + pathdemos = pathconvert(root_tlbx + "/demos/scilab2c.dem.gateway.sce",%f,%t); disp("**") disp(pathdemos); -- cgit