Event driven timed I/O
A very simple solution is to use a Map that (as its name implies) maps a string to a function so that you can pass an array of sorted strings and ask for the application to get each function and run it in the specified order.

Something like this:

var myFuncs={ 'firstI2C':firstI2C,
              'secondI2C':secondI2C,
              //so on
}


Then you can have a function that tells the program to run next function. For example:

var nextMethodIndex=0;

var methodOrder=['firstI2C','secondI2C','thirdI2C',....] // this array can be fed as JSON.

function runNextMethod()
{
    if(nextMethodIndex&lt;methodOrder.length)
    {
         var func= myFuncs[methodOrder[nextMethodIndex]];
         nextMethodIndex++;
         setTimeout(func, 1000)
    }

}


Finally you should modify your functions to call runNextMethod when they finish their job.

function timer() {
  runNextMethod();
  setTimeout(timer, 5000)
}

function firstI2C() {
  Servo.writeReg(1, 250);
  Servo.writeReg(2, 128+16+0x0);
  Servo.writeReg(37, 0);
  console.log("1");
  runNextMethod();
}