made some changes in sdk and thread