| UNAVCO
 


Knowledge Base

How to download a Topcon GB-1000 receiver using lftp

How to download a Topcon GB-1000 receiver using lftp

Use the following script utilizing lftp to download data off the internal memory of a Topcon GB-1000 receiver. This script uses lftp’s ability to mirror two directories.

# Script to mirror the internal memory
# of a Topcon GB-1000 to a local directory.
# File download is quite fast: takes about 82seconds
# for a daily 1second file.
#
# Setup:
# Set your ethernet port on your computer to have IP: 192.168.1.3
# and Subnet-Mask: 255.255.255.0. Then connect an ethernet
# cable from your computer to the GB-1000.
#
# Use:
# user@linux> ./ftp_download <dir-to-downlaod-to>
#
# Example:
# user@linux> ./ftp_downlaod site1
# ( will download data to ./site1/ )
#
# If the local directory does not exist lftp will
# create.
#
# Behavior of script if you run it more than once
# against the same local direcotry:
#
# 1) matching files are skipped and nothing is done.
# 2) if a new file is on the GB-1000 that is not on the
#    local directory it is copied over.
# 3) if there is a difference between a file on the GB-1000
#    and on the local direcotry (possibly because you have
#    previously downloaded a partial file and now the file is
#    bigger) the script will delete the smaller local file and
#    replace it with the new larger file.
#
# Note: If you kill the script while it is running with ctrl-c
#    make sure to run:
#   
#    user@linux> rm -f lftp_download_cmds.x
#   
#    to clear the file containing lftp commands generated by the
#    script. The file is deleted after a successful execuation
#    of the script.



#! /bin/bash

# Constants needed.
HOST=’192.168.1.2’                                 # IP of GB-1000
SITE=$1                                                 # dwnld dir specifed at run time
USER=’’                                                  # user name
PASSWD=’TOPCON’                                 # GB-1000 password
CMD_FILE="./lftp_download_cmds.x"          # file contaning lftp commands

# Can’t run if you don’t specify a directory to download to.
if [ "$SITE" = "" ]; then
    echo "You must specify a download directory. "
    exit 1

else
    # Commands to be fed into lftp.   
    echo "open -u $USER,$PASSWD $HOST"        >> $CMD_FILE;
    echo "mirror -e --verbose=3 / test/"               >> $CMD_FILE;
   
    # Run lftp with the command file created above.
    lftp -f $CMD_FILE
   
    # Clean up, delete lftp_download_cmds.x file.
    rm -f $CMD_FILE
fi

Attached Files
There are no attachments for this article.
Comments (2)
Comment by Frederick Blume on Tue, Nov 13th, 2012 at 5:55 PM
Xavi, Unfortunately Topcon has not yet provided a solution to automatically copy the files to the external memory. I have asked them for help with this and will post the results if we get them.
Comment by Javier Ramirez on Tue, Nov 13th, 2012 at 12:31 PM
Hi Guys. I have a topcon GB1000 receiver and my problem is that my receiver have 128mb of memory and i need a script or a solution for copy of the internal memory to a external memory automatic for obtain more observations. Thank for your help. cheers xavi
Name
Email
Security Code Security Code
Related Articles RSS Feed
How to enable 20 Hz (and other high-rate) logging in Topcon GB-1000 Receivers
Viewed 20405 times since Mon, Aug 24, 2009
Topcon GB-1000 - How to download data
Viewed 3404 times since Fri, Jan 9, 2009
Topcon GB1000 - Como bajar datos
Viewed 1064 times since Mon, Mar 22, 2010
Topcon GB-1000 - How to configure for static surveying
Viewed 3196 times since Fri, Jan 9, 2009
Topcon GB-1000 - How to configure for rapid static observations
Viewed 2516 times since Fri, Jan 9, 2009
Topcon GB-1000 - How to configure for kinematic surveys
Viewed 2533 times since Fri, Jan 9, 2009
MENU

Last modified: Monday, 12-May-2014 00:18:29 UTC