big sdk.rb splitted into files, fixed number of bugs