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

Thread: Using teensy 3.2 in standalone application.

  1. #1
    Junior Member
    Join Date
    Sep 2016
    Location
    Mumbai
    Posts
    16

    Using teensy 3.2 in standalone application.

    Can I use teensy3.2 in standalone application. I am thinking to program new MK20DX256VLH7(main IC) through MKL02Z32VFG4(bootloader IC) and then removing the main IC. And then placing the IC in different PCB with associated circuitry for doing predefined task. So, I will be using teensy3.2 as programmer to burn new IC (main).

    Is this possible.

    Thanks!

  2. #2
    I'm not really a hardware guy, so there might be different opinions on that. Personally, I would just solder a new K20 chip on the custom board and use JTAG to flash it. Much easier, you don't wreck your Teensy (i.e. can use it for more prototyping work), and you get JTAG for all the not-so-nice issues which are difficult to track down, especially on a new board design. I also remember that other Freescale/NXP SoCs have a bootup streaming interface (I think that is used on the Teensy in a way?), which you can use directly yourself as well. There are probably a few more options.

  3. #3
    Senior Member
    Join Date
    Apr 2013
    Posts
    1,936
    The solution others have used for the 'moving from Teensy prototype to production' is assorted flavours of:
    Build prototype
    Build protoype as single PCB with mounting of a Teensy Board
    Build production run of custom PCB with Teensy boards fitted (seems to work up to runs of several hundred)
    Once the sales justify the man hours mod the PCB to have it's own Teensy+MKL0 as a single board
    Once confirming that works as expected, delete the MKL0 and supporting hardware and mount them on a programing unit that gets plugged into each unit as it goes out the door to bootload it
    Once that gets too labor intensive then you transition to pre programed ICs and/or production machinery that's JTAG capable.

    Apologies if this is stuff that you are familiar with, and yes as noted above if this is a serious project in 5k and up units the plan should be to go straight to JTAG and pro tools to load and debug with.

    Main thing is that as soon as you let a product without a MKL0 out the door you have the potential for any firmware updates you ship to brick the unit in a way that requires additional shipped hardware to recover. If firmware is solid and not going to be updated this is fine, but for the early versions having the option of using a standard USB cable and standard PC to get a fix out to teensys in bricked condition can save a lot of pain.

  4. #4
    Senior Member Epyon's Avatar
    Join Date
    Apr 2013
    Location
    Belgium
    Posts
    443
    I've once made a custom Teensy with a MINI54 'programming stick'. So yes, it's possible, but only relevant when you're thinking high volumes. If you only make tens to maybe hundred products of one design and have a reasonable margin, it's better to stick with the default Teensy and spend your time increasing your sales.

    I think this is the trap most engineers-wanting-to-sell-stuff fall into: spending too much time making their initial designs and wanting to shave of every cent possible, while time-to-market and customer relations are way more important in a start-up phase.

  5. #5
    Junior Member
    Join Date
    Sep 2016
    Location
    Mumbai
    Posts
    16
    I have burned blinking LED program into teensy 3.2. Then I removed micro-controller from teensy3.2 and put that in a separate PCB custom PCB with the required circuitry. But LED is not blinking in the new environment. Do we need some more circuitry as to turn on the micro-controller.

    Any help will be useful. Click image for larger version. 

Name:	PJRC1.png 
Views:	136 
Size:	22.2 KB 
ID:	8135Click image for larger version. 

Name:	PJRC2.png 
Views:	103 
Size:	15.8 KB 
ID:	8136Click image for larger version. 

Name:	PJRC3.jpg 
Views:	221 
Size:	124.0 KB 
ID:	8137

  6. #6
    Senior Member Epyon's Avatar
    Join Date
    Apr 2013
    Location
    Belgium
    Posts
    443
    I ... don't even know where to begin .

    If you want to build a custom Teensy, at least start by implementing the reference schematic. You need a lot more than just 7 pins and three components. There is a lot of useful information in this post, including how to avoid common pitfalls and a reference design in Eagle.

  7. #7
    Senior Member
    Join Date
    Jan 2013
    Posts
    843
    Quote Originally Posted by tapasxplore View Post
    I have burned blinking LED program into teensy 3.2. Then I removed micro-controller from teensy3.2 and put that in a separate PCB custom PCB with the required circuitry. But LED is not blinking in the new environment. Do we need some more circuitry as to turn on the micro-controller.
    I don't know if your components are enough, but you need to connect the LED to package pin 50 (which is Teensy pin 13).

  8. #8
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    23,463
    VBAT was mentioned on another thread.

    You also need to connect VSSA to ground and VDDA to 3.3V.

    If your only goal was to check if the chip is able to boot up, you could have saved yourself a lot of troubleshooting effort by just purchasing the known-good reference board from OSH Park and only solder some of the parts.

    https://www.oshpark.com/shared_projects/d3J03Zeb

    or

    https://github.com/thewknd/teensy-bo...0board%20clone

  9. #9
    Senior Member
    Join Date
    Feb 2016
    Posts
    122
    Hi, Paul kindly let me know if I burn the teensy 3.2 with bootloader and remove the bootloader will the controller perform or not?

  10. #10
    Senior Member
    Join Date
    Apr 2013
    Posts
    1,936
    The bootloader IC is not required for normal operation, only when programing.

    This means all programing, since no part of the bootloader code remains in the main CPU so you can't reprogram it unless you have written your own update code and got it pre loaded.

  11. #11
    Senior Member
    Join Date
    Feb 2016
    Posts
    122
    Thanks, GremlinWrangler.
    I have to code it for once only till there is a new update.

    So if I remove the bootloader after burning there won't be any resetting of controller because of some watchdog or any other issue?.
    Also, I'm using the same schematic as per Paul which is present in pjrc website of teensy3.2.

  12. #12
    Senior Member Epyon's Avatar
    Join Date
    Apr 2013
    Location
    Belgium
    Posts
    443
    The bootloader IC is only activated when Teensyduino sends a 'programming signal' to the Teensy. For the rest of the time it is dormant, like it is not there in the first place.

Posting Permissions

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