Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 20 of 20

Thread: Teensyduino 1.18 Release Candidate #2 Available

  1. #1
    Administrator Paul's Avatar
    Join Date
    Oct 2012
    Posts
    390

    Teensyduino 1.18 Release Candidate #2 Available

    Here is a second release candidate for Teensyduino 1.18.


    Old beta download links removed. Please use the latest version:
    https://www.pjrc.com/teensy/td_download.html



    Please give this a try and report any bugs. Try to include a sample program that reproduces the problem!


    Here's a list of the changes since Teensyduino 1.18-rc1:

    • Speed up SD library
    • Fix upload > 128k on Teensy 3.1

  2. #2
    Senior Member
    Join Date
    Jun 2013
    Location
    So. Calif
    Posts
    2,828
    OK! new loader fed micropython to T3.1 and it runs. early alpha, indeed!
    thanks

  3. #3
    Senior Member+ manitou's Avatar
    Join Date
    Jan 2013
    Posts
    2,620
    So channel fix for VREF on teensy 3.1 didn't seem to get fixed? Previously described here
    http://forum.pjrc.com/threads/24691-...1-bug-and-vref

  4. #4
    Senior Member
    Join Date
    Nov 2012
    Posts
    298

    Serial.available() bug in 1.18 RC2

    Serial.available() seems to have a bug.

    If you do a Serial.read() with no data available, read returns -1 as expected but then calls to Serial.available() return non-zero.

    This example:
    Code:
    void setup() {
      Serial.begin(9600);
      while(!Serial);
    }
    void loop() {
      Serial.println(Serial.available());
      Serial.read();  
      delay(1000);
    }
    Prints these results for Serial.avalable().
    0
    57344
    49152
    40960
    32768
    24576
    16384
    8192
    0
    57344
    49152
    40960
    32768
    24576
    16384
    8192

  5. #5
    Senior Member
    Join Date
    Jun 2013
    Location
    So. Calif
    Posts
    2,828
    the list of numbers from Serial.available() are decreasing by 8192 per call. A clue?
    I wouldn't think that the ISR/driver is able to buffer 57344 (0xE000) bytes. That's a multiple of 8192 (0x2000)

  6. #6
    Senior Member sumotoy's Avatar
    Join Date
    Nov 2012
    Location
    Venezia, Italia
    Posts
    421
    I'm experiencing some weird Serial problem too. Yesterday I simply cannot get any printout. Btw, I never get consistent printout from Setup on Teensy3, forced me to linkup an LCD from long time, but I almost get working inside the Loop. With this last version I got printouts only with very simple sketches but on several projects I cannot get any printout at all. Tomorrow I try to figure out what breaks out.
    Win7/64, Teensy3,0. Ide 18/rc2
    Last edited by sumotoy; 01-08-2014 at 12:02 AM.

  7. #7
    Senior Member
    Join Date
    Nov 2012
    Posts
    1,569
    Do you wait for the port to open - like this:
    Code:
      Serial.begin(9600);
      // wait for the port to open
      while(!Serial);
      // wait for 2 seconds just to make sure
      delay(2000);
    Pete

  8. #8
    Senior Member
    Join Date
    Jun 2013
    Location
    So. Calif
    Posts
    2,828
    I've not had troubles with Serial.print or Serial1.print on T3.1

  9. #9
    Senior Member sumotoy's Avatar
    Join Date
    Nov 2012
    Location
    Venezia, Italia
    Posts
    421
    Quote Originally Posted by el_supremo View Post
    Do you wait for the port to open - like this:
    Code:
      Serial.begin(9600);
      // wait for the port to open
      while(!Serial);
      // wait for 2 seconds just to make sure
      delay(2000);
    Pete
    Hi Pete,
    this never fully worked from the ancient time so I simply forget any printout in setup. Maybe it's something related to my 2xWin/64 computers but as I said now serial not always works even in Loop and any Wait,Delay solutions not helped. It's strange because the arduinos laying around my table all working (even in setup). Maybe driver get messed up during upgrade?

  10. #10
    Senior Member sumotoy's Avatar
    Join Date
    Nov 2012
    Location
    Venezia, Italia
    Posts
    421
    I find a solution apparently... I got another serial problem in an application I wrote in Java time ago and after some quick research I discovered that I'm actually run Java 32 bit on a 64 bit machine. I installed 64 bit version and magically I solved the serial problems.
    On the other computer the same story but I still not deinstalled Java because I want to understand why it affects some serial communication and not all.

    Edit: oops! Too early!

    Adding while(!Serial); in setup worked a couple of times but now the While loop seems stucked in an infinite loop and sketch not start.
    Last edited by sumotoy; 01-08-2014 at 12:53 PM.

  11. #11
    Senior Member sumotoy's Avatar
    Join Date
    Nov 2012
    Location
    Venezia, Italia
    Posts
    421
    Deinstalled completely Java, cleaned all registers, cleaned folders with Java crap. Installed the correct 64 bit version... And finally now works as it should. Damn beans!
    A question, Arduino IDE uses Java, it's possible to use an external java or the arduino one has something special?

  12. #12
    Senior Member
    Join Date
    Jun 2013
    Location
    So. Calif
    Posts
    2,828
    Curious or bug:
    Teensy 3.1

    with
    Code:
    void setup() {
      delay(5000);
    	Serial.begin(9600);
      Serial.print(Serial == 0);
    }
    and using the serial monitor in the Arduino IDE, the Serial == 0 print shows 0.
    Same code, connect to COM16 via a dumb terminal emulator, not the IDE's serial monitor, the same Serial == 0 print shows 1.

    In either case, the following loops forever, no matter the delay, no matter if it's in setup() or loop(), no matter which terminal display program is used.

    Code:
    while (!Serial)
       ;
    I've just used a delay several seconds to give me time to open the desired terminal display (IDE or external).
    Probably better to just loop and read one character from Serial before proceeding from startup. Do so in loop().
    Last edited by stevech; 01-09-2014 at 05:22 AM.

  13. #13
    Senior Member
    Join Date
    Nov 2012
    Posts
    142
    Hi!

    I'm experiencing issues with uploading to the Teensy 3.0 and 3.1 boards with Teensyduino 1.18 RC2 on OS X 10.9 Mavericks.

    I dug into the Java code and managed to assemble those two functions:

    $ /Applications/Teensyduino.app/Contents/Resources/Java/hardware/tools/teensy_post_compile -file=sketch_jan30a.cpp -path=/var/folders/5d/dky9xc691m32kztqnhkn8bhw0000gn/T/build7991789148304455895.tmp/ -tools=/Applications/Teensyduino.app/Contents/Resources/Java/hardware/tools/

    $ /Applications/Teensyduino.app/Contents/Resources/Java/hardware/tools/teensy_reboot -v -v -v -v -pmk20dx128 -chalfkay -P/dev/cu.usbmodem1411 -b12000000 -D -Uflash:w:/var/folders/5d/dky9xc691m32kztqnhkn8bhw0000gn/T/build7991789148304455895.tmp/sketch_jan30a.cpp.hex:i


    Is there something missing?

    Based on the blink example,
    • When I connect the Teensy 3.0 or 3.1 board to the second USB port, port remains unchanged at /dev/cu.usbmodem1411 while it should be /dev/tty.usbmodem1421

    • When I perform a ls /dev/tty.usb*, I obtain /dev/tty.usbmodem20561 not /dev/cu.usbmodem1411 or /dev/tty.usbmodem1421.

    Thank you!
    Last edited by Avenue33; 01-30-2014 at 05:42 PM.

  14. #14
    Senior Member
    Join Date
    Jan 2014
    Posts
    154
    Known problems with Teensyduino 1.18-rc2 installer on WinXP? Attempted both before and after removal of previous version.

    Installer does not allow continue after the Choose Location step.

    Perhaps just have a corrupted download.

    EDIT:
    Never mind - more windoze weirdness fixed after a few reboots. Having to develop w/Win is getting tiresome - hopefully an errant Mac truck will flatten me long before the boss makes me go to .net.
    Last edited by BJB; 02-02-2014 at 09:57 PM.

  15. #15
    Senior Member sumotoy's Avatar
    Join Date
    Nov 2012
    Location
    Venezia, Italia
    Posts
    421
    Quote Originally Posted by stevech View Post
    Curious or bug:
    Teensy 3.1

    with
    Code:
    void setup() {
      delay(5000);
        Serial.begin(9600);
      Serial.print(Serial == 0);
    }
    and using the serial monitor in the Arduino IDE, the Serial == 0 print shows 0.
    Same code, connect to COM16 via a dumb terminal emulator, not the IDE's serial monitor, the same Serial == 0 print shows 1.

    In either case, the following loops forever, no matter the delay, no matter if it's in setup() or loop(), no matter which terminal display program is used.

    Code:
    while (!Serial)
       ;
    I've just used a delay several seconds to give me time to open the desired terminal display (IDE or external).
    Probably better to just loop and read one character from Serial before proceeding from startup. Do so in loop().
    So I'm not the only one going mad with serial issues! I've experimented the same thing (with exact results) and was suprised that none has similar issues. It's frustrating since I use serial mostly for debugging and those long delays for startup Serial (that NOT always works) are boring since Teensy3 it's blazing fast during uploading and a snail during startup, thanks for those not wanted delay and while loops. I have also troubles when have to debug a library with serial, most of the time I can succesfully debug only the part of the code that runs in loop but never the initializations, etc. that happen in setup, even if I use those long delays and while stuff.
    My only way to get a reliable serial connection:
    Code:
    while (!Serial)
       ;
    but have to wait some seconds before open Terminal and I'm forced to open terminal aniway otherwise it just hang in while loop, all this with preview1 and all older ones, still not tried this one but I'm sure it will be the same.
    Did you know if the other serial out has the same issues? I mean, working immediately without delays, while loop and whatever...
    This is my only issue with Teensy3 and 3.1 so far, I love it, it's tiny, powerful, marvellous designed and first class supported but serial out it's a big no, no, no.

  16. #16
    Senior Member
    Join Date
    Jun 2013
    Location
    So. Calif
    Posts
    2,828
    the hang in
    while !Serial() ;

    is intermittent, for me. Most often works properly.

    It may be related to another discussion here where it is said that some host computer operating systems, some of the time, take too long to respond to the new connection establishment protocol exchanges.

  17. #17
    Senior Member pictographer's Avatar
    Join Date
    May 2013
    Location
    San Jose, CA
    Posts
    700
    I solved my Teensy 3.0 serial intermittent connection issues by not using the Arduino built-in serial monitor. Instead I use cu, screen, or Putty. The only minor annoyance is that I can't upload new code while a serial session is active, but it's quick enough to disconnect, upload, and reconnect. I work on OS X Mavericks, Linux, and Windows 7.

  18. #18
    Senior Member
    Join Date
    Jun 2013
    Location
    So. Calif
    Posts
    2,828
    On windows, the terminal program called "Bray's terminal", has a user option to automatically close/reopen the serial port when the window focus comes/goes. So when you click away on some other window, it closes the port, and vice-versa.

  19. #19
    Quote Originally Posted by Paul View Post
    • Speed up SD library
    Quick question - are those SD speed ups patched in to the standard SD library? I know it's a long shot, but do you have a general idea of how it compares to the 'stock' SD library and/or the SD fat library? Perhaps I'm missing a post somewhere, if so, I'd love a spin in the right direction.

    Thanks!

  20. #20
    Senior Member Epyon's Avatar
    Join Date
    Apr 2013
    Location
    Belgium
    Posts
    443
    Quote Originally Posted by BJB View Post
    Known problems with Teensyduino 1.18-rc2 installer on WinXP? Attempted both before and after removal of previous version.

    Installer does not allow continue after the Choose Location step.
    I had this problem too (Win7 64). Reinstalling the Arduino IDE fixed it.

Posting Permissions

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