Updating my UF2 tools to handle what a Pico SDK 2.0.0 puts out for RP235X ARM-S builds I noticed the UF2 Blocks are as follows -
This query relates to "Num" for the "RP2XXX_ABSOLUTE" entry at the top, what Microsoft call "numBlocks". "Seq" is what Microsoft calls 'blockNo'.
The Microsoft UF2 specification is incomplete in parts, defines "Num" as "Total number of blocks in file", which isn't always the case. It's more "Total number of blocks which are present per specific Family ID" or something like that.
That holds up for "RP2350_ARM_S" where there are blocks 0 through 82, which matches the 83 blocks there are said to be for that. And that's how it was for RP2040.
But for "RP2XXX_ABSOLUTE" it doesn't. The "Num" indicates two blocks should be present when there's only one.
One can shrug, "it is what it is", and indeed it is not defined at all well, but would it be possible to set "Num" to "1" when there is only one block as that makes verifying the UF2 as being how it should be so much easier, more reliable.
It may simply be an off by one error and, if so, that's fine, no need to change anything, as long as we have it defined.
Or is there a block which should have been emitted which hasn't been ?
Code:
Family Name Seq Num AddressE48BFF57 RP2XXX_ABSOLUTE 0 2 10FFFF00E48BFF59 RP2350_ARM_S 0 83 10000000E48BFF59 RP2350_ARM_S 1 83 10000100...E48BFF59 RP2350_ARM_S 81 83 10005100E48BFF59 RP2350_ARM_S 82 83 10005200
The Microsoft UF2 specification is incomplete in parts, defines "Num" as "Total number of blocks in file", which isn't always the case. It's more "Total number of blocks which are present per specific Family ID" or something like that.
That holds up for "RP2350_ARM_S" where there are blocks 0 through 82, which matches the 83 blocks there are said to be for that. And that's how it was for RP2040.
But for "RP2XXX_ABSOLUTE" it doesn't. The "Num" indicates two blocks should be present when there's only one.
One can shrug, "it is what it is", and indeed it is not defined at all well, but would it be possible to set "Num" to "1" when there is only one block as that makes verifying the UF2 as being how it should be so much easier, more reliable.
It may simply be an off by one error and, if so, that's fine, no need to change anything, as long as we have it defined.
Or is there a block which should have been emitted which hasn't been ?
Statistics: Posted by hippy — Mon Aug 12, 2024 5:09 pm