Could you please paste your code in a nested code field ?
In your text screen, use your far right button named "wrapped [code]". And please tell at which lines it generates those errors.
User Profile
Collapse
-
What I meant with "work/doesn't work"...
Those code parts that generated compilation errors. So that's put the text "doesn't work" after the lines that didn't work.
But why can't I declare the struct pointer in main() ?...Leave a comment:
-
I found the problem...
Code:void InitReloadTimer(void)
I heard that the old C used prototypes with the variables beside it. Not inside (). So my compiler was looker for the variables and noted at the same time that my other prototypes were also wrong. Yea =P
Now I got a new question... about struct pointers. I've read several pages where all struct pointers are...Leave a comment:
-
I double checked everything and stripped contents of the header file, into the main file... Added, stripped en rebuild several things.
Only...
I still get the same problems. I loaded the C file into a sample project that gives no errors while compiling. When I overwrite it with my C file, it still generates the same errors. I talking about these errors...
line 19: both separate parameter declaration and parameter...Leave a comment:
-
Newbie compiler questions
I need a little help since I keep getting these errors while compiling. I can't find an answer that helps me out via google. I keep getting this error...
"both separate parameter declaration and parameter list declaration are used"
It refers to both off my global variables. These global vars are used when an interrupt is called. The compiler also gives a syntax error in the code off the interrupt. With the... -
thx for your reply. Could you please give me a simple example on how to make bit manipulation portable and reliable ?...Leave a comment:
-
Ok, thx for the help so far...
Could someone please explain why it is necessary to please an unsigned char within the union ? I'm not quite sure, but does it has something to do with the port containing 8 outputs ? I kinda understand the meaning of a union, but not the practical use of it.
Second, when using typecasting to load p_struct2 with the adres of struct1. That is adres 0x00. I can't seem to understand the logic...Leave a comment:
-
Setting two structures at the same adress
I'm trying to set two bitfield structures on the same adres. These two structures represent two different functions. And they control a register of 8 bits off a microcontroller . Which on their turn, they drive 8 outputs.
Why I use bitfields... is because I want to quickly set a variable to an individual port or to a defined set off ports. Depending of the function and a hardware switch.
So the first structure is nested...
No activity results to display
Show More
Leave a comment: