Need help with TNCPI96K and ARDOP


N3RDR
 

Need some help programming my TNCPI96K with the ARDOP firmware.  I followed the directions but when compiling it results in "ARDOP not defined in TeensyConfig.h"

I am using MacOS X.


John G8BPQ
 

What instructions are you following?

Did you follow the instructions in README.txt in the top level of the TeensyProjects download?

73,
John G8BPQ

On 03/07/2018 04:40, kc3ccd@... wrote:
Need some help programming my TNCPI96K with the ARDOP firmware.  I followed the directions but when compiling it results in "ARDOP not defined in TeensyConfig.h"

I am using MacOS X.


John
 

I suspect he is talking about the instructions in the TNCPi9K6 manual.  That includes the instructions about copying boards.txt and platform.txt and resetting the Sketchbook location.  I wonder if this has something to do with compiling on a Mac.  I don't have access to a Mac here and so I've never tested the arduino compiler on that platform.

John W2FS
Coastal ChipWorks

On Tue, Jul 3, 2018 at 3:05 AM, John Wiseman <john.wiseman@...> wrote:
What instructions are you following?

Did you follow the instructions in README.txt in the top level of the TeensyProjects download?

73,
John G8BPQ

On 03/07/2018 04:40, kc3ccd@... wrote:
Need some help programming my TNCPI96K with the ARDOP firmware.  I followed the directions but when compiling it results in "ARDOP not defined in TeensyConfig.h"

I am using MacOS X.



N3RDR
 

I followed the instructions from the TNC and the readme file. It is tricky in the Mac since the location to place those files is not the traditional Mac folder location. It requires to display the content of the app to see those folders. I also tried moving the Teensy folder location since the instructions of the TNC say to place it on the same location where Arduino was installed. I updated the preferences accordingly but had the same result. 

I was tempted to add the define statement to see if it is a matter of not finding the header file but it seems to be finding other files on the same location so I left it alone. 


John G8BPQ
 

The code should #define ARDOP if the ARDOP project is selected in the IDE, but it could be there is something different in the Mac environment. It shouldn't do any harm to add #define ARDOP to TeensyConfig.h. But you will have to change it if you want to build the Packet software.

73,
John

On 04/07/2018 04:52, kc3ccd@... wrote:
I followed the instructions from the TNC and the readme file. It is tricky in the Mac since the location to place those files is not the traditional Mac folder location. It requires to display the content of the app to see those folders. I also tried moving the Teensy folder location since the instructions of the TNC say to place it on the same location where Arduino was installed. I updated the preferences accordingly but had the same result. 

I was tempted to add the define statement to see if it is a matter of not finding the header file but it seems to be finding other files on the same location so I left it alone. 


N3RDR
 

Well, do I have to build it in order to program it? It seems to me there's a prebuilt included in the project folder. Not knowing how to do it I simply followed the TNC instructions and the bring me to having to build.


John G8BPQ
 

You may be able to program the prebuilt binary by starting the IDE and pressing the program button on the Teensy. It usually works on Windows but I don't know about on a Mac. But it will use whatever interface options are set in the supplied TeensyConfigARDOP.h, which may not be what you need.

73,
John

On 04/07/2018 15:06, kc3ccd@... wrote:
Well, do I have to build it in order to program it? It seems to me there's a prebuilt included in the project folder. Not knowing how to do it I simply followed the TNC instructions and the bring me to having to build.


N3RDR
 

I tried to compile. I saw TeensyWrapper.c has #define ARDOP.  TeensyConfig.h is looking for PROJECT_ARDOP_Teensy in order to define ARDOP (yup, it is defined twice, not sure why) so I added #define PROJECT_ARDOP_Teensy in ARDOP_Teensy file.  Now the errors are below. I also pushed the button and nothing happened. Troubleshooting that.

Arduino: 1.8.5 (Mac OS X), TD: 1.42, Board: "Teensy 3.6, Serial, 180 MHz, Faster, US English"
 
In file included from /Documents/Ham/Arduino/TeensyProjects/ARDOP_Teensy/ARDOP_Teensy.ino:61:0:
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/../../ARDOPC/ARDOPC.h:11:0: warning: "SendSize" redefined
 #define SendSize 1200  // 100 mS for now
 
 ^
In file included from /Documents/Ham/Arduino/TeensyProjects/ARDOP_Teensy/ARDOP_Teensy.ino:8:0:
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.h:47:0: note: this is the location of the previous definition
 #define SendSize DAC_SAMPLES_PER_BLOCK
 
 ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void CommonSetup()':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:188:11: error: 'pttPin' was not declared in this scope
   pinMode(pttPin, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:192:11: error: 'LED1' was not declared in this scope
   pinMode(LED1, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:193:11: error: 'LED2' was not declared in this scope
   pinMode(LED2, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:194:11: error: 'LED3' was not declared in this scope
   pinMode(LED3, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void PlatformSleep()':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:83:16: error: 'LED3' was not declared in this scope
 #define PKTLED LED3    // flash when packet received
 
                ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:330:14: note: in expansion of macro 'PKTLED'
       SetLED(PKTLED, 0);    // turn off packet rxed led
 
              ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'BOOL KeyPTT(BOOL)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:711:22: error: 'pttPin' was not declared in this scope
     digitalWriteFast(pttPin, blnPTT);
 
                      ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void WriteDebugLog(int, const char*, ...)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1334:10: warning: unused variable 'Mess' [-Wunused-variable]
     char Mess[256];
 
          ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1336:6: warning: unused variable 'len' [-Wunused-variable]
  int len;
 
      ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void MONprintf(const char*, ...)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1374:10: warning: unused variable 'Mess' [-Wunused-variable]
     char Mess[256];
 
          ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1376:6: warning: unused variable 'len' [-Wunused-variable]
  int len;
 
      ^
Error compiling for board Teensy 3.6.
 
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
 


John G8BPQ
 

If the environment isn't defining PROJECT_ARDOP_Teensy, then you need to #define ARDOP in TeensyConfig.h, not in ARDOP_Teensy.ino.

73, John

On 04/07/2018 16:49, kc3ccd@... wrote:
I tried to compile. I saw TeensyWrapper.c has #define ARDOP.  TeensyConfig.h is looking for PROJECT_ARDOP_Teensy in order to define ARDOP (yup, it is defined twice, not sure why) so I added #define PROJECT_ARDOP_Teensy in ARDOP_Teensy file.  Now the errors are below. I also pushed the button and nothing happened. Troubleshooting that.

Arduino: 1.8.5 (Mac OS X), TD: 1.42, Board: "Teensy 3.6, Serial, 180 MHz, Faster, US English"
 
In file included from /Documents/Ham/Arduino/TeensyProjects/ARDOP_Teensy/ARDOP_Teensy.ino:61:0:
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/../../ARDOPC/ARDOPC.h:11:0: warning: "SendSize" redefined
 #define SendSize 1200  // 100 mS for now
 
 ^
In file included from /Documents/Ham/Arduino/TeensyProjects/ARDOP_Teensy/ARDOP_Teensy.ino:8:0:
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.h:47:0: note: this is the location of the previous definition
 #define SendSize DAC_SAMPLES_PER_BLOCK
 
 ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void CommonSetup()':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:188:11: error: 'pttPin' was not declared in this scope
   pinMode(pttPin, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:192:11: error: 'LED1' was not declared in this scope
   pinMode(LED1, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:193:11: error: 'LED2' was not declared in this scope
   pinMode(LED2, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:194:11: error: 'LED3' was not declared in this scope
   pinMode(LED3, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void PlatformSleep()':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:83:16: error: 'LED3' was not declared in this scope
 #define PKTLED LED3    // flash when packet received
 
                ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:330:14: note: in expansion of macro 'PKTLED'
       SetLED(PKTLED, 0);    // turn off packet rxed led
 
              ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'BOOL KeyPTT(BOOL)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:711:22: error: 'pttPin' was not declared in this scope
     digitalWriteFast(pttPin, blnPTT);
 
                      ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void WriteDebugLog(int, const char*, ...)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1334:10: warning: unused variable 'Mess' [-Wunused-variable]
     char Mess[256];
 
          ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1336:6: warning: unused variable 'len' [-Wunused-variable]
  int len;
 
      ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void MONprintf(const char*, ...)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1374:10: warning: unused variable 'Mess' [-Wunused-variable]
     char Mess[256];
 
          ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1376:6: warning: unused variable 'len' [-Wunused-variable]
  int len;
 
      ^
Error compiling for board Teensy 3.6.
 
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
 


N3RDR
 

That is what I was hoping to accomplish by adding #define PROJECT_ARDOP_Teensy  in ARDOP_Teensy.ino.  But I just commented out the #ifdef PROJECT_ARDOP_Teensy in TeensyConfig.h to force the #define ARDOP and it all works now.  It compiled and acted if it programmed the Teensy.  I say acted because there was an indication on the computer but none on the board. 

The TNC is connected to a PiGate configured PI3. If there’s a way to confirm operation without having to connect to the rig, please let me know.

Thanks for the help!


On Jul 4, 2018, at 12:40 PM, John Wiseman <john.wiseman@...> wrote:

If the environment isn't defining PROJECT_ARDOP_Teensy, then you need to #define ARDOP in TeensyConfig.h, not in ARDOP_Teensy.ino.

73, John

On 04/07/2018 16:49, kc3ccd@... wrote:
I tried to compile. I saw TeensyWrapper.c has #define ARDOP.  TeensyConfig.h is looking for PROJECT_ARDOP_Teensy in order to define ARDOP (yup, it is defined twice, not sure why) so I added #define PROJECT_ARDOP_Teensy in ARDOP_Teensy file.  Now the errors are below. I also pushed the button and nothing happened. Troubleshooting that.

Arduino: 1.8.5 (Mac OS X), TD: 1.42, Board: "Teensy 3.6, Serial, 180 MHz, Faster, US English"
 
In file included from /Documents/Ham/Arduino/TeensyProjects/ARDOP_Teensy/ARDOP_Teensy.ino:61:0:
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/../../ARDOPC/ARDOPC.h:11:0: warning: "SendSize" redefined
 #define SendSize 1200  // 100 mS for now
 
 ^
In file included from /Documents/Ham/Arduino/TeensyProjects/ARDOP_Teensy/ARDOP_Teensy.ino:8:0:
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.h:47:0: note: this is the location of the previous definition
 #define SendSize DAC_SAMPLES_PER_BLOCK
 
 ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void CommonSetup()':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:188:11: error: 'pttPin' was not declared in this scope
   pinMode(pttPin, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:192:11: error: 'LED1' was not declared in this scope
   pinMode(LED1, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:193:11: error: 'LED2' was not declared in this scope
   pinMode(LED2, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:194:11: error: 'LED3' was not declared in this scope
   pinMode(LED3, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void PlatformSleep()':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:83:16: error: 'LED3' was not declared in this scope
 #define PKTLED LED3    // flash when packet received
 
                ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:330:14: note: in expansion of macro 'PKTLED'
       SetLED(PKTLED, 0);    // turn off packet rxed led
 
              ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'BOOL KeyPTT(BOOL)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:711:22: error: 'pttPin' was not declared in this scope
     digitalWriteFast(pttPin, blnPTT);
 
                      ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void WriteDebugLog(int, const char*, ...)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1334:10: warning: unused variable 'Mess' [-Wunused-variable]
     char Mess[256];
 
          ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1336:6: warning: unused variable 'len' [-Wunused-variable]
  int len;
 
      ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void MONprintf(const char*, ...)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1374:10: warning: unused variable 'Mess' [-Wunused-variable]
     char Mess[256];
 
          ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1376:6: warning: unused variable 'len' [-Wunused-variable]
  int len;
 
      ^
Error compiling for board Teensy 3.6.
 
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
 



John G8BPQ
 

I don't think PiGate supports ARDOP. In fact the only PI program I know that support Teensy ARDOP is linbpq.

73,
John G8BPQ

On 04/07/2018 17:58, KC3CCD wrote:
That is what I was hoping to accomplish by adding #define PROJECT_ARDOP_Teensy  in ARDOP_Teensy.ino.  But I just commented out the #ifdef PROJECT_ARDOP_Teensy in TeensyConfig.h to force the #define ARDOP and it all works now.  It compiled and acted if it programmed the Teensy.  I say acted because there was an indication on the computer but none on the board. 

The TNC is connected to a PiGate configured PI3. If there’s a way to confirm operation without having to connect to the rig, please let me know.

Thanks for the help!


On Jul 4, 2018, at 12:40 PM, John Wiseman <john.wiseman@...> wrote:

If the environment isn't defining PROJECT_ARDOP_Teensy, then you need to #define ARDOP in TeensyConfig.h, not in ARDOP_Teensy.ino.

73, John

On 04/07/2018 16:49, kc3ccd@... wrote:
I tried to compile. I saw TeensyWrapper.c has #define ARDOP.  TeensyConfig.h is looking for PROJECT_ARDOP_Teensy in order to define ARDOP (yup, it is defined twice, not sure why) so I added #define PROJECT_ARDOP_Teensy in ARDOP_Teensy file.  Now the errors are below. I also pushed the button and nothing happened. Troubleshooting that.

Arduino: 1.8.5 (Mac OS X), TD: 1.42, Board: "Teensy 3.6, Serial, 180 MHz, Faster, US English"
 
In file included from /Documents/Ham/Arduino/TeensyProjects/ARDOP_Teensy/ARDOP_Teensy.ino:61:0:
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/../../ARDOPC/ARDOPC.h:11:0: warning: "SendSize" redefined
 #define SendSize 1200  // 100 mS for now
 
 ^
In file included from /Documents/Ham/Arduino/TeensyProjects/ARDOP_Teensy/ARDOP_Teensy.ino:8:0:
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.h:47:0: note: this is the location of the previous definition
 #define SendSize DAC_SAMPLES_PER_BLOCK
 
 ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void CommonSetup()':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:188:11: error: 'pttPin' was not declared in this scope
   pinMode(pttPin, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:192:11: error: 'LED1' was not declared in this scope
   pinMode(LED1, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:193:11: error: 'LED2' was not declared in this scope
   pinMode(LED2, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:194:11: error: 'LED3' was not declared in this scope
   pinMode(LED3, OUTPUT);
 
           ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void PlatformSleep()':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:83:16: error: 'LED3' was not declared in this scope
 #define PKTLED LED3    // flash when packet received
 
                ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:330:14: note: in expansion of macro 'PKTLED'
       SetLED(PKTLED, 0);    // turn off packet rxed led
 
              ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'BOOL KeyPTT(BOOL)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:711:22: error: 'pttPin' was not declared in this scope
     digitalWriteFast(pttPin, blnPTT);
 
                      ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void WriteDebugLog(int, const char*, ...)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1334:10: warning: unused variable 'Mess' [-Wunused-variable]
     char Mess[256];
 
          ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1336:6: warning: unused variable 'len' [-Wunused-variable]
  int len;
 
      ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp: In function 'void MONprintf(const char*, ...)':
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1374:10: warning: unused variable 'Mess' [-Wunused-variable]
     char Mess[256];
 
          ^
/Documents/Ham/Arduino/TeensyProjects/libraries/TeensyConfig/TeensyCommon.cpp:1376:6: warning: unused variable 'len' [-Wunused-variable]
  int len;
 
      ^
Error compiling for board Teensy 3.6.
 
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.