Teensyduino 1.55 Beta #1

Status
Not open for further replies.
Just as a follow-on I tried it with a Teensy Micromod, and the Teensy 4.1, and all worked without a problem using the test sketch that @KurtE posted in post #275. Did confirm that you can creates, update and refreshes in explorer using the F5 button, etc. Also can confirm that the data is retained across restarts and power cycles.
 
and now with this beta with T4s being able to preserve the upper part of the flash, and also my assumption that this will also be true for T4.1 and MicroMod?

Yes. Or at least yes in the sorta-near future when those boards get the new 1.07 bootloader, all the T4.x boards will auto-wipe only 512K or 1M depending on security mode.

Today, except for these new beta test lockable boards (currently in the hands of only 5 people outside PJRC) and the very earliest beta test boards from 2019 before Teensy 4.0 release, all Teensy 4.0 & 4.1 have bootloader 1.05 and all Teensy MicroMod have bootloader 1.06. All versions before 1.07 fully wipe everything below the EEPROM emulation data.


Note: I am using a slightly updated version of the MTP library for this
....
But first off wondering if this is something interesting and then how far we should take it.

Yes, I absolutely am interested in this. I wanted to do this and so much more in 2020, after the release of Teensy 4.1 (in May 2020). Then of course the pandemic happened, draining away nearly all my dev hours while we struggled to keep PJRC running. Only recently has PJRC more-or-less returned to normal, which is why I've finally been able to work on this code security project. Code security is also a strange situation where I can't involve everyone else as I normally would, due to NXP's NDA, which is why I've been pretty quiet about this until it was mostly done. I happy to see we're now looking pretty good on code security. I hope to have the docs cleaned up tomorrow. I did half the MacOS port over the weekend, so more work needed there. And I still have a list of relatively minor bugs to fix in Teensy Loader.

So to specifically answer how far we should take it, my main thought is to release 1.55 sometime in September with code security and pretty much only minor fixes and updates, then focus on MTP integration, expanding the filesystem abstraction layer, MSC, and maybe an update of SdFat for version 1.56, to be released in December time frame.

It's tempting to work on the fun stuff now (and always). You definitely should. I need to focus on getting code security wrapped up and a stable 1.55 release. If I start pouring a lot of time info filesystems now, it would be a lot more fun, but we probably wouldn't get to any stable releases until well into 2022.
 
@Paul - Sounds good. A few of us will likely start (continue) parts of this and hopefully have pieces of it ready for you to play with, when you are ready.

So the new T4, in my PMB in town, does not have the option to only erase a portion...

In your first post you mentioned:
Standard Teensy 4.0 made after June 2021 can also run encrypted programs
So curious what is the differences in these newer one versus ones maybe made in March? Also does this only apply to T4?
 
Quick and clean TD 1.55 sounds good.

As far as that T4 Beta Breakout - has POGO's - but pin test not triggering ... so something missing ...
 
Good and not so good news (may be) :)

Good first: I recently upgraded to GCC 10.3.1 , and thought, let's try coremark again. With -O2 it reaches 2403 coremark. (5.4: 2295) - 100 "coremark" more.

Not so good news: Coremark crashes. Even with the old GCC 5.4 when using -Os . I don't remember that it crashed in the past.
Gcc 10.3.1 produces crashing code, too.


Edit: Everything OK.. the coremark code I ran was not the one from Paul`s github.
 
Last edited:
all good.
however, gcc 10.3.1 with -O3 still crashes. but that's not a problem.

In fact it crashes even with blink... before CrashReport.

hm.
 
@defragster - Not sure where my early T4 beta board is right now :eek:
...
So for the fun of it, @mjs513 and myself did a quick and dirty updated version of the new simple logging program, that also sets up MTP.

...

Good work Mike and Kurt!

I quickly/successfully hacked in a quick 5X log of micros on 's'tart of logging (both work about the same ~5 us with some jump), and then added in 2nd storage with DMAMEM :: github.com/Defragster/T4LockBeta/tree/main/MTPlogger

Both PROGMEM & DMAMEM working here - Windows 11 - and both persist across Uploads! >> On the LOCKED T_4.0 Beta.

Kurt - not sure the Beta Breakout with POGO had usable SDIO routing? As noted NewPinTest failed to on trigger most of those SC pins? Though seems to have see PCB traces? And I have seen my Hyper breakout recently ... but not sure where that was. I'll see if I can convince myself to solder the other TallDog breakout.
 
Last edited:
Gcc 10.3.1 with -O3 crashes in startup, here: memory_copy(&_sdata, &_sdataload, &_edata);
I'll stop posting here now about that - I'll try to find the problem and if I'm successfull I'll post in a new thread.
 
Gcc 10.3.1 with -O3 crashes in startup, here: memory_copy(&_sdata, &_sdataload, &_edata);
I'll stop posting here now about that - I'll try to find the problem and if I'm successfull I'll post in a new thread.

Good to know you are checking it out. Not sure many of the options have tested to work perfectly with the current GCC. Having some understanding of what can work when time for that 'fun' arrives. And 5% faster CoreMarks is cool. Will watch for new thread.
 
With -O3 it is again slower than with -O2

Fix: https://github.com/PaulStoffregen/cores/pull/599

Edit: GCC10 works pretty well. (Like GCC9 did)
- But I've used it only with O2 so far. Absolutely no problems. It has less bugs, but is not always faster. It finds more problems and prints more warnings, which is good.
However, in the months/years it was not my priority to compare performance of generated code between GCC versions.

BTW I found that gcc 5.4 is now faster, too. Paul has 2313 in his table but is now 2477 with O3 :) (perhaps due to optimizations to the core over the years?)
(...and only 2391 for GCC10 O3)

Note: it is possible that you get contrary numbers with other benchmarks. It depends on the code.
 
Last edited:
Today I picked up my new T4 at my PMB fresh from PJRC (non-beta).

So I thought I would try the Teensy 4 security on it.

So I tried running the Fuse Write sketch:
It ended with the fast blink...
But the output shows:
Code:
Writing public key hash
public key hash is good :-)
Writing secret key
key written, setting config

Testing Bus Encryption Engine
Success: ciphertext decryption test passed :-)

Error: JTAG can not be disabled

Error: Secure mode can not be set
So looks like Maybe parts of it may be in place?

So Tried @defragsters T4MemInfoKitchenSink sketch...
Code:
C:\Users\kurte\Documents\Arduino\Github\T4LockBeta\T4MemInfoKitchen\T4MemInfoKitchen.ino Aug 24 2021 08:57:37

	deg  C=60.673077	 F_CPU=600000000
_stext        00000000
_etext        000066a8 +26280b
_sdata        20000000
_edata        20001bf0 +7152b
_sbss         20001bf0
_ebss         200042c0 +9936b
curr stack    20077fb0 +474352b
_estack       20078000 +80b
_heap_start   20203060
__brkval      20204000 +4000b
_heap_end     20280000 +507904b

<ITCM>  00000000 .. 00007fff
<DTCM>  20000000 .. 20077fff
<RAM>   20200000 .. 2027ffff
<FLASH> 60000000 .. 601fffff

avail STACK   474352 b   463 kb	<<RAM1
avail HEAP    507904 b   496 kb	<<RAM2


++++++++++++++++++++++
Size of Free ITCM in Bytes = 6484
Start of Free ITCM = 26284 [ 66AC] 
End of Free ITCM = 32768 [ 8000] 
ITCM DWORD cnt = 1621 [#bytes=6484] 

---	hab_csf
6000A800 - 00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  : ........ ........
...	 6 duplicate line(s) removed.
6000A870 - 00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  : ........ ........
---	ITCM used
000056AC - BF F6 4B AE 54 EA 05 03  7F F4 4D AE 38 AE 30 34  : ..K.T... ..M.8.04
000056BC - 06 F8 41 4D 28 AB 9B 1B  08 93 08 9B 43 45 B8 BF  : ..AM(... ....CE..
000056CC - 43 46 04 93 00 23 0E 93  8A E6 0C 93 A8 46 00 2A  : CF...#.. .....F.*
000056DC - 40 F0 28 87 1B F0 20 0F  C2 48 00 F0 86 80 09 9F  : @.(... . .H......
000056EC - 07 37 27 F0 07 03 D3 E9  00 45 03 F1 08 02 09 92  : .7'..... .E......
000056FC - 1B F0 01 07 00 F0 47 82  54 EA 05 03 00 F0 A3 84  : ......G. T.......
0000570C - 00 27 30 23 9D F8 30 20  8D F8 50 30 B8 45 8D F8  : .'0#..0  ..P0.E..
0000571C - 51 20 8D F8 4F 70 4B F0  02 03 C0 F2 17 86 2B F0  : Q ..OpK. ......+.
---	ITCM filler to DTCM	 test 3 
000066AC - 01 00 00 00 01 00 00 00  01 00 00 00 01 00 00 00  : ........ ........
...	 403 duplicate line(s) removed.
00007FEC - 01 00 00 00 01 00 00 00  01 00 00 00 01 00 00 00  : ........ ........
00007FFC - 01 00 00 00                                       : ....
 ITCM Start: 
 Given addr of 0  *Skipping Addresses < 32 to avoid access violation
00000020 - 10 B5 05 4C 23 78 33 B9  04 4B 13 B1 04 48 AF F3  : ...L#x3. .K...H..
00000030 - 00 80 01 23 23 70 10 BD  F0 1B 00 20 00 00 00 00  : ...##p.. ... ....
00000040 - A4 66 00 00 08 4B 10 B5  1B B1 08 49 08 48 AF F3  : .f...K.. ...I.H..
00000050 - 00 80 08 48 03 68 03 B9  10 BD 07 4B 00 2B FB D0  : ...H.h.. ...K.+..
00000060 - BD E8 10 40 18 47 00 BF  00 00 00 00 F4 1B 00 20  : ...@.G.. ....... 
00000070 - A4 66 00 00 F0 1B 00 20  00 00 00 00 00 00 00 00  : .f.....  ........
00000080 - 15 4B 04 21 15 4A 1B 68  12 68 9B 1A 00 EE 10 3A  : .K.!.J.h .h.....:
00000090 - 9F ED 0F 7B B8 EE 40 0B  10 B5 11 4C 20 EE 07 0B  : ...{..@. ...L ...
Verify secure code is running properly

Fail: Bus Encryption Engine is not active
Fail: Encryption region starts at wrong address
Fail: Program data is not within encrypted region
Fail: title_function() is not in encrypted region
Fail: title_text[] is not in encrypted region
Fail: csf is Zero

From the Teensy verbose data:
Code:
08:57:39.466 (ports 2): hid,  opened handle
08:57:39.466 (ports 2):  devinst=0000001A, location=usb:0/140000/0/1/1/1
08:57:39.466 (ports 2):  vid=16C0, pid=0478, ver=0105, usepage=FF9C, use=0024
08:57:39.466 (ports 2):  devpath=\\?\hid#vid_16c0&pid_0478#8&1f0a2482&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
08:57:39.467 (ports 2): usb_add: usb:0/140000/0/1/1/1  hid#vid_16c0&pid_0478 (Teensy 4.0) Bootloader
08:57:39.562 (loader): remote cmd from 1596: "status"
08:57:39.573 (loader): Device came online, code_size = 2031616
08:57:39.576 (loader): Board is: Teensy 4.0 (IMXRT1062), version 1.05
08:57:39.590 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_491632\T4MemInfoKitchen.ino.hex", 46080 bytes
08:57:39.602 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_491632\T4MemInfoKitchen.ino.ehex", 46080 bytes, 4960 extra
08:57:39.609 (loader): ehex is valid, key hash: FB63C934 9683889D 3A20DB52 811A0593 83BEA33F 0F810CDF D6AD3C83 5DF1DA1A
08:57:39.616 (loader): set background IMG_ONLINE
08:57:39.640 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_491632\T4MemInfoKitchen.ino.hex", 46080 bytes
08:57:39.652 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_491632\T4MemInfoKitchen.ino.ehex", 46080 bytes, 4960 extra
08:57:39.657 (loader): ehex is valid, key hash: FB63C934 9683889D 3A20DB52 811A0593 83BEA33F 0F810CDF D6AD3C83 5DF1DA1A
08:57:39.663 (loader): elf appears to be for Teensy 4.0 (IMXRT1062) (2031616 bytes)
08:57:39.669 (loader): elf binary data matches hex file
08:57:39.673 (loader): elf file is for Teensy 4.0 (IMXRT1062)
08:57:39.678 (loader):[COLOR="#FF0000"] using hex file - Teensy not configured for encryption[/COLOR]

So not using the .ehex...
 
@KurtE - Only the new 1.07 bootloader (w/TD1.55 Loader) can do encrypted upload even if Teensy could do encryption.

Wonder if the 'new' is past the 'change' date? Not sure if Paul noted yet - but assuming those 'newer' must have another fuse set/change from factory - but 1.05 bootloader.

... Given a Teensy in hand it isn't clear what it is capable of. This is the hard part to document and set expectations.

@Paul - wondering if the 'Teensy 4 Security' security sketches might include a Fuse Read for their VALUES and if (UN)LOCKED. Could tell a user what: "Teensy at hand Can/Cannot" do?
> Maybe an Added First Sketch just to indicate Teensy capabilities, or common funcCapabilites() in one or more of the current sketches
-> Fuses already Locked, or Not
-> Current Fuse state allows : Code Encrypt or Not ...
> of course some of that 'info' is tied to bootloader version (1.05, 1.06 .vs. 1.07++ )- and the sketch can't tell that, But TLoader can.
-> So that would be a 'Push Button' now to see the Teensy State?


For T4MemInfoKitchen.ino That's the same second beta with no fuse changes here shows:
Code:
Fail: Bus Encryption Engine is not active
Fail: Encryption region starts at wrong address
Fail: Program data is not within encrypted region
Fail: title_function() is not in encrypted region
Fail: title_text[] is not in encrypted region
Fail: csf not PJRC
NOTE: hab_version == 0x40307
NOTE: hab_status NOT == 0xF0
Secure mode NOT SET

Note: Kitchen (w/lfs:pROG) and Sink (w/temp check) are two diff sketches.

Updated last 3 lines output came from the final lockSecureMode sketch ...
 
Thanks @defragster - I was just sort of curious as the first post stated:
Code:
Standard Teensy 4.0 made after June 2021 can also run encrypted programs, but the final secure lock mode can't be set. 
Running encrypted programs that way is akin to locking your door but leaving the window open. Still, might be worth trying. 
Anyone can open this window, create their own key.pem file, and get .EHEX files created.
So as part of our beta testing, I thought I would try it out.

I was curious if it by chance maybe had a new version of the firmware: But I see:
Code:
08:39:23.189 (loader): Board is: Teensy 4.0 (IMXRT1062), version 1.05
Maybe difference of RevB of the chip instead of RevA?
Or ???

Again just another Random Test...
 
Last edited:
Thanks @defragster - I was just sort of curious as the first post stated:
...
Or ???

Again just another Random Test...

Interesting to test - the process should let the user know as they go in some fashion.

Only Paul knows for sure ... seems like maybe alternate default factory fuse settings based on Paul's WIP. The linked Kitchen sketch could print Fuse Values of OLD and your NEW (post June?) production versions?
From PJRC's LockSecureMode line : if ((HW_OCOTP_CFG5 & 0x04C00002) == 0x04C00002) {
> Seems it might show with : Serial.print( HW_OCOTP_CFG5, HEX );

Though until TLoader pushes a bootloader update AFAIK they will all act the old way - except these Beta DIY/Secure Special units under test having 1.07.

Looks like the Kitchen INO needs the last lines the Sink.INO has for the final two lines - will try with added print above ...
 
Update Github :: Kitchen and Sink: Defragster/T4LockBeta

Beta - not yet locked - No Key Set
Code:
Fail: Bus Encryption Engine is not active
Fail: Encryption region starts at wrong address
Fail: Program data is not within encrypted region
Fail: title_function() is not in encrypted region
Fail: title_text[] is not in encrypted region
Fail: csf not PJRC
NOTE: hab_version == 0x40307
NOTE: hab_status == 0xF0
Secure mode NOT SET :: Fuses == 0x8B018

Beta - LOCKED:
Code:
Pass: Bus Encryption Engine is active
Pass: Encryption region starts at proper address
Pass: Program data is entirely within encrypted region
Pass: title_function() is within encrypted region
Pass: title_text[] is within encrypted region
Pass: csf is PJRC
NOTE: hab_version == 0x40307
NOTE: hab_status == 0xF0
Secure mode IS set :: Fuses == 0x4C8B01A
 
I thought to be complete on thest, I would pull out my parts reserve an older T4 (OSH Park addition) and ran the FuseWrite sketch:
And it did fail differently:

Today I picked up my new T4 at my PMB fresh from PJRC (non-beta).

So I thought I would try the Teensy 4 security on it.

So I tried running the Fuse Write sketch:
It ended with the fast blink...
But the output shows:
Code:
Writing public key hash
public key hash is good :-)
Writing secret key
key written, setting config

Testing Bus Encryption Engine
Success: ciphertext decryption test passed :-)

Error: JTAG can not be disabled

Error: Secure mode can not be set

Code:
Writing public key hash
public key hash is good :-)
Writing secret key
key written, setting config
Error: Key can not be used

Testing Bus Encryption Engine
Error: ciphertext decryption did not match plaintext!
  plain:  0A 22 D3 E6
  cipher: 70 89 4C D0
  dcrypt: 70 89 4C D0

Error: JTAG can not be disabled

Error: Secure mode can not be set
Probably all for now on that front
 
@Paul : Fireworks - well SUPER ODD FLASHING ...

IDE did Verify of the sketch above : T4LockBeta/tree/main/T4MemInfoSink

IIRC :: Then pushed button on Beta T4 Ser# 10379960, that has no KEY pushed yet, and of course not LOCKED. The LOCKED T4_Beta was also ONLINE Ser#10379970

<<EDIT>> :: I may have the Ser# and status swapped - I see I have the LOCKED is #70 one on the wrong colored cable - and thought that was the UNLOCKED #60 one that FLASHED both LEDS.

It tried to program and resulted in BOTH RED LED and the Pin #13 LED Flashing ON/OFF together in unison:

Here is the TLoader Verbose where I switched from Kitchen upload to SINK upload - Kitchen worked - then first SINK FAILED WITH LEDs FLASH - then Button again worked?:
I really saw the DUAL LED FLASH - hopefully you known what that means or the Verbose will show you if
Code:
15:35:59.120 (ports 5): nothing new, skipping HID & Ports enum
15:35:59.742 (loader): redraw, image 9
15:38:25.633 (post_compile 77): Begin, version=1.55-beta1, high-res time
15:38:25.638 (loader): remote connection 1492 opened
15:38:25.638 (loader): remote cmd from 1492: "comment: Teensyduino 1.55-beta1 - WINDOWS (teensy_post_compile)"
15:38:25.638 (loader): remote cmd from 1492: "status"
15:38:25.639 (post_compile 77): Sending command: comment: Teensyduino 1.55-beta1 - WINDOWS (teensy_post_compile)
15:38:25.639 (loader): remote cmd from 1492: "dir:C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\"
[B]15:38:25.639 (loader): remote cmd from 1492: "file:T4MemInfoSink.ino.hex"
15:38:25.640 (post_compile 77): Status: 1, 1, 0, 40, 0, 0, C:\Users\Tim\AppData\Local\Temp\arduino_build_857620\, T4MemInfoKitchen.ino.hex[/B]
15:38:25.640 (post_compile 77): Sending command: dir:C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\
15:38:25.640 (post_compile 77): Sending command: file:T4MemInfoSink.ino.hex
15:38:25.656 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.hex", 113664 bytes
15:38:25.669 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
15:38:25.669 (loader): ehex is valid, key hash: 85A79CC1 B7C7F866 7F5BB3ED 0F9C9BA5 B4149EE2 72846D35 86B63863 B0699942
15:38:25.674 (loader): remote cmd from 1492: "status"
15:38:25.676 (post_compile 77): Status: 1, 1, 0, 40, 0, 0, C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\, T4MemInfoSink.ino.hex
15:38:25.676 (post_compile 77): Disconnect
15:38:25.694 (loader): remote connection 1492 closed
15:38:36.621 (ports 5): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
15:38:36.625 (ports 5): remove: loc=usb:0/140000/0/6/3
15:38:36.625 (ports 5): usb_remove: usb:0/140000/0/6/3
15:38:36.625 (ports 5): nothing new, skipping HID & Ports enum
15:38:36.648 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:38:36.649 (ports 5): nothing new, skipping HID & Ports enum
15:38:36.649 (ports 5): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
15:38:36.650 (ports 5): nothing new, skipping HID & Ports enum
15:38:36.797 (ports 5): WM_DEVICECHANGE DBT_DEVICEARRIVAL
15:38:36.798 (ports 5): nothing new, skipping HID & Ports enum
15:38:36.830 (loader): handle 32c
15:38:36.830 (loader): HID/win32: HidD_GetPreparsedData ok
15:38:36.830 (loader):  security: 03  12 34 34 12
15:38:36.830 (loader):  response: 04  12 8A 8A 12
15:38:36.830 (loader): nxp_write_register32 success, 12343412 128a8a12
15:38:36.830 (loader): Device came online, code_size = 100
15:38:36.830 (loader): Board is: NXP IMXRT1062 ROM
15:38:36.830 (loader): begin operation
15:38:36.850 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.hex", 113664 bytes
15:38:36.860 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
15:38:36.860 (loader): ehex is valid, key hash: 85A79CC1 B7C7F866 7F5BB3ED 0F9C9BA5 B4149EE2 72846D35 86B63863 B0699942
15:38:36.860 (loader): set background IMG_ONLINE
15:38:36.870 (loader): state STATE_NXP_BEGIN
15:38:36.870 (loader):  security: 03  12 34 34 12
15:38:36.875 (loader):  response: 04  12 8A 8A 12
15:38:36.875 (loader): HAB locked secure mode
15:38:36.875 (loader): state STATE_NXP_CLOSED
15:38:36.875 (loader): sending ehex access, 4960 bytes
15:38:36.880 (loader):  security: 03  12 34 34 12
15:38:36.880 (loader):  response: 04  88 88 88 88
15:38:36.880 (loader): run it..
15:38:36.880 (loader):  security: 03  12 34 34 12
15:38:36.890 (loader): end operation, total time = 0.060 seconds
15:38:36.900 (loader): redraw timer set, image 80 to show for 2000 ms
15:38:36.906 (ports 5): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
15:38:36.908 (ports 5): nothing new, skipping HID & Ports enum
15:38:37.067 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:38:37.068 (ports 5): nothing new, skipping HID & Ports enum
15:38:37.079 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:38:37.079 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:38:37.079 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:38:37.079 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:38:37.079 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:38:37.079 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:38:37.080 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:38:37.080 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:38:37.264 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:38:37.265 (ports 5): nothing new, skipping HID & Ports enum
15:38:38.251 (ports 5): purge, name=COM9 (Teensy 4.0) Serial, loc=usb:0/140000/0/6/3, age=1.626 sec
15:38:38.894 (loader): redraw, image 9
15:39:00.350 (ports 5): WM_DEVICECHANGE DBT_DEVICEARRIVAL
15:39:00.351 (ports 5): nothing new, skipping HID & Ports enum
15:39:00.355 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:39:00.356 (ports 5): nothing new, skipping HID & Ports enum
15:39:00.462 (loader): handle 6e4
15:39:00.462 (loader): HID/win32: HidD_GetPreparsedData ok
15:39:00.464 (loader):  security: 03  12 34 34 12
15:39:00.465 (loader):  response: 04  12 8A 8A 12
15:39:00.465 (loader): nxp_write_register32 success, 12343412 128a8a12
15:39:00.465 (loader): Device came online, code_size = 100
15:39:00.465 (loader): Board is: NXP IMXRT1062 ROM
15:39:00.465 (loader): begin operation
15:39:00.484 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.hex", 113664 bytes
15:39:00.500 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
15:39:00.500 (loader): ehex is valid, key hash: 85A79CC1 B7C7F866 7F5BB3ED 0F9C9BA5 B4149EE2 72846D35 86B63863 B0699942
15:39:00.500 (loader): set background IMG_ONLINE
15:39:00.502 (loader): state STATE_NXP_BEGIN
15:39:00.502 (loader):  security: 03  12 34 34 12
15:39:00.508 (loader):  response: 04  12 8A 8A 12
15:39:00.508 (loader): HAB locked secure mode
15:39:00.508 (loader): state STATE_NXP_CLOSED
15:39:00.508 (loader): sending ehex access, 4960 bytes
15:39:00.513 (loader):  security: 03  12 34 34 12
15:39:00.513 (loader):  response: 04  88 88 88 88
15:39:00.513 (loader): run it..
15:39:00.513 (loader):  security: 03  12 34 34 12
15:39:00.528 (loader): end operation, total time = 0.063 seconds
15:39:00.528 (loader): redraw timer set, image 80 to show for 2000 ms
15:39:00.537 (ports 5): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
15:39:00.540 (ports 5): nothing new, skipping HID & Ports enum
15:39:00.545 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:39:00.546 (ports 5): nothing new, skipping HID & Ports enum
15:39:00.700 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:00.700 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:00.700 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:00.700 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:00.700 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:00.700 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:00.700 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:00.700 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:00.750 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:39:00.751 (ports 5): nothing new, skipping HID & Ports enum
15:39:00.835 (ports 5): WM_DEVICECHANGE DBT_DEVICEARRIVAL
15:39:00.836 (ports 5): found_usb_device, id=\\?\usb#vid_16c0&pid_0478#000fd6ad#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
15:39:00.836 (ports 5): found_usb_device, loc=usb:0/140000/0/6/3    Port_#0003.Hub_#0007
15:39:00.836 (ports 5): found_usb_device, hwid=USB\VID_16C0&PID_0478&REV_0107
15:39:00.836 (ports 5): found_usb_device, devinst=00000022
15:39:00.836 (ports 5): add: loc=usb:0/140000/0/6/3, class=HID, vid=16C0, pid=0478, ver=0107, serial=000fd6ad, dev=\\?\usb#vid_16c0&pid_0478#000fd6ad#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
15:39:00.836 (ports 5): hiddev_from_devinst_list: iface=0
15:39:00.837 (ports 5): found_usb_device complete
15:39:00.837 (ports 5): usb_add: usb:0/140000/0/6/3  [no_device] (Teensy) Bootloader
15:39:00.961 (loader): encryption is required, public key hash: 85A79CC1 B7C7F866 7F5BB3ED 0F9C9BA5 B4149EE2 72846D35 86B63863 B0699942
15:39:00.961 (loader): Device came online, code_size = 2031616
15:39:00.961 (loader): Board is: Teensy 4.0 (IMXRT1062), version 1.07
15:39:00.978 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.hex", 113664 bytes
15:39:00.992 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
15:39:00.993 (loader): ehex is valid, key hash: 85A79CC1 B7C7F866 7F5BB3ED 0F9C9BA5 B4149EE2 72846D35 86B63863 B0699942
15:39:00.994 (loader): set background IMG_ONLINE
[B]15:39:01.012 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.hex", 113664 bytes
15:39:01.026 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
[/B]15:39:01.027 (loader): ehex is valid, key hash: 85A79CC1 B7C7F866 7F5BB3ED 0F9C9BA5 B4149EE2 72846D35 86B63863 B0699942
15:39:01.028 (loader): elf appears to be for Teensy 4.0 (IMXRT1062) (2031616 bytes)
15:39:01.028 (loader): elf binary data matches hex file
15:39:01.028 (loader): elf file is for Teensy 4.0 (IMXRT1062)
15:39:01.029 (loader): using encrypted ehex (required - secure mode is locked)
15:39:01.066 (loader): begin operation
15:39:01.138 (loader): flash, block=0, bs=1024, auto=1
15:39:01.138 (loader): flash, block=1, bs=1024, auto=1
15:39:01.139 (loader): flash, block=2, bs=1024, auto=1
15:39:01.300 (loader): flash, block=3, bs=1024, auto=1
15:39:01.300 (loader): flash, block=4, bs=1024, auto=1
15:39:01.303 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:39:01.304 (ports 5): update_usb_device, devinst list change, old had 1, new has 2
15:39:01.304 (ports 5): hiddev_from_devinst_list: iface=0
15:39:01.305 (ports 5): hid, found devinst=00000027
15:39:01.305 (ports 5): hid, path=\\?\hid#vid_16c0&pid_0478#8&31719e78&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
15:39:01.305 (ports 5): hid,  opened handle
15:39:01.305 (ports 5):  devinst=00000027, location=usb:0/140000/0/6/3
15:39:01.305 (ports 5):  vid=16C0, pid=0478, ver=0107, usepage=FF9C, use=0024
15:39:01.305 (ports 5):  devpath=\\?\hid#vid_16c0&pid_0478#8&31719e78&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
15:39:01.305 (ports 5): usb_add: usb:0/140000/0/6/3  hid#vid_16c0&pid_0478 (Teensy 4.0) Bootloader
15:39:01.338 (loader): flash, block=5, bs=1024, auto=1
15:39:01.338 (loader): flash, block=6, bs=1024, auto=1
15:39:01.340 (loader): flash, block=7, bs=1024, auto=1
15:39:01.369 (loader): flash, block=8, bs=1024, auto=1
15:39:01.369 (loader): flash, block=9, bs=1024, auto=1
15:39:01.389 (loader): flash, block=10, bs=1024, auto=1
15:39:01.389 (loader): flash, block=11, bs=1024, auto=1
15:39:01.409 (loader): flash, block=12, bs=1024, auto=1
15:39:01.409 (loader): flash, block=13, bs=1024, auto=1
15:39:01.441 (loader): flash, block=14, bs=1024, auto=1
15:39:01.441 (loader): flash, block=15, bs=1024, auto=1
15:39:01.459 (loader): flash, block=16, bs=1024, auto=1
15:39:01.459 (loader): flash, block=17, bs=1024, auto=1
15:39:01.492 (loader): flash, block=18, bs=1024, auto=1
15:39:01.493 (loader): flash, block=19, bs=1024, auto=1
15:39:01.522 (loader): flash, block=20, bs=1024, auto=1
15:39:01.524 (loader): flash, block=21, bs=1024, auto=1
15:39:01.530 (loader): flash, block=22, bs=1024, auto=1
15:39:01.530 (loader): flash, block=23, bs=1024, auto=1
15:39:01.530 (loader): flash, block=24, bs=1024, auto=1
15:39:01.530 (loader): flash, block=25, bs=1024, auto=1
15:39:01.561 (loader): flash, block=26, bs=1024, auto=1
15:39:01.561 (loader): flash, block=27, bs=1024, auto=1
15:39:01.592 (loader): flash, block=28, bs=1024, auto=1
15:39:01.592 (loader): flash, block=29, bs=1024, auto=1
15:39:01.624 (loader): flash, block=30, bs=1024, auto=1
15:39:01.624 (loader): flash, block=31, bs=1024, auto=1
15:39:01.655 (loader): flash, block=32, bs=1024, auto=1
15:39:01.655 (loader): flash, block=33, bs=1024, auto=1
15:39:01.687 (loader): flash, block=34, bs=1024, auto=1
15:39:01.687 (loader): flash, block=35, bs=1024, auto=1
15:39:01.718 (loader): flash, block=36, bs=1024, auto=1
15:39:01.718 (loader): flash, block=37, bs=1024, auto=1
15:39:01.749 (loader): flash, block=38, bs=1024, auto=1
15:39:01.749 (loader): flash, block=39, bs=1024, auto=1
15:39:01.781 (loader): flash, block=40, bs=1024, auto=1
15:39:01.781 (loader): flash, block=41, bs=1024, auto=1
15:39:01.812 (loader): flash, block=42, bs=1024, auto=1
15:39:01.812 (loader): flash, block=43, bs=1024, auto=1
15:39:01.844 (loader): flash, block=44, bs=1024, auto=1
15:39:01.844 (loader): flash, block=45, bs=1024, auto=1
15:39:01.875 (loader): flash, block=46, bs=1024, auto=1
15:39:01.875 (loader): flash, block=47, bs=1024, auto=1
15:39:01.906 (loader): flash, block=48, bs=1024, auto=1
15:39:01.906 (loader): flash, block=49, bs=1024, auto=1
15:39:01.937 (loader): flash, block=50, bs=1024, auto=1
15:39:01.937 (loader): flash, block=51, bs=1024, auto=1
15:39:01.970 (loader): flash, block=52, bs=1024, auto=1
15:39:01.970 (loader): flash, block=53, bs=1024, auto=1
15:39:02.001 (loader): flash, block=54, bs=1024, auto=1
15:39:02.001 (loader): flash, block=55, bs=1024, auto=1
15:39:02.033 (loader): flash, block=56, bs=1024, auto=1
15:39:02.033 (loader): flash, block=57, bs=1024, auto=1
15:39:02.064 (loader): flash, block=58, bs=1024, auto=1
15:39:02.064 (loader): flash, block=59, bs=1024, auto=1
15:39:02.095 (loader): flash, block=60, bs=1024, auto=1
15:39:02.095 (loader): flash, block=61, bs=1024, auto=1
15:39:02.127 (loader): flash, block=62, bs=1024, auto=1
15:39:02.127 (loader): flash, block=63, bs=1024, auto=1
15:39:02.127 (loader): flash, block=64, bs=1024, auto=1
15:39:02.127 (loader): flash, block=65, bs=1024, auto=1
15:39:02.158 (loader): flash, block=66, bs=1024, auto=1
15:39:02.158 (loader): flash, block=67, bs=1024, auto=1
15:39:02.158 (loader): flash, block=68, bs=1024, auto=1
15:39:02.158 (loader): flash, block=69, bs=1024, auto=1
15:39:02.189 (loader): flash, block=70, bs=1024, auto=1
15:39:02.189 (loader): flash, block=71, bs=1024, auto=1
15:39:02.222 (loader): flash, block=72, bs=1024, auto=1
15:39:02.222 (loader): flash, block=73, bs=1024, auto=1
15:39:02.252 (loader): flash, block=74, bs=1024, auto=1
15:39:02.252 (loader): flash, block=75, bs=1024, auto=1
15:39:02.283 (loader): flash, block=76, bs=1024, auto=1
15:39:02.283 (loader): flash, block=77, bs=1024, auto=1
15:39:02.315 (loader): flash, block=78, bs=1024, auto=1
15:39:02.315 (loader): flash, block=79, bs=1024, auto=1
15:39:02.347 (loader): flash, block=80, bs=1024, auto=1
15:39:02.347 (loader): flash, block=81, bs=1024, auto=1
15:39:02.379 (loader): flash, block=82, bs=1024, auto=1
15:39:02.379 (loader): flash, block=83, bs=1024, auto=1
15:39:02.410 (loader): flash, block=84, bs=1024, auto=1
15:39:02.410 (loader): flash, block=85, bs=1024, auto=1
15:39:02.442 (loader): flash, block=86, bs=1024, auto=1
15:39:02.442 (loader): flash, block=87, bs=1024, auto=1
15:39:02.473 (loader): flash, block=88, bs=1024, auto=1
15:39:02.473 (loader): flash, block=89, bs=1024, auto=1
15:39:02.505 (loader): flash, block=90, bs=1024, auto=1
15:39:02.506 (loader): flash, block=91, bs=1024, auto=1
15:39:02.537 (loader): flash, block=92, bs=1024, auto=1
15:39:02.538 (loader): flash, block=93, bs=1024, auto=1
15:39:02.557 (loader): flash, block=94, bs=1024, auto=1
15:39:02.557 (loader): flash, block=95, bs=1024, auto=1
15:39:02.589 (loader): flash, block=96, bs=1024, auto=1
15:39:02.589 (loader): flash, block=97, bs=1024, auto=1
15:39:02.620 (loader): flash, block=98, bs=1024, auto=1
15:39:02.620 (loader): flash, block=99, bs=1024, auto=1
15:39:02.652 (loader): flash, block=100, bs=1024, auto=1
15:39:02.652 (loader): flash, block=101, bs=1024, auto=1
15:39:02.683 (loader): flash, block=102, bs=1024, auto=1
15:39:02.683 (loader): flash, block=103, bs=1024, auto=1
15:39:02.714 (loader): flash, block=104, bs=1024, auto=1
15:39:02.714 (loader): flash, block=105, bs=1024, auto=1
15:39:02.746 (loader): flash, block=106, bs=1024, auto=1
15:39:02.746 (loader): flash, block=107, bs=1024, auto=1
15:39:02.777 (loader): flash, block=108, bs=1024, auto=1
15:39:02.777 (loader): flash, block=109, bs=1024, auto=1
15:39:02.808 (loader): flash, block=110, bs=1024, auto=1
15:39:02.808 (loader): sending reboot
15:39:02.808 (loader): begin wait_until_offline
15:39:02.838 (ports 5): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
15:39:02.842 (ports 5): remove: loc=usb:0/140000/0/6/3
15:39:02.842 (ports 5): usb_remove: usb:0/140000/0/6/3
15:39:02.842 (ports 5): nothing new, skipping HID & Ports enum
15:39:02.871 (loader): offline, waited 1
15:39:02.871 (loader): end operation, total time = 1.805 seconds
15:39:02.871 (loader): set background IMG_REBOOT_OK
15:39:02.871 (loader): redraw timer set, image 14 to show for 1200 ms
15:39:02.950 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:02.950 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:02.950 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:02.950 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:02.950 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:02.950 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:02.950 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:02.950 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:39:03.167 (ports 5): WM_DEVICECHANGE DBT_DEVICEARRIVAL
15:39:03.168 (ports 5): found_usb_device, id=\\?\usb#vid_16c0&pid_0483#10379970#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
15:39:03.168 (ports 5): found_usb_device, loc=usb:0/140000/0/6/3    Port_#0003.Hub_#0007
15:39:03.168 (ports 5): found_usb_device, hwid=USB\VID_16C0&PID_0483&REV_0279
15:39:03.168 (ports 5): found_usb_device, devinst=0000001f
15:39:03.168 (ports 5): add: loc=usb:0/140000/0/6/3, class=USB, vid=16C0, pid=0483, ver=0279, serial=[B][U]10379970[/U][/B], dev=\\?\usb#vid_16c0&pid_0483#10379970#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
15:39:03.168 (ports 5):   comport_from_devinst_list attempt
15:39:03.168 (ports 5): found_usb_device complete
15:39:03.169 (ports 5): usb_add: usb:0/140000/0/6/3  [no_device] (Teensy 4.0) Serial
15:39:03.208 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:39:03.209 (ports 5): update_usb_device, devinst list change, old had 1, new has 2
15:39:03.209 (ports 5):   comport_from_devinst_list attempt
15:39:03.209 (ports 5):   found Ports in classguid_list at index=1
15:39:03.209 (ports 5):   port COM9 found from devnode
15:39:03.209 (ports 5): usb_add: usb:0/140000/0/6/3  COM9 (Teensy 4.0) Serial
15:39:03.267 (ports 5): WM_DEVICECHANGE DBT_DEVICEARRIVAL
15:39:03.268 (ports 5): nothing new, skipping HID & Ports enum
15:39:04.083 (loader): redraw, image 9
15:39:04.869 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:39:04.869 (ports 5): nothing new, skipping HID & Ports enum
15:39:23.041 (loader): Verbose Info event
15:42:11.546 (ports 5): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
15:42:11.549 (ports 5): remove: loc=usb:0/140000/0/6/1/1
15:42:11.549 (ports 5): usb_remove: usb:0/140000/0/6/1/1
15:42:11.549 (ports 5): nothing new, skipping HID & Ports enum
15:42:11.642 (ports 5): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
15:42:11.643 (ports 5): nothing new, skipping HID & Ports enum
15:42:11.643 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:42:11.643 (ports 5): nothing new, skipping HID & Ports enum
15:42:11.763 (ports 5): WM_DEVICECHANGE DBT_DEVICEARRIVAL
15:42:11.764 (ports 5): found_usb_device, id=\\?\usb#vid_16c0&pid_0478#000fd6ac#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
15:42:11.764 (ports 5): found_usb_device, loc=usb:0/140000/0/6/1/1    Port_#0001.Hub_#0011
15:42:11.764 (ports 5): found_usb_device, hwid=USB\VID_16C0&PID_0478&REV_0107
15:42:11.764 (ports 5): found_usb_device, devinst=0000001d
15:42:11.764 (ports 5): add: loc=usb:0/140000/0/6/1/1, class=HID, vid=16C0, pid=0478, ver=0107, serial=000fd6ac, dev=\\?\usb#vid_16c0&pid_0478#000fd6ac#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
15:42:11.764 (ports 5): hiddev_from_devinst_list: iface=0
15:42:11.765 (ports 5): found_usb_device complete
15:42:11.766 (ports 5): usb_add: usb:0/140000/0/6/1/1  [no_device] (Teensy 4.0) Bootloader
15:42:11.997 (loader): encryption is possible on this Teensy, but not yet configured
15:42:12.007 (loader): Device came online, code_size = 2031616
15:42:12.038 (loader): Board is: Teensy 4.0 (IMXRT1062), version 1.07
15:42:12.057 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.hex", 113664 bytes
15:42:12.097 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
15:42:12.127 (loader): ehex is valid, key hash: 85A79CC1 B7C7F866 7F5BB3ED 0F9C9BA5 B4149EE2 72846D35 86B63863 B0699942
15:42:12.127 (loader): set background IMG_ONLINE
[B]15:42:12.187 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.hex", 113664 bytes
15:42:12.207 (loader): File "C:\Users\Tim\AppData\Local\Temp\arduino_build_748551\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
[/B]15:42:12.217 (loader): ehex is valid, key hash: 85A79CC1 B7C7F866 7F5BB3ED 0F9C9BA5 B4149EE2 72846D35 86B63863 B0699942
15:42:12.232 (loader): elf appears to be for Teensy 4.0 (IMXRT1062) (2031616 bytes)
15:42:12.238 (loader): elf binary data matches hex file
15:42:12.248 (loader): elf file is for Teensy 4.0 (IMXRT1062)
15:42:12.265 (loader): using hex file - Teensy not configured for encryption
15:42:12.330 (loader): begin operation
15:42:12.359 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:42:12.360 (ports 5): hid, found devinst=0000001E
15:42:12.360 (ports 5): hid, path=\\?\hid#vid_16c0&pid_0478#8&8908516&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
15:42:12.360 (ports 5): hid,  opened handle
15:42:12.360 (ports 5):  devinst=0000001E, location=usb:0/140000/0/6/1/1
15:42:12.360 (ports 5):  vid=16C0, pid=0478, ver=0107, usepage=FF9C, use=0024
15:42:12.360 (ports 5):  devpath=\\?\hid#vid_16c0&pid_0478#8&8908516&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
15:42:12.361 (ports 5): usb_add: usb:0/140000/0/6/1/1  hid#vid_16c0&pid_0478 (Teensy 4.0) Bootloader
15:42:12.447 (loader): flash, block=0, bs=1024, auto=1
15:42:12.463 (loader): flash, block=1, bs=1024, auto=1
15:42:12.463 (loader): flash, block=2, bs=1024, auto=1
15:42:12.641 (loader): flash, block=3, bs=1024, auto=1
15:42:12.641 (loader): flash, block=4, bs=1024, auto=1
15:42:12.661 (loader): flash, block=5, bs=1024, auto=1
15:42:12.669 (loader): flash, block=6, bs=1024, auto=1
15:42:12.676 (loader): flash, block=7, bs=1024, auto=1
15:42:12.676 (loader): flash, block=8, bs=1024, auto=1
15:42:12.692 (loader): flash, block=9, bs=1024, auto=1
15:42:12.708 (loader): flash, block=10, bs=1024, auto=1
15:42:12.708 (loader): flash, block=11, bs=1024, auto=1
15:42:12.723 (loader): flash, block=12, bs=1024, auto=1
15:42:12.723 (loader): flash, block=13, bs=1024, auto=1
15:42:12.739 (loader): flash, block=14, bs=1024, auto=1
15:42:12.754 (loader): flash, block=15, bs=1024, auto=1
15:42:12.754 (loader): flash, block=16, bs=1024, auto=1
15:42:12.770 (loader): flash, block=17, bs=1024, auto=1
15:42:12.786 (loader): flash, block=18, bs=1024, auto=1
15:42:12.786 (loader): flash, block=19, bs=1024, auto=1
15:42:12.801 (loader): flash, block=20, bs=1024, auto=1
15:42:12.817 (loader): flash, block=21, bs=1024, auto=1
15:42:12.817 (loader): flash, block=22, bs=1024, auto=1
15:42:12.834 (loader): flash, block=23, bs=1024, auto=1
15:42:12.849 (loader): flash, block=24, bs=1024, auto=1
15:42:12.849 (loader): flash, block=25, bs=1024, auto=1
15:42:12.865 (loader): flash, block=26, bs=1024, auto=1
15:42:12.865 (loader): flash, block=27, bs=1024, auto=1
15:42:12.881 (loader): flash, block=28, bs=1024, auto=1
15:42:12.881 (loader): flash, block=29, bs=1024, auto=1
15:42:12.896 (loader): flash, block=30, bs=1024, auto=1
15:42:12.912 (loader): flash, block=31, bs=1024, auto=1
15:42:12.912 (loader): flash, block=32, bs=1024, auto=1
15:42:12.927 (loader): flash, block=33, bs=1024, auto=1
15:42:12.943 (loader): flash, block=34, bs=1024, auto=1
15:42:12.943 (loader): flash, block=35, bs=1024, auto=1
15:42:12.959 (loader): flash, block=36, bs=1024, auto=1
15:42:12.959 (loader): flash, block=37, bs=1024, auto=1
15:42:12.974 (loader): flash, block=38, bs=1024, auto=1
15:42:12.990 (loader): flash, block=39, bs=1024, auto=1
15:42:12.990 (loader): flash, block=40, bs=1024, auto=1
15:42:13.006 (loader): flash, block=41, bs=1024, auto=1
15:42:13.006 (loader): flash, block=42, bs=1024, auto=1
15:42:13.021 (loader): flash, block=43, bs=1024, auto=1
15:42:13.037 (loader): flash, block=44, bs=1024, auto=1
15:42:13.052 (loader): flash, block=45, bs=1024, auto=1
15:42:13.052 (loader): flash, block=46, bs=1024, auto=1
15:42:13.068 (loader): flash, block=47, bs=1024, auto=1
15:42:13.084 (loader): flash, block=48, bs=1024, auto=1
15:42:13.099 (loader): flash, block=49, bs=1024, auto=1
15:42:13.099 (loader): flash, block=50, bs=1024, auto=1
15:42:13.131 (loader): flash, block=51, bs=1024, auto=1
15:42:13.131 (loader): flash, block=52, bs=1024, auto=1
15:42:13.147 (loader): flash, block=53, bs=1024, auto=1
15:42:13.163 (loader): flash, block=54, bs=1024, auto=1
15:42:13.163 (loader): flash, block=55, bs=1024, auto=1
15:42:13.179 (loader): flash, block=56, bs=1024, auto=1
15:42:13.179 (loader): flash, block=57, bs=1024, auto=1
15:42:13.194 (loader): flash, block=58, bs=1024, auto=1
15:42:13.211 (loader): flash, block=59, bs=1024, auto=1
15:42:13.219 (loader): flash, block=60, bs=1024, auto=1
15:42:13.228 (loader): flash, block=61, bs=1024, auto=1
15:42:13.237 (loader): flash, block=62, bs=1024, auto=1
15:42:13.246 (loader): flash, block=63, bs=1024, auto=1
15:42:13.254 (loader): flash, block=64, bs=1024, auto=1
15:42:13.263 (loader): flash, block=65, bs=1024, auto=1
15:42:13.273 (loader): flash, block=66, bs=1024, auto=1
15:42:13.274 (loader): flash, block=67, bs=1024, auto=1
15:42:13.290 (loader): flash, block=68, bs=1024, auto=1
15:42:13.290 (loader): flash, block=69, bs=1024, auto=1
15:42:13.306 (loader): flash, block=70, bs=1024, auto=1
15:42:13.306 (loader): flash, block=71, bs=1024, auto=1
15:42:13.324 (loader): flash, block=72, bs=1024, auto=1
15:42:13.340 (loader): flash, block=73, bs=1024, auto=1
15:42:13.340 (loader): flash, block=74, bs=1024, auto=1
15:42:13.356 (loader): flash, block=75, bs=1024, auto=1
15:42:13.356 (loader): flash, block=76, bs=1024, auto=1
15:42:13.371 (loader): flash, block=77, bs=1024, auto=1
15:42:13.371 (loader): flash, block=78, bs=1024, auto=1
15:42:13.387 (loader): flash, block=79, bs=1024, auto=1
15:42:13.387 (loader): flash, block=80, bs=1024, auto=1
15:42:13.402 (loader): flash, block=81, bs=1024, auto=1
15:42:13.418 (loader): flash, block=82, bs=1024, auto=1
15:42:13.418 (loader): flash, block=83, bs=1024, auto=1
15:42:13.434 (loader): flash, block=84, bs=1024, auto=1
15:42:13.434 (loader): flash, block=85, bs=1024, auto=1
15:42:13.449 (loader): flash, block=86, bs=1024, auto=1
15:42:13.465 (loader): flash, block=87, bs=1024, auto=1
15:42:13.465 (loader): flash, block=88, bs=1024, auto=1
15:42:13.481 (loader): flash, block=89, bs=1024, auto=1
15:42:13.481 (loader): flash, block=90, bs=1024, auto=1
15:42:13.496 (loader): flash, block=91, bs=1024, auto=1
15:42:13.513 (loader): flash, block=92, bs=1024, auto=1
15:42:13.523 (loader): flash, block=93, bs=1024, auto=1
15:42:13.530 (loader): flash, block=94, bs=1024, auto=1
15:42:13.530 (loader): flash, block=95, bs=1024, auto=1
15:42:13.546 (loader): flash, block=96, bs=1024, auto=1
15:42:13.561 (loader): flash, block=97, bs=1024, auto=1
15:42:13.561 (loader): flash, block=98, bs=1024, auto=1
15:42:13.577 (loader): flash, block=99, bs=1024, auto=1
15:42:13.577 (loader): flash, block=100, bs=1024, auto=1
15:42:13.592 (loader): flash, block=101, bs=1024, auto=1
15:42:13.592 (loader): flash, block=102, bs=1024, auto=1
15:42:13.608 (loader): flash, block=103, bs=1024, auto=1
15:42:13.624 (loader): flash, block=104, bs=1024, auto=1
15:42:13.624 (loader): flash, block=105, bs=1024, auto=1
15:42:13.639 (loader): flash, block=106, bs=1024, auto=1
15:42:13.639 (loader): flash, block=107, bs=1024, auto=1
15:42:13.655 (loader): flash, block=108, bs=1024, auto=1
15:42:13.655 (loader): flash, block=109, bs=1024, auto=1
15:42:13.671 (loader): flash, block=110, bs=1024, auto=1
15:42:13.686 (loader): sending reboot
15:42:13.702 (loader): begin wait_until_offline
15:42:13.702 (loader): offline, waited 0
15:42:13.733 (loader): end operation, total time = 1.387 seconds
15:42:13.737 (ports 5): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
15:42:13.738 (ports 5): remove: loc=usb:0/140000/0/6/1/1
15:42:13.738 (ports 5): usb_remove: usb:0/140000/0/6/1/1
15:42:13.738 (ports 5): nothing new, skipping HID & Ports enum
15:42:13.749 (loader): set background IMG_REBOOT_OK
15:42:13.764 (loader): redraw timer set, image 14 to show for 1200 ms
15:42:13.953 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:42:13.969 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:42:13.969 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:42:13.985 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:42:13.985 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:42:14.001 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:42:14.001 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:42:14.016 (loader): HID/win32:  vid:046D pid:C52B ver:1211
15:42:14.033 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:42:14.033 (ports 5): nothing new, skipping HID & Ports enum
15:42:14.143 (ports 5): WM_DEVICECHANGE DBT_DEVICEARRIVAL
15:42:14.147 (ports 5): found_usb_device, id=\\?\usb#vid_16c0&pid_0483#10379960#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
15:42:14.147 (ports 5): found_usb_device, loc=usb:0/140000/0/6/1/1    Port_#0001.Hub_#0011
15:42:14.147 (ports 5): found_usb_device, devinst=00000004
15:42:14.147 (ports 5): found_usb_device, hwid=USB\VID_16C0&PID_0483&REV_0279
15:42:14.147 (ports 5): add: loc=usb:0/140000/0/6/1/1, class=USB, vid=16C0, pid=0483, ver=0279, serial=[B][U]10379960[/U][/B], dev=\\?\usb#vid_16c0&pid_0483#10379960#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
15:42:14.147 (ports 5):   comport_from_devinst_list attempt
15:42:14.147 (ports 5): found_usb_device complete
15:42:14.148 (ports 5): usb_add: usb:0/140000/0/6/1/1  [no_device] (Teensy 4.0) Serial
15:42:14.381 (ports 5): WM_DEVICECHANGE DBT_DEVICEARRIVAL
15:42:14.381 (ports 5): update_usb_device, devinst list change, old had 1, new has 2
15:42:14.381 (ports 5):   comport_from_devinst_list attempt
15:42:14.381 (ports 5):   found Ports in classguid_list at index=1
15:42:14.381 (ports 5):   port COM8 found from devnode
15:42:14.382 (ports 5): usb_add: usb:0/140000/0/6/1/1  COM8 (Teensy 4.0) Serial
15:42:14.979 (loader): redraw, image 9
15:42:16.745 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
15:42:16.746 (ports 5): nothing new, skipping HID & Ports enum
 
I thought to be complete on thest, I would pull out my parts reserve an older T4 (OSH Park addition) and ran the FuseWrite sketch:
...
Probably all for now on that front

@KurtE - if you update and run SINK or KITCHEN it should be showing the FUSE value? ... if I read the code right ...
 
@Paul - p#292 LED light show has not repeated - and I tried repeating.

Soldered together the TallDog T_4.0 breakout with the Locked beta T_4.0 working so far! Remembered to cut trace and Breakout switch on USB power works.

Couple of sketches - read SD CARD to LFS_PROG, and example/sd/datalogger, Ran NewPinTest around and all looks good. Power Off/On works.

USB Host tested with USB Logitech Dongle Mouse!

Looks good - didn't wash it clean - and of course it is a bit lopsided with high headers ( the multi for under pads, and power corner ) mixed with short header sides.

So it seems to be a T_4.1 less QSPI and Ethernet.

Going to update SINK and Kitchen - the temp 2X/sec is annoying - put in 5 sec wait when no Serial in - then will run each half sec for as many input chars it gets - than back to 5 secs.

Doing the git::pROG - with some tweaking to write on "R"estart - finding the updated "D"irVerify reporting 0x2f chars in the stream the should be 'a' or 'b' ???
> WHEW > That is 'By Design' as I push out some extra "test" files that don't match the expected "D"irVerify pattern

Was impatient after 1.5 hours of soldering while watching TV - washing would have meant a long dry ... and soldering went well - and not too much flus residue it seems. Will do a wash now for night of drying before RTC battery.
 
@defragster @Paul - Running your memory info sketch with the old T4 and new T4... My guess is it won't help gain much more information other than currently neither will load an .ehex file... Not sure if either can (hardware/firmware issue) or difference in A/B chip... And or need some other detection in the loader? ...

So first up Purple OSHPark T4
Code:
D:\GitHub\T4LockBeta\T4MemInfoSink\T4MemInfoSink.ino Aug 25 2021 05:40:12

	deg  C=43.454544	 F_CPU=600000000
_stext        00000000
_etext        00014958 +84312b
_sdata        20000000
_edata        20003368 +13160b
_sbss         20003368
_ebss         200062c0 +12120b
curr stack    20067f48 +400520b
_estack       20068000 +184b
_heap_start   20203060
__brkval      20204000 +4000b
_heap_end     20280000 +507904b

<ITCM>  00000000 .. 00017fff
<DTCM>  20000000 .. 20067fff
<RAM>   20200000 .. 2027ffff
<FLASH> 60000000 .. 601fffff

avail STACK   400520 b   391 kb	<<RAM1
avail HEAP    507904 b   496 kb	<<RAM2


++++++++++++++++++++++
Size of Free ITCM in Bytes = 13988
Start of Free ITCM = 84316 [ 1495C] 
End of Free ITCM = 98304 [ 18000] 
ITCM DWORD cnt = 3497 [#bytes=13988] 

---	hab_csf
6001B000 - 00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  : ........ ........
...	 6 duplicate line(s) removed.
6001B070 - 00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  : ........ ........
---	ITCM used
0001395C - 12 68 50 6B 00 28 08 BF  18 46 F0 30 70 47 00 BF  : .hPk.(.. .F.0pG..
0001396C - E8 2D 00 20 EC 2D 00 20  70 B5 0D 46 B1 F9 0E 10  : .-. .-.  p..F....
0001397C - 00 29 90 B0 14 46 1E 46  14 DB 01 AA 00 F0 68 FD  : .)...F.F ......h.
0001398C - 00 28 0F DB 02 9A 02 F4  70 42 A2 F5 00 52 B2 FA  : .(...... pB...R..
0001399C - 82 F2 52 09 4F F4 80 63  4F F4 00 60 32 60 23 60  : ..R.O..c O..`2`#`
000139AC - 10 B0 70 BD A8 89 00 F0  80 00 82 B2 00 20 30 60  : ..p..... ..... 0`
000139BC - 1A B1 40 23 23 60 10 B0  70 BD 4F F4 80 63 10 46  : ..@##`.. p.O..c.F
000139CC - 23 60 10 B0 70 BD 00 BF  8A 89 92 07 0B 46 06 D5  : #`..p... .....F..
---	ITCM filler to DTCM	 test 3 
0001495C - 01 00 00 00 01 00 00 00  01 00 00 00 01 00 00 00  : ........ ........
...	 872 duplicate line(s) removed.
00017FEC - 01 00 00 00 01 00 00 00  01 00 00 00 01 00 00 00  : ........ ........
00017FFC - 01 00 00 00                                       : ....
 ITCM Start: 
 Given addr of 0  *Skipping Addresses < 32 to avoid access violation
00000020 - 10 B5 05 4C 23 78 33 B9  04 4B 13 B1 04 48 AF F3  : ...L#x3. .K...H..
00000030 - 00 80 01 23 23 70 10 BD  68 33 00 20 00 00 00 00  : ...##p.. h3. ....
00000040 - 54 49 01 00 08 4B 10 B5  1B B1 08 49 08 48 AF F3  : TI...K.. ...I.H..
00000050 - 00 80 08 48 03 68 03 B9  10 BD 07 4B 00 2B FB D0  : ...H.h.. ...K.+..
00000060 - BD E8 10 40 18 47 00 BF  00 00 00 00 6C 33 00 20  : ...@.G.. ....l3. 
00000070 - 54 49 01 00 68 33 00 20  00 00 00 00 00 20 70 47  : TI..h3.  ..... pG
00000080 - 00 69 10 B1 03 68 9B 6A  18 47 70 47 00 69 10 B1  : .i...h.j .GpG.i..
00000090 - 03 68 DB 6A 18 47 70 47  00 69 10 B1 03 68 1B 69  : .h.j.GpG .i...h.i
Verify secure code is running properly

Fail: Bus Encryption Engine is not active
Fail: Encryption region starts at wrong address
Fail: Program data is not within encrypted region
Fail: title_function() is not in encrypted region
Fail: title_text[] is not in encrypted region
Fail: csf not PJRC
NOTE: hab_version == 0x40307
NOTE: hab_status == 0xF0
Secure mode NOT SET :: Fuses == 0x80018
New PJRC T4:
Code:
D:\GitHub\T4LockBeta\T4MemInfoSink\T4MemInfoSink.ino Aug 25 2021 05:40:12

	deg  C=45.192307	 F_CPU=600000000
_stext        00000000
_etext        00014958 +84312b
_sdata        20000000
_edata        20003368 +13160b
_sbss         20003368
_ebss         200062c0 +12120b
curr stack    20067f48 +400520b
_estack       20068000 +184b
_heap_start   20203060
__brkval      20204000 +4000b
_heap_end     20280000 +507904b

<ITCM>  00000000 .. 00017fff
<DTCM>  20000000 .. 20067fff
<RAM>   20200000 .. 2027ffff
<FLASH> 60000000 .. 601fffff

avail STACK   400520 b   391 kb	<<RAM1
avail HEAP    507904 b   496 kb	<<RAM2


++++++++++++++++++++++
Size of Free ITCM in Bytes = 13988
Start of Free ITCM = 84316 [ 1495C] 
End of Free ITCM = 98304 [ 18000] 
ITCM DWORD cnt = 3497 [#bytes=13988] 

---	hab_csf
6001B000 - 00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  : ........ ........
...	 6 duplicate line(s) removed.
6001B070 - 00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  : ........ ........
---	ITCM used
0001395C - 12 68 50 6B 00 28 08 BF  18 46 F0 30 70 47 00 BF  : .hPk.(.. .F.0pG..
0001396C - E8 2D 00 20 EC 2D 00 20  70 B5 0D 46 B1 F9 0E 10  : .-. .-.  p..F....
0001397C - 00 29 90 B0 14 46 1E 46  14 DB 01 AA 00 F0 68 FD  : .)...F.F ......h.
0001398C - 00 28 0F DB 02 9A 02 F4  70 42 A2 F5 00 52 B2 FA  : .(...... pB...R..
0001399C - 82 F2 52 09 4F F4 80 63  4F F4 00 60 32 60 23 60  : ..R.O..c O..`2`#`
000139AC - 10 B0 70 BD A8 89 00 F0  80 00 82 B2 00 20 30 60  : ..p..... ..... 0`
000139BC - 1A B1 40 23 23 60 10 B0  70 BD 4F F4 80 63 10 46  : ..@##`.. p.O..c.F
000139CC - 23 60 10 B0 70 BD 00 BF  8A 89 92 07 0B 46 06 D5  : #`..p... .....F..
---	ITCM filler to DTCM	 test 3 
0001495C - 01 00 00 00 01 00 00 00  01 00 00 00 01 00 00 00  : ........ ........
...	 872 duplicate line(s) removed.
00017FEC - 01 00 00 00 01 00 00 00  01 00 00 00 01 00 00 00  : ........ ........
00017FFC - 01 00 00 00                                       : ....
 ITCM Start: 
 Given addr of 0  *Skipping Addresses < 32 to avoid access violation
00000020 - 10 B5 05 4C 23 78 33 B9  04 4B 13 B1 04 48 AF F3  : ...L#x3. .K...H..
00000030 - 00 80 01 23 23 70 10 BD  68 33 00 20 00 00 00 00  : ...##p.. h3. ....
00000040 - 54 49 01 00 08 4B 10 B5  1B B1 08 49 08 48 AF F3  : TI...K.. ...I.H..
00000050 - 00 80 08 48 03 68 03 B9  10 BD 07 4B 00 2B FB D0  : ...H.h.. ...K.+..
00000060 - BD E8 10 40 18 47 00 BF  00 00 00 00 6C 33 00 20  : ...@.G.. ....l3. 
00000070 - 54 49 01 00 68 33 00 20  00 00 00 00 00 20 70 47  : TI..h3.  ..... pG
00000080 - 00 69 10 B1 03 68 9B 6A  18 47 70 47 00 69 10 B1  : .i...h.j .GpG.i..
00000090 - 03 68 DB 6A 18 47 70 47  00 69 10 B1 03 68 1B 69  : .h.j.GpG .i...h.i
Verify secure code is running properly

Fail: Bus Encryption Engine is not active
Fail: Encryption region starts at wrong address
Fail: Program data is not within encrypted region
Fail: title_function() is not in encrypted region
Fail: title_text[] is not in encrypted region
Fail: csf not PJRC
NOTE: hab_version == 0x40307
NOTE: hab_status == 0xF0
Secure mode NOT SET :: Fuses == 0x8B018

There is a fuse difference...

Portions of the verbose loader log:
Purple:
Code:
05:41:00.619 (ports 5): found_usb_device, hwid=USB\VID_16C0&PID_0478&REV_0105
05:41:00.619 (ports 5): found_usb_device, devinst=00000016
05:41:00.619 (ports 5): add: loc=usb:0/140000/0/1/1/1, class=HID, vid=16C0, pid=0478, ver=0105, serial=0009b091, dev=\\?\usb#vid_16c0&pid_0478#0009b091#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
05:41:00.620 (ports 5): hiddev_from_devinst_list: iface=0
05:41:00.620 (ports 5): found_usb_device complete
05:41:00.621 (ports 5): hid, found devinst=00000017
05:41:00.621 (ports 5): hid, path=\\?\hid#vid_16c0&pid_0478#8&32f2de20&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
05:41:00.621 (ports 5): hid,  opened handle
05:41:00.621 (ports 5):  devinst=00000017, location=usb:0/140000/0/1/1/1
05:41:00.621 (ports 5):  vid=16C0, pid=0478, ver=0105, usepage=FF9C, use=0024
05:41:00.621 (ports 5):  devpath=\\?\hid#vid_16c0&pid_0478#8&32f2de20&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
05:41:00.622 (ports 5): usb_add: usb:0/140000/0/1/1/1  hid#vid_16c0&pid_0478 (Teensy 4.0) Bootloader
05:41:00.719 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
05:41:00.720 (ports 5): nothing new, skipping HID & Ports enum
05:41:00.745 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
05:41:00.746 (ports 5): nothing new, skipping HID & Ports enum
05:41:00.854 (loader): Device came online, code_size = 2031616
05:41:00.862 (loader): Board is: Teensy 4.0 (IMXRT1062), version 1.05
05:41:00.889 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_951705\T4MemInfoSink.ino.hex", 113664 bytes
05:41:00.909 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_951705\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
05:41:00.915 (loader): ehex is valid, key hash: FB63C934 9683889D 3A20DB52 811A0593 83BEA33F 0F810CDF D6AD3C83 5DF1DA1A
05:41:00.924 (loader): set background IMG_ONLINE
05:41:00.944 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_951705\T4MemInfoSink.ino.hex", 113664 bytes
05:41:00.979 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_951705\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
05:41:00.985 (loader): ehex is valid, key hash: FB63C934 9683889D 3A20DB52 811A0593 83BEA33F 0F810CDF D6AD3C83 5DF1DA1A
05:41:00.995 (loader): elf appears to be for Teensy 4.0 (IMXRT1062) (2031616 bytes)
05:41:00.995 (loader): elf binary data matches hex file
05:41:01.005 (loader): elf file is for Teensy 4.0 (IMXRT1062)
05:41:01.009 (loader): using hex file - Teensy not configured for encryption
05:41:01.064 (loader): begin operation
And the true green:

Code:
05:48:37.775 (ports 5): found_usb_device, hwid=USB\VID_16C0&PID_0478&REV_0105
05:48:37.775 (ports 5): found_usb_device, devinst=0000001a
05:48:37.775 (ports 5): add: loc=usb:0/140000/0/1/1/1, class=HID, vid=16C0, pid=0478, ver=0105, serial=000fe6be, dev=\\?\usb#vid_16c0&pid_0478#000fe6be#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
05:48:37.775 (ports 5): hiddev_from_devinst_list: iface=0
05:48:37.777 (ports 5): found_usb_device complete
05:48:37.778 (ports 5): hid, found devinst=0000001B
05:48:37.778 (ports 5): hid, path=\\?\hid#vid_16c0&pid_0478#8&1f0a2482&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
05:48:37.778 (ports 5): hid,  opened handle
05:48:37.778 (ports 5):  devinst=0000001B, location=usb:0/140000/0/1/1/1
05:48:37.778 (ports 5):  vid=16C0, pid=0478, ver=0105, usepage=FF9C, use=0024
05:48:37.778 (ports 5):  devpath=\\?\hid#vid_16c0&pid_0478#8&1f0a2482&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
05:48:37.778 (ports 5): usb_add: usb:0/140000/0/1/1/1  hid#vid_16c0&pid_0478 (Teensy 4.0) Bootloader
05:48:37.848 (ports 5): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
05:48:37.850 (ports 5): nothing new, skipping HID & Ports enum
05:48:37.904 (loader): Device came online, code_size = 2031616
05:48:37.911 (loader): Board is: Teensy 4.0 (IMXRT1062), version 1.05
05:48:37.948 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_951705\T4MemInfoSink.ino.hex", 113664 bytes
05:48:37.973 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_951705\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
05:48:37.980 (loader): ehex is valid, key hash: FB63C934 9683889D 3A20DB52 811A0593 83BEA33F 0F810CDF D6AD3C83 5DF1DA1A
05:48:37.986 (loader): set background IMG_ONLINE
05:48:38.027 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_951705\T4MemInfoSink.ino.hex", 113664 bytes
05:48:38.058 (loader): File "C:\Users\kurte\AppData\Local\Temp\arduino_build_951705\T4MemInfoSink.ino.ehex", 113664 bytes, 4960 extra
05:48:38.061 (loader): ehex is valid, key hash: FB63C934 9683889D 3A20DB52 811A0593 83BEA33F 0F810CDF D6AD3C83 5DF1DA1A
05:48:38.070 (loader): elf appears to be for Teensy 4.0 (IMXRT1062) (2031616 bytes)
05:48:38.074 (loader): elf binary data matches hex file
05:48:38.079 (loader): elf file is for Teensy 4.0 (IMXRT1062)
05:48:38.081 (loader): using hex file - Teensy not configured for encryption
05:48:38.137 (loader): begin operation
Not sure if this shows much nor if there is anything else to gather...
 
@defragster @Paul - Running your memory info sketch with the old T4 and new T4... My guess is it won't help gain much more information other than currently neither will load an .ehex file... Not sure if either can (hardware/firmware issue) or difference in A/B chip... And or need some other detection in the loader? ...

So first up Purple OSHPark T4
Code:
D:\GitHub\T4LockBeta\T4MemInfoSink\T4MemInfoSink.ino Aug 25 2021 05:40:12
...
Verify secure code is running properly

Fail: Bus Encryption Engine is not active
Fail: Encryption region starts at wrong address
Fail: Program data is not within encrypted region
Fail: title_function() is not in encrypted region
Fail: title_text[] is not in encrypted region
Fail: csf not PJRC
NOTE: hab_version == 0x40307
NOTE: hab_status == 0xF0
Secure mode NOT SET :: [B]Fuses == 0x80018[/B]
New PJRC T4:
Code:
D:\GitHub\T4LockBeta\T4MemInfoSink\T4MemInfoSink.ino Aug 25 2021 05:40:12
...
Verify secure code is running properly

Fail: Bus Encryption Engine is not active
Fail: Encryption region starts at wrong address
Fail: Program data is not within encrypted region
Fail: title_function() is not in encrypted region
Fail: title_text[] is not in encrypted region
Fail: csf not PJRC
NOTE: hab_version == 0x40307
NOTE: hab_status == 0xF0
Secure mode NOT SET :: [B]Fuses == 0x8B018[/B]

There is a fuse difference...

...
Not sure if this shows much nor if there is anything else to gather...

Seems those are the same values seen here:
In the not yet locked or edited BETA T4 :: Secure mode NOT SET :: Fuses == 0x8B018
In a prior production T4 ::Secure mode NOT SET :: Fuses == 0x80018
And LOCKED Beta T4 :: Secure mode IS set :: Fuses == 0x4C8B01A

If that is the whole story on Fuses - new T4's are shipping LOCKED (unlike the Beta's) - but with 0x.B... that may be the bits '1011' to enable the optional use of eHex.

Unplugged the TallDog - 90% alcohol brush - and rinse after it was all tacky with rosin just redistributed. Hairdryer blow out and sitting overnight - FlexPCB plugged to working. Had to push plug end in with tweezers on the Flex shoulder.

Kitchen and Sink INO's current for the isEncrypt() output, and Kitchen has the slowed TEMP Spew.
 
T4 locked Beta temps versus prior production

With the Locked Beta T4 in the TallDog breakout I have two of those units - similarly setup:

Running the Kitchen with 5 second temp updates - showing 6 degrees C higher. Both on desktop on 1ft micro USB cables from same Hub - cables from same pack but diff colors.

Production T4 - does have longer pins through to sockets sticking up 5mm more - and canbus parts (chip and 2 more caps) in place:
Code:
233.1551, 47.92
233.2467, 47.30
233.3384, 47.30
...
241.1317, 47.92
241.2233, 47.92
241.3150, 47.30
...
310.9040, 47.30
310.9956, 47.92
311.0873, 47.30

Locked T4 - running longer but temp stable - tall not short side headers on base PCB:
Code:
233.1551, 53.28
233.2468, 52.58
233.3385, 53.28
...
480.5214, 53.99
480.6131, 53.99
480.7047, 53.99
...
555.2447, 54.70
555.3364, 54.70
555.4280, 53.99
555.5197, 54.70

So lots more thermal mass and similar air exposure options
Started at diff times - but the left col MINUTES is from the same point in time of TEMP in right column

More ref measures - Other Beta (not yet) Locking T4 and a Production T4 : Both now with pin row soldered hanging from 1ft USB cable.

Unlocked Beta Lockacble T4:
Code:
61.9791, 55.67
62.0708, 55.67
62.1625, 55.67
62.2541, 56.33
62.3458, 56.33

Prod T4 - was running some degrees C higher before pinning.
Code:
62.2541, 53.86
62.3458, 53.86
62.4375, 53.86
62.5292, 53.86
 
Last edited:
@Paul, just as a reminder, with medium priority :)

We still need something for the issue with reading (and writing) files from interrupts. The Audio lib does that.
I think we need something that handles the file accesses, independend of the medium. For Teensy 3.x, too.

Think of SPI-SD and display, recording while writing, several instances of the players (mixed wave and raw, etc) and simultanous access from the main program.
At least, we should develop a "plan".
I think first step would be to add informational functions that tell on which medium (and interface) a file is. And if the medium (and interface) is used by something else.
 
More temp data pending with new sketch. But on shutdown the prior two noted in p#297:
Code:
>>>TEMP DIFF 
LOCKED KITCHEN ::
1614.3923, 51.87
1614.4840, 52.58

PROD KITCHEN ::
1373.6272, 46.68
1373.7189, 46.68

New sketch has TEMP monitor as well - now running on 4 T4's - two pinned, two TallDog breakout. Where in each pair one is lockable.

This is the sketch hinted at last week: Sketch writes a "C" file of some number of functions that cascade to calling each other. Run with 500 and now 1,000 and it builds like:
Code:
Memory Usage on Teensy 4.0:
  FLASH: [B][COLOR="#FF0000"]code:286868, data:86464[/COLOR][/B], headers:8616   free for files:1649668
   RAM1: variables:107328, code:38472, padding:27064   free for local variables:351424
   RAM2: variables:24736  free for malloc/new:499552

It does some busy work - found a loop making digits of Pi. It can make 800 digits, stopped at only 60 digits because that takes ~1ms each run. And I marked that seePi() as inline to fatten up the code and void the cache sooner with the code in FLASHMEM.

The code is running from FLASHMEM, and accumulates chars to a stack szString[]. That szString is then compared to a PROGMEM copy of the string unique to each function, and a second const copy of the digit string.

IT IS RUNNING WELL SO FAR! - only problem is closing and restarting the IDE when it starts losing it. Am using TyComm OF COURSE : Required with 4 T_4.0's online, each with DUAL SERIAL! Should see about any needed changes to TSET that I have not tried yet, it may just work when TLoader is still the default.

Does this prove anything, Hopefully:
> assure all encrypted code from FLASH decrypts to run properly
> assure all encrypted data from FLASH decrypts to compare properly
> size of both CODE and DATA in FLASH exceed 32KB so it will have to flush/fill the cache from encrypted Flash.
> Should allow some 'upper' end of the speed cost from the decrypt on the fly

QUICK note on first calc so far: Decrypt from LOCKED Encrypted T_4 adds 7.5% to runtime versus the three unlocked/unencrypted T_4.0's. - with the current 1,000 cascading calls.
Code:
 Current code just posted here : [URL="https://github.com/Defragster/T4LockBeta/tree/main/Code4Code"][B]T4LockBeta/tree/main/Code4Code[/B][/URL]

Cleanup ahead:
> it uses DUAL SERIAL to write out the Code that the Code writes to SerialUSB1 - that could be put under #ifdef
> that code is then copied back to a file in the sketch folder to build for inclusion. For 1,000 cascading calls that "CodeMade.ino" file is 810KB.
> Need to have the Output self document each T_4.0 in use so TEMP and PERF numbers posted are clear as to the source device in test.
> Need to call direct a single LAST in chain function # of times the CASCADE does to see if the cache makes expected diff in speed.
> CHECK Math and reported numbers, look for more numbers
> lunchtime now

Undocumented copy of current run results from 4 Teensy 4.0's - you can guess which is which for now:
Code:
42.0898, 54.33
Complete Count 1000	digit  took 1286852 us [766530580 piCycles] : net 9302

41.6433, 51.16
Complete Count 1000	digit  took 1287843 us [766689424 piCycles] : net 10028

41.1847, 46.68
Complete Count 1000	digit  took 1286849 us [766544700 piCycles] : net 9275

43.3343, 52.02
Complete Count 1000	digit  took 1286909 us [766544182 piCycles] : net 9336
 
@Paul - bootloader of .hex and .eHex across four T_4.0's (2 Beta) working perfectly w/IDE build and Button or TyComm 'Bootloader'.
> Prior posted notes
-> Weird DUAL LED FLASH not repeated again - Orange and RED on Upload.
-> Ctrl+Alt+S doesn't move .eHex to Build directory along with the .hex file.
-> when New Bootloader ships 'general user' will need a means to KNOW the 'encrypt' capabilities of the 1062 Teensy they have with a Sketch or Loader feedback.


@KurtE and @mjs513 ( @other ? ) : have you both LOCKED both of your Beta units?

I have one Unlocked - if we had a shared pem.key would could trade encrypted HEX files nobody else could use. Saving it to Lock with Beta 2.

As noted : so far the Code4Code example shows CODE and DATA decrypts properly during execution

update p#299 - Code4Code of 10,000 too much with 8MB .c file - took a LONG time then failed at the end, worked to BUILD with 4,000:
Code:
Memory Usage on Teensy 4.0:
  FLASH: code:1026508, data:326464, headers:8944   free for files:669700
   RAM1: variables:344928, code:38472, padding:27064   free for local variables:113824
   RAM2: variables:24736  free for malloc/new:499552

But then Stack Death:
Code:
CrashReport:
  A problem occurred at (system time) 14:36:41
  Code was executing from address 0x31D8
  CFSR: 82
	(DACCVIOL) Data Access Violation
	(MMARVALID) Accessed Address: 0x20054378 (Stack problem)
	  Check for stack overflows, array bounds, etc.
  Temperature inside the chip was 43.58 °C
  Startup CPU clock speed is 600MHz
  Reboot was caused by auto reboot after fault or bad interrupt detected

Seems having 4,000 copies active stack data is a bit much, along with 4,000 of these "static char szPi[PI_DIGITS_SZ];" filling RAM
-> that can be rewritten as it doesn't add anything to test.

Works for now going to 2,000 cascading calls:
Code:
Memory Usage on Teensy 4.0:
  FLASH: code:535596, data:166528, headers:8528   free for files:1320964
   RAM1: variables:181120, code:38616, padding:26920   free for local variables:277632
   RAM2: variables:24736  free for malloc/new:499552

Temps may not be stable on PROD as it was off some time but close to peak by now:
Code:
24.6315, 46.06
Completed CASCADE Count 2000	Cascading took 2572893 us [1531773530 piCycles] : net 19938
Direct calls took 2554947 us [1532341474 piCycles] : net 1045

3.0178, 51.16  // LOCKED Beta on TallDog
Completed CASCADE Count 2000	Cascading took 2574867 us [1532072764 piCycles] : net 21413
Direct calls took 2554950 us [1532342343 piCycles] : net 1047
 
Status
Not open for further replies.
Back
Top