fix DEVICE_NAME to device_name & fix sample code for raspberry pi