Version 2 (modified by 6 years ago) ( diff ) | ,
---|
Antenna Setup/Installation/Deployment Validation
Attach E312 to the large sector antennas to test cabling; cover GPS and each of the panel antennas.
E312 + cabling + USB flash drive + directional antenna for SA + portable SA
Run two utilities:
- gpspipe
- tx_waveform
Start stop cadv script
#!/bin/sh ### BEGIN INIT INFO # Provides: cadv # Required-Start: $remote_fs $network gpsd # Required-Stop: $remote_fs $network # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: COSMOS Antenna Deployment Validation start/stop script # Description: Start/Stop script for the COSMOS service daemon, # which start logging the GPS coordinates and starts # the transmitter on channel 1 so it can verify the antenna # cabling functionality ### END INIT INFO # Author: WINLAB COSMOS Team # PATH should only include /usr/* if it runs after the mountnfs.sh script # PATH=/sbin:/usr/sbin:/bin:/usr/bin DESC="COSMOS Antenna Deplotment Validation" NAME=cadv SCRIPTNAME=/etc/init.d/$NAME LOGDIR=/mnt LOGFILE="$LOGDIR/$NAME-$(date -u +"%FT%H%MZ").log" TXFREQ="2440.0e6" TXRATE="4e6" TXWAVE="RAMP" TXWAVEFREQ="1e6" TXGAIN="100" PROG1=/usr/bin/gpspipe PROG2=/usr/lib/uhd/examples/tx_waveforms PROG1BASE=`basename $PROG1` PROG2BASE=`basename $PROG2` # Read configuration, if present [ -r /etc/init.d/functions ] && . /etc/init.d/functions [ -r /etc/default/$NAME ] && . /etc/default/$NAME # # Check for external storage # # # Function that starts the services # do_start() { echo -n "Mount storage drive..." mount /dev/sda1 /mnt echo " OK" echo -n "Starting $PROG1: " $PROG1 -d -r -t -o "$LOGFILE" RETVAL=$? if [ "$RETVAL" = 0 ] ; then echo "OK" touch /var/lock/subsys/$PROG1BASE else echo "FAIL" fi echo -n "Starting $PROG2: " $PROG2 --freq "$TXFREQ" --rate "$TXRATE" --gain "$TXGAIN" --wave-type "$TXWAVE" --wave-freq "$TXWAVEFREQ" >> "$LOGFILE" 2>&1 & RETVAL=$? if [ "$RETVAL" = 0 ] ; then echo "OK" touch /var/lock/subsys/$PROG2BASE else echo "FAIL" fi } # # Function that stops the services # do_stop() { echo -n "Stopping $PROG1: " killproc $PROG1 >& /dev/null rm -f /var/lock/subsys/$PROG1 if [ -n "`/bin/pidof $PROG1`" ] ; then echo "FAIL" else echo "OK" fi echo -n "Stopping $PROG2: " killproc $PROG2 >& /dev/null rm -f /var/lock/subsys/$PROG2 if [ -n "`/bin/pidof $PROG2`" ] ; then echo "FAIL" else echo "OK" fi umount /mnt } case "$1" in start) echo "Starting $DESC" "$NAME" do_start exit $? ;; stop) echo "Stopping $DESC" "$NAME" do_stop exit $? ;; restart) # # If the "reload" option is implemented then remove the # 'force-reload' alias # echo "Restarting $DESC" "$NAME" do_stop case "$?" in 0|1) do_start exit $? ;; *) # Failed to stop exit 1 ;; esac ;; *) echo "Usage: $SCRIPTNAME {start|stop|restart}" >&2 exit 3 ;; esac :
Install as startup script with:
update-rc.d cadv defaults 99
To use the E312 for antenna testing press and hold the power button for a second and release. Give it about a minute for start up. In this time frame the leds above the antenna ports should light up briefly but only the led above the transmit antenna will remain on once the applications are launched.
Output from transmit antenna on E312 is working fine:
The tx_waveforms application generated the above signal. The application is with run options for a 1KHz RAMP signal centered at 2440 MHz and a 100 dB gain.
GPS output will be logged into file stored on flash drive. Log file name will have timestamp of when the device was turned on and the path to this log file will be /mnt/cadv-{timestamp}.log. This log file should be populated with raw NMEA sentences containing the GPS coordinates with a corresponding timestamp.
Transition from all 0 to GPS coordinates in the log file will happen once GPS is synchronized with satellites.
Attachments (1)
-
sa-output.png
(1.6 MB
) - added by 6 years ago.
Spectrum Analyzer Screen
Download all attachments as: .zip