Some of the fns in dw1000 HAL layer are using global values directly for things like array indexes etc. We need to make local copies of these values in order to account for reentrance, otherwise when the fn stack is saved and restored those global values may have changed.