Borrar filtros
Borrar filtros

HDL Coder errors don't make sense

2 visualizaciones (últimos 30 días)
SAI GAUTHAM P
SAI GAUTHAM P el 15 de Mzo. de 2016
Editada: Tim McBrayer el 15 de Mzo. de 2016
I get the following HDL coder errors when I try to convert the attached be_alam.m. I have attached the function and the test bench. Please help.
Errors:
be_alam_fixpt:48 Error Found unsupported dynamic matrix type at output port: 0, name 'o1r', in the file/function be_alam_fixpt.
be_alam_fixpt:0 Error MATLAB HDL Coder failed in the code generation phase. See HDL Coder conformance report.

Respuestas (1)

Tim McBrayer
Tim McBrayer el 15 de Mzo. de 2016
Editada: Tim McBrayer el 15 de Mzo. de 2016
I believe your problem is your call to 'find' around like 50 of be_alam.m. 'find' returns a variable size vector as its result. This will be the proximate cause of the "dynamic matrix type". HDL Coder needs all variables to have a fixed size at all times.
I think you will have to implement the 'find' functionality explicitly, returning a single value.
min_dis = min(dis);
for ii = 1:numel(dis)
if dis(ii) == min_dis
n = ii;
end
end

Categorías

Más información sobre Code Generation en Help Center y File Exchange.

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by