Search:

Type: Posts; User: Sink0

Search: Search took 0.01 seconds.

  1. Replies
    9
    Views
    1,881

    So why it does work with 0x1FFFFFFFF? And why...

    So why it does work with 0x1FFFFFFFF?

    And why BITMASK(32) works?

    the 32 is suposed to be masked by the 5 bits too no?
  2. Replies
    9
    Views
    1,881

    Oh ok thats explain everything now.. yea i was...

    Oh ok thats explain everything now.. yea i was getting that warning but i was ignoring the equal case.. so i cant shift a 32bits variable 32 times...

    using 0x1FFFFFFFF works but i dont know if...
  3. Replies
    9
    Views
    1,881

    Nop it does not work.. i did copy and paste your...

    Nop it does not work.. i did copy and paste your code and got same result... do you think thats some problem with my mingw? Anyway i cant understand why should i have this behavior x is just the...
  4. Replies
    9
    Views
    1,881

    Could not get the point.. What is the...

    Could not get the point..

    What is the difference of

    uint8_t val = 32;
    uint32_t ret;

    ret = BITMASK(val); //return 0
    ret = BITMASK(32); // return 0xFFFFFFFF
  5. Replies
    9
    Views
    1,881

    Weird behavior on Macro...

    Hi, i have a code where i defined:

    #define FULLMASK 0xFFFFFFFF
    #define BITMASK(x) (~(FULLMASK<<x))

    If i use an uint8_t variable with value 32 the macro returns 0, but if i write...
  6. Replies
    2
    Views
    980

    Help with function Pointer

    Hi, i have a question about function pointer. I am implementing a structure inside a microcontroller's program, to deal with some programed events. On my function pointer definition i am using as an...
  7. I am slowly programing here haha. Its my mother's...

    I am slowly programing here haha. Its my mother's birthday today, so no time to work. Just one advice. I am going to make a GUI for the program (i am going to try as i dont have any experince with...
  8. I was wondering if that would not make use of too...

    I was wondering if that would not make use of too much memory, but i guess there is no option. Thank you!
  9. Hmm i was wondering .. how can i "insert" lines...

    Hmm i was wondering .. how can i "insert" lines on the begin of a file? If i write on a file from the begin it will start overwriting what is already on the file...

    Thank you!
  10. Program or Script to Add Header to .c and .h files.

    Hi... i was going to make myself a program to add headers to .c and .h files, but as i dont want to reinvent the wheel, is there such program on the intertet? As header i mean, a comment with the...
  11. Replies
    15
    Views
    3,074

    Wow, i would never expect that a compiler it is...

    Wow, i would never expect that a compiler it is writen on a previous version of its own language. .. very weird. .... well thank you about the answer!

    Any other comments are still accepted!!
    ...
  12. Replies
    15
    Views
    3,074

    General question about programming languages...

    I could not find any better topic to ask this. This question is generic and not only related to C programming. If it is not suited to this forum please feel free to remove it.

    My question is...
  13. Replies
    7
    Views
    1,317

    Oh, ok i will make use of that!! Thank you!

    Oh, ok i will make use of that!! Thank you!
  14. Replies
    7
    Views
    1,317

    Thank you!! It worked You helped a lot!!...

    Thank you!! It worked You helped a lot!! Actually, it did not complain haha. But thank you.

    And laserlight made everything more clear to me!!

    Cya
  15. Replies
    7
    Views
    1,317

    Hmmm .. thats true.. so i would just have to make...

    Hmmm .. thats true.. so i would just have to make like this?Yea thats makes sense...



    int f1(char *a)
    {
    return f2(a);
    }
  16. Replies
    7
    Views
    1,317

    Very stupid question about pointers

    Hi, i just want to make sure, Is this correct?


    int f1(char *a)
    {
    return f2(&a);
    }

    int f2(char *a)
    {
Results 1 to 16 of 17