dynamically allocate base
Merge pull request #9 from stevether/dev

dynamically allocate base