Best suited tool to document message processing done in C written program

Posted by user3494614 on Stack Overflow See other posts from Stack Overflow or by user3494614
Published on 2014-06-09T15:20:43Z Indexed on 2014/06/09 15:24 UTC
Read the original article Hit count: 188

Filed under:
|
|

I am relatively new to UML and it's seems to be very vast I have a small program which basically receives messages on socket and then depending upon message ID embedded as first byte of message it processes the buffer. There are around 5 different message ID which it processes and communicates on another socket and has around 8 major functions. So program in short is like this. I am not pasting entire .c file or main function but just giving some bits and pieces of it so that to get idea of program flow.

int main(int argc, char** argv)
{

register_shared_mem();

listen();

while(get_next_message(buffer))
{
   switch((msg)(buffer)->id)
   {
        case TYPE1:
              process1();
              answer();
.....
   }
}

}

I want to document this is pictorial way like for Message type 1 it calls this function which calls another and which calls another. Please let me know any open source tool which will allow me to quickly draw such kind of UML or sequence diagram and will also allow me to write brief description of what each function does?

Thanks In Advance

© Stack Overflow or respective owner

Related posts about c

    Related posts about uml