2021-12-20 05:50 AM
Does anyone have any experience of trying to control non-exisistant pins?
I have a design that takes stm32f767 in the lqfp100 package. But none seem to be available.
Looking around, I managed to procure a small run of stm32f779* in the wlcsp180 package, and I plan to make an adapter board so that they may be placed on my main board.
As far as I know, those processors are very similar so I intend to have the same firmware for both. The might even have the same die (i.e. chip), just that the unused pins are not bonded out.
Because the wlcsp180 omits certain pins present on the lqfp100 (PC2 - PC5), I plan to make a few minor changes to the pin-out. I want my code to auto-detect which processor is in use, and drive the appropriate pins.
My idea was that I could tie a pin on the wlcsp180 adapter board that isn't present on lqfp100. And then if I pull that pin either high or low and it follows both pulls the tie cannot be present and it must be the lqfp100 package.
But when I tried this with pin PF4 on my stm32f767VIT6 (taking care to enable the clock to GPIOF), the pin always read back as 0 - even if I was pulling or driving it high. So it might be that port F, which does not seem to be used at all on lqfp100, is not functional rather than just not bonded.
Is there a better pin to use? How might I detect which processor/package is present at run-time?
Regards,
Danish
*I only bought enough to cover one year's expected sales, a small fraction of what the distributor had at the time. And I see they are now all sold out.
2021-12-20 06:55 AM
My experience is that they always return 0 as well. I don't believe it is something that is specified.
If you have 1-2 free pins, you can tie those to ground on one one board while leaving them floating on the other and use pullups to determine which is which. Or if pins exist on one device and not on the other, you get this for free unless you tie them to ground.
The DEV_ID is the same between these packages so no help there.
2021-12-20 07:11 AM
That might explain why some absent pins are explicitly labelled as "NC" where most of the others are identified as "-".
The data sheet, in the notes for Table 11 pin and ball definitions says:
So by implication, pins labelled "-" are tied to Vss to prevent class-A current when a pin is programmed to be a floating digital input