how can i show figure in my m-file?
Mostrar comentarios más antiguos
Hi Im going to execute these codes in matlab in order tc generate hdl code
:function [iport,tnext] = ADD_TESTER (oport, tnow, portinfo)
persistent ud; %Create a struct to store persistent user data
tnext = []; %initialize tnext to null
iport = struct(); %initialize iport to null
if(nargin ==3) %First call has 3 arguments
ud.call_count = 0; %Initialize call counter
tnext = tnow+100e-9;%Next invocation after 100 ns
iport.a = '0';
iport.b = '0';
iport.cin = '0';
else
ud.call_count = ud.call_count + 1;
if ud.call_count < 8 %run for 8 cycles
tnext = tnow+100e-9; %Next invocation after 100 ns
bin = dec2bin(ud.call_count,3);%Convert counter to binary string
iport.a = bin(1); %Assign bits of bin to 3 inputs
iport.b = bin(2);
iport.cin = bin(3);
else
disp('Over'); %If 8 cycles are over, don’t invoke with tnext
end
end
AND THE ERROR IS:Error in ADD_TESTER (line 15)
ud.call_count = ud.call_count + 1;
>> ADD_TESTER
15 ud.call_count = ud.call_count + 1;
K>>
PLZ HELP ME THANK YOU SO MUCH!
2 comentarios
Walter Roberson
el 28 de Feb. de 2013
What error message is given?
shide agani
el 1 de Mzo. de 2013
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre AMD FPGA and SoC Devices en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!