Recent Posts

Pages: 1 ... 8 9 [10]
91
NXPTM M522XX, KINETIS and i.MX RT / Re: RT1064, boot from SD.
« Last post by mark on March 08, 2023, 06:31:48 PM »
Hi

If there were no QSPI flash the only loader available is the ROM loader, which can boot from SD cards but is not necessarily a very good choice since SD cards are unreliable in comparison to QSPI flash and if the card fails, is corrupted or is removed the board can't do anything.

It is possible for the uTasker boot loader to also load directly from SD card to RAM or SDRAM but, due to the above, I would never recommend it for an embedded system - plus why use an expensive (heat sensitive) SD card to hold a small program when a cheap ($0.50) QSPI flash can do it better? [Since a 1064 has this inside anyway it would make even less sense]

I don't know why there is a limit in ITC size in the article but that may be the ROM loader's limitation (unless eFUSEs are set possibly to change the configuration, which cannot be changed back again...!). The uTasker loader (running in the first blocks of QSPI flash) is limited to the chip's 512k ITC (since it can dynamically configure this according to the code's requirement) or much larger in SDRAM (or much larger in QSPI flash).

As noted in the article it is cool to boot from an SD card directly (without any need for QSPI flash) but whether it makes real sense in a real -world embedded system is highly unlikely.

Regards

Mark

92
NXPTM M522XX, KINETIS and i.MX RT / Re: RT1064, boot from SD.
« Last post by LuisHS on March 08, 2023, 05:36:56 PM »

Thanks Mark
And wouldn't it be possible to always boot from SD, without having to copy to flash?

I saw this article from McuonEclipse where they explain how to boot an application from SD, the processor starts the ROM bootloader, then loads the image from the SD card into RAM (ITC) and then runs it. In that configuration no internal or external FLASH memory would be needed.

https://mcuoneclipse.com/2019/01/22/tutorial-booting-the-nxp-i-mx-rt-from-micro-sd-card/

They also explain that the application is copied from SD to ITC RAM from where it runs, but that this limits the program to a maximum of 64k, which seems very little to me.

In your answer you tell me that in ITC+DTC the size of the program would be 512K, that is much more than the 64k indicated in mcuoneclipse. So this leaves me confused.

To always boot from SD, without copying to Flash, would it always be done using the Rom bootloader that would copy to ITC from where the program would run, and what would be the maximum size of the program that could be run?

Regards
93
NXPTM M522XX, KINETIS and i.MX RT / Re: RT1064, boot from SD.
« Last post by mark on March 08, 2023, 02:04:31 PM »
Hi

The standard SD card boot loader method is to have he new image on the card and load it to QSPI flash (and delete the SD card image after successful transfer).
At each subsequent boot there are three possibilities:
- copy the code from encrypted QSPI flash to ITC RAM and run it there (fastest operation)
- copy the code from encrypted QSPI flash to SRAM and run it there (second fastest operation but operation s no longer encrypted since the SDRAM operation can be observed)
- Run the code in place in QSPI Flash (XiP) or XiP-BEE (on the fly decryption). XiP is (depending on caching) up to 20x slower that running from ITC and less deterministic since the speed depends on caching so can change) -  XiP BEE is a bit slower again (about 30% I have heard). When the QSPI Flash in internal to the chip (RT1064) it is protected and possibly there is no advantage of using XiP BEE for code protection.

ITC + DTC is limited to the FlexRAM size of the chip. RT105x/6x have 512k so programs up to about 512k would be possible (as long as data is located in SDRAM or 512k OTCRAM2 (in 106x)

Large QSPI Flash are available so program size shouldn't generally be an issue (except for RT1064 where it is fixed at 4MBytes) and SDRAM loses code protection so is not always the best choice.

Regards

Mark
94
NXPTM M522XX, KINETIS and i.MX RT / Re: uTasker for Kinetis MK64
« Last post by mark on March 08, 2023, 01:53:40 PM »
Hi

Booting (or boot loading) from an SD card is possible and the card can be used for other storage too.
RT1062s are 0.65mm pitch. Since PCB hole sizes are a little smaller the PCB can be more expensive (about +20%) but the 0.8mm BGA is in fact a more expensive part and they tend to cancel each other out and results in smaller possible boards. Soldering of 0.65mm pitch is no problem since the chips align themselves when the solder is molten so I don't think it is a factor to consider.

Regards

Mark
95
NXPTM M522XX, KINETIS and i.MX RT / RT1064, boot from SD.
« Last post by LuisHS on March 08, 2023, 03:22:50 AM »

Hello Mark.
I was watching your video to run the program in ITC memory, and I have some doubts.
https://youtu.be/fnfLQ-nbscI

If I want my application to boot from an SD card, is it essential that it be loaded and run in ITC?
What maximum size can my application have to boot from SD, is that limit the ITC memory size?

Can't configure my app to boot from SD card to run on SDRAM? it's much bigger, and wouldn't limit the size of my program that much.
96
NXPTM M522XX, KINETIS and i.MX RT / Re: uTasker for Kinetis MK64
« Last post by LuisHS on March 08, 2023, 02:39:19 AM »

Thanks mark.
Regarding the i.MX RT, do you know if I can configure the boot to be done from an SD card?

If so, could I have my encrypted firmware on that SD card? So that the microcontroller can boot my firmware from SD and also have other files of my application stored on that same SD card, such as some configuration file, all using FatFS.

In that case, I suppose that a bootloader would not be necessary, the SD card would already have the boot firmware and it would be enough to copy the SD card or create an SD formatted in FAT32 and copy the boot file with my firmware.

As for the RT1062 and others you refer to, you sell them too, they are 0.8mm pitch??, I have not worked with pitches smaller than 0.8mm because the PCBs would be more expensive and I suppose that the soldering process in oven can also be more delicate.

97
NXPTM M522XX, KINETIS and i.MX RT / i.MX RT 1062 Stock available to uTasker users
« Last post by mark on March 07, 2023, 07:55:09 PM »
Hi All

Note that the chip shortage has resulted in the uTasker project investing in the following chips, which are reserved for uTasker users and available at reduced prices (in comparison to distributors):

IMXRT1062DVL6B - commercial
IMXRT1062CVL5B  - industrial


These are 10mmx10mm 196 pin BGA with full features (2 x Ethernet, 2 x USB ,1Meg RAM, TFT display interface) and footprint compatible (and code 99% compatible) with i.MX RT 1051/52/61/62 and are useful for porting Kinetis projects to (they can also be used in place of i.MX RT 1064 as long as there is a QSPI flash connected)). With 600MHz zero wait state operation (up to 1.2G instructions per second) they are FAST as well. As well as having very high compatibility with Kinetis the uTasker project makes it simple to port from Kinetis projects and, with the chip stock, can ensure that supplies are immediately available when needed (some parts still have over a year delivery time otherwise).

The small BGA was chosen after experimentation with soldering (also hand soldering) and layout with 4-layer boards. Reference designs and guidance is thus available for those unsure about using BGAs, whereby it can be stated that they are not as difficult to work with as initially feared and result in small, reliable circuity.

There are good stocks available for immediate delivery or reservation, whereby each new project can order/reserve up to 1'200 pieces at the moment. (Quantities of up to 10'000 are possible for immediate delivery but only under exceptional circumstances since it is preferred to supply as many new projects as possible).

Regards

Mark
98
NXPTM M522XX, KINETIS and i.MX RT / Re: uTasker for Kinetis MK64
« Last post by mark on March 07, 2023, 07:50:48 PM »
Hi

K66 is still a big problem and I don't know where to obtain them from apart from some brokers, although they can charge up to $900 for each chip it seems. In addition I have had a case where the chip was not the one written on the package but a similar one without Ethernet inside, so it is a risk too!

The uTasker serial loader for iMXRT can be encrypted (and clone protected) with almost zero effort. There are guides and videos at https://www.utasker.com/iMX/developers.html
The uTasker project includes all encrypting tools so it is much simpler than the NXP method (which is a one-time usable key method). The key used in every chip is different (randomly generated) and doesn't need to be known/managed by the user. It won't interfere with the NXP encryption method if that were used on the same chip and the HW can be reused with different projects since the project key is still replaceable.
Each time the uTasker reference project is build it automatically generates plain code and encrypted outputs (you can simply tell it which project key you want to use to personalise it) and so there is almost no effort involved.

Note that the chip shortage has resulted in the uTasker project investing in the following chips, which are reserved for uTasker users and available at reduced prices (in comparison to distributors):

IMXRT1062DVL6B - commercial
IMXRT1062CVL5B  - industrial


These are 10mmx10mm 196 pin BGA with full features (2 x Ethernet, 2 x USB ,1Meg RAM, TFT display interface) and footprint compatible (and code 99% compatible) with i.MX RT 1051/52/61/62 and are useful for porting Kinetis projects to (they can also be used in place of i.MX RT 1064 as long as there is a QSPI flash connected)). With 600MHz zero wait state operation (up to 1.2G instructions per second) they are FAST as well. As well as having very high compatibility with Kinetis the uTasker project makes it simple to port from Kinetis projects and, with the chip stock, can ensure that supplies are immediately available when needed (some parts still have over a year delivery time otherwise).

There are good stocks available for immediate delivery or reservation, whereby each new project can order/reserve up to 1'200 pieces at the moment. (Quantities of up to 10'000 are possible for immediate delivery but only under exceptional circumstances since it is preferred to supply as many new projects as possible).

Regards

Mark

P.S. The encryption used on the SD card is compatible with the boot loader encryption and is there is no conflict. The encrypted SD card content is simply copied and store in the QSPI flash in the same format.

P.P.S. I will make a post repeating the 1062 details since it hasn't generally been advertised here before.
99
NXPTM M522XX, KINETIS and i.MX RT / Re: uTasker for Kinetis MK64
« Last post by LuisHS on March 07, 2023, 03:24:00 AM »

Thanks mark
Do you know where I can order some MK66s ?, sold out at all vendors until 2024.

I have some projects made for MK66 that I will eventually try to migrate to RT1024 or RT1064, but until I can do that conversion I would like to be able to get some MK66 so I can continue to build my boards with MK66. That's why ultimately, I wanted to try to see if these MK64 that I have here can be used as a replacement by overclocking to 168Mhz, I know it's not ideal, but it would be the last option due to the shortage of chips.

On the other hand, I wanted to ask you some questions about the use of the uTasker SD bootloader with the RT1064.

1.- The uTasker binary is encrypted so that it cannot be extracted from the chip in commercial products?.
2.- The user firmware that will load the uTasker bootloader is encrypted with your program as it was done with the MK66 or it must also be encrypted with the NXP system to encrypt binaries.

I find it confusing to work with i.MX since in these the protection against reading and extracting the program is not like with the Kinetis with chip reading protection, but rather encrypting the binary before loading it on the chip, with a key that must be previously write in the chip so that it decrypts the binary at runtime. So now to use uTasker on the RT1064, it sees that there is a conflict in the encryption, on the one hand there is the encryption of the i.MX RT and on the other hand the encryption of uTasker on the binary to be loaded (in my case by SD).

100
NXPTM M522XX, KINETIS and i.MX RT / Re: uTasker for Kinetis MK64
« Last post by mark on March 06, 2023, 02:30:13 PM »
Hi

The boot loaders of both K64 and K66 operate at 120MHz due to the fact that in order to operate at 180MHz the high-speed RUN mode is needed, in which Flash programming doesn't operate.
Therefore the code that you built and used for the K66 will be operating in RUN mode at 120MHz, which would also be a legal speed for the K64.

The K66 binary may operate on a K64 but there are some differences between the chips and so is not guaranteed - you can also rebuild your original version by changing the target define from K66 to K64, which would be the sure way to do it.

Although the Teensy project does allow overclocking the K64 to achieve faster core performance I don't recommend doing it since it is operating the chip outside of its specifications and so this should only really be used for personal hobby projects where the reliability if not too critical.

Regards

Mark
Pages: 1 ... 8 9 [10]