- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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
Solved! Go to Solution.
- Labels:
-
TCPIP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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??
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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