Function to set device_id
Created by: Protofall
The function returns 0 on success and -1 on failure (Device can't be saved to for one reason or another)
Created by: Protofall
The function returns 0 on success and -1 on failure (Device can't be saved to for one reason or another)