Results 1 to 2 of 2

Thread: Hamlet solar BT GPS HOWTO (Ubuntu 12.04 LTS)

  1. #1
    Join Date
    Nov 2007
    Beans
    5

    Hamlet solar BT GPS HOWTO (Ubuntu 12.04 LTS)

    This is a short howto that covers the installation of the Hamlet(TM) bluetooth gps device equipped with solar cells on Ubuntu 12.04 LTS. It is an extremely inexpensive device useful to non-professional users, easely found on webstores for about 20 Euros. Surprisingly, I did not find a similar guide in the web. So here is the guide.

    To complete the configuration, you need to know how to couple a Bluetooth device, how to install packages, how to use the terminal, and how to edit a text file; your computer must have a built-in bluetooth device, or you can attach a bluetooth dongle to a USB port of your PC. Read the GPS device manual to understand the meaning of led signals and the usage of the button.

    The first step consists in associating the GPS device with your computer.

    Coupling the device

    Coupling (aka associating) is done the usual way: start by pushing the button on the GPS device until the blue led starts flashing rapidly, next select the bluetooth symbol in the upper band on the PC screen, and add a new device. Select the pin 0000 in the "Pin options" menu in the device discovery window.

    Setting up communication

    The next step consists of discovering how to access the GPS device. First find the bluetooth address:

    Code:
    # gksudo hcitool scan
    Scanning ...
        00:11:22:33:44:55    HBTSOL
    Annotate the number you read instead of 00:11:22:33:44:55, that corresponds to the GPS device address, and replace it in the following command:

    Code:
    # sudo sdptool record 00:11:22:33:44:55
    Service Name: SPP slave
    Service RecHandle: 0x10000
    Service Class ID List:
      "Serial Port" (0x1101)
    Protocol Descriptor List:
      "L2CAP" (0x0100)
      "RFCOMM" (0x0003)
        Channel: 1
    You need to interrupt the command with a ctrl-C. The important info here is the channel number, which should be 1.

    Now edit the file /etc/bluetooth/rfcomm.conf adding the following lines:

    Code:
    rfcomm0 {
        bind yes;
        device 00:11:22:33:44:55;
        channel    1;
        comment "Hamlet GPS receiver";
    }
    In case you have another rfcomm0 defined, use rfcomm1.


    Install GPS software

    Now you need to install some software: in a terminal type:

    Code:
    #sudo apt-get install gpsd gpsd-clients marble
    and properly configure gpsd

    Code:
    #sudo dpkg-reconfigure gpsd
    Reply to the dialog as follows:

    1. Start gps automatically at boot
    2. Automatically connection to the device
    3. set /dev/rfcomm0 (or the rfcomm in the rfcomm.conf) as theGPS device
    4. no options
    5. leave the socket to its default value



    Test


    Type and check:
    Code:
    # sudo rfcomm -a
    rfcomm0: 00:11:22:33:44:55 channel 1 ...
    This means that the connection with the GPS device is operational. Now place the GPS receiver close to a window and wait for the red led to blink slowly. Type:
    Code:
    # cgps
    The output after the command is a full screen showing longitude, latitude etc. Success!!!

    When your PC is correctly configured, to use your GPS device you simply need to switch it on and place it in a suitable position. Start a GPS application on your pc (like marble) and configure it for reading the current position from gpsd.
    Last edited by geppetto; August 27th, 2013 at 09:43 AM.

  2. #2
    Join Date
    Feb 2008
    Location
    Planet earth, for now.
    Beans
    Hidden!
    Distro
    Xubuntu

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •