Scale Magnometer to Servo
Okay, lets say the output of your BNO055 is called x and the value for your servo is y. We need to translate x to y and you are correct to use the map() function. But what you are forgetting is that you do not need to map all the values of x to all the values of y. You can split it up.

In your example the values of the BNO055 relate to the servo as follows:

x   | y   
0   | 0
120 | 0
300 | 180
360 | 180


The servo only rotates from 0 degrees to 180 degrees between the BNO055 sensor values of 120 and 300. So you only need to map those values, while all values below should result in 0 and all values above should result in 180 degrees for the servo.

This translates into the following code:

//x is the output of BNO055 sensor
if(x &lt; 120){
  servo.write(0);
}
if(x &gt; 300){
  servo.write(180);
}
if(x &gt; 120 &amp;&amp; x &lt; 300){
  y = map(x, 120, 300, 0, 180);
  servo.write(y);
}


Another way of coding this is:

if(x &lt; 120){
  servo.write(0);
}
else if(x &gt; 300){
  servo.write(180);
}
else{
  y = map(x, 120, 300, 0, 180);
  servo.write(y);
}