Date   

Re: TNC-PI Checksum error

J. Adam Sowers <adam.sowers@...>
 

Hi John,

Is there a repository (GitHub or something like it) where we can keep track of the latest version of the pitnc_[g|s]etparams programs? I had a tough time finding a valid link a month or so ago (the one in the docs didn't work) and I'd love to have one place to go to to get the latest version, add feature requests, etc. 

Thanks,
Adam


On Sun, Apr 8, 2018 at 11:31 AM, John Wiseman <john.wiseman@...> wrote:
Ok, Steve.

Thanks for letting me know.

73,
John

________________________________________
From: RaspberryPi-4-HamRadio@groups.io
[mailto:RaspberryPi-4-HamRadio@groups.io] On Behalf Of Steve Jones via
Groups.Io
Sent: 08 April 2018 14:22
To: RaspberryPi-4-HamRadio@groups.io
Subject: Re: [RaspberryPi-4-HamRadio] TNC-PI Checksum error

I have tried the new version (PITNCParamsApr18) and it looks good.
It now displays version of the pitnc_(g/s)etparams as 0.0.0.5

Below is the output from a couple of my tests:

************************************************************ Output start

pi@raspberrypi:~ $ ./pitnc_getparams 0 0
pitnc_getparams Version 0.0.0.5

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     14
8 1 0 40 a 0 0 0 0 e 4d c0 sum 0
pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2
pitnc_setparams Version 0.0.0.5
pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20
pitnc_setparams Version 0.0.0.5

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     14
8 1 14 40 a 0 0 0 0 e 59 c0 sum 0
pi@raspberrypi:

************************************************************ Output end


I will be doing more testing and will let you know if I find anything funny.

Thanks for your work and looking forward to moving forward with this!

Let me know if I can help in any way.

Steve KA6PRW






On Saturday, April 7, 2018, 2:12:43 PM PDT, John Wiseman
<john.wiseman@...> wrote:


Steve,

I think this will fix it.

http://www.cantab.net/users/john.wiseman/Downloads/PITNCParamsApr18.zip

Could you test and let me know?

Thanks,
John G8BPQ
On 07/04/2018 18:34, John Wiseman wrote:
I think it is a bug in pitnc_get/set when the checksum (or in fact any other
character) is 0E. That character is used in i2c polling to indicate nothing
available, but is being being incorrectly ignored in get/set. I'll looking
into a fix.

73,
John
On 07/04/2018 17:45, ka2dew Tadd wrote:
I thought I saw a 1 in his PIC firmware version.  Could that be the deal?
Tadd --- Sent from Planet X
http://tarpn.net   

On Apr 7, 2018, at 12:43 PM, John Wiseman <john.wiseman@...> wrote:
Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For
some reason your TNC isn't sending the checksum, so the final sum is
non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but
it would be nice to know what is happening. Do you get the same problem if
you change some of the registers?

73,
John


On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone
into the ether.

Thanks John for your update.  The new version does print PIC version (1),
but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was
pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I
am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I
also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 =
0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d =
0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the
sources that were in the zip, but I am getting an 'undefined error:
FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW








Re: TNC-PI Checksum error

John G8BPQ
 

Ok, Steve.

Thanks for letting me know.

73,
John

________________________________________
From: RaspberryPi-4-HamRadio@groups.io
[mailto:RaspberryPi-4-HamRadio@groups.io] On Behalf Of Steve Jones via
Groups.Io
Sent: 08 April 2018 14:22
To: RaspberryPi-4-HamRadio@groups.io
Subject: Re: [RaspberryPi-4-HamRadio] TNC-PI Checksum error

I have tried the new version (PITNCParamsApr18) and it looks good.
It now displays version of the pitnc_(g/s)etparams as 0.0.0.5

Below is the output from a couple of my tests:

************************************************************ Output start

pi@raspberrypi:~ $ ./pitnc_getparams 0 0
pitnc_getparams Version 0.0.0.5

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     14
8 1 0 40 a 0 0 0 0 e 4d c0 sum 0
pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2
pitnc_setparams Version 0.0.0.5
pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20
pitnc_setparams Version 0.0.0.5

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     14
8 1 14 40 a 0 0 0 0 e 59 c0 sum 0
pi@raspberrypi:

************************************************************ Output end


I will be doing more testing and will let you know if I find anything funny.

Thanks for your work and looking forward to moving forward with this!

Let me know if I can help in any way.

Steve KA6PRW

On Saturday, April 7, 2018, 2:12:43 PM PDT, John Wiseman
<john.wiseman@cantab.net> wrote:


Steve,

I think this will fix it.

http://www.cantab.net/users/john.wiseman/Downloads/PITNCParamsApr18.zip

Could you test and let me know?

Thanks,
John G8BPQ
On 07/04/2018 18:34, John Wiseman wrote:
I think it is a bug in pitnc_get/set when the checksum (or in fact any other
character) is 0E. That character is used in i2c polling to indicate nothing
available, but is being being incorrectly ignored in get/set. I'll looking
into a fix.

73,
John
On 07/04/2018 17:45, ka2dew Tadd wrote:
I thought I saw a 1 in his PIC firmware version.  Could that be the deal?
Tadd --- Sent from Planet X
http://tarpn.net   

On Apr 7, 2018, at 12:43 PM, John Wiseman <john.wiseman@cantab.net> wrote:
Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For
some reason your TNC isn't sending the checksum, so the final sum is
non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but
it would be nice to know what is happening. Do you get the same problem if
you change some of the registers?

73,
John


On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone
into the ether.

Thanks John for your update.  The new version does print PIC version (1),
but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was
pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I
am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I
also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 =
0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d =
0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the
sources that were in the zip, but I am getting an 'undefined error:
FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW


Re: TNC-PI Checksum error

Steve (KA6PRW)
 

I have tried the new version (PITNCParamsApr18) and it looks good.
It now displays version of the pitnc_(g/s)etparams as 0.0.0.5

Below is the output from a couple of my tests:

************************************************************ Output start

pi@raspberrypi:~ $ ./pitnc_getparams 0 0
pitnc_getparams Version 0.0.0.5

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     14
8 1 0 40 a 0 0 0 0 e 4d c0 sum 0
pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2
pitnc_setparams Version 0.0.0.5
pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20
pitnc_setparams Version 0.0.0.5

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     14
8 1 14 40 a 0 0 0 0 e 59 c0 sum 0
pi@raspberrypi:

************************************************************ Output end


I will be doing more testing and will let you know if I find anything funny.

Thanks for your work and looking forward to moving forward with this!

Let me know if I can help in any way.

Steve KA6PRW







On Saturday, April 7, 2018, 2:12:43 PM PDT, John Wiseman <john.wiseman@...> wrote:


Steve,

I think this will fix it.

http://www.cantab.net/users/john.wiseman/Downloads/PITNCParamsApr18.zip

Could you test and let me know?

Thanks,
John G8BPQ

On 07/04/2018 18:34, John Wiseman wrote:
I think it is a bug in pitnc_get/set when the checksum (or in fact any other character) is 0E. That character is used in i2c polling to indicate nothing available, but is being being incorrectly ignored in get/set. I'll looking into a fix.

73,
John

On 07/04/2018 17:45, ka2dew Tadd wrote:
I thought I saw a 1 in his PIC firmware version.  Could that be the deal?

Tadd --- Sent from Planet X

On Apr 7, 2018, at 12:43 PM, John Wiseman <john.wiseman@...> wrote:

Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For some reason your TNC isn't sending the checksum, so the final sum is non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but it would be nice to know what is happening. Do you get the same problem if you change some of the registers?

73,
John



On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone into the ether.

Thanks John for your update.  The new version does print PIC version (1), but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 = 0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d = 0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the sources that were in the zip, but I am getting an 'undefined error: FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW




--
Steve Jones
KA6PRW


Re: TNC-PI Checksum error

Steve (KA6PRW)
 

Yes will test in morning.  
Have been out and about today.
Thanks for the efforts.

Steve KA6PRW

On ‎Saturday‎, ‎April‎ ‎7‎, ‎2018‎ ‎02‎:‎12‎:‎43‎ ‎PM‎ ‎PDT, John Wiseman <john.wiseman@...> wrote:


Steve,

I think this will fix it.

http://www.cantab.net/users/john.wiseman/Downloads/PITNCParamsApr18.zip

Could you test and let me know?

Thanks,
John G8BPQ

On 07/04/2018 18:34, John Wiseman wrote:
I think it is a bug in pitnc_get/set when the checksum (or in fact any other character) is 0E. That character is used in i2c polling to indicate nothing available, but is being being incorrectly ignored in get/set. I'll looking into a fix.

73,
John

On 07/04/2018 17:45, ka2dew Tadd wrote:
I thought I saw a 1 in his PIC firmware version.  Could that be the deal?

Tadd --- Sent from Planet X

On Apr 7, 2018, at 12:43 PM, John Wiseman <john.wiseman@...> wrote:

Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For some reason your TNC isn't sending the checksum, so the final sum is non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but it would be nice to know what is happening. Do you get the same problem if you change some of the registers?

73,
John



On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone into the ether.

Thanks John for your update.  The new version does print PIC version (1), but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 = 0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d = 0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the sources that were in the zip, but I am getting an 'undefined error: FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW




--
Steve Jones
KA6PRW


Re: TNC-PI Checksum error

John G8BPQ
 

Steve,

I think this will fix it.

http://www.cantab.net/users/john.wiseman/Downloads/PITNCParamsApr18.zip

Could you test and let me know?

Thanks,
John G8BPQ

On 07/04/2018 18:34, John Wiseman wrote:
I think it is a bug in pitnc_get/set when the checksum (or in fact any other character) is 0E. That character is used in i2c polling to indicate nothing available, but is being being incorrectly ignored in get/set. I'll looking into a fix.

73,
John

On 07/04/2018 17:45, ka2dew Tadd wrote:
I thought I saw a 1 in his PIC firmware version.  Could that be the deal?

Tadd --- Sent from Planet X

On Apr 7, 2018, at 12:43 PM, John Wiseman <john.wiseman@...> wrote:

Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For some reason your TNC isn't sending the checksum, so the final sum is non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but it would be nice to know what is happening. Do you get the same problem if you change some of the registers?

73,
John



On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone into the ether.

Thanks John for your update.  The new version does print PIC version (1), but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 = 0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d = 0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the sources that were in the zip, but I am getting an 'undefined error: FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW




Re: Stratum One NTP server using a RPi

 

Yes.


On Sat, Apr 7, 2018, 05:11 WA7SKG via Groups.Io <wa7skg=yahoo.com@groups.io> wrote:
Just looked up the Adafruit Ultimate GPS Hat. Neat device! Can it be
used with a TNC-Pi for APRS? Right now I'm using a USB GPS puck, but I'm
wondering if this might also be a viable option to free up a USB port.

Michael WA7SKG


John D Hays - K7VE wrote on 04/02/2018 10:50 PM:
> Yes, I have been running one for a couple of months.
>
> I used the Adafruit Ultimate GPS Hat.
>
> On Mon, Apr 2, 2018, 22:32 w4oa@... <mailto:w4oa@...>
> <w4oa@... <mailto:w4oa@...>> wrote:
>
>     Anyone using a RPi with a gps as a NTP server? Should work wonders
>     for FT8, even if is total overkill. :)
>
>     I am working on one using an Adafruit gps, got it working today.
>     Will be checking accuracy over the next few days. The biggest hassle
>     so far is the wonky serial port/bluetooth port on the Pi.
>
>     Mitch W4OA
>




Re: TNC-PI Checksum error

John G8BPQ
 

I think it is a bug in pitnc_get/set when the checksum (or in fact any other character) is 0E. That character is used in i2c polling to indicate nothing available, but is being being incorrectly ignored in get/set. I'll looking into a fix.

73,
John

On 07/04/2018 17:45, ka2dew Tadd wrote:
I thought I saw a 1 in his PIC firmware version.  Could that be the deal?

Tadd --- Sent from Planet X

On Apr 7, 2018, at 12:43 PM, John Wiseman <john.wiseman@...> wrote:

Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For some reason your TNC isn't sending the checksum, so the final sum is non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but it would be nice to know what is happening. Do you get the same problem if you change some of the registers?

73,
John



On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone into the ether.

Thanks John for your update.  The new version does print PIC version (1), but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 = 0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d = 0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the sources that were in the zip, but I am getting an 'undefined error: FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW



Re: TNC-PI Checksum error

Steve (KA6PRW)
 

Yes - the version reports as "1". 
I get the same response (checksum error = 0xe) if I read (all) or write any register.
Steve


On Saturday, April 7, 2018, 9:45:36 AM PDT, ka2dew Tadd <tadd@...> wrote:


I thought I saw a 1 in his PIC firmware version.  Could that be the deal?

Tadd --- Sent from Planet X

On Apr 7, 2018, at 12:43 PM, John Wiseman <john.wiseman@...> wrote:

Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For some reason your TNC isn't sending the checksum, so the final sum is non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but it would be nice to know what is happening. Do you get the same problem if you change some of the registers?

73,
John



On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone into the ether.

Thanks John for your update.  The new version does print PIC version (1), but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 = 0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d = 0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the sources that were in the zip, but I am getting an 'undefined error: FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW


--
Steve Jones
KA6PRW


Re: TNC-PI Checksum error

 

I thought I saw a 1 in his PIC firmware version.  Could that be the deal?

Tadd --- Sent from Planet X

On Apr 7, 2018, at 12:43 PM, John Wiseman <john.wiseman@...> wrote:

Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For some reason your TNC isn't sending the checksum, so the final sum is non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but it would be nice to know what is happening. Do you get the same problem if you change some of the registers?

73,
John



On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone into the ether.

Thanks John for your update.  The new version does print PIC version (1), but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 = 0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d = 0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the sources that were in the zip, but I am getting an 'undefined error: FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW


Re: TNC-PI Checksum error

John G8BPQ
 

Steve,

Something odd going on..

I get
    TNC Software Version           3
01 TXDelay - Zero means use ADC  50
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         3
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     34
8 3 32 40 a 3 0 0 0 22 52 c0 sum 0

As you can see, there is one more byte, the checksum, before the c0. For some reason your TNC isn't sending the checksum, so the final sum is non-zero.

I suppose as it seems be working perhaps it isn't worth worrying about, but it would be nice to know what is happening. Do you get the same problem if you change some of the registers?

73,
John



On 07/04/2018 14:35, Steve Jones via Groups.Io wrote:
Sorry if this is a double post - but my previous reply appears to have gone into the ether.

Thanks John for your update.  The new version does print PIC version (1), but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 = 0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d = 0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the sources that were in the zip, but I am getting an 'undefined error: FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW


Re: TNC-PI Checksum error

Steve (KA6PRW)
 

Sorry if this is a double post - but my previous reply appears to have gone into the ether.

Thanks John for your update.  The new version does print PIC version (1), but still pesky checksum error. Always '0xe' from what I am seeing.
           I believe the version of pitnc_get/set that I was using was pointed to by the TNC-PI assembly manual online?
                            I have tried to get the correct versions, so I am not clear what happened there.


Note that when I manually do the xor checksum on the data examples below, I also get a '0xe' as the result:
               8 xor 1 xor 14 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 59 = 0xe
               8 xor 1 xor 00 xor 40 xor a xor 0 xor 0 xor 0 xor 0 xor 4d = 0xe

I tried both 'get' and 'set' and through in a reset "15 2", for good luck.
After all these, the checksum error remained. 

EXAMPLE #1 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 1 20

   PIC Software Version           1
01 TXDelay - Zero means use ADC  20
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     89
8 1 14 40 a 0 0 0 0 59 c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #2 *****************************************

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

EXAMPLE #3 *****************************************

pi@raspberrypi:~ $ ./pitnc_setparams 0 0 15 2

pi@raspberrypi:~ $ ./pitnc_getparams 0 0

Using Serial port /dev/ttyAMA0

   TNC Software Version           1
01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
** Checksum Error - Sum = e Should be Zero

Any suggestions? 
Quite willing to look at code if that might help.  I tried compiling the sources that were in the zip, but I am getting an 'undefined error: FIONBIO'.
               I will continue to look at that.

--
Steve Jones
KA6PRW


Re: Stratum One NTP server using a RPi

WA7SKG <wa7skg@...>
 

Just looked up the Adafruit Ultimate GPS Hat. Neat device! Can it be used with a TNC-Pi for APRS? Right now I'm using a USB GPS puck, but I'm wondering if this might also be a viable option to free up a USB port.

Michael WA7SKG


John D Hays - K7VE wrote on 04/02/2018 10:50 PM:

Yes, I have been running one for a couple of months.
I used the Adafruit Ultimate GPS Hat.
On Mon, Apr 2, 2018, 22:32 w4oa@arrl.net <mailto:w4oa@arrl.net> <w4oa@arrl.net <mailto:w4oa@arrl.net>> wrote:
Anyone using a RPi with a gps as a NTP server? Should work wonders
for FT8, even if is total overkill. :)
I am working on one using an Adafruit gps, got it working today.
Will be checking accuracy over the next few days. The biggest hassle
so far is the wonky serial port/bluetooth port on the Pi.
Mitch W4OA


Re: Stratum One NTP server using a RPi

WA7SKG <wa7skg@...>
 

Last year for Field Day, I set up an RPi and a wireless router for our logging computers to use. As there was no Internet access at the FD site, I connected a USB GPS puck to the RPi (~$35 Amazon device). The RPi served NTP, DHCP, and central file server for all computers on site. Worked great. Used the same setup for some remote FT8 ops just for time purposes.

73,
Michael WA7SKG


w4oa@arrl.net wrote on 04/02/2018 10:31 PM:

Anyone using a RPi with a gps as a NTP server? Should work wonders for FT8, even if is total overkill. :)
I am working on one using an Adafruit gps, got it working today. Will be checking accuracy over the next few days. The biggest hassle so far is the wonky serial port/bluetooth port on the Pi.
Mitch W4OA


Re: TNC-PI Checksum error

John G8BPQ
 

Steve,

It looks like you are using an old version of pitnc_getparams (it should display the TNC Software version before the TXDelay line).
You can download the latest from http://www.cantab.net/users/john.wiseman/Downloads/NewPITNCParams.zip. Try that and see if it helps.

73,
John G8BPQ

On 06/04/2018 23:49, Steve Jones via Groups.Io wrote:
Hello all:
First time posting in this group, so please excuse me  if I did not search deep enough for this question - but I did search and found nothing related:

I have a TNC-PI (40 Pin connector version) on a Raspberry PI.  I can communicate to the board via the PI's UART input and, additionally via the i2c addresses if I set up for that.
The issue I am having is that in both cases (UART and I2C connections) I appear to be getting a checksum error for both the 'pitnc_setparams' and the 'pitnc_getparams' commands.

Funny thing is that both of these commands do seem to work correctly - e.g. I can "set and get" parameters correctly but still get the checksum error. 

The following is an example of what I am seeing:
 
pi@raspberrypi:~ $ ./pitnc_getparams 0 0

** Checksum Error - Sum = e Should be Zero

01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
 

Does anyone have ANY idea why this may be happening or what to check next?
Additionally, I have tried this on two separate Raspberry Pi's and I get the same response on both.

Thanks!
--
Steve Jones
KA6PRW


Re: Writing the RPi iso image to SD card with Mac and ApplePi-Baker

J. Adam Sowers <adam.sowers@...>
 

+1 for etcher. Cross-platform and works great. I was never a fan of the way ApplePi-Baker doesn’t use the OS method of asking for admin access. 

Adam KJ4DEO 



On Fri, Apr 6, 2018 at 10:26 PM Perry Ogletree <pogletree@...> wrote:

The free Etcher for Windows is simple and works too… not everyone is on a Mac (and Etcher works on Mac and Linux as well!)

 

Perry K4PWO

 

From: RaspberryPi-4-HamRadio@groups.io <RaspberryPi-4-HamRadio@groups.io> On Behalf Of w4oa@...
Sent: Friday, April 6, 2018 8:49 AM
To: RaspberryPi-4-HamRadio@groups.io
Subject: [RaspberryPi-4-HamRadio] Writing the RPi iso image to SD card with Mac and ApplePi-Baker

 

A great ham (read FREE) program that I have been using to write RPi images to SD cards is ApplePi-Baker, available for the Mac at https://www.tweaking4all.com/. (No snide comments on the site name, please!)

 

Using the program, I first “Prep for Noobs” which does a standard format of the card. Then select your image file, and write the image to the card with “Restore Backup”.

 

I have been using the program since the RPi 2 with good success.

 

Mitch W4OA


Re: Writing the RPi iso image to SD card with Mac and ApplePi-Baker

Perry Ogletree
 

The free Etcher for Windows is simple and works too… not everyone is on a Mac (and Etcher works on Mac and Linux as well!)

 

Perry K4PWO

 

From: RaspberryPi-4-HamRadio@groups.io <RaspberryPi-4-HamRadio@groups.io> On Behalf Of w4oa@...
Sent: Friday, April 6, 2018 8:49 AM
To: RaspberryPi-4-HamRadio@groups.io
Subject: [RaspberryPi-4-HamRadio] Writing the RPi iso image to SD card with Mac and ApplePi-Baker

 

A great ham (read FREE) program that I have been using to write RPi images to SD cards is ApplePi-Baker, available for the Mac at https://www.tweaking4all.com/. (No snide comments on the site name, please!)

 

Using the program, I first “Prep for Noobs” which does a standard format of the card. Then select your image file, and write the image to the card with “Restore Backup”.

 

I have been using the program since the RPi 2 with good success.

 

Mitch W4OA


Re: Easy RPi headless configuration - enable SSH and WiFi before booting Stretch

Perry Ogletree
 

It’s interesting that the configuration utility sets the WiFi country as JP (Japan) instead of US.  I find it much easier to tell newbies to do the “ssh” file trick and then run raspi-config.  It will set up the WiFi for you,

 

Perry K4PWO

 

From: RaspberryPi-4-HamRadio@groups.io <RaspberryPi-4-HamRadio@groups.io> On Behalf Of w4oa@...
Sent: Thursday, April 5, 2018 10:42 AM
To: RaspberryPi-4-HamRadio@groups.io
Subject: [RaspberryPi-4-HamRadio] Easy RPi headless configuration - enable SSH and WiFi before booting Stretch

 

[Edited Message Follows]

If you run your Raspberry Pi headless (no keyboard or monitor), you know what a pain it is to get it configured, now that SSH is disabled in Stretch. This especially true with the RPi Zero and Zero W, with no Ethernet port.

 

There has to be an easier way! With a little digging, there is an easier way.

 

AFTER writing your image to the SD card, your /boot partition is accessible on your Mac, Linux, or Win box. Create an empty file “ssh”, no extension (no quotes) in the /boot partition. This will enable SSH login for the first boot. On your Mac or Linux box, the command to create an empty file is “touch ssh” (no quotes).

 

To enable wireless access on boot, create the “wpa_supplicant.conf” file (no quotes) for your wireless network using the pistar.uk Pi-Star Tools WiFiBuilder http://www.pistar.uk/wifi_builder.php on the pistar.uk website. Copy that file to the SD card /boot partition.

 

Put the SD card in your RPi, wait for it to boot, find its wireless ip or Ethernet ip address, log in via SSH, (user pi password raspberry) and then run sudo raspi-config to finish your configuration.

 

Mitch W4OA

- Corrected to state you create the empty ssh file and write the wifi config file AFTER you write the RPi image to the SD card.

 


Re: Easy RPi headless configuration - enable SSH and WiFi before booting Stretch

Tony
 

It's easy when one uses Linux:

# fdisk -l 2018-03-13-compass.img

Disk 2018-03-13-compass.img: 4.2 GiB, 4453302272 bytes, 8697856 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xa8e4691c

Device                  Boot  Start     End Sectors  Size Id Type
2018-03-13-compass.img1        8192  143359  135168   66M  c W95 FAT32 (LBA)
2018-03-13-compass.img2      143360 8697855 8554496  4.1G 83 Linux

# mount -o rw,offset=$((8192*512)) 2018-03-13-compass.img /mnt
# touch /mnt/ssh

We use wpa_passphrase to generate the wifi file:

# wpa_passphrase myssid mypasswd > /mnt/wpa_supplicant.conf
# umount /mnt

pv (pipeviewer) gives us a progress report, as dd works silently:

# pv 2018-03-13-compass.img | dd bs=4M of=/dev/sdb
4.15GiB 0:10:37 [6.66MiB/s] [====================================>] 100%           
135+11078 records in
135+11078 records out
4453302272 bytes (4.5 GB) copied, 842.858 s, 5.3 MB/s

The card is inserted in the (headless) RPi and booted. The new IP address on the network is easily visible, since everything else is already in our /etc/hosts:

# nmap -sn 192.168.1.0/24
...
Nmap scan report for 192.168.1.7
Host is up (0.014s latency).
MAC Address: B8:27:EB:4F:A3:08 (Raspberry Pi Foundation)
...

So we ssh to it, change passwords, enable permanent ssh and edit the sshd_config file to set a different port, etc:

$ ssh -l pi 192.168.1.7
The authenticity of host '192.168.1.7 (192.168.1.7)' can't be established.
ECDSA key fingerprint is 2c:82:17:80:db:d2:6b:63:5d:86:1b:ee:f8:e0:71:7e.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '192.168.1.7' (ECDSA) to the list of known hosts.
pi@....7's password:

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sat Apr  7 00:27:41 2018

SSH is enabled and the default password for the 'pi' user has not been changed.
This is a security risk - please login as the 'pi' user and type 'passwd' to set a new password.

pi@compass:~ $ sudo su -
... (same warning as above)
root@compass:~# passwd
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
root@compass:~# passwd pi
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
root@compass:~# vi /etc/ssh/sshd_config
root@compass:~# systemctl enable ssh
Synchronizing state for ssh.service with sysvinit using update-rc.d...
Executing /usr/sbin/update-rc.d ssh defaults
Executing /usr/sbin/update-rc.d ssh enable
Created symlink from /etc/systemd/system/sshd.service to /lib/systemd/system/ssh.service.
root@compass:~# raspi-config
... (expand filesystem)
... (change hostname)
... (etc., finish)

Then of course update/upgrade the OS, add additional packages of interest, etc.

And get rid of the annoying howdy-doody login message of the day (motd):

# > /etc/motd


On 04/06/2018 07:50 AM, David Ranch wrote:
Hello Mitch

To enable wireless access on boot, create the “wpa_supplicant.conf” file (no quotes) for your wireless network using the pistar.uk Pi-Star Tools WiFiBuilder http://www.pistar.uk/wifi_builder.php on the pistar.uk website. Copy that file to the SD card /boot partition.

I just looked at this Wifi configuration tool and it doesn't look like it's going to create useful Wifi configuration files.  I put in a simple wifi SSID name and pre-shared key (PSK) and it output:
--
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
ap_scan=1
fast_reauth=1
country=JP

network={
        ssid="tester-wifi"
        psk="dude"
        id_str="0"
        priority=100
}
--


There isn't any mention of:

   - configure the required "nl80211" driver for the Raspberry Pi hardware
   - the country code is wrong (well, for me at least)
   - Enable some best practices like:
      - disabling of old 802.11b support
      - enabling of 802.11n and now ac
      - turning on WPA2 security

--David
KI6ZHD


TNC-PI Checksum error

Steve (KA6PRW)
 

Hello all:
First time posting in this group, so please excuse me  if I did not search deep enough for this question - but I did search and found nothing related:

I have a TNC-PI (40 Pin connector version) on a Raspberry PI.  I can communicate to the board via the PI's UART input and, additionally via the i2c addresses if I set up for that.
The issue I am having is that in both cases (UART and I2C connections) I appear to be getting a checksum error for both the 'pitnc_setparams' and the 'pitnc_getparams' commands.

Funny thing is that both of these commands do seem to work correctly - e.g. I can "set and get" parameters correctly but still get the checksum error. 

The following is an example of what I am seeing:
 
pi@raspberrypi:~ $ ./pitnc_getparams 0 0

** Checksum Error - Sum = e Should be Zero

01 TXDelay - Zero means use ADC   0
02 Persistance                   64
03 Slottime (in 10 mS)           10
04 TXTail                         0
05 Full Duplex - Not used         0
06 Our Channel (Hex)             00
07 I2C Address (0 = async) Hex   00
   ADC Value                     77
8 1 0 40 a 0 0 0 0 4d c0 sum e
 

Does anyone have ANY idea why this may be happening or what to check next?
Additionally, I have tried this on two separate Raspberry Pi's and I get the same response on both.

Thanks!
--
Steve Jones
KA6PRW


Re: Writing the RPi iso image to SD card with Mac and ApplePi-Baker

Mark Dymek <markdymek@...>
 

i second the recommendation of apple-pi baker. you can also use disk utility if your more of a do it yourselfer. i used apple-pi baker.

On Fri, Apr 6, 2018 at 9:48 AM w4oa@... <w4oa@...> wrote:

A great ham (read FREE) program that I have been using to write RPi images to SD cards is ApplePi-Baker, available for the Mac at https://www.tweaking4all.com/. (No snide comments on the site name, please!)

 

Using the program, I first “Prep for Noobs” which does a standard format of the card. Then select your image file, and write the image to the card with “Restore Backup”.

 

I have been using the program since the RPi 2 with good success.

 

Mitch W4OA



--
KB1WAG

Mark Daniel Dymek 

6021 - 6040 of 13916