20
votes

Is there a way of preventing the reset when starting the serial monitor in the Arduino IDE?

3

3 Answers

17
votes

For the Uno, connect a 10μF capacitor between the reset and ground pins.

For other Arduinos, a 120 Ohm resistor (or equivalent resistance made up of multiple resistors, since 120 Ohms is quite rare on its own) between the 5V and Reset pins should do the trick.

4
votes

The arduino Playground site has a quite detailed breakdown of different methods of preventing your arduino from restarting, with a bit of background and explanation.

http://playground.arduino.cc/Main/DisablingAutoResetOnSerialConnection

2
votes

If you would connect a Windows PC, This rudimentary Powershell script works (tested on Arduino Mega):

$port = new-Object System.IO.Ports.SerialPort COM8,9600,None,8,one
$port.DtrEnable = $false
$port.open()
while ($true) {
	$nChar = $port.BytesToRead
	if ($nChar -gt 0) {Write-Host -NoNewline $port.ReadExisting()}
}