Teensy 3.2 difficulty uploading using Teensyduino

Status
Not open for further replies.

AndyUK

Member
Hi, I hope I can get a little help please:confused:
I am new to the Teensy 3.2, but have some experience using the Arduino Uno/Pro Mini and the Arduino IDE. I have successfully installed Teensyduino and see the Teensy 3.2 under Tools>Boards. I have uploaded blink and changed the delay periods to make sure a sketch is being uploaded. All OK.:)Two ports have been allocated by Windows 10. Tools>port(COM5(Teensy3.2)Serial>...then a choice of Serial ports/COM5(Teensy) or Teensy/COM5(Teensy3.2)Serial. Not sure why two appear?:confused:
I am using the Teensy 3.2 for the extra Flash and RAM needed for graphics using e-paper. The library I hope to use is GxEPD2 by ZinggJM. At the moment I am unable to upload the example sketch. The Teensy 3.2 is not specifically listed in the example but having read up on the "Waveshare e-paper displays with SPI" Arduino Forum thread (specifically thread #188 staberas) it is apparent that it is possible to use this library with the Teensy 3.2...in the example you have to select a generic equivalent board. For the Teensy 3.2 this is the Arduino MKR1000, generic type Arduino_Arch_SAMD. So far so good.
Once I have selected the Arduino MKR1000 board in Tools>Board I am ready to try and upload the sketch. However, although the code compiles without problem it will not upload.
The following error message is given.....No device found on COM5.
I am not sure why this is happening. Can anyone throw a little light my way...I get the feeling this may be something pretty straight forward but as a newcomer to Teensy I'm not sure. Thanks:D
 
I'm not getting a clear picture of what you're really seeing. Maybe screenshots would help?


I have uploaded blink and changed the delay periods to make sure a sketch is being uploaded. All OK.:)

Good. Are you doing this same upload in another case that's not working? That's the part I don't understand...


Two ports have been allocated by Windows 10. Tools>port(COM5(Teensy3.2)Serial>...then a choice of Serial ports/COM5(Teensy) or Teensy/COM5(Teensy3.2)Serial. Not sure why two appear?:confused:

Starting in Teensyduino 1.42, we added a Teensy-specific way of detecting the port. Historically, we've had many problems where Arduino's way doesn't always work. Arduino's way is known to not work at all when you set Tools > USB Type to any of the options not having "Serial".

When everything is working properly, and you're using a "Serial" USB Type, you should see the port appear twice. One is from Arduino's code, the other from Teensyduino's way.


For the Teensy 3.2 this is the Arduino MKR1000, generic type Arduino_Arch_SAMD. So far so good.
Once I have selected the Arduino MKR1000 board in Tools>Board I am ready to try and upload the sketch. However, although the code compiles without problem it will not upload.
The following error message is given.....No device found on COM5.

This is the parts where I'm confused.

Are you using Teensy 3.2 or a MKR1000 board?

This kinda sounds like you've clicked Tools > Boards and selected MKR1000, and then you're trying to upload the MKR1000-built code onto your Teensy 3.2. But that can't possibly work. Maybe I've just mis-read what you're doing. I can't see your screen, can't tell what you've actually done, and can't see the actual error message.

Again, a screenshot would really help here, showing the actual error and other stuff in the Arduino window, like the on the bottom with info about the selected boards & port.
 
PaulStoffRegen, my apologies for sending a message here, but I am a real customer who bought and uses teensy 3.6Since some months now I can NOT acces the forums at all because it always says that my IP is blocked! I tried multiple internetproviders and computers and I did never abuse anything (I'm now browsing using an anonymous US located proxy to get any access at all)I sent mails to paul@pjrc.com and robin@pjrc.com a while ago. I even sent a private message to Robin about 5 days ago, but I don't get any answer at all.What must happen before I get noticed? I'm a real customer and getting desperate because I can't contact you and my IP (I guess a whole range of IPs actually) is banned from the forum.I had to contact tou through this reply (sorry for that) because mail failed and private message to Robin also seemed to fail (you are not reachable by private message so that was also not a possibility)Please as a customer help me. Kind regard,Bart LibertBelgium
 
Hi Paul, Thanks for taking the time to reply. You are right, and his is my lack of knowledge here, I have selected the MKR1000 board as I thought that you have to select the generic ARM board that matches the Teensey 3.2. If I compile the example having selected the Teensy 3.2 I get the following error message...sorry for the length. I believe this library does work with the Teensey 3.2 and maybe some tweeks are required to the example or library code, but I don't really know where to look. Can you please help further, it would be appreciated? thanks.

Arduino: 1.8.8 (Windows 10), TD: 1.45, Board: "Teensy 3.2 / 3.1, Serial, 96 MHz (overclock), Faster, US English"

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void setup()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:232:3: error: 'display' was not declared in this scope

display.init(115200);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloWorld()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:271:3: error: 'display' was not declared in this scope

display.setRotation(1);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloWorldForDummies()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:297:3: error: 'display' was not declared in this scope

display.setRotation(1);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloFullScreenPartialMode()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:343:3: error: 'display' was not declared in this scope

display.setPartialWindow(0, 0, display.width(), display.height());

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloArduino()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:393:3: error: 'display' was not declared in this scope

display.setRotation(1);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloEpaper()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:422:3: error: 'display' was not declared in this scope

display.setRotation(1);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void deepSleepTest()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:452:3: error: 'display' was not declared in this scope

display.setRotation(1);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void showBox(uint16_t, uint16_t, uint16_t, uint16_t, bool)':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:499:3: error: 'display' was not declared in this scope

display.setRotation(1);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void drawCornerTest()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:520:3: error: 'display' was not declared in this scope

display.setFullWindow();

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void showFont(const char*, const GFXfont*)':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:544:3: error: 'display' was not declared in this scope

display.setFullWindow();

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void drawFont(const char*, const GFXfont*)':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:558:3: error: 'display' was not declared in this scope

display.fillScreen(GxEPD_WHITE);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void showPartialUpdate()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:587:19: error: 'display' was not declared in this scope

uint16_t incr = display.epd2.hasFastPartialUpdate ? 1 : 3;

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void drawBitmaps()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:643:3: error: 'display' was not declared in this scope

display.setFullWindow();

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void drawBitmaps200x200()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:701:7: error: 'display' was not declared in this scope

if (display.epd2.panel == GxEPD2::GDEP015OC1)

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:719:22: error: 'display' was not declared in this scope

bool mirror_y = (display.epd2.panel != GxEPD2::GDE0213B1);

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:729:20: error: 'display' was not declared in this scope

bool mirror_y = (display.epd2.panel != GxEPD2::GDE0213B1);

^

Multiple libraries were found for "Adafruit_GFX.h"
Used: C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX
Not used: C:\Users\Andy\Documents\Arduino\libraries\Adafruit_GFX_Library
Error compiling for board Teensy 3.2 / 3.1.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
 
Hi Paul, I have attached the files of the example code. Hope this helps further. Thanks:)
 

Attachments

  • GxEPD2_Example_1.0.ino
    45.2 KB · Views: 94
  • GxEPD2_boards_added.h
    7.5 KB · Views: 171
Whoever wrote "GxEPD2_boards_added.h" designed this code to only work on 3 specific types of boards. Sadly, they didn't provide a case for Teensy. :(

Maybe it can work if you just delete 2 of the 3 cases, and delete all 3 of the "#if defined" lines and their 3 matching #endif, but of course not the final #endif, which matches "#ifndef _GxEPD2_boards_added_H_" from the beginning of the file. But as they wrote it (whoever "they" is...) the #ifdef lines specifically check for exactly 3 cases and if none of those 3 exist it leaves all of the stuff the rest of this project needs not defined at all. Not nice!

The .ino file depends on GxEPD2_BW.h, GxEPD2_3C,h and other files I don't have. I really can't give better advice than this unless I have all the related libs and maybe some idea of who published this code and what it's supposed to do.
 
Once again thanks for responding.
The library is on github. The latest version is GxEPD2 and this where I have taken the example sketch from.
githubGithubhttps://github.com/ZinggJM
I will,try your suggestion tomorrow:)
Hope this other information sheds some further light.
 
Apparently, this library is designed to rely on a bunch of #defines for every different (supported) MCU. If there aren’t the needed definitions in the ino file or in the ..._boards_added.h file, the library won’t simply work because of the lack of suitable parameters. I don’t understand why the author does make things so complicated for himself and for the users. I’d tend in such cases to punish him by ignoring his stuff and move on to find another (better) ePaper library. A forum search should point you towards the few threads where people report successful control of various ePaper displays with Teensy MCUs.

Or you might contact him via github and ask him to add Teensy support. In ever case, it’s clearly an external library problem and not a Ttensy(duino) issue!
 
Hi again Paul, I tried your suggestion #6. Unfortunately the code did not compile. I have pasted the error message below.:(
I have spent a lot of time looking for links to explain how to use this library with Teensy and am keeping the faith:)
I found this link "18 March 2018 https://forum.pjrc.com/threads/50385-Is-there-a-simple-E-paper-driver-for-Teensy-LC" on the Teensy Forum where MichaelMeissner says he had success with the 3.2 working with the earlier version of the library (GxEPD), but no info on any tweaks he made. I will try this earlier version of the library and hope for some success :)
I would like to stick with this if possible. I think a lot of other Teensy users may will find this library helpful as the popularity of e-paper grows...maybe ...thanks again

Arduino: 1.8.8 (Windows 10), TD: 1.45, Board: "Teensy 3.2 / 3.1, Serial, 96 MHz (overclock), Faster, US English"

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloWorld()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:275:65: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(HelloWorld, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloWorldForDummies()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:304:59: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(text, 0, 0, &tbx, &tby, &tbw, &tbh); // it works for 0, 0, fortunately (negative tby!)

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloFullScreenPartialMode()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:363:65: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(fullscreen, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:366:65: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(updatemode, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:369:65: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(HelloWorld, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloArduino()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:398:65: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(HelloWorld, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:401:67: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(HelloArduino, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void helloEpaper()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:427:65: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(HelloWorld, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:430:66: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(HelloEpaper, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino: In function 'void deepSleepTest()':

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:457:66: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(hibernating, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:471:61: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(wokeup, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:482:60: error: invalid conversion from 'const char*' to 'char*' [-fpermissive]

display.getTextBounds(again, 0, 0, &tbx, &tby, &tbw, &tbh);

^

In file included from C:\Users\Andy\Documents\Arduino\libraries\GxEPD2-master\src/GxEPD2_BW.h:15:0,

from C:\Users\Andy\Documents\Arduino\GxEPD2_Example_1.0\GxEPD2_Example_1.0.ino:49:

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX/Adafruit_GFX.h:104:5: note: initializing argument 1 of 'void Adafruit_GFX::getTextBounds(char*, int16_t, int16_t, int16_t*, int16_t*, uint16_t*, uint16_t*)'

getTextBounds(char *string, int16_t x, int16_t y,

^

Multiple libraries were found for "Adafruit_GFX.h"
Used: C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Adafruit_GFX
Not used: C:\Users\Andy\Documents\Arduino\libraries\Adafruit_GFX_Library
Error compiling for board Teensy 3.2 / 3.1.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
 
The library is on github. The latest version is GxEPD2 and this where I have taken the example sketch from.
githubGithubhttps://github.com/ZinggJM

Could you be more specific about exactly which library you're really using? I see 4 different libraries on that page with similar names. One claims to be specifically for 32 bit Arduino, but you didn't say "_32" in the name.

If I dig into the problem for you, I will do it only once... so please, make it count by pointing me to exactly the same library!
 
Hi Paul,
The example I have been using is from the GxEPD2 library. I have read/skimmed through the 77 pages in the "Waveshare e-paper displays with SPI" Arduino Forum thread and it appears that GxEPD2 is the version which wraps up previous versions. Prior to this the main library was GxEPD with the others appearing to be offshoots to answer specific requests during the library development.
I mentioned I would try the earlier GxEPD library and I have done that this morning. The example in this library compiled with the Teensy 3.2 selected in Teensyduino. I was also able to upload the example. After some trial and error on which pins might work I got the example in the GxEPD library to run on the Waveshare 1.54" b/w display I have. In the example I again used the ARDUINO_ARCH_SAMD option when selecting the appropriate display.

Working pin mapping as follows;
E-paper > Teensy 3.2
Busy > 7
RST > 9
DC > 8
CS > 10
CLK > 13
DIN > 11

So, it seems that the example compiles and uploads for the earlier GxEPD library. However, it does not compile for the newer GxEPD2 library.
I will ask a question on the Arduino thread I mentioned earlier to see if there is a fix for the Teensy using the newer GxEPD2 library. The example in GxEPD2 has many more options and display functions which can help a beginner like me:)
I have a display displaying... :)
I am not sure whether you feel you would like to investigate further or draw a line at this point. Either way many thanks for your assistance.
 
Hi

apologies for chiming in - I have similar problem.

Linux Mint 19.1, Arduino 1.8.8, Teensyduino 1.45, all just set up. Port: "/dev/ttyACM0(Teensy 3.2) Serial"

Tried to compile and load the Blink program. Most of it works and the program is loaded if reset button is pushed.

Sometimes I get on the Teensyloader the message "Arduino is attemting to put Teensy into program mode", which stays forever. If I push the reset button on the Teensy it goes away.

Sometimes the Arduino IDE is stuck after compile - message Opening Teensy loader, no message on the Teensy loader.

Sometimes the Arduino IDE is stuck after upload - the upload is not finished..


Tried as well with a T36. Same problems.

At the moment I am somewhat lost. Any ideas ?
 
Last edited:
The button is NOT a reset button, it’s a PGM button which forces the Teensy into programming mode, in case of troubled USB connection. Since you are on Linux, did you install the needed undeveloped rules as required and documented on the Teensy website?
 
The button is NOT a reset button, it’s a PGM button which forces the Teensy into programming mode, in case of troubled USB connection. Since you are on Linux, did you install the needed undeveloped rules as required and documented on the Teensy website?

Do you mean the 49-teensy.rules in /etc/udev/rules.d ?
 
yes - I did.

Something new - the message "Teensy Loader could not find the directory /tmp/arduino_build_903280"

Pushing the PGM button clears this. I try to compile and upload again -> message Opening Teensy Loader -> no progress -> PGM button
-> program is loaded -> message Opening Teensy Loader stays ->after a while message "Error compiling for Teensy board 3.6"
 
Last edited:
So, it must be something different which makes the USB HID communication hang at a point that the Arduino IDE stalls. That’s definitively not normal. If I were you, I’d look for anomalies in the system log files. Unfortunately, it’s already 8 years that I abandoned Linux in favor of macOS...
 
Something new - the message "Teensy Loader could not find the directory /tmp/arduino_build_903280"

Any chance you closed or quit the Arduino IDE, but left Teensy Loader running? On exit, it automatically deletes all the temporary files it created.

Or maybe you have some process running on your machine that automatically cleans up the /tmp directory?
 
Any chance you closed or quit the Arduino IDE, but left Teensy Loader running? On exit, it automatically deletes all the temporary files it created.

Or maybe you have some process running on your machine that automatically cleans up the /tmp directory?

I don't think that this is the real problem. Happened probably when pushing compile/upload when the previous upload was not completed. Really strange - never encountered this before.
How can I uninstall Teensyduino ?
 
Some lines out of the protocol :

23:01:30 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
23:01:30 kernel: usb 2-1.4: SerialNumber: 2406400
23:01:30 kernel: usb 2-1.4: SerialNumber: 2406400
23:01:30 kernel: usb 2-1.4: Manufacturer: Teensyduino
23:01:30 kernel: usb 2-1.4: Product: USB Serial
23:01:30 kernel: usb 2-1.4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
23:01:30 kernel: usb 2-1.4: New USB device found, idVendor=16c0, idProduct=0483
23:01:30 kernel: usb 2-1.4: new full-speed USB device number 48 using ehci-pci
23:01:29 kernel: usb 2-1.4: USB disconnect, device number 47
23:01:28 kernel: hid-generic 0003:16C0:0478.0017: hidraw2: USB HID v1.11 Device [HID 16c0:0478] on usb-0000:00:1d.0-1.4/input0
23:01:28 kernel: usb 2-1.4: SerialNumber: 0003AC00
23:01:26 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
23:01:26 kernel: usb 2-1.4: SerialNumber: 2406400
23:01:25 kernel: hid-generic 0003:16C0:0478.0016: hidraw2: USB HID v1.11 Device [HID 16c0:0478] on usb-0000:00:1d.0-1.4/input0
23:01:25 kernel: usb 2-1.4: SerialNumber: 0003AC00
23:01:22 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
23:01:22 kernel: usb 2-1.4: SerialNumber: 2406400
23:01:19 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
23:01:19 kernel: usb 2-1.4: SerialNumber: 2406400
23:01:17 kernel: hid-generic 0003:16C0:0478.0015: hidraw2: USB HID v1.11 Device [HID 16c0:0478] on usb-0000:00:1d.0-1.4/input0
23:01:17 kernel: usb 2-1.4: SerialNumber: 0003AC00
23:01:09 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
23:01:09 kernel: usb 2-1.4: SerialNumber: 2406400
23:01:08 kernel: hid-generic 0003:16C0:0478.0014: hidraw2: USB HID v1.11 Device [HID 16c0:0478] on usb-0000:00:1d.0-1.4/input0
23:01:08 kernel: usb 2-1.4: SerialNumber: 0003AC00
23:00:48 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
23:00:48 kernel: usb 2-1.4: SerialNumber: 2406400
23:00:46 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
23:00:46 kernel: usb 2-1.4: SerialNumber: 2406400
23:00:45 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
23:00:45 kernel: usb 2-1.4: SerialNumber: 2406400
22:48:25 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
22:48:25 kernel: usb 2-1.4: SerialNumber: 2406400
22:48:24 kernel: hid-generic 0003:16C0:0478.0013: hidraw2: USB HID v1.11 Device [HID 16c0:0478] on usb-0000:00:1d.0-1.4/input0
22:48:24 kernel: usb 2-1.4: SerialNumber: 0003AC00
22:48:22 kernel: cdc_acm 2-1.4:1.0: ttyACM0: USB ACM device
22:48:22 kernel: usb 2-1.4: SerialNumber: 2406400
22:48:21 kernel: hid-generic 0003:16C0:0478.0012: hidraw2: USB HID v1.11 Device [HID 16c0:0478] on usb-0000:00:1d.0-1.4/input0
22:48:21 kernel: usb 2-1.4: SerialNumber: 0003AC00


Checked the T3.6 and USB cable on another computer with Arduino 1.85 and Teensyloader 1.4.1. Normal operation.

Noticed a difference regarding port selection : under 1.8.1 only Port: "/dev/ttyACM0(Teensy)", on on Arduino 1.8.8 Port: "/dev/ttyACM0(Teensy) and
Port: "/dev/ttyACM0(Teensy)Serial for selection. Does this mean something ? Tried both of them - same result.
 
Last edited:
How can I uninstall Teensyduino ?

Just delete the copy of Arduino which has it installed. If you want revert to an unmodified copy of Arduino, just download a fresh copy from Arduino's website and extract the .tar.xz file.

To double check, in Arduino click Help > About. The about dialog shows which version of Arduino & Teensduino (if present) you actually have.

Arduino by default on Linux stores your settings in ~/.arduino15 and your saved programs in ~/Documents/Arduino (though this location is configurable from File > Preferences). Teensyduino does not (currently) store any files in either of these locations.
 
Just delete the copy of Arduino which has it installed. If you want revert to an unmodified copy of Arduino, just download a fresh copy from Arduino's website and extract the .tar.xz file.

To double check, in Arduino click Help > About. The about dialog shows which version of Arduino & Teensduino (if present) you actually have.

Arduino by default on Linux stores your settings in ~/.arduino15 and your saved programs in ~/Documents/Arduino (though this location is configurable from File > Preferences). Teensyduino does not (currently) store any files in either of these locations.

After using Teenssduino under Linux for years I am a little pissed now. I can't get newer versions of Linux Mint, Arduino IDE and Teensyduino working.

Linux Mint 19.1, freshly installed, nothing else on it. Arduino 1.8.8 and Teensyduino 1.45. Test sketch the basic blink.

Arduino IDE works without problems with an Arduino Nano. So basically the USB connection should be fine.

Teensyduino has problems establishing and terminating the upload. Needs two to three times pressing the PGM button. Then the upload works.

I desperately need some help finding out what is wrong.
 
Officially, PJRC only supports Ubuntu (for x86) and Raspbian (for ARM). I personally test the software on those distros, so I can say with confidence they work. Most other distros like Mint & Fedora usually work. Some distros, expecially Arch & Gentoo, have a long history of problems. When Linux distros vary, and particularly when something important is broken, the minor differences between Linux systems can be incredibly frustrating.

Running inside a virtual machine is never recommended. Virtual machines have to fully emulate a USB controller in software. Amazingly, this sometimes works, but there's plenty that can go wrong. Running on real hardware is always recommended. I have no idea if you're running natively or virtual, but mentioning this because it sometimes comes up after *many* messages troubleshooting a system that would have worked perfectly, if not run inside a virtual machine.

If you're reinstalling distros, maybe give Ubuntu 18.04 a try? That's what I use for nearly all of Teensy's development. In fact, I'm writing this message using a machine running Ubuntu 18.04.

If you *really* want to continue trying to get this work on Mint, you're certainly welcome to keep asking here. I don't use Mint, so there's little I can do. Even if someone who does use Mint sees your message, unless they happen to encountered exactly the same issue, odds are slim anyone could offer useful advice if you don't show them exactly what's happening. Nobody can see your screen, or kernel log file, or Teensy Loader verbose info log, or other key details if you write a message that basically amounts to "it doesn't work". To get useful help, at a bare minimum people need to be able to see the problem, actually see the key info.
 
Hi Paul

thanks for reply. I gave Ubuntu 18.04.2 LTS a try. Installed Arduino IDE - works without problems with a Nano. Teensyduino ? Same behaviour as described above. It can upload with pressing the PGM button, but the communication with the Arduino IDE is not working as it should. Needs about 2-3 pressing the PGM button for the Arduino IDE to finish an compile/upload.

I noticed that you probably changed the instructions on your website. I think I followed the steps mentioned there.

Could you please tell me what information you need out of the Ubuntu installation for solving the problem ?

PS at the moment plain vanilla installation, nothing else on it, just the Ubuntu, Arduino IDE and Teensyduino.
 
I've never seen anything like that.

If you program wrong code onto the Teensy, so it isn't listening to the USB port, then 1 button press is needed. That's normal. But pressing more than once should never be needed.


plain vanilla installation, nothing else on it, just the Ubuntu, Arduino IDE and Teensyduino.

Absent in your description is installing the udev rule file. But without the udev rules, uploading shouldn't work at all (unless running as root) because HID devices don't default to write access for ordinary users.

What did you do with the udev rules?


Could you please tell me what information you need out of the Ubuntu installation for solving the problem ?

Look, as you've described this problem (especially pressing the button 2-3 times) is so far from any of the usual problems that I'm not 100% sure where to start.

Teensy Loader has a verbose info window, in the Help menu. It shows a lot of info about what Teensy Loader is detecting.

The Linux kernel provides log message, which tell you when USB devices connect and disconnect, and when it loads drivers. On my Ubuntu system, the command to see this as they occur is "sudo tail -d /var/log/syslog".

Maybe get both those windows open and watch what happens. If you show that info here, it's important to know the time of when you did each button press.
 
Status
Not open for further replies.
Back
Top