cancel
Showing results for 
Search instead for 
Did you mean: 

Wi-Fi Combo

jats_2143151
New Contributor

I using STM32F4 to transmit camera capture jpep

form device to server via wifi udp

I do frame transmit, and packet size is 1460, speed 400 packet / second

it's often stuck on wiced_udp_send

it's my code

while(pp->length >0){

if(pp->length>1460){

if(cam_send_data((uint8_t *)pbuff, (uint16_t)1460 )!= WICED_SUCCESS){

WPRINT_MACRO(("socket send data : send data failed\r\n"));

return WICED_ERROR;

}

pbuff=(uint8_t *)(pbuff+1460);

pp->length=(uint32_t)(pp->length-1460);

} else {

if(cam_send_data((uint8_t *)pbuff, (uint16_t)pp->length )!= WICED_SUCCESS){

WPRINT_MACRO(("socket send data : send final data failed\r\n"));

return WICED_ERROR;

}

pp->length=0;

break;

}

}

and cam_send_data is do

const wiced_ip_address_t INITIALISER_IPV4_ADDRESS( peer_ip_addr, MAKE_IPV4_ADDRESS(192, 168, 1, 35) );

memcpy(tx_data, pp, data_length);

wiced_packet_set_data_end(packet, (uint8_t*)tx_data + data_length);

if (wiced_udp_send(&udp_socket, &peer_ip_addr, peer_port, packet) != WICED_SUCCESS)

{

WPRINT_APP_INFO(("UDP packet send failed\n"));

wiced_packet_delete(packet);

return WICED_ERROR;

}

Any solution can fix this problem?

0 Likes
1 Solution
jats_2143151
New Contributor

Thanks, I change another wifi ap solve my problem.

It's seems to be the problem of wifi ap.

Wiced not dump any problem.

View solution in original post

0 Likes
2 Replies