----------------------------------------------------------------------------- Process a response from the Z-Wave PC interface -----------------------------------------------------------------------------
| 3331 | // Process a response from the Z-Wave PC interface |
| 3332 | //----------------------------------------------------------------------------- |
| 3333 | void Driver::HandleNetworkUpdateRequest |
| 3334 | ( |
| 3335 | uint8* _data |
| 3336 | ) |
| 3337 | { |
| 3338 | ControllerState state = ControllerState_Failed; |
| 3339 | ControllerError error = ControllerError_None; |
| 3340 | uint8 nodeId = GetNodeNumber( m_currentMsg ); |
| 3341 | switch( _data[3] ) |
| 3342 | { |
| 3343 | case SUC_UPDATE_DONE: |
| 3344 | { |
| 3345 | Log::Write( LogLevel_Info, nodeId, "Received reply to FUNC_ID_ZW_REQUEST_NETWORK_UPDATE: Success" ); |
| 3346 | state = ControllerState_Completed; |
| 3347 | break; |
| 3348 | } |
| 3349 | case SUC_UPDATE_ABORT: |
| 3350 | { |
| 3351 | Log::Write( LogLevel_Warning, nodeId, "WARNING: Received reply to FUNC_ID_ZW_REQUEST_NETWORK_UPDATE: Failed - Error. Process aborted." ); |
| 3352 | error = ControllerError_Failed; |
| 3353 | break; |
| 3354 | } |
| 3355 | case SUC_UPDATE_WAIT: |
| 3356 | { |
| 3357 | Log::Write( LogLevel_Warning, nodeId, "WARNING: Received reply to FUNC_ID_ZW_REQUEST_NETWORK_UPDATE: Failed - SUC is busy." ); |
| 3358 | error = ControllerError_Busy; |
| 3359 | break; |
| 3360 | } |
| 3361 | case SUC_UPDATE_DISABLED: |
| 3362 | { |
| 3363 | Log::Write( LogLevel_Warning, nodeId, "WARNING: Received reply to FUNC_ID_ZW_REQUEST_NETWORK_UPDATE: Failed - SUC is disabled." ); |
| 3364 | error = ControllerError_Disabled; |
| 3365 | break; |
| 3366 | } |
| 3367 | case SUC_UPDATE_OVERFLOW: |
| 3368 | { |
| 3369 | Log::Write( LogLevel_Warning, nodeId, "WARNING: Received reply to FUNC_ID_ZW_REQUEST_NETWORK_UPDATE: Failed - Overflow. Full replication required." ); |
| 3370 | error = ControllerError_Overflow; |
| 3371 | break; |
| 3372 | } |
| 3373 | default: |
| 3374 | { |
| 3375 | } |
| 3376 | } |
| 3377 | |
| 3378 | UpdateControllerState( state, error ); |
| 3379 | } |
| 3380 | |
| 3381 | //----------------------------------------------------------------------------- |
| 3382 | // <Driver::HandleAddNodeToNetworkRequest> |