Advice with LLAP code

I am using a ciseco xinoRF to control a pc fan using a dallas temp sensor.

I have been having problems with the code in that it does not send the Starting Message or temp.

When I remove the code for the fan it works ok but as soon as I put it back in it stops.

I am getting a bit frustrated and think I must be missing something fundamental.

Thank you

// Do not remove the include below
#include "LLAPav.h"
#include <LLAPSerial.h>
#include <OneWire.h>
#include <DallasTemperature.h>
//The setup function is called once at startup of the sketch

/*LLAP AV
 * Aim to control fan in av cabenet depending on temp
 * Upload to LLAP
 * Enable manual overide Possiible
 */
#define ONE_WIRE_BUS 9 //Temp input pin
#define TEMPERATURE_PRECISION 9
#define FanOutputPin 3 //Fan Output Pin
#define DEVICEID "AV"	// this is the LLAP device ID


// Setup Temp Sensor
OneWire oneWire(ONE_WIRE_BUS);
DallasTemperature sensors(&oneWire);


unsigned long lastmillis = 0;
unsigned long llapmillis = 0;
char TempString[10];
char RPMString[10];
double Input = 0;
double minTemp = 20;
// inputs
uint8_t inputs[] = {2,3,4,7,10,12,254};

String msg;        // storage for incoming message
String reply;    // storage for reply

void setup()
{
	//Start LLAP
	Serial.begin(115200);
	  	LLAP.init(DEVICEID);
		pinMode(8,OUTPUT);		// switch on the radio
		digitalWrite(8,HIGH);
		pinMode(4,OUTPUT);		// switch on the radio
		digitalWrite(4,LOW);	// ensure the radio is not sleeping
		delay(400);				// allow the radio to startup
		 byte i=0;
		  while (inputs[i] != 254) {pinMode(inputs[i],INPUT); digitalWrite(inputs[i++],HIGH);}
		  i=0;

		  String permittedChars = "-#@?\\*ABCDEFGHIJKLMNOPQRSTUVWXYZ";

	//Temp setup
		sensors.begin();
		sensors.requestTemperatures();
		Input = sensors.getTempCByIndex(0); //Set Input to Current Temperature

	 //Setup Pins
			pinMode(FanOutputPin, OUTPUT);
			LLAP.sendMessage(F("STARTED"));  // send the usual "started message
			digitalWrite(FanOutputPin, HIGH);

}

void loop()
{
	//llap recieve
	if (LLAP.bMsgReceived) // got a message?
    {
        msg = LLAP.sMessage;
        LLAP.bMsgReceived = false;
        reply = msg;
        if (msg.compareTo("HELLO----") == 0)
        {
            ;    // just echo the message back
        }
        else if (msg.startsWith("SETT"))
                {
                    msg = msg.substring(5);
                    int value = msg.toInt();
                    minTemp = value;
                    reply = "TempSet-";
                }
    }

	//Read Temp
	if(millis() - lastmillis == 10000){
	sensors.requestTemperatures();
	Input=sensors.getTempCByIndex(0);

	if(Input<= minTemp){
		digitalWrite(FanOutputPin, HIGH);
	}
	else{
		digitalWrite(FanOutputPin, LOW);
	}
		lastmillis = millis();
	}



//Need to add LLAP output
	   if(millis() - llapmillis == 60000){
			sensors.requestTemperatures();
			Input=sensors.getTempCByIndex(0);
		   if (isnan(Input)){
		
			LLAP.sendMessage(F("ERROR"));
		} else {
			dtostrf(Input,5,2,TempString);
				String ST;
				ST = "T" + String(TempString);
		LLAP.sendMessage(ST);

	   }
		llapmillis = millis();
	   }
}
#define FanOutputPin 3 //Fan Output Pin
uint8_t inputs[] = {2, 3, 4, 7, 10, 12, 254};

Is the fan connected to pin 3 or is an input connected to pin 3 ?

Fan

I thought the

 uint8_t inputs[] = {2, 3, 4, 7, 10, 12, 254};

was part of the serial buffer for the LLAP receive.
Have I misunderstood what that line is for?

I am very new at this but having lots of fun.

Thank you

These lines set pin 3 to be an INPUT

uint8_t inputs[] = {2, 3, 4, 7, 10, 12, 254};
.....
  byte i = 0;
  while (inputs[i] != 254) {
    pinMode(inputs[i], INPUT);
    digitalWrite(inputs[i++], HIGH);
  }

These lines set pin 3 as an OUTPUT

#define FanOutputPin 3 //Fan Output Pin
.....
pinMode(FanOutputPin, OUTPUT);

The inputs array does not seem to be used in the program so I do not know what it is for.

Thank you.
I think it was a hang over from previous attempt. Will remove those lines later an give it a go.