Forum : ST7/STM8
Original Post
Post Information | Post |
---|---|
November 18, 2009 - 11:37pm
|
Just downloaded the latest ST7/STM8 toolkit (2.26.09.0317) to test it out. So far I've encountered an issue with bit variables shared across modules. CFile1.c extern bit TestFlag; void main(void) { TestFunc(); if (TestFlag) { while(1); } while(1); } CFile2.c bit TestFlag; void TestFunc(void) { TestFlag=1; } The code in TestFunc() modifies address 0x00 (pheripheral registers) instead of using a bit in RAM. |
Hi Blasio,
Thank you for this report.
We reproduced you issue in our labs. The compiler is consistently using bit addresses, but these addresses are consistently wrong!
We are working on this issue, which may require a compiler patch.
Regards,
Bruno
Any update on this?
--
Blasio
Hi Blasio,
Sorry for the latency. We have another open issue on the comipler, which should be fixed within few days. We will release a patch for both problems, but we still need some time to validate.
If waiting for few more days for the patch is a problem for you we can send you an engineering --unsupported-- compiler patch which corrects the bit issues. Let us know.
Thanks for your patience.
Regards,
Bruno
Hi Bruno,
I've reverted to the previous release of the toolkit for the time being, so there's no hurry for the patch.
thanks,
Blasio
Hello,
I've tried out the latest compiler version, with the patch (V2.26.09.317) and it seems to be working correctly now.
Other than some optimizations in the output code the only change I've noticed is that in listing files bit variables all have an offset of 0, while in the older listing files (V2.25.09.238) there are offset values. I'm guessing this is by design?
Regards
Blasio
Hi Blasio,
There isn't any change in the bit display since version 2.24.09.238
Can you give us more information or a sample?
Regards,
Stéphane
With V2.25.09.238 of the compiler I get this in the listing:
With V2.26.09.317 I get:
I can send you the listings and/or source code if required.
--
Blasio
The offset of uninitialized variables is currently displayed too early (when 'symbols' command/pragma is provided).
Will be fixed in next release.
Stéphane
I am currently experiencing problems with external bit variables as well. Please inform me (by posting on this thread) when any new patches or releases are ready. Thank you.
Hello JQ,
Raisonance released a patch on the 14th that amongs others fixes the problem I was encountering when I made this post. If it's the same issue, that should solve it.
--
Blasio