Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
The Wireless Transceiver Subsystem was a very crucial decision for the final
design. The wireless aspects of any two-way car alarm security system have
to be carefully crafted to work reliably and integrate with the existing system
architecture. Unfortunately, the later part integration of the Wireless
Transceiver Subsystem with the rest of the system proved ill conceived.
While the TRM-433-LT transceivers boasted variability in power biasing and
long-range, high-power reliable RF communication link, the system could not
operate at 5 V power supply. The datasheet explains that the highest power
supply useable by the transceivers is 4 V, experimentation deemed that at 4 V
this system had questionable reliability. In the end, transmissions were
successful with these transceivers using test data. But their use with other
subsystems was unsuccessful. For more detailed analysis of the Wireless
Transceiver Subsystem, consult Section 5.8 of Design Project Details.
This DSSS Subsystem was crucial to the full-duplex secure operation of the
Novel Two-Way Car Alarm Security System. In general, by theoretical
understanding of pseudo-random sequence characteristics over a wireless
channel a truly multiple access system is capable on any transmission
medium. In this regard, using two distinctly different PN sequences to spread
data, two independent data streams can be supplied simultaneously. Although
only one direction of communication was built in the prototype, a direct
duplicate in all aspects aside from the feedback taps of the PN generators
could provide the second half of the communication system. For more
detailed information of the DSSS Subsystems, consult Section 5.4 of Design
Project Details.
136
10.2 Ryan Ginter
137
explored including frequency shift keying (FSK), amplitude shift keying (ASK), on-off shift
keying (OOK), and binary phase shift keying (BPSK). Initially it was desired to use FSK or
BPSK because of there resilience against noise, but because of hardware limitations OOK was
the only viable option. However within the DSSS Subsystem, BPSK was performed at a low
frequency to prove that is an option given the appropriate hardware to convert it to higher
frequencies.
Along with the DSSS and wireless communication necessary for the system to be secure
it was also determined that some form of error checking should be implemented to eliminate the
chance of false alarms. To do this research was done into several error correction methods before
the final decision was made to implement Hamming (7, 4) codes. The reason for this choice was
because of its ability to both detect and correct bit errors. The last piece of the project was the
baseband communications that was necessary to accurately convey the sensor data to the DSSS
system and interpret the data accurately at the user’s responder.
After the design methods for the overall system were defined, the system was categorized
into two major parts. The first being the DSSS communications system and the second being the
baseband communications system. In the final prototype these two systems were to be integrated
to provide a secure and accurate communication link between sensor status and alert. After
defining the two systems and dividing the work evenly between group members, individual
research was performed on hardware possibilities for each system. Following this research
hardware test were designed and performed to characterize each subsystem before attempting the
final integration.
Following the subsystem hardware tests the final integration between DSSS and
baseband communications was performed. This integration went very well leading to a final
prototype, two sensor system, whose alerts are conveyed by LEDs that correspond to the specific
sensor that was triggered. The final prototype was able to use DSSS to effectively spread and
despread the data, however it was never performed wirelessly. While an OOK wireless link was
established it was not able to be correctly integrated within the final system, because of
unforeseen characteristics of the OOK transceivers used. Despite this issue evidence was shown
that this form of car-to-user communication is very possible. Not only is it possible, but it can be
done at an inexpensive cost.
138
This project, while successful in creating a prototype, was very challenging process.
Throughout the process a great appreciation was developed for the complexities of the systems
that being implemented on standard ICs, such as the UART and DSSS transmission system.
Along with this appreciation came the rewarding sense of accomplishment in having the chance
to develop a project from concept to end prototype.
140
Subsystem designs were completely tested it was decided to integrate the overall baseband
system on a PCB.
The PCB decision came about in order to make the design more presentable, and to
simplify the integration process between the DSSS system and baseband system. This PCB
design process involved deciding upon the best IC layout that would minimize the space needed
by the board, along with minimizing the complexity of the connections on the board. After
several designs were attempted the final PCB design in Figs. 3.4.9 – 3.4.12 were decided upon.
Within these designs several connections were changed to simplify the number of connections on
the board. This was possible because only the two sensor system was being prototyped. The next
step in the PCB design process was to manufacture the boards. This involved first creating
transparencies of the PCB designs. Then the transparencies were placed over the copper clad
boards and exposed to a UV light. Next the board is place in a solution of positive developer to
remover the protective coating of the copper clad board except in the areas that were not exposed
to the UV light. Then the board was place in a Ferric Chloride which removed all of the copper
that was exposed the UV light. This left just the copper that outlined the pathways of the circuit.
The board was then assembled and tested. Despite the initial concerns, the board functioned just
as it did the protoboard level, with the added functionality of Hamming correction codes.
After all of the baseband processes were built and tested the system was integrated with
the DSSS subsystem. The only issue that came about during this process was the need for the
data to be inverted for the two systems to work properly. Once this adjustment was made
transmissions were tested and the system was characterized appropriately as described in Section
3.3. While this integration was being completed the wireless communication link was being
established. As mentioned earlier in Section 10.2.1 OOK was the choice made for the final
wireless link. To complete this system, transceivers were isolated from older systems, than
rewired to be tested. Once a link was established it was attempted to send the baseband data over
this link, but it was ultimately unsuccessful. Data was able to be sent and received, however it
was never done accurately. The reason for this was discovered to be a difference in framing
protocols between the baseband communications and wireless transceivers. The solution to this
issue would involve reworking either the baseband’s framing method or the transceiver choice.
At the point of this discovery it was too late for either of these options to be pursued. The
wireless test was not a complete failure it still proved that a wireless link could be established
141
with the overall system given the proper specifications for interpreting the data. For further detail
into the wireless issues and solutions refer to Section 5.8.
Overall while the final system had many subsystems operational and interrogated, the
final prototype was simply a proof of concept. This prototyped demonstrated the possibility for a
communication link to be established between a car and user via DSSS transmission method. It
also demonstrated that the baseband processes can be done inexpensively if the proper parts are
found. While in the end the Hamming codes were seemingly unnecessary, they were proven to
work. The Hamming codes become more important if the prototype eventually develops a
wireless component. Steps that would be necessary to carry this project forward would be to first
rework the wireless method, then to PCB the whole system in to a more compact and user
friendly product.
142
References
1. Chiang, Chin-Yi. Serial-to-Parallel Data Converter and Method of Conversion. Patent No:
6,768,431 B2. Jul. 27, 2004. http://www.freepatentsonline.com/6768431.pdf
2. C, J. MATLAB File Exchange. “BPSK and ASK Simulation”. 18 Apr. 2005. <
http://www.mathworks.com/matlabcentral/fileexchange/7458-bpsk-and-ask-
simulation>
6. Haykin, Simon. Communication Systems. “7.2 Pseudo-Noise Sequences”. 2001. 4th Edition.
7. Hornet Car Security – Technology. Hornet Car Security Glossary. 02/17/2010. <
http://www.hornetcarsecurity.com/Technology/Glossary.aspx
9. Kesteloot, André. The ARRL Spread Spectrum Sourcebook. “Experimenting With Direct-
Sequence Spread Spectrum”. Pages 8-31 – 8-35. Published 1991.
14. Viper Car Alarm – Technology. Viper Car Alarms. 02/17/2010. <
http://www.viper.com/Technology/>
15. Wakerly, John F. Digital Design: Principles and Practices. “Hamming.” Pages 63, 450-
451.
16. Wakerly, John F. Digital Design: Principles and Practices. “Counters.” Pages 711-713.
17. Wakerly, John F. Digital Design: Principles and Practices. “Shift Registers.” Pages 727-
730.
143
18. Ebay. Estimated prices of competing systems drawn from the following:
a. http://cgi.ebay.com/ebaymotors/DEI-564T-HORNET-2WAY-ALARM-
SYSTEM-564T-
_W0QQcmdZViewItemQQhashZitem3ee9f4fb01QQitemZ27021311872
1QQptZCarQ5fAudioQ5fVideo#ht_554wt_939
b. http://cgi.ebay.com/Viper-5002-Responder-2-Way-Security-System-Car-
Alarm-/140400966969?
cmd=ViewItem&pt=LH_DefaultDomain_0&hash=item20b08cbd39
c. http://cgi.ebay.com/VIPER-5902-2-Way-HD-Car-Alarm-Remote-Start-
Pager-/140400965158?
cmd=ViewItem&pt=LH_DefaultDomain_0&hash=item20b08cb626#ht_
12416wt_1165
144
APPENDICES
Oscilloscope
• Tektronix DPO 4032 Digital Phosphor Oscilloscope
o Used to observe waveforms in time domain.
Spectrum Analyzer
• Agilent E4411B ESA-L Series Spectrum Analyzer
o Used to observe frequency content of waveforms
o Frequency analysis capability of range 9 kHz - 1.5 GHz
Function Generators
• Tektronics FG 501A 2 MHz Function Generator
o Used to generate modulating signal (50 Hz to 15 kHz)
• Hewlett Packard 3314A Function Generator
o Used to generate carrier signal during modulation exercise and used to generate
AM modulated signal for synchronous demodulation exercise
Power supplies
• Tektronix PS503A Dual Power Supply
o Used to provide DC bias power to circuit components.
Multimeter
• Agilent 34401A 6½ Digit Multimeter
o Aided in circuit debugging via voltmeter mode.
o Aided in quality assurance of resistor values in ohmeter mode.
Protoboards
• EIC-104-1
o Provided layout for easy connection of components to form circuits used in
experiments.
BNC connectors
• Various sizes
o Used to for isolated signal transport between circuit and equipment modules.
o Manufacturers: Pomona Electronics, Pasternack Enterprises
145
Appendix 2: Simulations and Program Code
Hamming (7, 4).m
BPSK_ASKsims_elds.m – A few modifications were made to the code to make the output
graphs more usable for the report. Shows BPSK vs. ASK theoretical BER and also
simulation results via MATLAB computation. Varies each run of the code slightly as the
noise is randomly generated. [2]
%Run from editor Debug(F)
%This m file(ASK.m) analyzes a coherent amplitute shift keyed(ASK) and a
binary
%phase shift keyed(BPSK) communication system. The receiver uses a correlator
%(mixer-integrator [lpf]) configuration with BER measurements comparing
measured
%and theoretical results. The band pass and low pass filters used in the
%receiver are
%constructed using z transforms. M files on BPF and LPF design using z
%transforms can be found in the author index (CJ) mathworks file exchange. A
%fundemental
%question to ask is: "Why does BPSK show a 3dB improvement(as you will see
using %the
%program)in BER over ASK?". A simple answer is that the signal for ASK is
being
%transmitted only half the time. A reference is provided at the end of the
%program that
%was used in writing the program. Always remember a journey of a thousand
%miles requires a first one small step.
%========================================
% Set universal parameters
%=======================================
clear
fs=8e5;%sampling frequency
fm=20e3;%square wave modulating frequency(NRZ)= 40KHz bit rate
n=2*(6*fs/fm);
final=(1/fs)*(n-1);
fc=2e5; % carrier frequency
t=0:1/fs:(final);
Fn=fs/2;%nyquist frequency
%=========================================
%Generate square wave by using cosine wave
%==========================================
% cosine wave
% 2 pi fc t is written as below
twopi_fc_t=2*pi*fm*t;
A=1;
phi=0;
x = A * cos(twopi_fc_t + phi);
% square wave
am=1;
148
x(x>0)=am;
%x(x<0)=0;%use for ASK-comment out BPSK
x(x<0)=-1;%use for BPSK-remember ASK variables become BPSK
figure(1)
subplot(211);
plot(t,x);
axis([0e-4 100e-6 -2 2]);
title('Square Wave Modulating Input To Transmitter');
grid on
subplot(212);
plot(t,ask);
axis([0 100e-6 -2 2]);
title('Modulated Sinewave Carrier Waveform');
grid on;
%=====================================================
%Noise generator SNR=Eb/No=20log(Signalrms/Noiserms)
%======================================================
%vn=0;
vn=.1;%set noise level 0.1~=6db=SNR=Eb/No
noise=vn*(randn(size(t)));%noise generator
figure(2)
subplot(311);
plot(t,ask);
axis([0 100e-6 -2 2]);
title('Modulated Sinewave Carrier Waveform');
grid on;
subplot(312);
plot(t,noise);
grid on;
title('Noise Level');
axis([0 100e-6 -1 1]);
%======================================================================
%Receiver bandpass filter(two poles two zeros)
%======================================================================
fBW=40e3; %Bandwidth = 40 kHz
149
f=(0:3e3:40e3); %spectrum 0 to 40 kHz, 3 kHz intervals.
w=2*pi*f/fs;
z=exp(w*j); %#ok<*IJCL>
BW=2*pi*fBW/fs;
a=.8547;%BW=2(1-a)/sqrt(a)
p=(j^2*a^2);
gain=.135;
Hz=gain*(z+1).*(z-1)./(z.^2-(p));
figure(3)
subplot(411);
plot(f,abs(Hz));
title('Receiver Bandpass Filter Response');
grid on;
Hz(Hz==0)=10^(8);%avoid log(0)
subplot(412);
plot(f,20*log10(abs(Hz)));
grid on;
title('Receiver -3dB Filter Response');
axis([1e5 3e5 -3 1]);
%filter coefficients
a=[1 0 .7305];%[1 0 p]
b=[.135 0 -.135];%gain*[1 0 -1]
faskn=filter(b,a,askn);
figure(3)
subplot(413);
plot(t,faskn);
axis([0 100e-6 -2 2]);
title('Receiver BPF Output');
grid on;
%%
%===================================================================
%Low pass filter(one pole one zero)
%==================================================================
p=.72;
gain1=.14;%gain=(1-p)/2
Hz1=gain1*(z+1)./(z-(p));
%0.65=53KHz
%0.7=45KHz
%0.72=40KHZ=best for lowest BER-Theory says set equal to the bit rate
%0.75=37KHz
150
%0.8=28KHz
%subplot(323);
%plot(f,abs(Hz1));
%title('Receiver LPF Response');
%grid on;
subplot(323);
Hz1(Hz1==0)=10^(-8);%avoid log(0)
plot(f,20*log10(abs(Hz1)));
grid on;
title('LPF -3dB response');
axis([0 5e4 -3 1]);
%filter coefficients
a1=[1 -.72];%(z-(p))
b1=[.14 .14];%gain*[1 1]
so=filter(b1,a1,cm);
so=so*10;%add gain
so=so-mean(so);%removes DC component
subplot(324);
plot(t,so);
axis([1e-4 3e-4 -2.5 2.5]);
title('Receiver Output Signal-LPF');
grid on;
%%
%======================================================
%Comparator
%======================================================
High=2.5;
Low=-2.5;
vt=0;%sets comparator threshold
error=0;
%calculate the number of elements in matrix so, the output of the filter
len1=length(so); %number of elements in so
for ii=1:len1
if so(ii) >= vt
Vs(ii)=High;
else
Vs(ii)=Low;
end
end
Vo=Vs+2.5;
subplot(325);
plot (t,Vo), title('Receiver Regenerated signal'),
axis([1e-4 3e-4 -8 8])
grid on;
xlabel('Time (s)'), ylabel('Magnitude(V)'),
%%
151
%========================================================
%Generate delayed squarewave
%=========================================================
%cosine wave delayed to match receiver regenerated signal square waves.
%filters have delay
% 2 pi fc t is written as below
twopi_fc_t1=2*pi*fm*(t-.59e-4);%adds delay
%A=1;
phi1=0;
x1 = A * cos(twopi_fc_t1 + phi1);
% square wave
x1(x1>0)=am;
x1(x1<0)=0;
sr=x1;
sf=5*sr;
subplot(326);
plot (t,sf), title('Input signal-delayed'),
axis([1e-4 3e-4 -8 8]);
grid on;
xlabel('Time (s)'), ylabel('Magnitude(V)'),
figure(4);
err=[0 0 0 0 0 0 error/460 0 0];%Measured at different values of SNR by
setting vn
snr=10.^ ( [0:0.1:12]./10);
Pb= 0.5*erfc(.707*sqrt(snr)); % BER (Theoretical-ASK)
Pb1= 0.5*erfc(sqrt(snr)); % BER (Theoretical-BPSK)
semilogy([0:8],err,'*',[0:0.1:12],Pb,'-',[0:0.1:12],Pb1,'--'); % plot
grid on; xlabel('SNR=Eb/No(dB)'); ylabel('BER');
title('Simulation of BER for ASK and BPSK');
legend('BER','ASK Theoretical','BPSK Theoretical');
BER=error/460%display BER
%Could have set up a for loop using vn to calculate all points(err) but would
%complicate matters.Easier to run by hand and observe BER plot. Presently
%set for SNR=6dB.
152
%%
%===================================================
%Frequency domain plots
%====================================================
%Lets take a look at askn(unfiltered carrier + noise) and
%faskn(band pass filtered carrier + noise) output on a spectrum analyzer.
%This fft code is somewhat complex but comes from the mathworks. Works
%great as it shows one what they would actually see using a spectrum analyzer.
figure(5)
% subplot(2,2,1); plot(f1,MY);xlabel('FREQUENCY');ylabel('AMPLITUDE');
% axis([0 3e5 -.5 1]);%zoom in/out
% title('Modulated Tx carrier plus noise');
% grid on;
plot(f1,20*log10(abs(MY).^2));xlabel('FREQUENCY');ylabel('DB');
axis([0 3e5 -60 5]);
grid on;
title('Power Spectral Density of BPSK data')
%Reference
%http://soe.unn.ac.uk/ocr/people/ghassemlooy/
%Prof. Z Ghassemlooy's website
%Good site for theory and m files. I structured this m file from his work
%and have added a few things. I constructed filters using z transforms
%since I don't have the filter toolbox functions.
153
Appendix 3: Datasheets
TRM-433-LT - Transceiver RF 433 MHz LT Series
http://www.linxtechnologies.com/Documents/TRM-xxx-LT_Data_Guide.pdf
74HC04 - Inverters
http://www.fairchildsemi.com/ds/MM/MM74HC04.pdf
74HC00 - NAND
http://www.fairchildsemi.com/ds/MM/MM74HC00.pdf
74HC08 - AND
http://www.fairchildsemi.com/ds/MM/MM74HC08.pdf
74HC86 - XOR
http://www.fairchildsemi.com/ds/MM/MM74HC86.pdf
HCF4077BEY - XNOR
http://www.st.com/stonline/products/literature/ds/8229/hcf4077.pdf
MC14043BCPG – SR Latch
http://www.onsemi.com/pub_link/Collateral/MC14043B-D.PDF
74HC74 – D Flip-Flop
http://focus.ti.com/lit/ds/symlink/sn74hc74.pdf
154