This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

issues while using unsigned long data type

I'm curious to know if anyone has had issues using unsigned/signed long data types.

In previous version of software this did not present an issue, however, when I recompile the old projects and flash it to my device, the program will not run even if there have been no changes to the code. Commenting out the lines of code that handle the long data types will allow the code to run but in the end, I need to be able to use these variables.

I previously used uVision 4 without an issue, and I have recompiled code a few months ago that also worked with any issue.

Any help and/or insight would be appreciated.

Thank you,
Alex

Parents Reply Children
  • Thank you, I believe this will help. I also have v9.55 which I downloaded at the end of March.

    I found a work around to the issue, however. I simply used pointers to point to the variables that were causing issues and manipulated them that way.

    Thank you for pointing me to this article,
    Alex Ramirez

  • You are neither describing a compiler version nor posting any specific source code lines and exactly what is going wrong with them.

    If you are doing interesting things with type casts, then you could have alignment issues so depending on linker and runtime library your variables for some tool versions happens correctly aligned while not for some other tool versions.

    There are many ways to write incorrect code that still happens to work as intended by (bad) luck.