Delaying an enumerated signal
20 views (last 30 days)
Show older comments
Michael Joslin
on 28 Jul 2011
Commented: ICT
on 13 Sep 2024 at 13:04
I have a model that is sending out signals on a certain schedule. There are several merge blocks that combine some of my signals, however I have two signals that are arriving at the merge block at the same time. One needs to be delayed but I cannot simply put in a unit delay because they are enumerated signals. I get the following error:
'rpMDL/Behavioral Models/BCCR_EREV_Container/BCCR_EREV/MngBCCR_BatChargCntrl/MngBCCR_CntrlBatChargProcess/Unit Delay' cannot convert parameter X0 from data type 'double' to data type 'TeBCCR_e_ChrgSysMd' because conversion of parameters with enumerated data types is not supported
Is there a way to delay an enumeration signal without to add in some data type conversions?
0 Comments
Accepted Answer
Kaustubha Govind
on 28 Jul 2011
What have you entered as the Initial Conditions value on the block? If it is the default of '0', you need to change that to an enumerated value.
2 Comments
ICT
on 13 Sep 2024 at 13:04
For me, this does not work. Are there any other solutions?
I keep getting this error:
Data type mismatch. 'Input Port 1' of '<model>/Unit Delay2' expects a signal of data type 'double'. However, it is driven by a signal of data type 'MyEnum'.
More Answers (0)
See Also
Categories
Find more on String in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!