cancel
Showing results for 
Search instead for 
Did you mean: 

WICED Studio Wi-Fi Combo

Anonymous
Not applicable

Hello,

I am working on project where I required to send packet using UDP method.

I found one App in Wiced udp_transmit. But i'm not able to send my packet.

i,e .

     struct packet_data{

          char str[20];

          int data_length;

     };

     struct packet{

               int i;

               struct packet_data data;

               char c;

      };

so what is the API for sending this packet over UDP??

Thanks,

Prashant

0 Likes
Reply
1 Solution
Employee

Hi Prashant,

You will need to copy your data into udp_data after creating a UDP packet with the function

wiced_packet_create_udp( wiced_udp_socket_t* socket, uint16_t content_length, wiced_packet_t** packet, uint8_t** data, uint16_t* available_space )

Please refer to line 154 and after in WICED-SDK-2.4.1\Apps\snip\udp_transmit\udp_transmit.c. It shows an example of creating and sending a UDP packet.

Thanks,

Jaeyoung

View solution in original post

0 Likes
Reply
4 Replies
Employee

Which version of SDK are you using ? and which platform ?

There is udp_receive and udp_transmit in this version of SDK

WICED SDK supporting Amazon Web Services 3.4.0-AWS

Thnx

vik86

0 Likes
Reply
Anonymous
Not applicable

Wiced version 2.4.1 I'm using.

I'd checked that udp_receive and udp_transmit examples but I'm not understanding how can I send my packet suppose struct packet over UDP??

0 Likes
Reply
Employee

Hi Prashant,

You will need to copy your data into udp_data after creating a UDP packet with the function

wiced_packet_create_udp( wiced_udp_socket_t* socket, uint16_t content_length, wiced_packet_t** packet, uint8_t** data, uint16_t* available_space )

Please refer to line 154 and after in WICED-SDK-2.4.1\Apps\snip\udp_transmit\udp_transmit.c. It shows an example of creating and sending a UDP packet.

Thanks,

Jaeyoung

View solution in original post

0 Likes
Reply
Anonymous
Not applicable

Thank you jaeyoung,

it helped me a lot!!!!!!!!!!

Thanks & Regards,

Prashantsinh Parmar

Sr. Embedded Software Engineer | TeksunMicrosys Pvt. Ltd.

Tel : +91 (79) 2396-3130

Website : <http://www.teksun.in/> www.teksun.in | www.teksun.us

Global Research& Development Services

Product Design | Hardware | Firmware | Software | Surveillance | Security | PCB

0 Likes
Reply