Easiest and maybe effective in some fashion - unless the included library examples were altered:
This 320x240 color TFT display is recommended for use with Teensy 3.2 to Teensy 4.1, for high resolution color...
Yes, I copied from that link in post #2 to resolve the problem ...
It seems a bit distant {with two interposed lines} as it gets missed? And the examples for the prior linked display library include the Analog not...
Good results Fast!
Yes, that confusion has come up before where the display examples don't fit the PJRC display.
@Paul might see this - but there is a 'Web-site-could-use-a-few-updates' edits needed thread - if...
The post seen should resolve your issue.
To answer this - some Touch Screens present analog output to represent the touch position. The PJRC display has onboard logic to parse the analog values and present them...
That uses library #include "TouchScreen.h"
That is not the one for the PJRC display.
Use a sample from this library folder: github.com/PaulStoffregen/XPT2046_Touchscreen/tree/master/examples
That uses library:...
OC Trial posts long ago - but not sure it ever has worked over 1.08 GHz.
Internal voltage has to rise as the speed goes up - and over max spec voltage before 1.08 GHz.
There is some cusp/spike internally when it...
Indeed 71.582788266666666666666666666667 Minutes - the question mark was there for a reason ... Opps
There is a 1 ms interrupt that is used to track Millis() systick - that is also the base of Micros() response...
That reply suggests proper setup - both methods resolve to SdFat code - but getting to SDIO is unique - provided examples should make it clear. Once they are setup they are using the Max Perf Code - as long as they are...
@mnissov - will go back to the necro thread linked above if I update the PPS/intervalTimer code. It won't be any good for microsPPS() unless the PPS is reliable - or deals with misses. With an RTC versus GPS it should...
@mnissov : Opened/soldered/wired the SparkFun GPS Logger Shield to a T_4.1. Got Space Data Fix in the window, saw UART strings and went to the indicated code and made what seem to be improvements. No time now to add...
All three are perfectly good options: Millis, Micros, ARM_DWT_CYCCNT. Which to use depends on the needs and limitations of the timing at hand.
All can be used 'bare' in the fashion of the p#4 code:
uint32_t start...
Interrupts are a mixed blessing with 'shared data/purpose'. Same PRI means one can delay the other - diff PRI means one can interrupt the other :)
Not questioning RTC accuracy/correctness - saw Digikey Eval board and...
Just in case it helps with time sync and analysis.
Code used above came from this 2 year old @PaulStoffregen post "Here's a little program to automatically adjust the IntervalTimer period.":...
Just seeing this ... not seeing all code where 'micros_from_second' is accessed.
Is this _isr on the same priority as the others? So they cannot interrupt each other and have the second change a volatile value? And...
From the included ILI9341_t3 and assuming in the _t3n extension library use: void setClock(unsigned long clk) { _clock = clk;}
The default is 30Mhz and if 60 MHz is used in setClock() that value will be used for all...
Note in p#11: "if I press a little harder" suggests it works either from a firmer press making the button 'close' fully to indicate the press as needed, or added dwell time from a longer 'harder' press allows the...
On T_4.0 bottom side pads? That D+ and D- are to USB_Host port. Data could be sent to a Device - but not to a Host using those underside pads.
Device could be a hard drive or flash drive or other supported device...
Not seeing a clear resolution path given the info as it seems unique and odd.
USB Hub here occasioanlly goes offline on upload and all devices go away - have to unplug the USB to PC cable and all is well.
What OS...
Indeed, a hub on USB host is supported, and if powered allows more and high current devices.
Not sure what those USB parts shown are? Looks like they are just two USB device sockets wired with connections for each?
The Teensy Micromod Beta thread did camera imaging - finding that thread would give a good idea of what it can do. It didn't do continuous SD card saves. Active writes to tft display gave about 15 fps -
Seems the...
Might depend on the device - the 'generic' device following the protocol versus some other?
@tonton81 did a SPI Master/Slave Teensy to Teensy library with err check and other control elements where he could program...
Production Teensy 4.x's ship with fuses locked that ensure long happy unbricked life.
The 1062 MCU is the same Production or Locked, the diff is the Fuse settings.
Looking at the ic_mkl02_t4.html link text it...
Made local.txt changes and they were also ignored.
There are cached settings - there is a folder that needs to be removed with IDE 2 closed - See item #4 this post: Arduino-CLI-And-IDE-now-Released-Teensy-Supported!...
I see that isn't 'Windows'. I've made at least one IDE 2 .local. edit that worked - under Windows using "that path".
Though IDE 2 does some caching for those .txt files - not sure if that is causing trouble seeing...
Find the location where the boards.txt and platform.txt are located. Copy the .local. files there and restart the IDE and it should work.
On Windows this opens the folder holding the installed board 0.58.3 {for Beta...
Please include a minimal but Complete sketch. Without that assuming the SD Card is wired to the T_4.0 Underside for SDIO demo.
Also on desk here is a T_4.0 with an SD card well mounted and tested (thanks to...
At least one of those pin #'s look odd compared to the posted/expected pin numbers for Teensy 4.1?
Try showing a mapping with Pin function to make the list readable for pin intended use:
T_4.1 #13 <> AShield #14 ::...
Interesting note. Since T_4.0 beta hardware, the LTO that worked well with new T_3.6, it regularly failed so it just never got used. And looking at optimized options LTO has been removed at this time. Perhaps due to the...
Snippets and pieces questioning function were presented here, so just looking up and linking docs and info to show intended use.
Good it has been made to work - Bug Free - in the actual system.
@KD5RXT :)
@Kalinchuk: Also, may be a private copy of old non-PJRC copy of SdFat in \libraries folder.
That will show in verbose console output in the 'libraries Used or Not Used section'.
The working version is the one...
Before you posted the enormous gains I was going to ask how the samples are acquired? ... Snippets don't show that ...
And given floats - maybe it doesn't involve an ADC digital value read at all ...
If reading...
Snippets again? :)
Okay - misread the problem then - didn't see the "if (!spibegun)" - and not sure what that "spibegun" is ???
if (!spibegun) {
Serial.println( "begin spi" );
SPI.begin(); ...
Cool. 35 cycles per float element didn't seem unexpectedly out of bounds
Wonder if the array diff is because it might use *ptr indexing versus indexing ...
SPI.begin(); needs called just one time, typically in setup().
As for mode this (one of many) came up on search: corelis.com/education/tutorials/spi-tutorial/
If CPOL and CPHA are both ‘0’ (defined as Mode 0) data...
Not at a place to run the code - hoping others might ...
Note Pin 13 is SCK - so setup pinMode(13) will be reset in spi.begin. Not used after - but had to check after seeing that.
Second 'test' case doesn't include...
Opps - knew note was a bit wrong as PJRC gets to control Ser# progression.
Also wondered about User code timing with a hook versus CORES edit - and noticed there is a 'weak' on the related Ser# string?
The IDE does some pre-processing work to find and locate the needed libraries and organize the INO's and pre-define for the user functions declared after use, so the user need not do that. In lieu of a MAKE created and...
Teensy Serial number is derived from a fixed read only MAC value on each chip set by NXP at the factory: ...\hardware\teensy\avr\cores\teensy4\usb_desc.c
void usb_init_serialnumber(void)
{
char buf;
uint32_t i,...
How big is the code on the SD card? Known to be small or large or unknown? Is it a self standing snippet() that doesn't call anything to be linked?
Code can't execute from RAM2 (per the .LD file - OLD??), and in...
The code included for SdFat is the full source library. Only some glue edits for PJRC inclusion and use as SD.h replacement.
If not used through SD interfaces the features of SdFat are there 'natively' and the...
Heat not too bad at those speeds - usually. If it is heat, the CrashReport() output would indicate that. If it is Crashing through that code - there may be an 8 second delay - though with TEMP fault not sure the timing...
The use of CrashReport @KurtE suggested will indicate if there is a TEMP issue with overclocking that can get unusably hot.
What OC speed is being used?
For ref and tracking Temp monitor code looks like:
...
Great if you can see it work on the Beta of 1.58 so it might get changed and work going forward with the new toolchain.
Interesting - seems a simple alignment/location issue of a couple of bytes the linker can get...
@Paul - with Two T_4.1's connected Neither will program 'automatically' with IDE 2.0.3 they both give:
C:\Users\Tim\AppData\Local\Arduino15\packages\teensy\tools\teensy-tools\0.58.3/teensy_post_compile"...
It might be best to confirm with the 1.58 Beta install - currently #3?
The tool chain is getting updated and if the linker script change is safe and good - and it works with the pending update to the toolchain it...
ICK - Flooded with Flux - if all that shine around the pins (on both PSRAM and FLASH) is flux and not a photo aberration.
Chip label isn't legible to confirm make or type. But if a normal 8 MB PSRAM it should work,...
@Jayjer66 if you can upload a picture of the soldered PSRAM we can see it to confirm.
And the Pin1/DOT of the PSRAM as shown in p10 image should be nearest corner Pin #32.
Also, where did you get the PSRAM - and...
If you are seeing this: "EXTMEM Memory Test, 0 Mbyte"
> And the Teensy LED is FLASHING then the PSRAM is not being recognized. That is what I see on a T_4.1 with NO PSRAM installed.
> When a PSRAM is found and...
Is there any output on the serial monitor?
Built with USB Type: Serial
There should be output when it connects. That program will sit and do nothing until Serial connects with: while (!Serial) ; // wait
That is...
That looks close to what I have here. If you have TeensyDuino 1.57 it would have diff size as the Beta of 1.58 is in use here with an updated tool chain that grows code.
Glad to help. The IDE gives a decent usable...
Yes, that is not a 'library' - just a 'sketch' folder.
Don't place the folder in "/users/justin/documents/arduino/libraries"
Put it in your normal sketchbook or other folder and in the IDE just open the file:...
@PaulStoffregen: in furtherance of p#45,46 and #43
Using setup as in pjrc.com/threads/71975-Teensy-4-1-psram-memtest
Built again for T_4.1, did code edit to print added File&Date in setup() just to see the build to...
Starting with a T_4.1 and PSRAM soldered - Cool. github.com/PaulStoffregen/teensy41_psram_memtest
Then A copy of the Arduino IDE needs to be installed 1.8.x or 2.x.
Then Current TeensyDuino 1.57 for the IDE 1.8.x,...
But, no board was in Bootloader when IDE was told to Build/Upload.
Somehow this T_4.0 board was 'addressed' to go to bootloader - even when the T_4.1 or T_MM were the selected port.
That's a helpful current drop - and a good/better temp drop.
Heat sinks can help if there is good air transfer - fans are better esp together.
Getting excess waste heat from the 3.3V reg will help.
Hopefully...
Not seen Ethernet power called out before.
283 mA explains the temp of the 3.3V regulator.
Was 528 MHz build tried? It may still have the needed speed and makes a measurable difference in internal processor...
That seems warm. You might drop to 528 MHz and see if you get the needed performance and measure the temp and current diff.
Normal T_4.1 current is closer to 100 mA - so that temp at 80 mA suggests the board isn't...
On Teensy 3.x any call to micros() - as done by delay() will leave with: __enable_irq();
This is NOT that case on Teensy 4.x with the code for micros() with atomic enforcing code to tolerate millis tick updates.
...
Interrupt code can easily be broken. Not having the .end() before the next interrupt was queued was the problem. Paul has made a change to the CORES to alter the behavior, but as noted in p#3 it was expected behavior as...
That p#15 code should only print anything on button change.
Though the delay(100) could be better handled and only delay when there was a change detected. As written any button held over 100+ milliseconds should be...
Just made @luni edit p#19 as suggested to prior code with 'LATE .end()' and indeed that is clearing the pending interrupt! :: channel->TFLG = 1;
> Paul suggested a fix forthcoming on the intervalTimer page - maybe...
Found the edit for .end() - good.
But, English fail here: IntervalTimer will call you function from interrupt context.
Would read better as: IntervalTimer will call your function from interrupt context.
Try this - maybe as is - it was not compiled:
const int numButtons = 16;
bool bLast;
void setup() {
Serial.begin(38400);
for (int i = 0; i < numButtons; i++)
pinMode(i, INPUT_PULLUP); // IF CHANGED TO...
Does one of those present the expected readings of the buttons? Perhaps the first where one is noted as pressed?
This line is not clear: if (digitalRead(i) == INPUT) {
For working PULLUP it should read: if...
Only the specified 1062 versions are supported by the PJRC bootloader.
The T_4.0 started life as a 1052 and was functional, but the 1062 released in quantity after first beta, and offered a better processor and only...
That is pretty well HIDDEN :(
If you can get a meter across the button from GND testing for continuity it probably just closes a switch.
Test for Ohms and it may show there is a resistor inline with the button...
Thanks for complete code - wrongly assumed there were two competing IntervalTimer()'s.
SEE POST #3 for the ANSWER!
code re-ordering moving .end() up to top : needed change marked in testinner( )
Gives this correct...
Not sure if this adds anything not known? PJRC includes code for T_3.6 going over 120 MHz down to 120 MHz and exiting hsrun to program the EEPROM that cannot be done in hsrun mode, then returning the HSRUN and prior...