add device read/set api
Merge pull request #32 from michaelfung/master

add device read/set api