solving reviews pt3
This commit is contained in:
@@ -135,9 +135,17 @@ int main(void)
|
||||
tftp_server_init();
|
||||
|
||||
// Initialize the UDP broadcast service
|
||||
if (udp_broadcast_init(270,255) != ERR_OK || udp_broadcast_connection_init() != ERR_OK){
|
||||
LOG_WARN(TAG,"error initializing udp connection");
|
||||
|
||||
if (udp_broadcast_init(270,255) == ERR_OK){
|
||||
goto connected;
|
||||
}
|
||||
LOG_WARN(TAG,"error initializing udp connection, trying again in 500ms");
|
||||
HAL_Delay(500);
|
||||
if(udp_broadcast_connection_init() != ERR_OK){
|
||||
LOG_WARN(TAG,"error initializing udp connection, check warnings from udp_broadcast_init() or udp_broadcast_connection_init()");
|
||||
}
|
||||
|
||||
connected:
|
||||
if (udp_broadcast_set_owner_details("Joran", "Van Nieuwenhoven")){
|
||||
LOG_WARN(TAG,"error setting owner's details");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user