:sleepy: gain and offset calculation verified and excellent