I apologize for the bad English. I would be sincerely grateful if anyone could help make the text beautiful...

Introduction

What is interesting about PowerLine? It's no additional wiring is required.

Most of the devices in the modern world are powered by external sources by
wires. Radio modules in their mass are no exception. Power can be either a
constant current of 12-24V or alternating current of 110V - 220V. For transmit of
information it does not matter if there is voltage in the line or not, you need
only two wires.

The idea is to make a simple and inexpensive modem based on the ARM controller, in particular STM32F103. This controller can simultaneously be a modem and perform control functions.

Block diagram of the modem:

A modem is a device that modulates the UART signal with a radio frequency. The
signal modulation method is CW, the frequency is 1.84 MHz (160 m). The UART
speed is 2400-19200 bps.

Electric scheme:

The circuit is designed with minimum amount of parts surrounding the

microcontroller and maximum "pleasure", i.e., the load on the microcontroller
is minimized. The hardware capabilities of the microcontroller are used as much
as possible.

The microcontroller can perform tasks with sensors, load control (relays,
triacs), etc.

Description of the work of modem

Capacitors C3, C4 and transformer coil L3 perform the following functions:
  • galvanic isolation
  • Band-pass filter

Because Our modem is most likely to work in an environment with other modems,
eg modems G3 Prime, HomePlug, ... then the task is to filter out frequencies
not included in the frequency range we used when receiving the signal.

The filter is designed for a cut-off frequency of 1 MHz (low
frequencies). Those. All that is lower, including a 50-60 Hz network is not
visible in principle. The resonance frequency of the oscillatory circuit is
approximately 1.5-2 MHz. The ferrite is selected for which the operating
frequency is approximately 1.8 MHz. Our required frequency is 1.84 MHz. At
the resonance frequency, the amplitude amplification (simulation) is
approximately 100-120 times. But taking into account the physical limitations
of ferrite, the real resonance was obtained at the frequencies 1.8 - 1.9 MHz,

All what lower and higher is cut. Our required frequency is 1.84 MHz. At
the resonance frequency, the amplitude amplification (simulation) is
approximately 100-120 times.
But taking into account the physical limitations
of ferrite, the real resonance was obtained at the frequencies 1.8 - 1.9 MHz,
and is approximately 15-30 times in amplitude. It is what we need.

For receiving / transmitting, UART3 (PB10; PB11) is used.

Transmission mode

As a meander of 1.84 MHz, PWM (PA3) is used. The percent of infill is 0 and
50%. The signal PB10 (Tx) is the control. The control signal is routed to PA4,
which generates an interrupt when the state changes. The state of PA4 has
changed to a low - set up 50% PWM filling. The state has changed to a high -
set up 0% infill. The signal PWM is amplified by a transistor VT2, which is
loaded with an oscillating circuit L2-C5. The circuit is designed for a
resonance frequency of 1.84 MHz. The output of the transformer coil L2 will be
a "pure sine".

To block the reception signal during transmission (turning off the "echo"), it
is enough to set 3.3V on the output of DAC (PB1), at that the receiving signal
level will never exceed 2V and the comparator will never turn on. The signal
will not be accepted.

Modulated signal UART (output), coil L2

Receive Mode

The L1 coil of the transformer has no "tricky" functions. Works as a
transformer coil in order to separate the receiving and transmitting lines.
Next - a two-stage amplifier. On the VT2 amplitude amplifier (k-t gain
approximately 250 times). Linearity does not interest us, the task is to
maximize amplification. On the VT3, the current amplifier, the detector and the
UART signal inverter, plus the amplitude-limiting filter (cuts short bursts -
where the noise frequency coincided with our operating frequency...

Read more »