Wireless Module taking input from Serial Monitor without any code

I am using a HC12 wireless module for a drone project. The Receiver on the Drone is connected to a Arduino Micro. To receive Data, it uses the boards Serial1 function.

The sender on my self made Controller is connected to an Arduino Uno.

The Rx pin of the module is connected to the rx pin of the uno.
The Tx pin of the module is connected to the tx pin of the uno.

Now here comes the weird part.

When I open the Serial Monitor and input anything, the Receiver on the Micro gets the inputted message without ANY CODE on the unos side.

How is this possible?

Post a wiring diagram.

The sender on my self made Controller is connected to an Arduino Uno.
The Rx pin of the module is connected to the rx pin of the uno.
The Tx pin of the module is connected to the tx pin of the uno.

These are the pins to which the serial monitor is connected.

As an aside, it is unlikely that the MCU has "no code", unless you have loaded a completely empty sketch.

I have loaded an completely empty sketch. Without Serial.begin() etc.

When Serial is connected, why can't I use Serial.write()? I mean I can compile it, but the receiver doesn't get anything.

It only works when I use the Serial Monitor

What don't you understand about the above comment?

Please post the requested wiring diagram, and explain exactly what you are trying to do. The following makes no sense at all. Post the code, using code tags.

When Serial is connected, why can't I use Serial.write()? I mean I can compile it, but the receiver doesn't get anything.

Edit: If you want the Uno to talk to the radio transmitting module, use one of the software serial libraries, and avoid using pins 0 and 1 (RX and TX).

The thing I am trying to achieve is to send messages to my receiver without a Computer connected to my sender.

When there's no computer connected to my Sender, there is no Serial Monitor.

Is there a code alternative to typing something into the Serial Monitor?
If there is an alternative, what is it?

Edit: I just saw your edit, ty

Software serial, see above.

Thank you very much for your time

You can use pins 0 and 1 with Serial to communicate with an external module, but not when the Arduino is connected to the PC.

Those pins are generally reserved for program loading and communicating with the serial monitor program, running on the PC.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.