Index: applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/ByteHelper.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/ByteHelper.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/ByteHelper.java	(revision 12778)
@@ -12,102 +12,102 @@
 {
 
-	/**
-	 * 
-	 * @param src
-	 * @param startS
-	 * @param len
-	 * @param dest
-	 * @param startD
-	 * @return
-	 */
-	public static int copyByteArr2ByteArr(byte src[], int startS, int len, byte dest[], int startD)
-	{
-		for (int ii = 0 ;
-			ii < len && startD < dest.length && startS < src.length && startD >= 0 && startS >= 0;
-			++ii, ++startD, ++startS)
-		{
-			dest[startD] = src[startS];
-		}
-		return startD;
-	}
+    /**
+     *
+     * @param src
+     * @param startS
+     * @param len
+     * @param dest
+     * @param startD
+     * @return
+     */
+    public static int copyByteArr2ByteArr(byte src[], int startS, int len, byte dest[], int startD)
+    {
+        for (int ii = 0 ;
+            ii < len && startD < dest.length && startS < src.length && startD >= 0 && startS >= 0;
+            ++ii, ++startD, ++startS)
+        {
+            dest[startD] = src[startS];
+        }
+        return startD;
+    }
 
-	/**
-	 * 
-	 * @param byt
-	 * @return
-	 */
-	public static int byte2IntUnsigned(byte byt)
-	{
-		return ((byt >= 0) ? byt : 256 + byt);
-	}
+    /**
+     *
+     * @param byt
+     * @return
+     */
+    public static int byte2IntUnsigned(byte byt)
+    {
+        return ((byt >= 0) ? byt : 256 + byt);
+    }
 
-	/**
-	 * 
-	 * @param nibble
-	 */
-	private static char nibble2Char(int nibble)
-	{
-		char chr = '*';
-		nibble = nibble & 0xF;
-		switch (nibble)
-		{
-		case 0: chr = '0'; break;
-		case 1: chr = '1'; break;
-		case 2: chr = '2'; break;
-		case 3: chr = '3'; break;
-		case 4: chr = '4'; break;
-		case 5: chr = '5'; break;
-		case 6: chr = '6'; break;
-		case 7: chr = '7'; break;
-		case 8: chr = '8'; break;
-		case 9: chr = '9'; break;
-		case 10: chr = 'A'; break;
-		case 11: chr = 'B'; break;
-		case 12: chr = 'C'; break;
-		case 13: chr = 'D'; break;
-		case 14: chr = 'E'; break;
-		case 15: chr = 'F'; break;
-		}
-		return chr; 
-	}
+    /**
+     *
+     * @param nibble
+     */
+    private static char nibble2Char(int nibble)
+    {
+        char chr = '*';
+        nibble = nibble & 0xF;
+        switch (nibble)
+        {
+        case 0: chr = '0'; break;
+        case 1: chr = '1'; break;
+        case 2: chr = '2'; break;
+        case 3: chr = '3'; break;
+        case 4: chr = '4'; break;
+        case 5: chr = '5'; break;
+        case 6: chr = '6'; break;
+        case 7: chr = '7'; break;
+        case 8: chr = '8'; break;
+        case 9: chr = '9'; break;
+        case 10: chr = 'A'; break;
+        case 11: chr = 'B'; break;
+        case 12: chr = 'C'; break;
+        case 13: chr = 'D'; break;
+        case 14: chr = 'E'; break;
+        case 15: chr = 'F'; break;
+        }
+        return chr;
+    }
 
-	/**
-	 * 
-	 * @return
-	 */
-	public static String byte2StringUnsigned(byte byt)
-	{
-		StringBuffer buf = new StringBuffer(4);
-		int bb = byte2IntUnsigned(byt);
-		//buf.append("0x");
-		buf.append(nibble2Char(bb / 16));
-		buf.append(nibble2Char(bb % 16));
-		return buf.toString();
-	}
+    /**
+     *
+     * @return
+     */
+    public static String byte2StringUnsigned(byte byt)
+    {
+        StringBuffer buf = new StringBuffer(4);
+        int bb = byte2IntUnsigned(byt);
+        //buf.append("0x");
+        buf.append(nibble2Char(bb / 16));
+        buf.append(nibble2Char(bb % 16));
+        return buf.toString();
+    }
 
-	/**
-	 * 
-	 * @param byt
-	 */
-	public static String byteArray2String(byte byt[])
-	{
-		return byteArray2String(byt, byt.length);
-	}
+    /**
+     *
+     * @param byt
+     */
+    public static String byteArray2String(byte byt[])
+    {
+        return byteArray2String(byt, byt.length);
+    }
 
-	/**
-	 * 
-	 * @param byt
-	 * @param cnt
-	 */
-	public static String byteArray2String(byte byt[], int cnt)
-	{
-		StringBuffer buf = new StringBuffer(cnt * 5);
-		for (int ii = 0 ; ii < cnt && ii < byt.length ; ++ii)
-		{
-			if (ii > 0) {buf.append(" ");}
-			buf.append(byte2StringUnsigned(byt[ii]));
-		}
-		return buf.toString();
-	}
+    /**
+     *
+     * @param byt
+     * @param cnt
+     */
+    public static String byteArray2String(byte byt[], int cnt)
+    {
+        StringBuffer buf = new StringBuffer(cnt * 5);
+        for (int ii = 0 ; ii < cnt && ii < byt.length ; ++ii)
+        {
+            if (ii > 0) {buf.append(" ");}
+            buf.append(byte2StringUnsigned(byt[ii]));
+        }
+        return buf.toString();
+    }
 
 }
Index: applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/Dg100Config.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/Dg100Config.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/Dg100Config.java	(revision 12778)
@@ -30,485 +30,485 @@
 //  nn nn nn nn: distance in m
 //  xx xx: checksum
-//	A0 A2 00 35 B7 jj kk ll ll ll ll mm nn nn nn nn
+//  A0 A2 00 35 B7 jj kk ll ll ll ll mm nn nn nn nn
 //  aa aa aa aa bb bb bb bb cc cc cc cc 00 00 gg hh
 //  ii dd dd dd dd ee ee ee ee ff ff ff ff 01 61 01
 //  01 0C D5 0D 00 04 CC B0 B3
 
-	private byte logFormat = -1;
-	private byte disableLogSpeed = -1;
-	private int speedThres = -1;
-	private byte disableLogDist = -1;
-	private int distThres = -1;
-	private int swATime = -1;
-	private int swBTime = -1;
-	private int swCTime = -1;
-	private short unk1 = -1;
-	private byte swATimeOrDist = -1;
-	private byte swBTimeOrDist = -1;
-	private byte swCTimeOrDist = -1;
-	private int swADist = -1;
-	private int swBDist = -1;
-	private int swCDist = -1;
-	private byte unk2 = -1;
-	private int remainder = -1;
-	private int unk3 = -1;
-	private int unk4 = -1;
-
-	private static String propLogFormat = "logFormat";
-	private static String propDisableLogSpeed = "disableLogSpeed";
-	private static String propSpeedThres = "speedThres";
-	private static String propDisableLogDist = "disableLogDist";
-	private static String propDistThres = "distThres";
-	private static String propSwATime = "swATime";
-	private static String propSwBTime = "swBTime";
-	private static String propSwCTime = "swCTime";
-	private static String propUnk1 = "unk1";
-	private static String propSwATimeOrDist = "swATimeOrDist";
-	private static String propSwBTimeOrDist = "swBTimeOrDist";
-	private static String propSwCTimeOrDist = "swCTimeOrDist";
-	private static String propSwADist = "swADist";
-	private static String propSwBDist = "swBDist";
-	private static String propSwCDist = "swCDist";
-	private static String propUnk2 = "unk2";
-	private static String propRemainder = "remainder";
-	private static String propUnk3 = "unk3";
-	private static String propUnk4 = "unk4";
-
-	public Dg100Config(ByteBuffer buf)
-	{
-		logFormat = buf.get();
-		disableLogSpeed = buf.get();
-		speedThres = buf.getInt();
-		disableLogDist = buf.get();
-		distThres = buf.getInt();
-		swATime = buf.getInt();
-		swBTime = buf.getInt();
-		swCTime = buf.getInt();
-		unk1 = buf.getShort();
-		swATimeOrDist = buf.get();
-		swBTimeOrDist = buf.get();
-		swCTimeOrDist = buf.get();
-		swADist = buf.getInt();
-		swBDist = buf.getInt();
-		swCDist = buf.getInt();
-		unk2 = buf.get();
-		remainder = buf.get();
-		unk3 = buf.get();
-		unk4 = buf.get();
-	}
-
-	public Dg100Config(String fName)
-		throws Exception
-	{
-		readProps(fName);
-	}
-
-	public String toString()
-	{
-		return 
-			"[Dg100Config: logFormat = " + logFormat
-			+ ",disableLogSpeed = " + disableLogSpeed
-			+ ",speedThres = " + speedThres
-			+ ",disableLogDist = " + disableLogDist
-			+ ",distThres = " + distThres
-			+ ",swATime = " + swATime
-			+ ",swBTime = " + swBTime
-			+ ",swCTime = " + swCTime
-			+ ",unk1 = " + unk1
-			+ ",swATimeOrDist = " + swATimeOrDist
-			+ ",swBTimeOrDist = " + swBTimeOrDist
-			+ ",swCTimeOrDist = " + swCTimeOrDist
-			+ ",swADist = " + swADist
-			+ ",swBDist = " + swBDist
-			+ ",swCDist = " + swCDist
-			+ ",unk2 = " + unk2
-			+ ",remainder = " + remainder
-			+ ",unk3 = " + unk3
-			+ ",unk4 = " + unk4
-			;
-	}
-
-	/**
-	 * @param buf
-	 */
-	public void write(ByteBuffer buf)
-	{
-		buf.position(5);
-		buf.put(logFormat);
-		buf.put(disableLogSpeed);
-		buf.putInt(speedThres);
-		buf.put(disableLogDist);
-		buf.putInt(distThres);
-		buf.putInt(swATime);
-		buf.putInt(swBTime);
-		buf.putInt(swCTime);
-		buf.putShort(unk1);
-		buf.put(swATimeOrDist);
-		buf.put(swBTimeOrDist);
-		buf.put(swCTimeOrDist);
-		buf.putInt(swADist);
-		buf.putInt(swBDist);
-		buf.putInt(swCDist);
-		buf.put(unk2);
-	}
-
-	/**
-	 * @return Returns the disableLogDist.
-	 */
-	public boolean getDisableLogDist()
-	{
-		return disableLogDist != 0;
-	}
-
-	/**
-	 * @param disableLogDist The disableLogDist to set.
-	 */
-	public void setDisableLogDist(boolean disableLogDist)
-	{
+    private byte logFormat = -1;
+    private byte disableLogSpeed = -1;
+    private int speedThres = -1;
+    private byte disableLogDist = -1;
+    private int distThres = -1;
+    private int swATime = -1;
+    private int swBTime = -1;
+    private int swCTime = -1;
+    private short unk1 = -1;
+    private byte swATimeOrDist = -1;
+    private byte swBTimeOrDist = -1;
+    private byte swCTimeOrDist = -1;
+    private int swADist = -1;
+    private int swBDist = -1;
+    private int swCDist = -1;
+    private byte unk2 = -1;
+    private int remainder = -1;
+    private int unk3 = -1;
+    private int unk4 = -1;
+
+    private static String propLogFormat = "logFormat";
+    private static String propDisableLogSpeed = "disableLogSpeed";
+    private static String propSpeedThres = "speedThres";
+    private static String propDisableLogDist = "disableLogDist";
+    private static String propDistThres = "distThres";
+    private static String propSwATime = "swATime";
+    private static String propSwBTime = "swBTime";
+    private static String propSwCTime = "swCTime";
+    private static String propUnk1 = "unk1";
+    private static String propSwATimeOrDist = "swATimeOrDist";
+    private static String propSwBTimeOrDist = "swBTimeOrDist";
+    private static String propSwCTimeOrDist = "swCTimeOrDist";
+    private static String propSwADist = "swADist";
+    private static String propSwBDist = "swBDist";
+    private static String propSwCDist = "swCDist";
+    private static String propUnk2 = "unk2";
+    private static String propRemainder = "remainder";
+    private static String propUnk3 = "unk3";
+    private static String propUnk4 = "unk4";
+
+    public Dg100Config(ByteBuffer buf)
+    {
+        logFormat = buf.get();
+        disableLogSpeed = buf.get();
+        speedThres = buf.getInt();
+        disableLogDist = buf.get();
+        distThres = buf.getInt();
+        swATime = buf.getInt();
+        swBTime = buf.getInt();
+        swCTime = buf.getInt();
+        unk1 = buf.getShort();
+        swATimeOrDist = buf.get();
+        swBTimeOrDist = buf.get();
+        swCTimeOrDist = buf.get();
+        swADist = buf.getInt();
+        swBDist = buf.getInt();
+        swCDist = buf.getInt();
+        unk2 = buf.get();
+        remainder = buf.get();
+        unk3 = buf.get();
+        unk4 = buf.get();
+    }
+
+    public Dg100Config(String fName)
+        throws Exception
+    {
+        readProps(fName);
+    }
+
+    public String toString()
+    {
+        return
+            "[Dg100Config: logFormat = " + logFormat
+            + ",disableLogSpeed = " + disableLogSpeed
+            + ",speedThres = " + speedThres
+            + ",disableLogDist = " + disableLogDist
+            + ",distThres = " + distThres
+            + ",swATime = " + swATime
+            + ",swBTime = " + swBTime
+            + ",swCTime = " + swCTime
+            + ",unk1 = " + unk1
+            + ",swATimeOrDist = " + swATimeOrDist
+            + ",swBTimeOrDist = " + swBTimeOrDist
+            + ",swCTimeOrDist = " + swCTimeOrDist
+            + ",swADist = " + swADist
+            + ",swBDist = " + swBDist
+            + ",swCDist = " + swCDist
+            + ",unk2 = " + unk2
+            + ",remainder = " + remainder
+            + ",unk3 = " + unk3
+            + ",unk4 = " + unk4
+            ;
+    }
+
+    /**
+     * @param buf
+     */
+    public void write(ByteBuffer buf)
+    {
+        buf.position(5);
+        buf.put(logFormat);
+        buf.put(disableLogSpeed);
+        buf.putInt(speedThres);
+        buf.put(disableLogDist);
+        buf.putInt(distThres);
+        buf.putInt(swATime);
+        buf.putInt(swBTime);
+        buf.putInt(swCTime);
+        buf.putShort(unk1);
+        buf.put(swATimeOrDist);
+        buf.put(swBTimeOrDist);
+        buf.put(swCTimeOrDist);
+        buf.putInt(swADist);
+        buf.putInt(swBDist);
+        buf.putInt(swCDist);
+        buf.put(unk2);
+    }
+
+    /**
+     * @return Returns the disableLogDist.
+     */
+    public boolean getDisableLogDist()
+    {
+        return disableLogDist != 0;
+    }
+
+    /**
+     * @param disableLogDist The disableLogDist to set.
+     */
+    public void setDisableLogDist(boolean disableLogDist)
+    {
             this.disableLogDist = (byte)(disableLogDist ? 1 : 0);
-	}
-
-	/**
-	 * @return Returns the disableLogSpeed.
-	 */
-	public boolean getDisableLogSpeed()
-	{
-		return disableLogSpeed != 0;
-	}
-
-	/**
-	 * @param disableLogSpeed The disableLogSpeed to set.
-	 */
-	public void setDisableLogSpeed(boolean disableLogSpeed)
-	{
+    }
+
+    /**
+     * @return Returns the disableLogSpeed.
+     */
+    public boolean getDisableLogSpeed()
+    {
+        return disableLogSpeed != 0;
+    }
+
+    /**
+     * @param disableLogSpeed The disableLogSpeed to set.
+     */
+    public void setDisableLogSpeed(boolean disableLogSpeed)
+    {
             this.disableLogSpeed = (byte)(disableLogSpeed ? 1 : 0);
-	}
-
-	/**
-	 * @return Returns the distThres.
-	 */
-	public int getDistThres()
-	{
-		return distThres;
-	}
-
-	/**
-	 * @param distThres The distThres to set.
-	 */
-	public void setDistThres(int distThres)
-	{
-		this.distThres = distThres;
-	}
-
-	/**
-	 * @return Returns the logFormat.
-	 */
-	public byte getLogFormat()
-	{
-		return logFormat;
-	}
-
-	/**
-	 * @param logFormat The logFormat to set.
-	 */
-	public void setLogFormat(byte logFormat)
-	{
-		this.logFormat = logFormat;
-	}
-
-	/**
-	 * @return Returns the speedThres.
-	 */
-	public int getSpeedThres()
-	{
-		return speedThres;
-	}
-
-	/**
-	 * @param speedThres The speedThres to set.
-	 */
-	public void setSpeedThres(int speedThres)
-	{
-		this.speedThres = speedThres;
-	}
-
-	/**
-	 * @return Returns the swADist.
-	 */
-	public int getSwADist()
-	{
-		return swADist;
-	}
-
-	/**
-	 * @param swADist The swADist to set.
-	 */
-	public void setSwADist(int swADist)
-	{
-		this.swADist = swADist;
-	}
-
-	/**
-	 * @return Returns the swATime.
-	 */
-	public int getSwATime()
-	{
-		return swATime;
-	}
-
-	/**
-	 * @param swATime The swATime to set.
-	 */
-	public void setSwATime(int swATime)
-	{
-		this.swATime = swATime;
-	}
-
-	/**
-	 * @return Returns the swATimeOrDist.
-	 */
-	public byte getSwATimeOrDist()
-	{
-		return swATimeOrDist;
-	}
-
-	/**
-	 * @param swATimeOrDist The swATimeOrDist to set.
-	 */
-	public void setSwATimeOrDist(byte swATimeOrDist)
-	{
-		this.swATimeOrDist = swATimeOrDist;
-	}
-
-	/**
-	 * @return Returns the swBDist.
-	 */
-	public int getSwBDist()
-	{
-		return swBDist;
-	}
-
-	/**
-	 * @param swBDist The swBDist to set.
-	 */
-	public void setSwBDist(int swBDist)
-	{
-		this.swBDist = swBDist;
-	}
-
-	/**
-	 * @return Returns the swBTime.
-	 */
-	public int getSwBTime()
-	{
-		return swBTime;
-	}
-
-	/**
-	 * @param swBTime The swBTime to set.
-	 */
-	public void setSwBTime(int swBTime)
-	{
-		this.swBTime = swBTime;
-	}
-
-	/**
-	 * @return Returns the swBTimeOrDist.
-	 */
-	public byte getSwBTimeOrDist()
-	{
-		return swBTimeOrDist;
-	}
-
-	/**
-	 * @param swBTimeOrDist The swBTimeOrDist to set.
-	 */
-	public void setSwBTimeOrDist(byte swBTimeOrDist)
-	{
-		this.swBTimeOrDist = swBTimeOrDist;
-	}
-
-	/**
-	 * @return Returns the swCDist.
-	 */
-	public int getSwCDist()
-	{
-		return swCDist;
-	}
-
-	/**
-	 * @param swCDist The swCDist to set.
-	 */
-	public void setSwCDist(int swCDist)
-	{
-		this.swCDist = swCDist;
-	}
-
-	/**
-	 * @return Returns the swCTime.
-	 */
-	public int getSwCTime()
-	{
-		return swCTime;
-	}
-
-	/**
-	 * @param swCTime The swCTime to set.
-	 */
-	public void setSwCTime(int swCTime)
-	{
-		this.swCTime = swCTime;
-	}
-
-	/**
-	 * @return Returns the swCTimeOrDist.
-	 */
-	public byte getSwCTimeOrDist()
-	{
-		return swCTimeOrDist;
-	}
-
-	/**
-	 * @param swCTimeOrDist The swCTimeOrDist to set.
-	 */
-	public void setSwCTimeOrDist(byte swCTimeOrDist)
-	{
-		this.swCTimeOrDist = swCTimeOrDist;
-	}
-
-	/**
-	 * @return Returns the unk1.
-	 */
-	public short getUnk1()
-	{
-		return unk1;
-	}
-
-	/**
-	 * @param unk1 The unk1 to set.
-	 */
-	public void setUnk1(short unk1)
-	{
-		this.unk1 = unk1;
-	}
-
-	/**
-	 * @return Returns the unk2.
-	 */
-	public byte getUnk2()
-	{
-		return unk2;
-	}
-
-	/**
-	 * @param unk2 The unk2 to set.
-	 */
-	public void setUnk2(byte unk2)
-	{
-		this.unk2 = unk2;
-	}
-
-	/**
-	 * @return Returns the remainder.
-	 */
-	public int getRemainder()
-	{
-		return remainder;
-	}
-
-	/**
-	 * @return Returns the unk3.
-	 */
-	public int getUnk3()
-	{
-		return unk3;
-	}
-
-	/**
-	 * @return Returns the unk4.
-	 */
-	public int getUnk4()
-	{
-		return unk4;
-	}
-
-	public void writeProps(String fName)
-		throws Exception
-	{
-		Properties props = new Properties();
-		props.setProperty(propLogFormat, "" + logFormat);
-		props.setProperty(propDisableLogSpeed, "" + disableLogSpeed);
-		props.setProperty(propSpeedThres, "" + speedThres);
-		props.setProperty(propDisableLogDist, "" + disableLogDist);
-		props.setProperty(propDistThres, "" + distThres);
-		props.setProperty(propSwATime, "" + swATime);
-		props.setProperty(propSwBTime, "" + swBTime);
-		props.setProperty(propSwCTime, "" + swCTime);
-		props.setProperty(propUnk1, "" + unk1);
-		props.setProperty(propSwATimeOrDist, "" + swATimeOrDist);
-		props.setProperty(propSwBTimeOrDist, "" + swBTimeOrDist);
-		props.setProperty(propSwCTimeOrDist, "" + swCTimeOrDist);
-		props.setProperty(propSwADist, "" + swADist);
-		props.setProperty(propSwBDist, "" + swBDist);
-		props.setProperty(propSwCDist, "" + swCDist);
-		props.setProperty(propUnk2, "" + unk2);
-		props.setProperty(propRemainder, "" + remainder);
-		props.setProperty(propUnk3, "" + unk3);
-		props.setProperty(propUnk4, "" + unk4);
-		OutputStream os = null;
-		try
-		{
-			os = new FileOutputStream(fName);
-			props.store(os, "dg100 config");
-		}
-		catch (Exception ex)
-		{
-			ex.printStackTrace();
-			throw ex;
-		}
-		finally
-		{
-			if (os != null) {os.close();}
-		}
-	}
-
-	public void readProps(String fName)
-		throws Exception
-	{
-		Properties props = new Properties();
-		InputStream is = null;
-		try
-		{
-			is = new FileInputStream(fName);
-			props.load(is);
-		}
-		catch (Exception ex)
-		{
-			ex.printStackTrace();
-			throw ex;
-		}
-		finally
-		{
-			if (is != null) {is.close();}
-		}
-		logFormat = Byte.parseByte(props.getProperty(propLogFormat, "2"));
-		disableLogSpeed = Byte.parseByte(props.getProperty(propDisableLogSpeed, "0"));
-		speedThres = Integer.parseInt(props.getProperty(propSpeedThres, "0"));
-		disableLogDist = Byte.parseByte(props.getProperty(propDisableLogDist, "0"));
-		distThres = Integer.parseInt(props.getProperty(propDistThres, "0"));
-		swATime = Integer.parseInt(props.getProperty(propSwATime, "1000"));
-		swBTime = Integer.parseInt(props.getProperty(propSwBTime, "1000"));
-		swCTime = Integer.parseInt(props.getProperty(propSwCTime, "1000"));
-		swATimeOrDist = Byte.parseByte(props.getProperty(propSwATimeOrDist, "0"));
-		swBTimeOrDist = Byte.parseByte(props.getProperty(propSwBTimeOrDist, "0"));
-		swCTimeOrDist = Byte.parseByte(props.getProperty(propSwCTimeOrDist, "0"));
-		swADist = Integer.parseInt(props.getProperty(propSwADist, "0"));
-		swBDist = Integer.parseInt(props.getProperty(propSwBDist, "0"));
-		swCDist = Integer.parseInt(props.getProperty(propSwCDist, "0"));
-		unk1 = Short.parseShort(props.getProperty(propUnk1, "0"));
-		unk2 = Byte.parseByte(props.getProperty(propUnk2, "0"));
-		unk3 = Integer.parseInt(props.getProperty(propUnk3, "0"));
-		unk4 = Integer.parseInt(props.getProperty(propUnk4, "0"));
-	}
+    }
+
+    /**
+     * @return Returns the distThres.
+     */
+    public int getDistThres()
+    {
+        return distThres;
+    }
+
+    /**
+     * @param distThres The distThres to set.
+     */
+    public void setDistThres(int distThres)
+    {
+        this.distThres = distThres;
+    }
+
+    /**
+     * @return Returns the logFormat.
+     */
+    public byte getLogFormat()
+    {
+        return logFormat;
+    }
+
+    /**
+     * @param logFormat The logFormat to set.
+     */
+    public void setLogFormat(byte logFormat)
+    {
+        this.logFormat = logFormat;
+    }
+
+    /**
+     * @return Returns the speedThres.
+     */
+    public int getSpeedThres()
+    {
+        return speedThres;
+    }
+
+    /**
+     * @param speedThres The speedThres to set.
+     */
+    public void setSpeedThres(int speedThres)
+    {
+        this.speedThres = speedThres;
+    }
+
+    /**
+     * @return Returns the swADist.
+     */
+    public int getSwADist()
+    {
+        return swADist;
+    }
+
+    /**
+     * @param swADist The swADist to set.
+     */
+    public void setSwADist(int swADist)
+    {
+        this.swADist = swADist;
+    }
+
+    /**
+     * @return Returns the swATime.
+     */
+    public int getSwATime()
+    {
+        return swATime;
+    }
+
+    /**
+     * @param swATime The swATime to set.
+     */
+    public void setSwATime(int swATime)
+    {
+        this.swATime = swATime;
+    }
+
+    /**
+     * @return Returns the swATimeOrDist.
+     */
+    public byte getSwATimeOrDist()
+    {
+        return swATimeOrDist;
+    }
+
+    /**
+     * @param swATimeOrDist The swATimeOrDist to set.
+     */
+    public void setSwATimeOrDist(byte swATimeOrDist)
+    {
+        this.swATimeOrDist = swATimeOrDist;
+    }
+
+    /**
+     * @return Returns the swBDist.
+     */
+    public int getSwBDist()
+    {
+        return swBDist;
+    }
+
+    /**
+     * @param swBDist The swBDist to set.
+     */
+    public void setSwBDist(int swBDist)
+    {
+        this.swBDist = swBDist;
+    }
+
+    /**
+     * @return Returns the swBTime.
+     */
+    public int getSwBTime()
+    {
+        return swBTime;
+    }
+
+    /**
+     * @param swBTime The swBTime to set.
+     */
+    public void setSwBTime(int swBTime)
+    {
+        this.swBTime = swBTime;
+    }
+
+    /**
+     * @return Returns the swBTimeOrDist.
+     */
+    public byte getSwBTimeOrDist()
+    {
+        return swBTimeOrDist;
+    }
+
+    /**
+     * @param swBTimeOrDist The swBTimeOrDist to set.
+     */
+    public void setSwBTimeOrDist(byte swBTimeOrDist)
+    {
+        this.swBTimeOrDist = swBTimeOrDist;
+    }
+
+    /**
+     * @return Returns the swCDist.
+     */
+    public int getSwCDist()
+    {
+        return swCDist;
+    }
+
+    /**
+     * @param swCDist The swCDist to set.
+     */
+    public void setSwCDist(int swCDist)
+    {
+        this.swCDist = swCDist;
+    }
+
+    /**
+     * @return Returns the swCTime.
+     */
+    public int getSwCTime()
+    {
+        return swCTime;
+    }
+
+    /**
+     * @param swCTime The swCTime to set.
+     */
+    public void setSwCTime(int swCTime)
+    {
+        this.swCTime = swCTime;
+    }
+
+    /**
+     * @return Returns the swCTimeOrDist.
+     */
+    public byte getSwCTimeOrDist()
+    {
+        return swCTimeOrDist;
+    }
+
+    /**
+     * @param swCTimeOrDist The swCTimeOrDist to set.
+     */
+    public void setSwCTimeOrDist(byte swCTimeOrDist)
+    {
+        this.swCTimeOrDist = swCTimeOrDist;
+    }
+
+    /**
+     * @return Returns the unk1.
+     */
+    public short getUnk1()
+    {
+        return unk1;
+    }
+
+    /**
+     * @param unk1 The unk1 to set.
+     */
+    public void setUnk1(short unk1)
+    {
+        this.unk1 = unk1;
+    }
+
+    /**
+     * @return Returns the unk2.
+     */
+    public byte getUnk2()
+    {
+        return unk2;
+    }
+
+    /**
+     * @param unk2 The unk2 to set.
+     */
+    public void setUnk2(byte unk2)
+    {
+        this.unk2 = unk2;
+    }
+
+    /**
+     * @return Returns the remainder.
+     */
+    public int getRemainder()
+    {
+        return remainder;
+    }
+
+    /**
+     * @return Returns the unk3.
+     */
+    public int getUnk3()
+    {
+        return unk3;
+    }
+
+    /**
+     * @return Returns the unk4.
+     */
+    public int getUnk4()
+    {
+        return unk4;
+    }
+
+    public void writeProps(String fName)
+        throws Exception
+    {
+        Properties props = new Properties();
+        props.setProperty(propLogFormat, "" + logFormat);
+        props.setProperty(propDisableLogSpeed, "" + disableLogSpeed);
+        props.setProperty(propSpeedThres, "" + speedThres);
+        props.setProperty(propDisableLogDist, "" + disableLogDist);
+        props.setProperty(propDistThres, "" + distThres);
+        props.setProperty(propSwATime, "" + swATime);
+        props.setProperty(propSwBTime, "" + swBTime);
+        props.setProperty(propSwCTime, "" + swCTime);
+        props.setProperty(propUnk1, "" + unk1);
+        props.setProperty(propSwATimeOrDist, "" + swATimeOrDist);
+        props.setProperty(propSwBTimeOrDist, "" + swBTimeOrDist);
+        props.setProperty(propSwCTimeOrDist, "" + swCTimeOrDist);
+        props.setProperty(propSwADist, "" + swADist);
+        props.setProperty(propSwBDist, "" + swBDist);
+        props.setProperty(propSwCDist, "" + swCDist);
+        props.setProperty(propUnk2, "" + unk2);
+        props.setProperty(propRemainder, "" + remainder);
+        props.setProperty(propUnk3, "" + unk3);
+        props.setProperty(propUnk4, "" + unk4);
+        OutputStream os = null;
+        try
+        {
+            os = new FileOutputStream(fName);
+            props.store(os, "dg100 config");
+        }
+        catch (Exception ex)
+        {
+            ex.printStackTrace();
+            throw ex;
+        }
+        finally
+        {
+            if (os != null) {os.close();}
+        }
+    }
+
+    public void readProps(String fName)
+        throws Exception
+    {
+        Properties props = new Properties();
+        InputStream is = null;
+        try
+        {
+            is = new FileInputStream(fName);
+            props.load(is);
+        }
+        catch (Exception ex)
+        {
+            ex.printStackTrace();
+            throw ex;
+        }
+        finally
+        {
+            if (is != null) {is.close();}
+        }
+        logFormat = Byte.parseByte(props.getProperty(propLogFormat, "2"));
+        disableLogSpeed = Byte.parseByte(props.getProperty(propDisableLogSpeed, "0"));
+        speedThres = Integer.parseInt(props.getProperty(propSpeedThres, "0"));
+        disableLogDist = Byte.parseByte(props.getProperty(propDisableLogDist, "0"));
+        distThres = Integer.parseInt(props.getProperty(propDistThres, "0"));
+        swATime = Integer.parseInt(props.getProperty(propSwATime, "1000"));
+        swBTime = Integer.parseInt(props.getProperty(propSwBTime, "1000"));
+        swCTime = Integer.parseInt(props.getProperty(propSwCTime, "1000"));
+        swATimeOrDist = Byte.parseByte(props.getProperty(propSwATimeOrDist, "0"));
+        swBTimeOrDist = Byte.parseByte(props.getProperty(propSwBTimeOrDist, "0"));
+        swCTimeOrDist = Byte.parseByte(props.getProperty(propSwCTimeOrDist, "0"));
+        swADist = Integer.parseInt(props.getProperty(propSwADist, "0"));
+        swBDist = Integer.parseInt(props.getProperty(propSwBDist, "0"));
+        swCDist = Integer.parseInt(props.getProperty(propSwCDist, "0"));
+        unk1 = Short.parseShort(props.getProperty(propUnk1, "0"));
+        unk2 = Byte.parseByte(props.getProperty(propUnk2, "0"));
+        unk3 = Integer.parseInt(props.getProperty(propUnk3, "0"));
+        unk4 = Integer.parseInt(props.getProperty(propUnk4, "0"));
+    }
 
 }
Index: applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/FileInfoRec.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/FileInfoRec.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/FileInfoRec.java	(revision 12778)
@@ -13,26 +13,26 @@
 public class FileInfoRec
 {
-	private int timeZ = 0;
-	private int date = 0;
-	private int idx = 0;
-	
-	public FileInfoRec(ByteBuffer buf)
-	{
-		timeZ =  buf.getInt();
-		date =  buf.getInt();
-		idx =  buf.getInt();
-	}
-	
-	public String toString()
-	{
-		return "[FileInfoRec: timeZ = " + timeZ + ", date = " + date + ", idx = " + idx + "]";
-	}
+    private int timeZ = 0;
+    private int date = 0;
+    private int idx = 0;
 
-	/**
-	 * @return Returns the idx.
-	 */
-	public int getIdx()
-	{
-		return idx;
-	}
+    public FileInfoRec(ByteBuffer buf)
+    {
+        timeZ =  buf.getInt();
+        date =  buf.getInt();
+        idx =  buf.getInt();
+    }
+
+    public String toString()
+    {
+        return "[FileInfoRec: timeZ = " + timeZ + ", date = " + date + ", idx = " + idx + "]";
+    }
+
+    /**
+     * @return Returns the idx.
+     */
+    public int getIdx()
+    {
+        return idx;
+    }
 }
Index: applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/GpsRec.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/GpsRec.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/GpsRec.java	(revision 12778)
@@ -22,420 +22,420 @@
 //  ff ff ff ff: dg100Altitude (m): alt * 10000
 
-	private int dg100Latitude = -1;
-	private int dg100Longitude = -1;
-	private int dg100TimeZ = -1;
-	private int dg100Date = -1;
-	private int dg100Speed = -1;
-	private int dg100Altitude = -1;
-	private int dg100Unk1 = -1;
-	private int dg100TypeOfCurRec = -1;
-	private int dg100TypeOfNextRec = -1;
-	// calculated data
-	private Calendar dateTime = null;
-
-	public GpsRec()
-	{
-		dg100TypeOfNextRec = 2;
-		dg100TypeOfCurRec = 2;
-		dg100Latitude = 0;
-		dg100Longitude = 0;
-		dg100TimeZ = 0;
-		dg100Date = 0;
-		dg100Speed = 0;
-		dg100Altitude = 0;
-		dg100Unk1 = -1;
-		dateTime = null;
-	}
-
-	public void copy(GpsRec init)
-	{
-		dg100TypeOfNextRec = init.dg100TypeOfNextRec;
-		dg100TypeOfCurRec = init.dg100TypeOfCurRec;
-		dg100Latitude = init.dg100Latitude;
-		dg100Longitude = init.dg100Longitude;
-		dg100TimeZ = init.dg100TimeZ;
-		dg100Date = init.dg100Date;
-		dg100Speed = init.dg100Speed;
-		dg100Altitude = init.dg100Altitude;
-		dg100Unk1 = init.dg100Unk1;
-		dateTime = init.dateTime;
-	}
-
-	public GpsRec(GpsRec init)
-	{
-		copy(init);
-	}
-
-	/**
-	 * @see java.lang.Object#equals(java.lang.Object)
-	 */
-	public boolean equals(Object arg0)
-	{
-		boolean isEqual = false;
-		if (arg0 != null && arg0 instanceof GpsRec)
-		{
-			GpsRec otherGpsRec = (GpsRec)arg0;
-			isEqual =
-				dg100TypeOfNextRec == otherGpsRec.dg100TypeOfNextRec
-				&& dg100TypeOfCurRec == otherGpsRec.dg100TypeOfCurRec
-				&& dg100Latitude == otherGpsRec.dg100Latitude
-				&& dg100Longitude == otherGpsRec.dg100Longitude
-				&& dg100TimeZ == otherGpsRec.dg100TimeZ
-				&& dg100Date == otherGpsRec.dg100Date
-				&& dg100Speed == otherGpsRec.dg100Speed
-				&& dg100Altitude == otherGpsRec.dg100Altitude
-				//&& dg100Unk1 == otherGpsRec.unk1
-				;
-		}
-		return isEqual;
-	}
-
-	public GpsRec(ByteBuffer buf, int recType)
-	{
-		dg100Latitude =  buf.getInt();
-		dg100Longitude =  buf.getInt();
-		dg100TypeOfNextRec = recType;
-		dg100TypeOfCurRec = recType;
-		dateTime = null;
-		if (dg100TypeOfNextRec >= 1)
-		{
-			dg100TimeZ = buf.getInt();
-			dg100Date = buf.getInt();
-			calcDateTime();
-			dg100Speed =  buf.getInt();
-			if (dg100TypeOfNextRec >= 1)
-			{
-				dg100Altitude =  buf.getInt();
-				dg100Unk1 =  buf.getInt();
-				dg100TypeOfNextRec =  buf.getInt();
-			}
-		}
-	}
-
-	/**
-	 * Shows wether this is a valid GPS record.
-	 * @return true if GPS record is valid; otherwise false.
-	 */
-	public boolean isValid()
-	{
-		return
-			dg100Latitude <= 360000000
-			&& dg100Latitude >= 0
-			&& dg100Longitude <= 360000000
-			&& dg100Longitude >= 0
-			&& dg100TimeZ >= 0
-			&& dg100TimeZ <= 240000
-			&& dg100Unk1 >= 0
-			&& dg100Unk1 <= 1
-			;
-	}
-
-	public int getDg100TypeOfNextRec()
-	{
-		return dg100TypeOfNextRec;
-	}
-
-	public int getDg100TypeOfCurRec()
-	{
-		return dg100TypeOfCurRec;
-	}
-
-	public String toString()
-	{
-		return "[GpsRec: "
-			+ " Lat = " + dg100Latitude
-			+ ", Long = " + dg100Longitude
-			+ ", TimeZ = " + dg100TimeZ
-			+ ", Date = " + dg100Date
-			+ ", Speed = " + dg100Speed
-			+ ", Alt = " + dg100Altitude
-			+ ", Unk1 = " + dg100Unk1
-			+ ", TypeOfCurRec = " + dg100TypeOfCurRec
-			+ ", TypeOfNextRec = " + dg100TypeOfNextRec
-			+ "]";
-	}
-
-	/**
-	 * @return Returns the dg100Latitude.
-	 */
-	public int getDg100Latitude()
-	{
-		return dg100Latitude;
-	}
-
-	/**
-	 * Converts this object to its GPX representation.
-	 * @return this object's GPX representation as a String.
-	 */
-	public String toGpxTrkpt()
-	{
-//		<trkpt lat="47.6972383333" lon="11.4178650000">
-//		<ele>662.0000000000</ele>
-//		<time>2007-04-21T13:56:05Z</time>
-//		<dg100Speed>1.0833333333</dg100Speed>
-//		</trkpt>
-		StringBuffer buf = new StringBuffer(500);
-		buf.append("<trkpt");
-		buf.append(" lat=\"").append(getLatitude()).append("\"");
-		buf.append(" lon=\"").append(getLongitude()).append("\"");
-		buf.append(">");
-		if (dg100TypeOfCurRec > 0)
-		{
-			if (dg100TypeOfCurRec > 1)
-			{
-				buf.append("<ele>").append(getAltitude()).append("</ele>");
-			}
-			buf.append("<time>").append(getStringZuluTime()).append("</time>");
-			buf.append("<speed>").append(getSpeed()).append("</speed>");
-		}
-		buf.append("</trkpt>");
-		return buf.toString();
-	}
-
-	/**
-	 * Converts this object to its GPX waypoint representation.
-	 * @return this object's GPX representation as a String.
-	 */
-	public String toGpxWpt()
-	{
-//		<wpt lat="47.6972383333" lon="11.4178650000">
-//		<ele>662.0000000000</ele>
-//		<time>2007-04-21T13:56:05Z</time>
-//		</wpt>
-		StringBuffer buf = new StringBuffer(500);
-		buf.append("<wpt");
-		buf.append(" lat=\"").append(getLatitude()).append("\"");
-		buf.append(" lon=\"").append(getLongitude()).append("\"");
-		buf.append(">");
-		if (dg100TypeOfCurRec > 0)
-		{
-			if (dg100TypeOfCurRec > 1)
-			{
-				buf.append("<ele>").append(getAltitude()).append("</ele>");
-			}
-			buf.append("<time>").append(getStringZuluTime()).append("</time>");
-		}
-		buf.append("</wpt>");
-		return buf.toString();
-	}
-
-	/**
-	 * Converts GlobalSat dg100Latitude and dg100Longitude internal format to degrees.
-	 * @param gsLatOrLon
-	 * @return nodeg in degrees
-	 */
-	private double toDegree(int gsLatOrLon)
-	{
-		int scale = 1000000;
-		double deg = 9999.9999;
-		double degScaled = (double)(gsLatOrLon / scale);
-		double minScaled = ((double)(gsLatOrLon - degScaled * scale)) / 600000.0;
-		deg = degScaled + minScaled;
-		return deg;
-	}
-
-	/**
-	 * Gets dg100Date and time as a String in GPX dg100Date-time-format (aka zulu time).
-	 * @return a dg100Date-time-string in GPX dg100Date-time-format (aka zulu time).
-	 */
-	public String getStringZuluTime()
-	{
-		return getStringDateTime("yyyy-MM-dd'T'HH:mm:ss'Z'");
-	}
-
-	/**
-	 * Gets dg100Date and time as a String in format "yyyyMMddHHmmss".
-	 * @return a dg100Date-time-string in format "yyyyMMddHHmmss".
-	 */
-	public String getStringDateTime()
-	{
-		return getStringDateTime("yyyyMMddHHmmss");
-	}
-
-	/**
-	 * Gets dg100Date and time as a String in given format.
-	 * @param dateTimeFormat
-	 * @return
-	 */
-	private String getStringDateTime(String dateTimeFormat)
-	{
-		String dateTimeString = "???";
-		if (dateTime != null)
-		{
-			SimpleDateFormat sdf = new SimpleDateFormat(dateTimeFormat);
-			//logger.info(gsTime + " " + gsDate);
-			dateTimeString = sdf.format(dateTime.getTime());
-		}
-		return dateTimeString;
-	}
-
-	/**
-	 * @return Returns the dg100Altitude.
-	 */
-	public int getDg100Altitude()
-	{
-		return dg100Altitude;
-	}
-
-	/**
-	 * @param dg100Altitude The dg100Altitude to set.
-	 */
-	private void setDg100Altitude(int altitude)
-	{
-		this.dg100Altitude = altitude;
-	}
-
-	/**
-	 * @return Returns the dg100Date.
-	 */
-	public int getDg100Date()
-	{
-		return dg100Date;
-	}
-
-	/**
-	 * @param dg100Date The dg100Date to set.
-	 */
-	private void setDg100Date(int date)
-	{
-		this.dg100Date = date;
-		calcDateTime();
-	}
-
-	/**
-	 * @return
-	 */
-	private void calcDateTime()
-	{
-		int hh = dg100TimeZ / 10000;
-		int mm = (dg100TimeZ - hh * 10000) / 100;
-		int ss = dg100TimeZ - hh * 10000 - mm * 100;
-		int DD = dg100Date / 10000;
-		int MM = (dg100Date - DD * 10000) / 100;
-		int YY = dg100Date - DD * 10000 - MM * 100;
-		dateTime = GregorianCalendar.getInstance();
-		dateTime.set(2000 + YY, MM, DD, hh, mm, ss);
-	}
-
-	/**
-	 * @return Returns the dg100Longitude.
-	 */
-	public int getDg100Longitude()
-	{
-		return dg100Longitude;
-	}
-
-	/**
-	 * @param dg100Longitude The dg100Longitude to set.
-	 */
-	private void setDg100Longitude(int longitude)
-	{
-		this.dg100Longitude = longitude;
-	}
-
-	/**
-	 * @return Returns the dg100Speed.
-	 */
-	public int getDg100Speed()
-	{
-		return dg100Speed;
-	}
-
-	/**
-	 * @param dg100Speed The dg100Speed to set.
-	 */
-	private void setDg100Speed(int speed)
-	{
-		this.dg100Speed = speed;
-	}
-
-	/**
-	 * @return Returns the dg100TimeZ.
-	 */
-	public int getDg100TimeZ()
-	{
-		return dg100TimeZ;
-	}
-
-	/**
-	 * @param dg100TimeZ The dg100TimeZ to set.
-	 */
-	private void setDg100TimeZ(int timeZ)
-	{
-		this.dg100TimeZ = timeZ;
-		calcDateTime();
-	}
-
-	/**
-	 * @param dg100Latitude The dg100Latitude to set.
-	 */
-	private void setDg100Latitude(int latitude)
-	{
-		this.dg100Latitude = latitude;
-	}
-
-	public void updateMin(GpsRec next)
-	{
-		if (next != null)
-		{
-			if (next.getDg100Latitude() < getDg100Latitude()) {setDg100Latitude(next.getDg100Latitude());}
-			if (next.getDg100Longitude() < getDg100Longitude()) {setDg100Longitude(next.getDg100Longitude());}
-			if (next.getDg100Altitude() < getDg100Altitude()) {setDg100Altitude(next.getDg100Altitude());}
-			if (next.getDg100Date() < getDg100Date()
-				|| (next.getDg100Date() == getDg100Date() && next.getDg100TimeZ() < getDg100TimeZ())
-				)
-			{
-				setDg100Date(next.getDg100Date());
-				setDg100TimeZ(next.getDg100TimeZ());
-			}
-			if (next.getDg100Speed() < getDg100Speed()) {setDg100Speed(next.getDg100Speed());}
-		}
-	}
-
-	public void updateMax(GpsRec next)
-	{
-		if (next != null)
-		{
-			if (next.getDg100Latitude() > getDg100Latitude()) {setDg100Latitude(next.getDg100Latitude());}
-			if (next.getDg100Longitude() > getDg100Longitude()) {setDg100Longitude(next.getDg100Longitude());}
-			if (next.getDg100Altitude() > getDg100Altitude()) {setDg100Altitude(next.getDg100Altitude());}
-			if (next.getDg100Date() > getDg100Date()
-				|| (next.getDg100Date() == getDg100Date() && next.getDg100TimeZ() > getDg100TimeZ())
-				)
-			{
-				setDg100Date(next.getDg100Date());
-				setDg100TimeZ(next.getDg100TimeZ());
-			}
-			if (next.getDg100Speed() > getDg100Speed()) {setDg100Speed(next.getDg100Speed());}
-		}
-	}
-
-	/**
-	 * @return Returns the dateTime.
-	 */
-	public Calendar getDateTime()
-	{
-		return dateTime;
-	}
-
-	public double getLatitude()
-	{
-		return toDegree(dg100Latitude);
-	}
-
-	public double getLongitude()
-	{
-		return toDegree(dg100Longitude);
-	}
-
-	public double getAltitude()
-	{
-		return dg100Altitude / (double)10000.0;
-	}
-
-	public double getSpeed()
-	{
-		return dg100Speed / (double)360.0;
-	}
+    private int dg100Latitude = -1;
+    private int dg100Longitude = -1;
+    private int dg100TimeZ = -1;
+    private int dg100Date = -1;
+    private int dg100Speed = -1;
+    private int dg100Altitude = -1;
+    private int dg100Unk1 = -1;
+    private int dg100TypeOfCurRec = -1;
+    private int dg100TypeOfNextRec = -1;
+    // calculated data
+    private Calendar dateTime = null;
+
+    public GpsRec()
+    {
+        dg100TypeOfNextRec = 2;
+        dg100TypeOfCurRec = 2;
+        dg100Latitude = 0;
+        dg100Longitude = 0;
+        dg100TimeZ = 0;
+        dg100Date = 0;
+        dg100Speed = 0;
+        dg100Altitude = 0;
+        dg100Unk1 = -1;
+        dateTime = null;
+    }
+
+    public void copy(GpsRec init)
+    {
+        dg100TypeOfNextRec = init.dg100TypeOfNextRec;
+        dg100TypeOfCurRec = init.dg100TypeOfCurRec;
+        dg100Latitude = init.dg100Latitude;
+        dg100Longitude = init.dg100Longitude;
+        dg100TimeZ = init.dg100TimeZ;
+        dg100Date = init.dg100Date;
+        dg100Speed = init.dg100Speed;
+        dg100Altitude = init.dg100Altitude;
+        dg100Unk1 = init.dg100Unk1;
+        dateTime = init.dateTime;
+    }
+
+    public GpsRec(GpsRec init)
+    {
+        copy(init);
+    }
+
+    /**
+     * @see java.lang.Object#equals(java.lang.Object)
+     */
+    public boolean equals(Object arg0)
+    {
+        boolean isEqual = false;
+        if (arg0 != null && arg0 instanceof GpsRec)
+        {
+            GpsRec otherGpsRec = (GpsRec)arg0;
+            isEqual =
+                dg100TypeOfNextRec == otherGpsRec.dg100TypeOfNextRec
+                && dg100TypeOfCurRec == otherGpsRec.dg100TypeOfCurRec
+                && dg100Latitude == otherGpsRec.dg100Latitude
+                && dg100Longitude == otherGpsRec.dg100Longitude
+                && dg100TimeZ == otherGpsRec.dg100TimeZ
+                && dg100Date == otherGpsRec.dg100Date
+                && dg100Speed == otherGpsRec.dg100Speed
+                && dg100Altitude == otherGpsRec.dg100Altitude
+                //&& dg100Unk1 == otherGpsRec.unk1
+                ;
+        }
+        return isEqual;
+    }
+
+    public GpsRec(ByteBuffer buf, int recType)
+    {
+        dg100Latitude =  buf.getInt();
+        dg100Longitude =  buf.getInt();
+        dg100TypeOfNextRec = recType;
+        dg100TypeOfCurRec = recType;
+        dateTime = null;
+        if (dg100TypeOfNextRec >= 1)
+        {
+            dg100TimeZ = buf.getInt();
+            dg100Date = buf.getInt();
+            calcDateTime();
+            dg100Speed =  buf.getInt();
+            if (dg100TypeOfNextRec >= 1)
+            {
+                dg100Altitude =  buf.getInt();
+                dg100Unk1 =  buf.getInt();
+                dg100TypeOfNextRec =  buf.getInt();
+            }
+        }
+    }
+
+    /**
+     * Shows wether this is a valid GPS record.
+     * @return true if GPS record is valid; otherwise false.
+     */
+    public boolean isValid()
+    {
+        return
+            dg100Latitude <= 360000000
+            && dg100Latitude >= 0
+            && dg100Longitude <= 360000000
+            && dg100Longitude >= 0
+            && dg100TimeZ >= 0
+            && dg100TimeZ <= 240000
+            && dg100Unk1 >= 0
+            && dg100Unk1 <= 1
+            ;
+    }
+
+    public int getDg100TypeOfNextRec()
+    {
+        return dg100TypeOfNextRec;
+    }
+
+    public int getDg100TypeOfCurRec()
+    {
+        return dg100TypeOfCurRec;
+    }
+
+    public String toString()
+    {
+        return "[GpsRec: "
+            + " Lat = " + dg100Latitude
+            + ", Long = " + dg100Longitude
+            + ", TimeZ = " + dg100TimeZ
+            + ", Date = " + dg100Date
+            + ", Speed = " + dg100Speed
+            + ", Alt = " + dg100Altitude
+            + ", Unk1 = " + dg100Unk1
+            + ", TypeOfCurRec = " + dg100TypeOfCurRec
+            + ", TypeOfNextRec = " + dg100TypeOfNextRec
+            + "]";
+    }
+
+    /**
+     * @return Returns the dg100Latitude.
+     */
+    public int getDg100Latitude()
+    {
+        return dg100Latitude;
+    }
+
+    /**
+     * Converts this object to its GPX representation.
+     * @return this object's GPX representation as a String.
+     */
+    public String toGpxTrkpt()
+    {
+//      <trkpt lat="47.6972383333" lon="11.4178650000">
+//      <ele>662.0000000000</ele>
+//      <time>2007-04-21T13:56:05Z</time>
+//      <dg100Speed>1.0833333333</dg100Speed>
+//      </trkpt>
+        StringBuffer buf = new StringBuffer(500);
+        buf.append("<trkpt");
+        buf.append(" lat=\"").append(getLatitude()).append("\"");
+        buf.append(" lon=\"").append(getLongitude()).append("\"");
+        buf.append(">");
+        if (dg100TypeOfCurRec > 0)
+        {
+            if (dg100TypeOfCurRec > 1)
+            {
+                buf.append("<ele>").append(getAltitude()).append("</ele>");
+            }
+            buf.append("<time>").append(getStringZuluTime()).append("</time>");
+            buf.append("<speed>").append(getSpeed()).append("</speed>");
+        }
+        buf.append("</trkpt>");
+        return buf.toString();
+    }
+
+    /**
+     * Converts this object to its GPX waypoint representation.
+     * @return this object's GPX representation as a String.
+     */
+    public String toGpxWpt()
+    {
+//      <wpt lat="47.6972383333" lon="11.4178650000">
+//      <ele>662.0000000000</ele>
+//      <time>2007-04-21T13:56:05Z</time>
+//      </wpt>
+        StringBuffer buf = new StringBuffer(500);
+        buf.append("<wpt");
+        buf.append(" lat=\"").append(getLatitude()).append("\"");
+        buf.append(" lon=\"").append(getLongitude()).append("\"");
+        buf.append(">");
+        if (dg100TypeOfCurRec > 0)
+        {
+            if (dg100TypeOfCurRec > 1)
+            {
+                buf.append("<ele>").append(getAltitude()).append("</ele>");
+            }
+            buf.append("<time>").append(getStringZuluTime()).append("</time>");
+        }
+        buf.append("</wpt>");
+        return buf.toString();
+    }
+
+    /**
+     * Converts GlobalSat dg100Latitude and dg100Longitude internal format to degrees.
+     * @param gsLatOrLon
+     * @return nodeg in degrees
+     */
+    private double toDegree(int gsLatOrLon)
+    {
+        int scale = 1000000;
+        double deg = 9999.9999;
+        double degScaled = (double)(gsLatOrLon / scale);
+        double minScaled = ((double)(gsLatOrLon - degScaled * scale)) / 600000.0;
+        deg = degScaled + minScaled;
+        return deg;
+    }
+
+    /**
+     * Gets dg100Date and time as a String in GPX dg100Date-time-format (aka zulu time).
+     * @return a dg100Date-time-string in GPX dg100Date-time-format (aka zulu time).
+     */
+    public String getStringZuluTime()
+    {
+        return getStringDateTime("yyyy-MM-dd'T'HH:mm:ss'Z'");
+    }
+
+    /**
+     * Gets dg100Date and time as a String in format "yyyyMMddHHmmss".
+     * @return a dg100Date-time-string in format "yyyyMMddHHmmss".
+     */
+    public String getStringDateTime()
+    {
+        return getStringDateTime("yyyyMMddHHmmss");
+    }
+
+    /**
+     * Gets dg100Date and time as a String in given format.
+     * @param dateTimeFormat
+     * @return
+     */
+    private String getStringDateTime(String dateTimeFormat)
+    {
+        String dateTimeString = "???";
+        if (dateTime != null)
+        {
+            SimpleDateFormat sdf = new SimpleDateFormat(dateTimeFormat);
+            //logger.info(gsTime + " " + gsDate);
+            dateTimeString = sdf.format(dateTime.getTime());
+        }
+        return dateTimeString;
+    }
+
+    /**
+     * @return Returns the dg100Altitude.
+     */
+    public int getDg100Altitude()
+    {
+        return dg100Altitude;
+    }
+
+    /**
+     * @param dg100Altitude The dg100Altitude to set.
+     */
+    private void setDg100Altitude(int altitude)
+    {
+        this.dg100Altitude = altitude;
+    }
+
+    /**
+     * @return Returns the dg100Date.
+     */
+    public int getDg100Date()
+    {
+        return dg100Date;
+    }
+
+    /**
+     * @param dg100Date The dg100Date to set.
+     */
+    private void setDg100Date(int date)
+    {
+        this.dg100Date = date;
+        calcDateTime();
+    }
+
+    /**
+     * @return
+     */
+    private void calcDateTime()
+    {
+        int hh = dg100TimeZ / 10000;
+        int mm = (dg100TimeZ - hh * 10000) / 100;
+        int ss = dg100TimeZ - hh * 10000 - mm * 100;
+        int DD = dg100Date / 10000;
+        int MM = (dg100Date - DD * 10000) / 100;
+        int YY = dg100Date - DD * 10000 - MM * 100;
+        dateTime = GregorianCalendar.getInstance();
+        dateTime.set(2000 + YY, MM, DD, hh, mm, ss);
+    }
+
+    /**
+     * @return Returns the dg100Longitude.
+     */
+    public int getDg100Longitude()
+    {
+        return dg100Longitude;
+    }
+
+    /**
+     * @param dg100Longitude The dg100Longitude to set.
+     */
+    private void setDg100Longitude(int longitude)
+    {
+        this.dg100Longitude = longitude;
+    }
+
+    /**
+     * @return Returns the dg100Speed.
+     */
+    public int getDg100Speed()
+    {
+        return dg100Speed;
+    }
+
+    /**
+     * @param dg100Speed The dg100Speed to set.
+     */
+    private void setDg100Speed(int speed)
+    {
+        this.dg100Speed = speed;
+    }
+
+    /**
+     * @return Returns the dg100TimeZ.
+     */
+    public int getDg100TimeZ()
+    {
+        return dg100TimeZ;
+    }
+
+    /**
+     * @param dg100TimeZ The dg100TimeZ to set.
+     */
+    private void setDg100TimeZ(int timeZ)
+    {
+        this.dg100TimeZ = timeZ;
+        calcDateTime();
+    }
+
+    /**
+     * @param dg100Latitude The dg100Latitude to set.
+     */
+    private void setDg100Latitude(int latitude)
+    {
+        this.dg100Latitude = latitude;
+    }
+
+    public void updateMin(GpsRec next)
+    {
+        if (next != null)
+        {
+            if (next.getDg100Latitude() < getDg100Latitude()) {setDg100Latitude(next.getDg100Latitude());}
+            if (next.getDg100Longitude() < getDg100Longitude()) {setDg100Longitude(next.getDg100Longitude());}
+            if (next.getDg100Altitude() < getDg100Altitude()) {setDg100Altitude(next.getDg100Altitude());}
+            if (next.getDg100Date() < getDg100Date()
+                || (next.getDg100Date() == getDg100Date() && next.getDg100TimeZ() < getDg100TimeZ())
+                )
+            {
+                setDg100Date(next.getDg100Date());
+                setDg100TimeZ(next.getDg100TimeZ());
+            }
+            if (next.getDg100Speed() < getDg100Speed()) {setDg100Speed(next.getDg100Speed());}
+        }
+    }
+
+    public void updateMax(GpsRec next)
+    {
+        if (next != null)
+        {
+            if (next.getDg100Latitude() > getDg100Latitude()) {setDg100Latitude(next.getDg100Latitude());}
+            if (next.getDg100Longitude() > getDg100Longitude()) {setDg100Longitude(next.getDg100Longitude());}
+            if (next.getDg100Altitude() > getDg100Altitude()) {setDg100Altitude(next.getDg100Altitude());}
+            if (next.getDg100Date() > getDg100Date()
+                || (next.getDg100Date() == getDg100Date() && next.getDg100TimeZ() > getDg100TimeZ())
+                )
+            {
+                setDg100Date(next.getDg100Date());
+                setDg100TimeZ(next.getDg100TimeZ());
+            }
+            if (next.getDg100Speed() > getDg100Speed()) {setDg100Speed(next.getDg100Speed());}
+        }
+    }
+
+    /**
+     * @return Returns the dateTime.
+     */
+    public Calendar getDateTime()
+    {
+        return dateTime;
+    }
+
+    public double getLatitude()
+    {
+        return toDegree(dg100Latitude);
+    }
+
+    public double getLongitude()
+    {
+        return toDegree(dg100Longitude);
+    }
+
+    public double getAltitude()
+    {
+        return dg100Altitude / (double)10000.0;
+    }
+
+    public double getSpeed()
+    {
+        return dg100Speed / (double)360.0;
+    }
 
 }
Index: applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/Response.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/Response.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/kaintoch/gps/globalsat/dg100/Response.java	(revision 12778)
@@ -14,148 +14,148 @@
 public class Response
 {
-	final static public byte typeFileInfo = (byte)0xBB;
-	final static public byte typeId = (byte)0xBF;
-	final static public byte typeGpsRec = (byte)0xB5;
-	final static public byte typeConfig = (byte)0xB7;
+    final static public byte typeFileInfo = (byte)0xBB;
+    final static public byte typeId = (byte)0xBF;
+    final static public byte typeGpsRec = (byte)0xB5;
+    final static public byte typeConfig = (byte)0xB7;
 
-	private int typeOfResponse = 0;
-	private int cntDataCur = 0;
-	private int nextIdx = 0;
-	private Dg100Config config = null;
-	private List data = new ArrayList(100);
-	private long id = 0;
-    
-	private Response(int typeOfResponse)
-	{
-		this.typeOfResponse = typeOfResponse;
-	}
+    private int typeOfResponse = 0;
+    private int cntDataCur = 0;
+    private int nextIdx = 0;
+    private Dg100Config config = null;
+    private List data = new ArrayList(100);
+    private long id = 0;
 
-	/**
-	 *
-	 * @param resp
-	 */
-	static public Response parseResponse(byte resp[], int len)
-	{
-		ByteBuffer buf = ByteBuffer.wrap(resp);
-		byte respType = buf.get(4);
-		Response response = new Response(respType);
-		buf.position(5);
-		if (respType == typeFileInfo) // file info
-		{
-			int cntInfoCur = buf.getShort();
-			int nextIdx = buf.getShort();
-			response.cntDataCur = cntInfoCur;
-			response.nextIdx = nextIdx;
-			for (int ii = 0 ; ii < cntInfoCur ; ++ii)
-			{
-				FileInfoRec fileInfoRec = new FileInfoRec(buf);
-				response.addRec(fileInfoRec);
-			}
-		}
-		else if (respType == typeGpsRec) // gps recs
-		{
-			int recType = 2;
-			int ii = 0;
-			// read part 1
-			while (buf.position() <= len)
-			{
-				GpsRec gpsRec = new GpsRec(buf, recType);
-				if (gpsRec.isValid() && buf.position() <= len)
-				{
-					response.addRec(gpsRec);
-				}
-				else
-				{
-					break;
-				}
-				recType = gpsRec.getDg100TypeOfNextRec();
-				++ii;
-			}
-			// read part 2
-			buf.position(1042);
-			while (buf.position() <= len)
-			{
-				GpsRec gpsRec = new GpsRec(buf, recType);
-				if (gpsRec.isValid() && buf.position() <= len)
-				{
-					response.addRec(gpsRec);
-				}
-				else
-				{
-					break;
-				}
-				recType = gpsRec.getDg100TypeOfNextRec();
-				++ii;
-			}
-		}
-		else if (respType == typeConfig) // config
-		{
-			Dg100Config config = new Dg100Config(buf);
-			response.config = config;
-		}
-		else if (respType == typeId) // id
-		{
-			response.id = 0;
-			for (int ii = 0 ; ii < 8 ; ++ii)
-			{
-				int digit = (int)buf.get();
-				response.id = response.id * 10 + digit;
-			}
-		}
-		else
-		{
-		}
-		return response;
-	}
+    private Response(int typeOfResponse)
+    {
+        this.typeOfResponse = typeOfResponse;
+    }
 
-	private void addRec(Object obj)
-	{
-		data.add(obj);
-	}
+    /**
+     *
+     * @param resp
+     */
+    static public Response parseResponse(byte resp[], int len)
+    {
+        ByteBuffer buf = ByteBuffer.wrap(resp);
+        byte respType = buf.get(4);
+        Response response = new Response(respType);
+        buf.position(5);
+        if (respType == typeFileInfo) // file info
+        {
+            int cntInfoCur = buf.getShort();
+            int nextIdx = buf.getShort();
+            response.cntDataCur = cntInfoCur;
+            response.nextIdx = nextIdx;
+            for (int ii = 0 ; ii < cntInfoCur ; ++ii)
+            {
+                FileInfoRec fileInfoRec = new FileInfoRec(buf);
+                response.addRec(fileInfoRec);
+            }
+        }
+        else if (respType == typeGpsRec) // gps recs
+        {
+            int recType = 2;
+            int ii = 0;
+            // read part 1
+            while (buf.position() <= len)
+            {
+                GpsRec gpsRec = new GpsRec(buf, recType);
+                if (gpsRec.isValid() && buf.position() <= len)
+                {
+                    response.addRec(gpsRec);
+                }
+                else
+                {
+                    break;
+                }
+                recType = gpsRec.getDg100TypeOfNextRec();
+                ++ii;
+            }
+            // read part 2
+            buf.position(1042);
+            while (buf.position() <= len)
+            {
+                GpsRec gpsRec = new GpsRec(buf, recType);
+                if (gpsRec.isValid() && buf.position() <= len)
+                {
+                    response.addRec(gpsRec);
+                }
+                else
+                {
+                    break;
+                }
+                recType = gpsRec.getDg100TypeOfNextRec();
+                ++ii;
+            }
+        }
+        else if (respType == typeConfig) // config
+        {
+            Dg100Config config = new Dg100Config(buf);
+            response.config = config;
+        }
+        else if (respType == typeId) // id
+        {
+            response.id = 0;
+            for (int ii = 0 ; ii < 8 ; ++ii)
+            {
+                int digit = (int)buf.get();
+                response.id = response.id * 10 + digit;
+            }
+        }
+        else
+        {
+        }
+        return response;
+    }
 
-	public List getRecs()
-	{
-		return data;
-	}
+    private void addRec(Object obj)
+    {
+        data.add(obj);
+    }
 
-	/**
-	 * @return Returns the cntDataCur.
-	 */
-	public int getCntDataCur()
-	{
-		return cntDataCur;
-	}
+    public List getRecs()
+    {
+        return data;
+    }
 
-	/**
-	 * @return Returns the nextIdx.
-	 */
-	public int getNextIdx()
-	{
-		return nextIdx;
-	}
+    /**
+     * @return Returns the cntDataCur.
+     */
+    public int getCntDataCur()
+    {
+        return cntDataCur;
+    }
 
-	/**
-	 * @return Returns the typeOfResponse.
-	 */
-	public int getTypeOfResponse()
-	{
-		return typeOfResponse;
-	}
+    /**
+     * @return Returns the nextIdx.
+     */
+    public int getNextIdx()
+    {
+        return nextIdx;
+    }
 
-	/**
-	 * @return Returns the config.
-	 */
-	public Dg100Config getConfig()
-	{
-		return config;
-	}
+    /**
+     * @return Returns the typeOfResponse.
+     */
+    public int getTypeOfResponse()
+    {
+        return typeOfResponse;
+    }
 
-	/**
-	 * @return Returns the id.
-	 */
-	public long getId()
-	{
-		return id;
-	}
+    /**
+     * @return Returns the config.
+     */
+    public Dg100Config getConfig()
+    {
+        return config;
+    }
+
+    /**
+     * @return Returns the id.
+     */
+    public long getId()
+    {
+        return id;
+    }
 
 }
Index: applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatConfigDialog.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatConfigDialog.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatConfigDialog.java	(revision 12778)
@@ -50,5 +50,5 @@
 /**
  * Configuration download dialog.
- * 
+ *
  * @author Raphael Mack <ramack@raphael-mack.de>
  *
@@ -58,11 +58,11 @@
 
     public class IntegerTextField extends JTextField {
-        
+
         final static String badchars = "-`~!@#$%^&*()_+=\\|\"':;?/>.<, ";
-        
+
         public void processKeyEvent(KeyEvent ev) {
 
             char c = ev.getKeyChar();
-            if((Character.isLetter(c) && !ev.isAltDown()) 
+            if((Character.isLetter(c) && !ev.isAltDown())
                || badchars.indexOf(c) > -1) {
                 ev.consume();
@@ -74,5 +74,5 @@
 
 
-	
+
     // the JOptionPane that contains this dialog. required for the closeDialog() method.
     private JOptionPane optionPane;
@@ -103,5 +103,5 @@
 
     private List<CommPortIdentifier> ports = new LinkedList<CommPortIdentifier>();
-    
+
     private Dg100Config conf;
 
@@ -132,5 +132,5 @@
         logFormat.add(formatPosTDS);
         logFormat.add(formatPosTDSA);
-        
+
         JPanel logPanel = new JPanel();
         logPanel.setLayout(new BoxLayout(logPanel, BoxLayout.PAGE_AXIS));
@@ -209,5 +209,5 @@
         minLogSpeed.setText("" + conf.getSpeedThres());
         minLogDist.setText("" + conf.getDistThres());
-        
+
         ButtonGroup group = new ButtonGroup();
         group.add(aTime);
@@ -261,9 +261,9 @@
         c.gridy = 6;
         add(bMeters, c);
-        
+
         group = new ButtonGroup();
         group.add(cTime);
         group.add(cDist);
-        
+
         c.insets = new Insets(4,4,0,4);
         c.gridwidth = 1;
@@ -307,5 +307,5 @@
             JOptionPane.showMessageDialog(Main.parent, tr("Unknown logFormat"));
         }
-            
+
         if(conf.getSwATimeOrDist() == 0){
             aTime.setSelected(true);
Index: applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatDg100.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatDg100.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatDg100.java	(revision 12778)
@@ -45,6 +45,6 @@
 
     public static final int TIMEOUT = 2000;
-    public static final int TRACK_TYPE = 1; 
-    
+    public static final int TRACK_TYPE = 1;
+
     /** delete file: A0 A2 00 02 BC 01 00 BD B0 B3 */
     private static byte dg100CmdSwitch2Nmea[] =
@@ -111,12 +111,12 @@
       , (byte) 0x00, (byte) 0x00, (byte) 0x00, (byte) 0x00
       , (byte) 0x00, (byte) 0xC0, (byte) 0xB0, (byte) 0xB3};
-    
+
     private byte[] response = new byte[65536];
-    
+
     private CommPortIdentifier portIdentifier;
     private SerialPort port = null;
 
     private boolean cancelled = false;
-    
+
     public GlobalsatDg100(CommPortIdentifier portId){
         this.portIdentifier = portId;
@@ -178,5 +178,5 @@
         return result;
     }
-    
+
     public void deleteData() throws ConnectionException{
         if(port == null){
@@ -189,5 +189,5 @@
         }
     }
-    
+
     public void disconnect(){
         if(port != null){
@@ -210,5 +210,5 @@
         }
     }
-    
+
     private List<FileInfoRec> readFileInfoList() throws ConnectionException
     {
@@ -226,10 +226,10 @@
         }
     }
- 
+
     public List<GpsRec> readGpsRecList(List<FileInfoRec> fileInfoList) throws ConnectionException
     {
         int cnt = 0;
         List<GpsRec> result = new ArrayList<GpsRec>(200);
-        
+
         try{
             for(FileInfoRec fileInfoRec:fileInfoList){
@@ -243,5 +243,5 @@
         }
     }
- 
+
     private Response sendCmdDelFiles() throws IOException, UnsupportedCommOperationException
     {
@@ -317,5 +317,5 @@
         return Response.parseResponse(response, len);
     }
-    
+
     /**
      *
@@ -348,5 +348,5 @@
     }
 
-    
+
     private int readResponse(byte[] response, int bytesToRead) throws IOException, UnsupportedCommOperationException
     {
@@ -396,5 +396,5 @@
             }
             return ((cntBytTot > bytesToRead) ? bytesToRead : cntBytTot);
-	}
+    }
         return -1;
     }
Index: applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatImportDialog.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatImportDialog.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatImportDialog.java	(revision 12778)
@@ -39,10 +39,10 @@
 /**
  * Main download dialog.
- * 
+ *
  * @author Raphael Mack <ramack@raphael-mack.de>
  *
  */
 public class GlobalsatImportDialog extends JPanel {
-	
+
     // the JOptionPane that contains this dialog. required for the closeDialog() method.
     private JOptionPane optionPane;
@@ -111,5 +111,5 @@
                     System.out.println("configureing the device");
                     try{
-                        
+
                         GlobalsatConfigDialog dialog = new GlobalsatConfigDialog(GlobalsatPlugin.dg100().getConfig());
                         JOptionPane pane = new JOptionPane(dialog, JOptionPane.PLAIN_MESSAGE, JOptionPane.OK_CANCEL_OPTION);
@@ -136,5 +136,5 @@
         add(configBtn, c);
 
-        
+
         delete = new JCheckBox(tr("delete data after import"));
         delete.setSelected(Main.pref.getBoolean("globalsat.deleteAfterDownload", false));
@@ -167,5 +167,5 @@
 
     }
-	
+
     public boolean deleteFilesAfterDownload(){
         return delete.isSelected();
Index: applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatPlugin.java
===================================================================
--- applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatPlugin.java	(revision 12707)
+++ applications/editors/josm/plugins/globalsat/src/org/openstreetmap/josm/plugins/globalsat/GlobalsatPlugin.java	(revision 12778)
@@ -106,5 +106,5 @@
         }
     }
-    
+
     class GlobalsatImportAction extends JosmAction{
         public GlobalsatImportAction(){
