[Bug 651] New: build error while using DataPort<int>

https://www.fmtc.be/bugzilla/orocos/show_bug.cgi?id=651

Summary: build error while using DataPort<int>
Product: Simulink Toolbox
Version: 1.0
Platform: i386 Compatible
OS/Version: Windows
Status: NEW
Severity: normal
Priority: P3
Component: General
AssignedTo: orocos-dev [..] ...
ReportedBy: snowbluff [..] ...
CC: orocos-dev [..] ...
Estimated Hours: 0.0

Created an attachment (id=419)
--> (https://www.fmtc.be/bugzilla/orocos/attachment.cgi?id=419)
simulink model

Hi,
when I use DataPort<double> and the build process is successful. But when I
replace it with DataPort<int>, it has errors like this:
Error building Real-Time Workshop target for block diagram 'orocostest'. MATLAB
error message:
Error using ==> rtwgen
--> Error reported by S-function 'sfun_idataport' in ')">'orocostest/DataPort<int>':
Second parameter must be an integer value.
--> Error reported by S-function 'sfun_idataport' in 1')">'orocostest/DataPort<int>1':
Second parameter must be an integer value.

The attachment included two files:
OrocosTestDouble.mdl is the one using DataPort<double>
OrocosTestInt.mdl is the one using DataPort<int>

[Bug 651] build error while using DataPort<int>

https://www.fmtc.be/bugzilla/orocos/show_bug.cgi?id=651

Klaas Gadeyne <klaas [dot] gadeyne [..] ...> changed:

What |Removed |Added
----------------------------------------------------------------------------
Resolution| |WONTFIX
Status|ASSIGNED |RESOLVED

--- Comment #5 from Klaas Gadeyne <klaas [dot] gadeyne [..] ...> 2010-07-02 15:17:02 ---
Forgot to update the status of this one after consensus submitter. The "bug"
only occurs using r13 and older and is due to a lack of "feature" in the older
versions.

[Bug 651] build error while using DataPort<int>

https://www.fmtc.be/bugzilla/orocos/show_bug.cgi?id=651

--- Comment #4 from Jack Lee <snowbluff [..] ...> 2009-05-05 10:38:17 ---
(In reply to comment #3)
> (In reply to comment #2)
> > [Please reply on bugzilla instead of orocos-dev]
> >
> > >> MATLAB error message:
> > >> Error using ==> rtwgen
> > >> S-function > >> meval="das_dv_hyperlink('mdl','OrocosTestInt/DataPort<int>2')">'OrocosTestInt/DataPort<int>2'
> > >> parameters must be of type double or char for Real-Time Workshop if the
> > >> S-function does not have TLC.
> >
> >
> > >> Jack, which version of matlab/simulink are you using?
> >
> > > I'm using matlab 7.3(R2006b) and simulink 6.5(R2006b)
> >
> > We haven't got that version here, so it's hard for me to check :-( Maybe the
> > capability has only been added in later versions (I've fixed it on 2008B)
> If you compare
> <http://www.mathworks.com/access/helpdesk_r13/help/toolbox/simulink/sfg/sfun.html>
> with the current documentation of s-functions, it seems indeed a limitation of
> older simulink versions.
> Can you work around using doubles? Unless we really need this ourselves, I
> guess this will be a WONTFIX for now.

OK,thanks for your help.
I can work around using doubles. And I'll try it in matlab 2008B later.
Thanks again.

[Bug 651] build error while using DataPort<int>

https://www.fmtc.be/bugzilla/orocos/show_bug.cgi?id=651

Klaas Gadeyne <klaas [dot] gadeyne [..] ...> changed:

What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|1.1 |---
Version|1.0 |1.2

--- Comment #3 from Klaas Gadeyne <klaas [dot] gadeyne [..] ...> 2009-05-05 10:31:07 ---
(In reply to comment #2)
> [Please reply on bugzilla instead of orocos-dev]
>
> >> MATLAB error message:
> >> Error using ==> rtwgen
> >> S-function >> meval="das_dv_hyperlink('mdl','OrocosTestInt/DataPort<int>2')">'OrocosTestInt/DataPort<int>2'
> >> parameters must be of type double or char for Real-Time Workshop if the
> >> S-function does not have TLC.
>
>
> >> Jack, which version of matlab/simulink are you using?
>
> > I'm using matlab 7.3(R2006b) and simulink 6.5(R2006b)
>
> We haven't got that version here, so it's hard for me to check :-( Maybe the
> capability has only been added in later versions (I've fixed it on 2008B)

If you compare
<http://www.mathworks.com/access/helpdesk_r13/help/toolbox/simulink/sfg/sfun.html>
with the current documentation of s-functions, it seems indeed a limitation of
older simulink versions.

Can you work around using doubles? Unless we really need this ourselves, I
guess this will be a WONTFIX for now.

[Bug 651] build error while using DataPort<int>

https://www.fmtc.be/bugzilla/orocos/show_bug.cgi?id=651

--- Comment #2 from Klaas Gadeyne <klaas [dot] gadeyne [..] ...> 2009-05-05 10:14:51 ---
[Please reply on bugzilla instead of orocos-dev]

>> MATLAB error message:
>> Error using ==> rtwgen
>> S-function > meval="das_dv_hyperlink('mdl','OrocosTestInt/DataPort<int>2')">'OrocosTestInt/DataPort<int>2'
>> parameters must be of type double or char for Real-Time Workshop if the
>> S-function does not have TLC.

>> Jack, which version of matlab/simulink are you using?

> I'm using matlab 7.3(R2006b) and simulink 6.5(R2006b)

We haven't got that version here, so it's hard for me to check :-( Maybe the
capability has only been added in later versions (I've fixed it on 2008B)

[Bug 651] build error while using DataPort<int>

https://www.fmtc.be/bugzilla/orocos/show_bug.cgi?id=651

Klaas Gadeyne <klaas [dot] gadeyne [..] ...> changed:

What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |1.1
Status|NEW |ASSIGNED

--- Comment #1 from Klaas Gadeyne <klaas [dot] gadeyne [..] ...> 2009-05-05 09:11:18 ---
(In reply to comment #0)

The following procedure fixes this for me (debian lenny, matlab 7.7)

> 1/ open $MATLAB_ROOT/rtw/c/orocos/taskcontext/orocos_taskcontext.mdl,
> 2/ unlock the library (Menu: Edit -> Unlock Library)
> 3/ double click on the DataPort<int> block and
> 4/ change the "initial value" from '0' to 'int32(0)'

But seems to cause the following error for Jack

MATLAB error message:
Error using ==> rtwgen
S-function 2')">'OrocosTestInt/DataPort<int>2'
parameters must be of type double or char for Real-Time Workshop if the
S-function does not have TLC.

Jack, which version of matlab/simulink are you using?

[Bug 651] build error while using DataPort<int>

On Tue, May 5, 2009 at 3:11 PM, Klaas Gadeyne <klaas [dot] gadeyne [..] ...> wrote:

> https://www.fmtc.be/bugzilla/orocos/show_bug.cgi?id=651
>
>
> Klaas Gadeyne <klaas [dot] gadeyne [..] ...> changed:
>
> What |Removed |Added
>
> ----------------------------------------------------------------------------
> Target Milestone|--- |1.1
> Status|NEW |ASSIGNED
>
>
>
>
> --- Comment #1 from Klaas Gadeyne <klaas [dot] gadeyne [..] ...> 2009-05-05
> 09:11:18 ---
> (In reply to comment #0)
>
> The following procedure fixes this for me (debian lenny, matlab 7.7)
>
> > 1/ open $MATLAB_ROOT/rtw/c/orocos/taskcontext/orocos_taskcontext.mdl,
> > 2/ unlock the library (Menu: Edit -> Unlock Library)
> > 3/ double click on the DataPort<int> block and
> > 4/ change the "initial value" from '0' to 'int32(0)'
>
> But seems to cause the following error for Jack
>
> MATLAB error message:
> Error using ==> rtwgen
> S-function
> meval="das_dv_hyperlink('mdl','OrocosTestInt/DataPort<int>2')">'OrocosTestInt/DataPort<int>2'

> parameters must be of type double or char for Real-Time Workshop if the
> S-function does not have TLC.
>
> Jack, which version of matlab/simulink are you using?
>
> --
> Configure bugmail:
> https://www.fmtc.be/bugzilla/orocos/userprefs.cgi?tab=email
> ------- You are receiving this mail because: -------
> You reported the bug.
>

I'm using matlab 7.3(R2006b) and simulink 6.5(R2006b).
Does it have something to do with the version of matlab?

ps:
While I compile the code generated in Ubuntu 8.10, there is a message "make:
*** No rule to make target `rt_atan2.o', needed by `rtwlib.a'. Stop.". what
should I do to fix it?