0

I am a beginner to Arduino programming and started working on my first Arduino project recently to power a Peltier cooling pad. Below is the code I used and in the circuit, I connected the positive (red wire) end of the Peltier to D12 of Nano Arduino board and the negative end( black wire) to the negative end of the 6V battery. Then I powered the Arduino board by connecting Vin(Arduino) and battery(+) using a jumper wire. The GND pin of the Arduino was connected to the battery(-) using a jumper wire.

The Peltier is not working and it would be a great help if someone can help me to understand what I did wrong.

int p=12;

void setup() {
   pinMode(p,OUTPUT);
}

void loop() {
   digitalWrite(p,HIGH); 
   delay(2000);
}
Filip Franik
  • 1,272
  • 1
  • 7
  • 20
Indee
  • 23
  • 6
  • Note that you set pin 12 to HIGH, but you never change it (is that intentionally?) .. In this case you could have set it high in setup and remove the delay (meaning the loop will stay empty). – Michel Keijzers Oct 07 '19 at 13:40
  • 1
    Arduino cannot provide the amount of current that Peltier needs to heat up. Arduino cannot power devices it can only steer something that powers them. Try checking out a relay shield or read about MOSFET. – Filip Franik Oct 07 '19 at 13:46
  • Hi Michel and Flip, Thank you very much for the responses. I am a beginner to electronics and Arduino and your support is highly appreciated. I found below example online, which is powering a Peltier using an Arduino and wanted to build a simple circuit with the same principle using Nano Arduino board. If I connect a resistor to the circuit will it function? – Indee Oct 07 '19 at 14:03
  • https://www.instructables.com/id/How-to-Set-Up-a-Peltier-Module/ – Indee Oct 07 '19 at 14:07
  • Find a different tutorial, cause that one is terrible. I you read the comments for that tutorial, you see that they point to the same problem Michel and Filip told about. – Gerben Oct 07 '19 at 15:48
  • Hi Filip and Gerben, Thank you very much for the comments. I tried making the circuit, and the Peltier is not functioning. As suggested in the comments of that tutorial, I thought of using a motor driver for the Peltier and found below article, which is a bit complicated for a beginner like me. However, I made the circuit following instructions, but the Peltier and the circuit are still not working. Please tell me whether the instructions and circuit in this article are correct? – Indee Oct 07 '19 at 21:24
  • Is there a simple method to connect Peltier to Arduino using a Motor driver.? As suggested by Filip, I read about MOSFET, but couldn't figure out how to connect it to the circuit. It would be a great support if you guys could assist me. – Indee Oct 07 '19 at 21:24
  • https://www.instructables.com/id/Smartphone-Operated-Smart-Wristband-for-Personal-A/ – Indee Oct 07 '19 at 21:25
  • I'm in a helpless situation now due to lack of my knowledge in this domain. I did a lot of reading also bit still couldn't figure out the solution. I was continuously working on this circuit and determined to find a solution and your help will be a great support for me. – Indee Oct 07 '19 at 21:31
  • You could use a motor driver, but it's overkill. See Filip's answer, using a single MOSFET transistor and a pull-down resistor. That's all you need. (Note that you may have fried the pin on your Arduino by trying to push too much current through it. An Arduino pin can only put out ≈20mA, and your peltier junction probably draws a couple of amps (100X more than the max). – Duncan C Oct 09 '19 at 00:49
  • Note that you COULD use a motor driver to drive the Peltier junction in both cooling and heating mode (motor drivers have "H Bridge" circuits that let you push current in either direction. If you power a Peltier junction the opposite way, it heats instead of cools.) – Duncan C Oct 09 '19 at 00:51

1 Answers1

0

I prepared a little circuit that should help you safely connect the Peltier module to Arduino. It uses a single n-channel MOSFET and 1K resistor.

I couldn't find any Peltier in Tinkercad so instead I used a simple light bulb. (In previous version of this answer I used a DC motor, but it was not a good replacement for Peltier module)

When Arduino Pin12 is HIGH light is bright (high current flows through it just like it should through the Peltier) when Pin12 is LOW light bulb goes dark (no current is flowing)

circuit

Filip Franik
  • 1,272
  • 1
  • 7
  • 20
  • One note to other readers: Don't wire a motor that way. It will fry the transistor. If you're going to power a motor you need a flyback diode to protect the transistor from back EMF from the motor's inductive coils. – Duncan C Oct 09 '19 at 00:49
  • Hi Filip, Thank you very much for guiding me and the circuit diagram is very helpful. I will make the circuit and will check the functionality. Really appreciate your help. :) – Indee Oct 09 '19 at 01:23
  • Hi Duncan, Thank you very much for guiding me. Regarding your last comment on ' motor', does that apply to Peltier circuit as well as I am planning on making the circuit following the diagram proposed by Filip. Well noted your suggestion to use a motor drive to make a circuit to get both heating and cooling effect from Peltier. I will try working on that circuit after finalizing the circuit with MOSFET( proposed by Filip). – Indee Oct 09 '19 at 01:23
  • @DuncanC I changed DC motor to a light bulb. No extra circuitry is required for light bulb and Peltier module. – Filip Franik Oct 09 '19 at 10:46
  • Filip, good idea. Indee, A Peltier junction and a light bulb are both simple resistive loads, and don't require flyback diodes. That's only needed for inductive loads like motors and relay coils. – Duncan C Oct 09 '19 at 13:05
  • Indee, you could also rig 2 MOSFET transistors to run your peltier junction as either a heater or a cooler. (You'd make one MOSET feed current in one direction when it was energized, and wire the other one to feed current in the opposite direction. You'd either have to make certain that you'd never turn on both transistors at the same time, or add a high current diode to avoid a short circuit if both transistors are turned on at the same time (which would likely destroy the transistors) – Duncan C Oct 09 '19 at 13:10
  • Hi Filip and Duncan, I made the circuit and it worked well with the Peltier. But I had to connect the system into 1.5x4 V battery. Thank you very much for your guidance and really appreciate your support. Now I will try the circuit with 2 MOSFET transistors to get both heating and cooling. – Indee Oct 14 '19 at 00:23