Added dyn sys for the gain adapting