Sunday, April 28, 2013

For DCN Subject

Mid Semester Remedial of DCN Subject may be taken in college in next week. Time Table for the Examination may be posted on Monday to the Notice Board. Thanks to Vishal Modi & Ganesh Patel for this Information.
For More Detail Contact on Monday to Vishal Modi, Ganesh Patel, Taj. 
Please Do not Call me for the Details. 

Saturday, April 27, 2013

Best Luck

So Finally Submission and Viva has been Completed.
Best of Luck Guys for the Final Examinations of the Bachelor of Engineering.


 

Friday, April 26, 2013

Submission & Viva

For 8th EC Students,
Tommorrow (i.e.27/4/2013) Submission & viva will be taken in College.

So be Present. 

Tuesday, April 23, 2013

Title Page of Project Report

GSM based Passenger Control & Management System in BRTS

A PROJECT REPORT
Submitted by
                              Jani Darshan B.   (090580111053)
                           

In fulfillment for the award of the degree
of
BACHELOR OF ENGINEERING
In
 Electronics and Communication Engineering


FACULTY OF ENGINEERING, RAJPUR
Shree Saraswati Education Santhan’s Group of Institutions

Gujarat Technological University, Ahmedabad
May, 2013


Monday, April 22, 2013

Radar's Practical List



     Date:      /     / 
Experiment No: 1

Aim: Write a program in Matlab for computing minimum detectable power for radar.
Code:

pt = 1.5e6;                     % transmitted power (W)
G = 10*log10 (45);        % antenna gain (dB)
sigma = 0.1;                   % antenna effective aperture (m^2)
f= 5.6e9   ;                     % frequency (Hz)
c= 3e8;                          % speed of light (m/s)
lambda = c/f;                
for rmax = 10e3:0.5e3:30e3;        % min detectable signal power (m)
smin = (pt*(G^2)*(lambda^2)*sigma)/(((4*pi)^3)*(rmax^4))
plot (rmax,smin,'*');
hold on;
end

xlabel('Max range ');
ylabel('Smin ');
title('Minimum dectable signal power for radar range ');

Result:


                                                                                                                                  Date:     /    /
Experiment No: 2

Aim: Write a program in Matlab for computing radar range with SNR.
Code:

pt = 1.5e6;                                   % tranmitted power(W)
G = 10^(45/10);                          % antenna gain (dB)
sigma = 0.1;                                 % target cross section (m^2)
f = 5.6e9;                                     % frequency (Hz)
c = 3.0e8;                                    % speed of light (m/s)
k = 1.38e-23;                               % Boltzman's constant
Te =290;                                      % effective temp. (K)
F = 10^(3/10);                             % noise figure (dB)
SNR_min = 10^(20/10);             % signal to noise ratio (dB)
lambda = c/f;

for pulse_width = [0.2e-6:0.05e-6:2e-6]; % (sec)
    B = 1/pulse_width;
    rmax = ((pt*(G^2)*(lambda^2)*sigma)/(((4*pi)^3)*k*Te*B*F*SNR_min))^(1/4)
    plot(rmax,pulse_width,'.');
    hold on;
end

xlabel('Max range ');
ylabel('Pulse width');
 Result: 

Date:     /    /
Experiment No: 3

Aim: Write a program in Matlab for radar cross section
Code:

frequ = 0e6;
freql = 15e6;
scat_spacing = 50;
eps = 0.0001;
freq_band = frequ - freql;
delfreq = freq_band / 500.;
index = 0;
for freq = freql: delfreq: frequ
index = index +1;
wavelength(index) = 3.0e+8 / freq;
end
elec_spacing = 2.0 * scat_spacing ./ wavelength;
rcs = abs ( 1 + cos((2.0 * pi) .* elec_spacing) + i * sin((2.0 * pi) .* elec_spacing));
rcs = rcs + eps;
rcs = 20.0*log10(rcs); % RCS ins dBsm

% Plot RCS versus frequency
 freq = freql:delfreq:frequ;
plot(freq,rcs,'linewidth',2); grid;
xlabel('Frequency (Hz)');
ylabel('RCS in dBsm'); 
Result:
                                                                                                                                      Date:     /    /
Experiment No: 4

Aim: Write a program in Matlab for computing Doppler frequency.

Code:

%for freq = 10E6:5E6:100E6;

freq = 20e6;
ang = 30;
for tv = 500:10:750;  % m/s
target = 1;
format long
c = 3.0e+8;
ang_rad = ang * pi /180.;
lambda = c / freq;
if (target == 1)
fd = 2.0 * tv * cos(ang_rad) / lambda;
tdr = (c - tv) / (c + tv);
else
fd = -2.0 * c * tv * cos(and_rad) / lambda;
tdr = (c + tv) / (c -tv);
end
subplot(2,1,1);
plot(tv,fd,'*');
hold on;
subplot(2,1,2);
plot(tv,tdr,'o');
hold on;
end

fd
tdr

display ('Calculation Result for Doppler Frequency');
display('--------------------------------------------');
disp (['Doppler Frequency = ',num2str(fd)]);
disp (['Time Dilation Factor  = ',num2str(tdr)]);

Result:

fd =   86.60
tdr =    0.99

Calculation Result for Doppler Frequency
--------------------------------------------
Doppler Frequency = 86.6025
Time Dilation Factor  = 1



Date:     /    /
Experiment No: 5

Aim: Write a program in Matlab for matched filter.

Code:


% Matched Filter
% Input Parameter
nf = 14;                           % Fontsize
np = 300000;                       % Number of point for FFT
c = 3E8;                           % Speed of Light
T  = 20E-6;                        % Pulse Duration (T = 20usec)
BW = 100E6;                        % Chirp Bandwidth of interest(BW = 25MHz)
K = BW/T;                          % Chirp rate
fc = 0;                           
fs = 4*BW;                         % Sampling frequency
TB = BW*T;                         % Time Bandwidth product
n = T*fs;                          % Number of sample
t = (-T/2):(1/fs):(T/2)-(1/fs);
color = ['r' 'g' 'b' 'y' 'b' 'c' 'm'];
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
h = 1;         
LFM = exp(1i*(pi*((fc)*t + K*t.^2)));           % LFM
LFMC = conj(LFM);                               % Match Filter (Complex Conjugate of LFM)
LFM_rate = fc + (K * t);

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Frequency domain
fmin = (fc-BW)/2;
fmax = (fc+BW)/2;
fre = linspace(fmin,fmax,n);
FLFM = fftshift(fft(LFM,n));             
FLFMC = fftshift(fft(LFMC,n));           
Y0 = db(FLFM)-db(FLFM(int16(n/2)));
figure(1), plot(fre,Y0,color(h),'linewidth',2);
axis([-0.2e8,0.2e8,-50,5]);            
hold on;
title(['Frequency Spectrum Bandwidth = ',int2str(BW)],'fontsize',nf);
xlabel('Frequency(Hz)','fontsize',nf);ylabel('Power(db)','fontsize',nf);

 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Generation of the Power Pattern
% Method using convolution
CLFM = conv(LFM,LFMC);
cn = length(CLFM)+1;                    % length of Convolution
lmin = (cn/2-n/2)+1;                    % Minimum limit for CLFM
lmax = (cn/2+n/2);                      % maximum limit for CLFM
Y1 = interpft(CLFM,np);
T1 = interpft(t,np);
PLFM1 = db(Y1)-max(db(Y1));
figure(2),plot(T1,PLFM1,color(h),'linewidth',2); grid on;
axis([-5e-8,5e-8,-50,5]);
xlabel('Time(sec)','fontsize',nf);ylabel('Power(db)','fontsize',nf);

Result:

Date:     /    /
Experiment No: 6

Aim: Write a program in Matlab for LFM.
Code:

fid = fopen('C:\Users\Nilesh\Documents\MATLAB\radar\lfm.csv','w');

% Linear FM Radar Waveform

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Input Parameter
nf = 14;                           % Fontsize
np = 300000;                       % Number of point for FFT
c = 3E8;                           % Speed of Light
T  = 20E-6;                        % Pulse Duration (T = 20usec)
BW = 100E6;                        % Chirp Bandwidth of interest(BW = 25MHz)
K = BW/T;                          % Chirp rate
fc = 0;                           
fs = 1*BW;                         % Sampling frequency
TB = BW*T;                         % Time Bandwidth product
n = T*fs;                          % Number of sample
t = (-T/2):(1/fs):(T/2)-(1/fs);

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

LFM = exp(1i*(pi*((fc)*t + K*t.^2)));         
LFM_rate = fc + (K * t);
y = [t; real(LFM)];
y = y';
fprintf(fid,'%12.8f  %12.8f\n',y);
title('Linear FM','Fontsize',nf);
figure(1),subplot(3,1,1);plot(t,real(LFM),'r','linewidth',2);                     
axis([-T/5,T/5,-1.5,1.5]);         
xlabel('Time(sec)','Fontsize',nf);ylabel('idata','Fontsize',nf); hold on;
subplot(3,1,2);plot(t,imag(LFM),'r','linewidth',2);                
axis([-T/5,T/5,-1.5,1.5]);
xlabel('Time(sec)','Fontsize',nf);ylabel('qdata','Fontsize',nf);
%title('Chirp Phase Response');
xlabel(Time(sec)','Fontsize',nf);
subplot(3,1,3); plot(t,LFM_rate,'r','linewidth',2);hold on;
axis([-T/5,T/5,-5E7,5E7]);          % Bandwidth = 100MHz
xlabel('Time(sec)','fontsize',nf);ylabel('Fre(MHz)','fontsize',nf);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
fclose(fid);

 Result:

Date:     /    /
Experiment No: 7

Aim: Write a program in Matlab for single line delay canceller.

Code:
% single canceler
eps = 0.00001;
fofr = 0:0.01:1;
arg1 = pi .* fofr;
resp = 4.0 .*((sin(arg1)).^2);
max1 = max(resp);
resp = resp ./ max1;

subplot(2,1,1)
plot(fofr,resp,'k')
xlabel ('Normalized frequency - f/fr')
ylabel( 'Amplitude response - Volts')
grid

subplot(2,1,2)
resp=10.*log10(resp+eps);
plot(fofr,resp,'k');
axis tight
grid
xlabel ('Normalized frequency - f/fr')
ylabel( 'Amplitude response - dB')

Result: 
Date:     /    /
Experiment No: 8

Aim: Write a program in Matlab for double line delay canceller.

Code:

eps = 0.00001;
fofr = 0:0.001:1%fofr1;
arg1 = pi .* fofr;
resp = 4.0 .* ((sin(arg1)).^2);
max1 = max(resp);
resp = resp ./ max1;
resp2 = resp .* resp;

subplot(2,1,1);
plot(fofr,resp,'k--',fofr, resp2,'k');
ylabel ('Amplitude response - Volts')

resp2 = 20. .* log10(resp2+eps);
resp1 = 20. .* log10(resp+eps);

subplot(2,1,2)
plot(fofr,resp1,'k--',fofr,resp2,'k');

legend ('single canceler','double canceler')
xlabel ('Normalized frequency f/fr')
ylabel ('Amplitude response - dB')  

Result:

Date:     /    /
Experiment No: 9

Aim: Write a program in Matlab for linear antenna field intensity

Code:

   % Linear Antenna Field Intensity
   
    clc;
    clear all;
    close all;
   
    n = input('Enter the The Number of linear Array (n) : ');
    si = 0 : 0.01 : (2*pi) ;
   
    % Field Intensity
    FI = abs((sin(n*si./2))./(sin (si./2)));
   
    figure,plot(si,FI);
    title('Field Intensity of Antenna');
    xlabel('si');
    ylabel('Field Intensity of Antenna');
   
    figure,polar (si,FI);
    title('Polar Plot of Antenna Pattern');

Result:

Enter the The Number of linear Array (n) : 5


Date:     /    /
Experiment No: 10

Aim:  Write a program in Matlab for synthetic aperture radar.

Code:

% SAR
clc;
clear all;
close all;

v = 150 ;
R = 10E3;
f = linspace(1E9,100E9,100);
for crr = 1:2:10;
c = 3E8;
lamda = c./f;
Daz = R*lamda/crr;
Ta = Daz/v;
figure(1),loglog(f,Ta); grid on; hold on;
end
xlabel(' Fig 1.               Frequency (Hz)','fontsize',14); ylabel('Aperature(sec)','fontsize',14);

v = 7500;
R = 770E3;
for crr = 10:10:100;
c = 3E8;
lamda = c./f;
Daz = R*lamda/crr;
Ta = Daz/v;
figure(2),loglog(f,Ta); grid on; hold on;
end
xlabel('' Fig 2               Frequency (Hz)','fontsize',14); ylabel('Aperature(sec)','fontsize',14); 

Result:

Happy wala Newz

Tomorrow (i.e. 23rd April 2013)  is holiday in our College...!!!
Special Thanks to God....!!!
     

Thursday, April 18, 2013

Assignment-2 of DCN by Pratik Shah

(1) Explain ALOHA Protocol in Detail. (Techmax 5.4)
(2) Exp CSMA in detail with CSMA-CA & CD. (Techmax 5.5)
(3) List out the Device used in Network & exp each. (Techmax 6.11,13,14,15,16)

(4) Classification of IP adderess. (Techmax 7.23)

Wednesday, April 17, 2013

Program to Make a Bidirectional Visitor Counter using IR sensor

// Program to make a bidirectional visitor counter using IR sensor
#include <reg51.h>
#define msec 1
unsigned int num=0;
sbit dig_ctrl_4=P1^3;  //declare the control pins of seven segments
sbit dig_ctrl_3=P1^2;
sbit dig_ctrl_2=P1^1;
sbit dig_ctrl_1=P1^0;
unsigned int digi_val[10]={0x40,0xF9,0x24,0x30,0x19,0x12,0x02,0xF8,0x00,0x10};
unsigned int dig_1,dig_2,dig_3,dig_4,test=0;
unsigned char dig_disp=0;
sbit up=P3^5;  //up pin to make counter count up
sbit down=P3^6;  //down pin to make counter count down
void init()  // to initialize the output pins and Timer0
{
p=down=1;
dig_ctrl_4 = 0;
dig_ctrl_3 = 0;
dig_ctrl_2 = 0;
dig_ctrl_1 = 0;
TMOD=0x01;
TL0=0xf6;
TH0=0xFf;
IE=0x82;
TR0=1;
}
void delay()  //To provide a small time delay
{
TMOD=0x01;
    TL0=0x36;
    TH0=0xF6;
    TR0=1;
    while(TF0==0);
    TR0=0;
    TF0=0;
}

void display() interrupt 1  // Function to display the digits on seven segment. For more details refer seven segment multiplexing.
{
TL0=0x36;
    TH0=0xf6;
P2=0xFF;
dig_ctrl_1 = dig_ctrl_3 = dig_ctrl_2 = dig_ctrl_4 = 0;
dig_disp++;
dig_disp=dig_disp%4;
switch(dig_disp)
{
   case 0:
  P2= digi_val[dig_1];
  dig_ctrl_1 = 1;
  break;
  case 1:
  P2= digi_val[dig_2];
  dig_ctrl_2 = 1;
  break;
  case 2:
  P2= digi_val[dig_3];
  dig_ctrl_3 = 1;
  break;
  case 3:
  P2= digi_val[dig_4];
  dig_ctrl_4 = 1;
  break;
}
}
void main()
{
   init();
   while(1)
   {
  if(up==0&&down==1)  //check if up pin is pressed
     {
  test++;
     num=test;
     dig_4=num%10;
  num=num/10;
     dig_3=num%10;
  num=num/10;
     dig_2=num%10;
  dig_1=num/10;
  if(test==9999)
  test=0;
  }
    if(up==1&&down==0)  //check if down pin is pressed
    {
  test--;
     num=test;
     dig_4=num%10;
  num=num/10;
     dig_3=num%10;
  num=num/10;
     dig_2=num%10;
  dig_1=num/10;
  if(test==0)
  test=9999;
  }