Issue with BBQ spark ignitor and DS18B20 temperature sensor

Hi all,
I've been working on an automated brewery system using propane and managed to burn up 2 hot surface ignitors. Since these seem to be so fragile, I thought I'd try spark ignition.

I'm using a barbeque spark ignitor

Which I've hooked up as a motor to the arduino - these BBQ ignitors are usually a motor which strikes a piezo crystal to generate 10kV to create the spark - which works quite well.

I've also wired up a DS18B20 to measure temperature, which also works quite well.

The problem is that when I try to run them together they don't work well.

The DS18B20 starts reading 0º and doesn't come back until I unplug the ground and plug it back in.

perature for the device 1 (index 0) is: 34.75
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 34.69
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 34.56 
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 0.00 //begin firing the ignitor
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 0.00

... trimmed ...

Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 0.00
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 0.00
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 0.00
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: -127.00  //unplugged
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 85.00 // plugged back in 
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 38.94 //happy again
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 38.13
Requesting temperatures...DONE
Temperature for the device 1 (index 0) is: 37.63

This doesn't happen when I trigger the bbq ignitor manually using it's included power supply, a AA battery.

I've got the ignitor wired as a motor according to this diagram

Though I am using 3v from the arduino and a 600Ω resistor going to the base of the 2n222a transistor.

I've even tried using the battery as the power supply, which works -- albeit more slowly than the 3v from the arduino -- but I still get the 0 signal from the temperature sensor.

This can't be a simple case of EMI or RFI can it? I mean this doesn't happen with the ignitor being triggered by hand, so it can't be, right? How can I "separate" the two power supplies? Is that the issue?

Thanks
JR

PS, here's my sketch (it's the dallas temperature "simple" with "blink without delay" spliced in. LEDpin = motor pin

#include <OneWire.h>
#include <DallasTemperature.h>

// Data wire is plugged into port 2 on the Arduino
#define ONE_WIRE_BUS 9

// Setup a oneWire instance to communicate with any OneWire devices (not just Maxim/Dallas temperature ICs)
OneWire oneWire(ONE_WIRE_BUS);

// Pass our oneWire reference to Dallas Temperature. 
DallasTemperature sensors(&oneWire);
const int ledPin =  13;
int ledState = LOW;             // 
unsigned long previousMillis = 0;        // will store last time LED was updated

// constants won't change :
const long interval = 1000;    

void setup(void)
{
  // start serial port
  Serial.begin(9600);
  Serial.println("Dallas Temperature IC Control Library Demo");

  // Start up the library
  sensors.begin();
  pinMode(ledPin, OUTPUT);


}

void loop(void)
{ 
  // call sensors.requestTemperatures() to issue a global temperature 
  // request to all devices on the bus
  Serial.print("Requesting temperatures...");
  sensors.requestTemperatures(); // Send the command to get temperatures
  Serial.println("DONE");
  
  Serial.print("Temperature for the device 1 (index 0) is: ");
  Serial.println(sensors.getTempCByIndex(0));
   unsigned long currentMillis = millis();
 
  if(currentMillis - previousMillis >= interval) {
    // save the last time you blinked the LED 
    previousMillis = currentMillis;   

    // if the LED is off turn it on and vice-versa:
    if (ledState == LOW)
      ledState = HIGH;
    else
      ledState = LOW;

    // set the LED with the ledState of the variable:
    digitalWrite(ledPin, ledState);
  }
    
}

The 5V and 3.3V outputs on the Arduino were never intended to power motors, because doing so causes just the type of problem you are observing. Running the motor off the power pack connected to "raw" Vin might work, but the best solution is to use separate power packs.

jremington, thanks for the feedback, but I think perhaps you missed this key sentence of my OP

I've even tried using the battery as the power supply, which works -- albeit more slowly than the 3v from the arduino -- but I still get the 0 signal from the temperature sensor.

Even running the ignitor from the battery wired through the transistor runs into this 0 signal case -- I suspect the reason is that the ground/battery negative must still be connected.

I didn't miss that "key sentence" -- it made no sense to me, and it still doesn't. What are you using for batteries?

Yes, all grounds must be connected.

jremington:
I didn't miss that "key sentence" -- it made no sense to me, and it still doesn't. What are you using for batteries?

Yes, all grounds must be connected.

Arduino is being powered from USB, the spark ignitor from a D cell battery. I tried using the AA cell that comes with it, but it was generating sparks very slowly.

The only thing that I can think is that the spark generator is causing noise on the ground, which is shutting down the DS18b20.

Thanks,
JR

The ignitor will generate lots of broad band radio frequency interference. It should be located as as far as possible from other electronics, and the ground lead from it should come back to the Arduino, rather than being shared with the temperature sensor.

jremington:
The ignitor will generate lots of broad band radio frequency interference. It should be located as as far as possible from other electronics, and the ground lead from it should come back to the Arduino, rather than being shared with the temperature sensor.

Yes, so I can definitely see interference and incorrect readings because of that. I can live with that by not reading during sparking. However, it's not just interference, the temp sensor is switching itself off.
The ignitor is using a separate ground socket on the arduino. They are still connected within the arduino itself, are they not?

Hi.
Facing the same issue with a spark igniter causing interference on DS18B20 lines.
Did you guys get a solution. Any help would be appreciated