From: khan Sim on
first of all, alot of thanks to you for your time , ideas, guidelines.

i have started working on fixed point tool box, worked on the HDL demos. those were really eye openers to me.

well i have further divided the embedded matlab function code into simulink blocks.

now the only code left is

function smb = fcn(fsb,fsb0,amp_max,afsb0,P_max)
%#eml
for k = 1:length(fsb0)
if afsb0(k) > amp_max*P_max
fsb0(k) = (amp_max*(P_max^2)./afsb0(k)).*exp(1j*angle(fsb0(k)));
end
end
% Apply a window (e.g., power window) on fsb0 here%
% Matched Filtering%
fsmb=fsb.*conj(fsb0);%
% Inverse Fourier Transform%
smb=fftshift(ifft(fftshift(fsmb.'))).';


i think the difference between the early code and this code is visible.

can you guide me how can i implement the following code in term of simulink blocks so that i can synthesize them. any hint.. ?

fs
for k = 1:512
if afsb0(k) > amp_max*P_max
fsb0(k) = (amp_max*(P_max^2)./afsb0(k)).*exp(1j*angle(fsb0(k)));
end

thank you very much, after working on your previous post, i ve been able to go ahead.

waiting for your reply
regards
khan
From: khan Sim on
in addition to the above post,

i ve some queries,

do we define a clock source in simulink model like we define in verilog?
what is the difference between sample based, time based and frame based???
From: Walter Roberson on
khan Sim wrote:

> do we define a clock source in simulink model like we define in verilog?
> what is the difference between sample based, time based and frame based???

http://www.mathworks.com/access/helpdesk/help/toolbox/dspblks/ug/f13-62668.html
From: Walter Roberson on
khan Sim wrote:

> do we define a clock source in simulink model like we define in verilog?
> what is the difference between sample based, time based and frame based???

http://www.mathworks.com/access/helpdesk/help/toolbox/dspblks/ug/f13-62668.html
From: Walter Roberson on
khan Sim wrote:

> do we define a clock source in simulink model like we define in verilog?
> what is the difference between sample based, time based and frame based???

http://www.mathworks.com/access/helpdesk/help/toolbox/dspblks/ug/f13-62668.html