PDA

View Full Version : Coming Soon: Teensy-LC (low cost Teensy)



Pages : 1 2 [3]

MichaelMeissner
01-21-2016, 07:35 PM
wow, thanks for the fast answer. Can I make it compatible, or is this an absolutely no :)

The Teensy 3.x chips use an Arm Cortex M4 chip, while the Teensy LC uses an Arm Cortex M0 chip. Among other things that the M4 has that the M0 does not have is a bunch of integer vector instructions where it does the operation on an integer sized value (32-bits) which are really parallel 8/16-bit fields. The audio libraries use these instructions to speed up the processing of the audio files. In addition, the M4 normally runs at a higher clock speed.

So, you may be able to do it, but it may involve adding #ifdef's to the code for LC support, and possibly not doing as much due to the slower processor.

Pensive
01-21-2016, 07:46 PM
Well most of the audio library uses advanced math not available on LC - this will probably never be implemented.

its possible to make parts of it work, I'm sure. It's unlikely to play Franks MP3 and AAC bits, but playback of WAV and RAW with some mixing and possibly some synth functions is quite possible. The power is there to achieve the basics.

I know Paul plans to do this to some extent - and has made some progress however small. But that's all I know.

if you like a challenge then go for it!

PaulStoffregen
01-21-2016, 09:48 PM
Sure, jump right in. Fork the code on github and start hacking. I've already done some work towards Teensy LC support, but much remains to be done....

The place to work first is output_analog.cpp. The entire library depends on at least one input or output object having update responsibility. You'll see some preliminary work has already started, but it's incomplete and utterly untested and certainly doesn't work yet.

I can't do a lot of guide your effort, but hopefully this can at least help you get a start in the right place.

MajorTom
01-29-2016, 07:16 PM
Understanding. I thought it would be nice to get it for the half price (LC). And the only thing I need was to use it as sample player... so the whole audio Effects / FFT code is not necessary.

I think not a huge task. But... anyway, I've an other (smarter an smaller) solution for this issue, without the teensy audio board.

pictographer
01-30-2016, 12:05 AM
I think not a huge task. But... anyway, I've an other (smarter an smaller) solution for this issue, without the teensy audio board.

What's your smarter and smaller solution?

1205tm
02-12-2016, 09:30 AM
is it possible to run a cheap bluetooth modul like the hc-05 or simular at the teensy lc?
thx for reply.

mcsarge
02-12-2016, 11:06 AM
Absolutely, I use it with the JY-MCU connected to Serial1. Works perfect!

mortonkopf
02-12-2016, 11:24 AM
Yes, I use HC-07 on Serial1 - for a simple test sketch see post #203 https://forum.pjrc.com/threads/27689-Teensy-LC-Beta-Testing/page9

mjhilger
03-02-2016, 12:17 AM
I apologize if this is obvious, but is the LC's internal analog reference for the ADC the same 1.2v as the 3.2?

PaulStoffregen
03-02-2016, 12:50 AM
No, there's no internal reference voltage on Teensy LC. Your only options are 3.3V power, or applying an external reference voltage.

The internal 1.2V references is unfortunately one of the features removed that allows the hardware to be so much less expensive.

MajorTom
04-30-2016, 10:02 PM
EEPROM: 128 Bytes are to small. I need min. 256 or better 512 . It's emulated, so it would be nice to update the EEPROM size for the Teensy LC and take another 1-2K from the flash size.

PaulStoffregen
04-30-2016, 11:50 PM
EEPROM: 128 Bytes are to small. I need min. 256 or better 512 .

You can get 255 by editing E2END in eeprom.h

https://github.com/PaulStoffregen/cores/blob/master/teensy3/avr/eeprom.h

255 (#define E2END 0xFE) is the maximum, since 8 bits are used for the address and 0xFF is reserved for unallocated space.

Increasing to 255 will consume more RAM on the stack when you fill up the flash and all 255 bytes need to be temporarily held on the stack while the flash is erased.

You'll also get less wear leveling, since the same 2K flash (supporting 1024 writes) will be used.



It's emulated, so it would be nice to update the EEPROM size for the Teensy LC and take another 1-2K from the flash size.

A huge change that breaks backwards compatibility with every Teensy LC already shipped just isn't going to happen.

If you need more memory, use Teensy 3.2 or an external EEPROM chip.

2_Wheeler
10-06-2016, 06:43 AM
I'm going to be using one of these for an automotive gauge project. I see in the specs it has a 5V output on pin 17? Is it possible to use this to power a NTC thermistor that is designed to work on 5V? I have tested it OK on 3.3V, but saw tonight the LC has a 5V output so I wanted to ask about this.

GremlinWrangler
10-06-2016, 08:34 AM
Depends on what you mean there. The 5V output is actual a Vin output so for powering a thermister it is the same as connecting it to the Vin pad, unless being able to depower it is a critical thing which this would allow. Would be cautious of what sort of analog stability you would get from this as well.

MichaelMeissner
10-06-2016, 12:03 PM
According to my notes, the VIN output on pin 17 can deliver 8mA. Note, the LC is NOT 5v compatible for digital inputs. If you read from the thermistor and it returns more than 3.3v, you risk damaging the Teensy LC. The pin on the Teensy LC is meant to drive ws2812b (neopixel) LED strings where pin 17 is the data stream, but the main power for the LEDs comes from VIN (typically 5v when you are using USB).

2_Wheeler
10-06-2016, 01:42 PM
Thanks for the answers. Would it be feasible to power the thermistor from the 5V input power (I'm using a hacked USB phone charger to step down 12V to 5V) and then read it on an analog pin? Do you think there would be any long term issues on powering it via 3.3V? I adjusted a resistor setting in the code and it gave a reliable reading. The datasheet says the coolant temp sensor is designed to operate on a "typical voltage supply" of 5V. Again, I appreciate the advice and education here.

Datasheet (http://pe-ltd.com/assets/coolant_temp.pdf)


Here's my project thread if you need it. (https://forum.pjrc.com/threads/37469-New-member-question-about-an-automotive-gauge)

EDIT
I took some voltage readings at the sensor pigtail at 84 degrees ambient:
Using 3.3V: 1.575V

Using 5V: 2.375

Continuing with 5V, I then used a hairdryer to heat the sensor.
129 degrees F: 1.175V Voltage continued to decline as temperature increased. The sensor has a range of up to 302 degrees F.

I then used a cup of ice water to cool the sensor:
41 degrees F: 3.619V

It looks like it would indeed go beyond 3.3V in colder weather at least until the oil warmed up.

GremlinWrangler
10-06-2016, 02:02 PM
Given it works from 3.3V it looks like there isn't anything particularly clever in it's internal design so would suggest sticking with 3.3V power and calling it done. If it had active components in there then it would be more likely you'd find min and max supply voltages but given it's >100 degrees operating enviroment there are probably no silicon components inside there, just some carefully crafted passives that as long as you don't run so much current through it that things melt will pretty much not care what's running through it. Would be nice if the data sheet was a bit clearer on the topic though.

If you wanted to do this right you run the sensor off 5V, and use an op-amp to shift it's offset and range to match the Teensy. This takes you into instrumentation amplification which is a useful design skill but probably more than you want to deal with on this particular project.

https://en.wikipedia.org/wiki/Operational_amplifier

Idea would be to set up one or possibly two amplfiers so you get the full analog range of the Teensy for the useful temperature range, and clamp things so you don't exceed the Teensy input tolerences (op amps normally have more robust inputs) while also probably doing some common mode noise suppression. As stated before this would generally be overkill for a temp sensor on an engine, but could be an interesting learning project if that's the plan.

2_Wheeler
10-06-2016, 03:04 PM
Being a noob on this stuff, I found out my resistor value in the code for 3.3V was way off, my 41 degree ice water read 93 degrees, so I need to either adjust something or go with another sensor to use 3.3V.

Here's the relevant code, which was accurate for both hot and cold ranges at 5V:

// Data for thermistor
int a;
float temperature;
int B=3975; //B value of the thermistor
float resistance;

I had changed the 3975 to get an accurate reading on 3.3V at room temp.

Then in the loop section:

a=analogRead(0);
resistance=(float)(1023-a)*10000/a;
//get the resistance of the sensor
Temp=1/(log(resistance/10000)/B+1/298.15)-273.15;
//convert to temperature via datasheet
Temp = (Temp * 9.0)/ 5.0 + 32.0; // Convert Celsius to Fahrenheit

The GM sensor I'm using needed a 2.2K + a 550 ohm resistor to give an accurate reading using 5V. I had arrived at that after using a spreadsheet with the table data from the datasheet. I can't understand the voltage input factor at this point, so I'm doing more reading.

If I'm using 3.3V, I'm presuming I need to change these. What formula to calculate this should I use?

As an alternative, I considered a digital sensor. I found this one (LMT01LPGM) at Mouser for under $3, it's a TI digital sensor that has an operating range of 5.5 to 2V:
Datasheet (http://www.ti.com/general/docs/lit/getliterature.tsp?genericPartNumber=lmt01&fileType=pdf)

Depending on the diameter, I could enclose it in a brass pipe fitting and add a pigtail to it.

2_Wheeler
10-06-2016, 06:20 PM
I did some experimenting with the resistors on the sensor, and by changing the 2.2K + 550 to 10K + 550 I was within .2 degrees between the two sensors at room temp.

I then immersed the sensor in another cup of ice water. After a few minutes, it dropped to 55 degrees where it had been 41 earlier. Substituting a 10K resistor lowered the reading to 54 degrees.

Next I retried the pan of boiling water. Where the sensor at 5V had been fairly dead on at 199 degrees (200 indicated on manual thermometer), after several minutes the sensor read only 103 degrees.

To verify my findings, I tried again @ 5V with the original 2750 ohm resistor. It immediately display 188 degrees, which by the time elapsed (the water had cooled) was consistent with the thermometer.

It seemed like it was very slow to respond to temperature changes as well. The sketch calls for a B value, which was 3975 for the 5V setup. I don't know enough to determine if the B value should change along with the sensor's resistors.

My conclusion at this point is that this sensor does not do very well with 3.3V. Absent another solution, I do not consider it usable here at 3.3V.

2_Wheeler
10-06-2016, 09:05 PM
Given it works from 3.3V it looks like there isn't anything particularly clever in it's internal design so would suggest sticking with 3.3V power and calling it done. If it had active components in there then it would be more likely you'd find min and max supply voltages but given it's >100 degrees operating environment there are probably no silicon components inside there, just some carefully crafted passives that as long as you don't run so much current through it that things melt will pretty much not care what's running through it. Would be nice if the data sheet was a bit clearer on the topic though.

If you wanted to do this right you run the sensor off 5V, and use an op-amp to shift it's offset and range to match the Teensy. This takes you into instrumentation amplification which is a useful design skill but probably more than you want to deal with on this particular project.

https://en.wikipedia.org/wiki/Operational_amplifier

Idea would be to set up one or possibly two amplifiers so you get the full analog range of the Teensy for the useful temperature range, and clamp things so you don't exceed the Teensy input tolerances (op amps normally have more robust inputs) while also probably doing some common mode noise suppression. As stated before this would generally be overkill for a temp sensor on an engine, but could be an interesting learning project if that's the plan.

Thank you for your help and suggestions. I need to learn about op amplifiers.

It seems like the best solution with what is mostly on hand is to craft a 3.3V capable sensor such as the one I linked above. I'd like to keep this project less complex electronics wise so that if another noob comes along they can easily repeat what I've done. I did some tinkering this afternoon with an old 1/8 NPT water temperature sender. I cut off the terminal and gutted the inside with a drill bit. Plenty of room for the above digital sensor (it is 4.1mm wide). It could be held in place inside the tube via some silicone and topped off with JB Weld. The next problem would be adapting that to a 3/8 NPT opening which is what is on the car. I looked at a 3/8 NPT plug and I think I can turn down the hex on the 1/8 unit and then solder the two together. The bit that sticks out would be sufficient to expose the sensor inside. I made something similar for a motorcycle Microsquirt project a while back. I also have a number of feet of some shielded 22 gauge wire on hand from another project that could be put to use here.

If this works out I'll likely make two gauge sets so I can use the second one to replace two existing gauges in another car.

MichaelMeissner
10-07-2016, 02:28 AM
If you have a 5v sensor that you want to read on a 3.3v system, one approach is to use an i2c analog reader (https://www.adafruit.com/product/1085) and a bi-directional level shift (https://www.adafruit.com/products/1875). Now, i2c is a slow bus, so it won't be appropriate if you are trying to read the sensors thousands of times a second.

2_Wheeler
10-07-2016, 04:03 AM
Thanks for the links. I've been reading datasheets today and going through some brass pipe fittings I have on hand. I was able to cut the end off of an old 1/8 brass NPT temperature fitting and drill it out. An 18B20 sensor fits inside it easily, but it cannot handle a high enough temperature range. I turned down the hex part of it and it will fit tightly into a 1/4 brass pipe plug. I ground down the end and it is now the same length past the thread as the GM sensor. The plug end can be opened up so the sensor could go in after the tube was soldered and then sealed as below.

The sensor I'm leaning toward now is the TI LM84T (http://www.ti.com/lit/gpn/lmt84) (data sheet link). It's under $1 at Mouser (http://www.mouser.com/Search/Refine.aspx?Keyword=595-LMT84LP), runs on 1.5 to 5.5V, is good to 150 C, and is 4.3 x 3.5mm. Using my design program it will fit into a 6.1mm ID / 7mm OD tube- it would almost fit into a 5.1mm ID / 6mm OD tube. McMaster-Carr sells inexpensive metric and SAE brass tubes as well as brass rods that can be used to cap them via soldering.

At this point, I'm leaning towards making my own sensor housing with the LM84T inside. It looks like the 6mm OD/5.1mm ID tube could be enlarged slightly to clear the sensor or I could use the next size up. Having a tight fit at the end would be a good thing for heat transfer. I could then insulate the leads with some 22 gauge TXL wire casing and some silicone sealant. The sensor could then be capped off with some JB Weld for a permanent install.

I read about people wanting to interface sensors with the Arduino for vehicle use, and if this works as planned it could help them in the future.

2_Wheeler
10-07-2016, 04:46 PM
Now that I have a viable sensor housing, I've been trying to learn about converting millivolts (mV) to degrees Celsius (C) for use with the LC, but have experienced severe brain fade. ;) Time to ask the experts.

The LMT84 datasheet specifies a lookup table, which was a spreadsheet in a zip file (http://www.ti.com/lit/zip/snic006). I downloaded it and learned:

The LMT84 sensor outputs in mV with a range of 1299 to 183.
1299 is -50 C and 183 is 150C.

Here is some math I performed:
The Teensy LC has a resolution of 12 bits and an analog voltage input range of 0-3.3V.
12 bits= 4,096 resolution compared to the usual 10 bit 1024.
3.3V / 4096= 0.0008056641 V resolution, or 0.8056640625 mV.

1299-183= a mV range of 1116
1116/4096= .2725 mV/degree

Since this is smaller than the .8056x above, does this mean the LC does not have the resolution to read this sensor in mV?

I'd prefer to avoid putting a lookup table into code, so I've been reading about formulas. It appears most of them are for increasing temperatures and increasing voltages.

As the LMT84 temperature increases, the voltage decreases.

I tried a few formulas I found and experienced the above brain fade. I have a lot of data, but don't know how to apply it.

Wade Hassler
10-07-2016, 06:43 PM
An LC can measure the temperature: you need to decide how much accuracy you need.
The output range of the LMT84 is 1.116 volts, which is (1.116/3.3)*(2^12) = 1385 counts of the ADC's range. Each degree would be 1385/(150 + 50) = about 7 counts.


The datasheet (http://www.ti.com/lit/ds/symlink/lmt84-q1.pdf) notes (in section 8.3.1 )that there is a parabolic shape to the volts/degree equation and offers some approximation equations.

2_Wheeler
10-07-2016, 07:17 PM
Thanks for the help. I went to math class with Barbie :), so I'm trying to work the equation listed. I came up with a negative number to square, which is impossible, so I've done something wrong.

2_Wheeler
10-07-2016, 08:34 PM
On the first equation, it calls for an undefined C, T, and mV, two of which (C and mV) I input from sensor specs using an example temperature (C) of 10 degrees and corresponding (mV) of 980. The second equation mentions solving for T, so I went on with it using the same 980 mV. I got T=36 using my spreadsheet and T=1380.91 using the online equation site. I remember now why I hated algebra class so much. :mad:

I saved both equations as JPGs I'll attach.

83768377

EDIT
I'm not sure how I missed it, but the TMP 36 (http://www.instructables.com/id/Temperature-Sensor-Tutorial/) appears to do everything I need it to do w/o all the complex math. The site says accuracy drops off above 125C, but I doubt my oil will hit 257F.

charnjit
10-10-2016, 09:47 AM
Can Teensy LC be re-programmed with new code after using as usb midi controller with pc.???

Frank B
10-10-2016, 09:50 AM
Yes.......

charnjit
10-10-2016, 11:01 AM
Thank u sir ,,, can i get direct link of all needed softwares for pc window 7(to make my own usb midi controller from teensy LC)

charnjit
10-10-2016, 11:38 AM
Please reply if any member from INDIA

Wozzy
10-10-2016, 12:07 PM
can i get direct link of all needed softwares for pc
http://www.pjrc.com/teensy/td_download.html

Omnigamer
10-30-2016, 03:45 AM
I'm fiddling with getting the LC working with the TLC5940 library, but so far my bit of hackery hasn't had any effect. The LC isn't officially supported by the library, but I assume that's just because the LC was released after the most recent update to the library and not because of some actual incompatibility. Before I dig too much deeper, does anybody know anything that would prevent the LC from working with this library the same as the 3.0/1/2?

For reference: https://www.pjrc.com/teensy/td_libs_Tlc5940.html

MichaelMeissner
10-30-2016, 04:07 AM
Note, the LC uses an ARM Cortex M0, while the 3.0/3.1/3.2 use variants of the M4 (and the 3.5/3.6 use variants of the M4F). The library plays with the underlying timers, pin configurations, and pin interrupts. So, you will likely need to delve deep into the datasheet of both the LC and the 3.2.

PaulStoffregen
10-30-2016, 05:44 AM
The LC isn't officially supported by the library, but I assume that's just because the LC was released after the most recent update to the library

By the time Teensy LC was released, that ancient TLC5940 had long become obsolete. Many better chips have replace it, and the need for PWM LED chips is much less now that WS2812B and APA102 addressable LEDs are so commom.



and not because of some actual incompatibility.


Teensy LC lacks the CMT timer peripheral which exists in all the Teensy 3.x boards.

PaulStoffregen
10-30-2016, 05:46 AM
You might look at ShiftPWM, using 74HCT595 chips and resistors. ShiftPWM was ported to Teensy LC.

Pensive
10-30-2016, 07:29 AM
Apologies if you read my post - it was related to the pca9685 not the TLC5940, therefore irrelevant and now deleted

Omnigamer
10-31-2016, 06:34 AM
My specific application requires constant-current all the time, so I was hoping to make use the DC mode on the TLC5940 rather than any of the PWM management. In the end I decided it was easier to write my own small library for interacting with it; works fine for the time being.

charnjit
11-07-2016, 10:54 AM
I want to make a midi controller using teensy LC . I have also code for this . Teensy loader is installed on pc. In Arduino 1.6.12 ,there is not option to select teensy lc in board. There is also no option to select midi in Usb Type. So , please tell me which version of Arduino is correct to make midi controller from teensy lc board ? ,,,,,,,, can be made midi controller from teensy lc using c or c++ ? ,,,,,,,,,Please give me any solution

MichaelMeissner
11-07-2016, 11:35 AM
You have to install the Teensydunio overlay to Arduino 1.6.12 (http://www.pjrc.com/teensy/td_download.html). The Teensydunio installation is a lot more complex than the Arduino board overlay system can handle.

charnjit
11-09-2016, 03:32 AM
2 push buttons are used to control 1 parameter in midi controller using teensy LC board.if I want connect only push buttons for maximum parameters. How many maximum buttons and how many maximum parameters can be control from teensy LC ?

Burly
11-11-2016, 03:51 AM
Three Questions:

#1. The two pin header holes marked 3.3v I assume get 3.3v output voltage from the VOUT33 pin on the processor. So these are not in any way used as input 3.3v to power the chip...correct?

#2. Why would I need to cut the jumper between VUSB and VIN. If I cut it, won't I will always need Battery power at VIN...even when using a USB cable for flashing or in a user program that employs USB?

#3. In applications where USB won't be used (no USB cable), we therefore need to power the board with 5v from an external source. What is the difference in powering externally through the VUSB header vs. the VIN header? I don't want to cut the jumper because I do want retain the option of powering the board solely off of a USB cable. But, if there is no USB cable present, I don't see any difference in powering externally from either VIN or VUSB. That's certainly what the schematic seems to show.

The bottom line is:
- if the board is being powered off a USB Cable, you should have 5 volts ouput power at both VUSB and VIN.
- if there is no USB cable present you can power with 5volts at VUSB...and draw 5volts at VIN....or...you can power with 5volts at VIN...and draw 5volts at VUSB.
Isn't that correct?

MichaelMeissner
11-11-2016, 04:25 AM
Three Questions:

#1. The two pin header holes marked 3.3v I assume get 3.3v output voltage from the VOUT33 pin on the processor. So these are not in any way used as input 3.3v to power the chip...correct?


Note, I'm a software guy, but.... You can power the Teensy through the 3.3v pins providing you have no power on the VIN pin (and VUSB if it is connected to VIN). As I understand it, USB won't work (if the VIN->VUSB solder pad is cut), because it needs 5v.



#2. Why would I need to cut the jumper between VUSB and VIN. If I cut it, won't I will always need Battery power at VIN...even when using a USB cable for flashing or in a user program that employs USB?


You might want to cut the connection if you are powering the Teensy by feeding it power through VIN. For example, you might need more watts than a typical USB connection might make. Or perhaps you have a lipo battery that powers the Teensy, and uses the 5v from VUSB to recharge the battery (for example, https://www.tindie.com/products/onehorse/stbc08-high-current-lipo-battery-charger/). Yes, if you cut the VUSB/VIN solder pad, you will need to provide appropriate voltage to VIN to power the Teensy when doing a download.



#3. In applications where USB won't be used (no USB cable), we therefore need to power the board with 5v from an external source. What is the difference in powering externally through the VUSB header vs. the VIN header? I don't want to cut the jumper because I do want retain the option of powering the board solely off of a USB cable. But, if there is no USB cable present, I don't see any difference in powering externally from either VIN or VUSB. That's certainly what the schematic seems to show.

The bottom line is:
- if the board is being powered off a USB Cable, you should have 5 volts ouput power at both VUSB and VIN.
- if there is no USB cable present you can power with 5volts at VUSB...and draw 5volts at VIN....or...you can power with 5volts at VIN...and draw 5volts at VUSB.
Isn't that correct?

In general, things are simpler if have power coming from only one source. If it comes from two sources without something like diodes to block the power going backwards, whichever power source is weaker will have current coming in from the strong source. As I said, you can use diodes to make the power go in one direction, but diodes take power also. Or you can do like I do, and just only plug in one source at a time.

Burly
11-11-2016, 05:36 AM
Hi Michael,

I totally agree about only having one source of power.
And I don't want to loose the ability to power strictly off of USB...so cutting the jumper is a non-starter.

I want to either be pulling power off the USB cable if one is plugged in.
Or, I want to be sourcing 5v externally when the USB cable is not present.
And in this case there is no battery charging involved.

But I'm still scratching my head over the schematic.

I'm spinning a new Base Board that will use the Teensy LC as a Riser Board.
When the USB cable is not present, I want to power with an external 5v source, by going in through the VUSB header.
It's much more convenient from a layout perspective than going through the VIN header.
I can't see where it would be an issue.

madmattd
11-11-2016, 12:38 PM
VUSB and VIN are one and the same if the trace/jumper is not cut. You can supply 5V through either header to power the on-board voltage regulator, but do not connect a USB cable from your computer to the board at the same time. If you do, you will have 2 5V supply outputs connected directly to each other.

If you will never have external power applied when you have the USB cable hooked up between the Teensy and computer, you do not need to cut the trace. If you intend to not unplug your external 5V power before reprogramming or otherwise utilizing the USB connector, you need to cut the trace, and then yes you will have to always apply the external power.

You can also supply a regulated 3V3 source to any of the labeled pins, but again you will need to cut the trace unless this power is disconnected before the USB is connected.


I removed this need on a custom Teensy-based solution I made by using an in-line diode for each of the VUSB and VIN pins. Yes, it wastes some power, but I can either leave my batteries hooked up or not when I connect the USB cable to the computer.

Burly
11-11-2016, 02:12 PM
Thank's MadMatt,

You're describing just how I thought things worked.
I wanted to confirm because I'm about send a board design off to OSH Park...
I didn't want any gotchas...
The rule of thumb is USB Cable...or External 5V Power...but never both at the same time.

Thanks again.

madmattd
11-11-2016, 04:22 PM
The rule of thumb is USB Cable...or External 5V Power...but never both at the same time.

Correct, you can leave the trace alone then. And 5V through VUSB, the USB connector itself, or VIN.

JanWagner
03-08-2017, 08:43 AM
One comment, something you could fix/update on the Teensy LC web page (https://www.pjrc.com/teensy/teensyLC.html)?

The table there says three "FTM Type" timers. But 3.8.1.1 of the manual (https://www.pjrc.com/teensy/KL26P121M48SF4RM.pdf) says the "device contains three low power TPM modules". So I guess the web page should say "TPM Type" timers, i.e. the old timers, not the new fancy extra versatile FTMs.

Similarly Teensyduino 1.35 header files do define FTM0_SYNC and FTM1_SYNC but these FTM things are not actually found in the manual, only TPM related registers and fields are listed. So perhaps also a header file bug...?

PaulStoffregen
03-09-2017, 12:02 AM
[QUOTE=JanWagner;136039]One comment, something you could fix/update on the Teensy LC web page (https://www.pjrc.com/teensy/teensyLC.html)?

I've updated the web page to say "TPM / FTM" with a footnote about their difference. Hopefully that helps?

JanWagner
03-13-2017, 01:34 AM
I've updated the web page to say "TPM / FTM" with a footnote about their difference. Hopefully that helps?

Thanks! The footnote helps! Table change, hmm, to clearly show which board offers which type of timer, perhaps you could expand the table like this?


Timers LC 3.2
TPM Type* 3 0
FTM Type 0 3
PWM Outputs 10 12

defragster
12-09-2018, 08:46 AM
It seems I am just seeing this OLD thread - at least in context to a 2/1/15 post - so old it predates my start here by some 13 days.

I haven't created a thread yet - just posts to get feedback on the debug_t3 library (https://forum.pjrc.com/threads/54201-Program-hangs-depending-on-code-length?p=190353&viewfull=1#post190353) where I pulled PJRC's Stack Dump and keep up the USB polling with a define in the lib for the weak fault handlers - and blink the LED ( or other pin ).
Indeed having the USB polling allows the faults I've found software reprogram and to do extended USB output - even bi-directional SerMon commands (reset/bootloader/continue) and call into user code to a declared weak function the user can define to do as they choose.

I haven't gotten much feedback yet - as faults are rare. It has a long TODO list and needs a rewrite to allow use/test of any Serial#. It may be handy with T_4 - if it can run similarly there … and odd things happen porting other stuff.