title: Convert C structure into unsigned char
body: <p>I have a function UartSend() to send data to network through uart. it takes argument unsigned char and an integer</p>
  
  <pre><code>UartSend(unsigned char *psend_data,int length);
  </code></pre>
  
  <p>i want to send a structure through this function</p>
  
  <pre><code>#pragma pack(push, 1)
  struct packet
  {
  
      int a;
      char b[3];
      ...
  
  }PacketData;
  
  #pragma pack(pop)
  </code></pre>
  
  <p>How to covert this structure to unsigned char for sending this data through UartSend?
  thanks..</p>