You are trying to set a constant to a constant?
I know what you mean to do, but thats my only guess as to why its buggin.
Quote: Now, this would work just fine but there are some issues with this code. First there is the fact that since these are hardware registers we may not be the only ones changing them. This is something the compiler needs to know else it will try to optimize our code and likely break it. The way we tell the compiler that variables change outside of the c code is to declare them volatile. The last issue is that we are using a variable (RAM) to store a constant. We would be much better served if we just used a #define…this also allows us to dereference the register in its declaration and makes writing to it a bit simpler. Here is the new, more proper code.
I know what you mean to do, but thats my only guess as to why its buggin.
Source: The Pern Project.
I was gonna write that myself...but its explained so well in The Pern Project tutorials.