Skip to main content

uBITX Auto reset problem and solution

Already this issue is known to Arduino users. and There are also various solutions to this.
If you are an Arduino or BITX (uBITX) user, you've already experienced it and have solved the problem.
This article is for those who are new to Arduino like me.
I spent a lot of time thinking that this problem from my firmware.
In other words, I am an old firmware developer, but I first tried it (arduino).




1.Let's find out the cause of the problem.

Below are the videos that are causing the problem.

As you can see in the video, uBITX is powered on and uBITX is reset when starting communication via serial port (usb) for the first time.

The problem is not in uBITX but in Arduino.

The cause can be found in the schematic below.

(https://www.arduino.cc/en/uploads/Main/Arduino_Nano-Rev3.2-SCH.pdf)

The DTR pin of USB (uart to usb) and the RESET pin of ATMEGA are connected.
This means that if the RESET pin on the USB goes low (low is 0 volt), the Atmega is reset.


So why did it do this?
To update the firmware through the USB serial port, because the Reset pin control is required to upload firmware to the Atmega.

2.Let's fix the problem

Anyway, all we have to do is keep the Atmega's Reset pin.

The solution to this problem can easily be found on the Internet.
Searching for arduino rather than uBITX on the Internet is the easiest way to find it.

I searched for 'disable arduino auto reset' on Google.



Is there really a lot of solutions?

i suggest you choose one of Three way (Use the parts you can easily obtain)

2.1 Use resistors
  This method connects the Atmega reset pin and the 5Volt pin with a 100-120 resistor.
Even if DTR of USB becomes low, the reset pin of Atmega does not go down to Low because the resistance lower than the internal resistance of USB chip is connected to 5Volt.


Reference to https://playground.arduino.cc/Main/DisablingAutoResetOnSerialConnection



(ignore red, yellow, green wires, there is for just my work)

Connect 5Volt and RST pin with resistors as shown in the picture.
The resister must be between 100 and 120 ohms.




2.2 Use Capacitor
This is how the capacitor supplies power to the Atmega's Reset pin when the USB DTR goes low.
This is a usable method because USB's DTR is only going low for a very short time.
This affects how long the USB DTR goes low to select the capacity of the capacitor.


Reference https://tushev.org/articles/arduino/22/preventing-arduino-from-auto-reset-when-com-port-opens-closes

You can connect a 10uF capacitor to ground and reset pins.
(Connect the - to the ground of the capacitor and the + to the reset pin.)





When 5 volts is applied to the reset pin, the capacitor is charged. and The capacitor will supply power to the reset pin when the reset pin status chainging to low.


2.3 Controlling DTR when writing a PC program
skip this solution because we will use Ham radio deluxe or wsjtx for the time being.


Below is a video that solves the problem using a capacitor.



3 Problems with the above two solutions

The two problems above are that it is hard to upload the firmware when you do the above.
As mentioned at the beginning of this article, connecting the USB DTR pin to the Atmega's reset pin is for upgrading the firmware.



Since we have defended the USB chip resetting the atmega, upgrading the firmware will no longer be difficult.

Many sites offer an upgrade method through the reset switch control of Arduino. below link is one of there (How to upload code without auto reset chapter)
https://playground.arduino.cc/Main/DisablingAutoResetOnSerialConnection

However, in the case of uBITX, it would be very difficult to operate the reset switch.

I suggest using a switch. The resistor or capacitor is connected via a switch rather than directly to the reset pin. When the switch is on, the resistor or capacitor is connected to the reset pin, and when off, it is disconnected.


4 Problems with the above two solutions

I use with problem, no solution, no fixed...  lol

If I get an error when I connect for the first time without doing any modifications, I click again to connect.


73
KD8CEC Ph.D Ian lee  

Comments

Popular posts from this blog

How to upgrade uBITX Firmware

uBITX is based on Arduino Nano. So uBITX's firmware upgrade method is the same as Arduino.
There are two ways to upgrade the firmware of uBITX.

The first is to compile the source from the Arduino IDE, and the second is to upload the compiled hex file using the Firmware Upgrade Tool.

I'll show you how to upload a compiled hex file as a second method.

1.Connect the uBITX's USB cable to the computer.


2.Run Device Manager on your computer.
  The way to open the Device Manager for each OS Version differs slightly.
  In most Windows, you can easily launch the Device Manager by running.

  On your computer, press the Windows key + R.



 Type devmgmt.msc and press OK Button.




On most operating systems, there will be a serial port named Ports with CH340. If so, the next step is skipped.

If the serial port is not installed as below, you need to install the driver.



Included in uBITX is the Adonano, which uses the CH340 USB To UART part.

Download the latest CH340 driver from the Internet.

uBITX with Nextion LCD (CEC Firmware) - Installation and Introduction

uBITX with Nextion LCD (CEC Firmware) - Installation and Introduction uBITX CEC Firmware supports various LCD since Version 1.08 (16x02 Parallel, 20x04 Parallel, 16x02  I2C, 20x04 I2C, 16x02 Dual LCD with I2C).
Supports Nextion LCD (Graphic LCD) from Version 1.09, Version 1.09x is primarily aimed at Nextion LCD support. Also 1.09x will continue to be Beta version. If you want a stable version, please use 1.08 or 1.1 version to be released in the future.

uBITX Firmware CEC Version 1.08 Release

uBITX Firmware CEC Version 1.08 Release
Version 1.08 is the first major release since 1.061, I will release it after a 50-day beta test