AM / FM signal workspaceLocal audio

Ready — sound is off

Sine carrier and sine modulator. Output level is digital gain; begin with low device volume. AM reserves half the amplitude for modulation headroom.

AM · 1000 Hz carrier · 10 Hz modulator · 50% depth

Modulator10 Hz sineCarrier1000 Hz sineModulated outputAmplitude varies

Press Play to view actual output samples. The display freezes when stopped. Slow modulation can take several seconds to complete a cycle.

Playback uses your browser sample rate. Export uses that rate once known, otherwise 48000 Hz.

Export is a local mono PCM WAV with short fades. Open the file in the Audio Spectrum Analyzer to inspect carrier and sidebands.

Browser audio signal toolkit

Audio Modulation Generator

This modulation generator creates audio-frequency amplitude modulation (AM) and frequency modulation (FM). Set a sine carrier and a sine modulator, listen at a conservative level, and inspect the generated waveform. Export a short WAV for a repeatable example.

What Is a Modulation Generator?

A modulation generator changes one property of a carrier using another signal called the modulator. The carrier is the repeating waveform you hear. The modulator determines how its amplitude or instantaneous frequency varies over time. Slow changes can sound like pulsing or wavering pitch; faster changes can create a new timbre with additional frequency components called sidebands.

This tool synthesizes digital audio in your browser using two sine oscillators. AM connects the modulator to an amplitude control. FM connects it to the carrier frequency control, so modulation runs at audio rate rather than through occasional JavaScript updates. The selected mode changes the signal path and the available controls. Playback begins only after you press Play.

Three simple steps

How to Get Started

Try the defaults first. Change one parameter at a time so that the sound and waveform remain easy to relate to each other.

01

Select AM or FM

AM starts with a 1000 Hz carrier, a 10 Hz modulator, and 50% depth. FM starts with a 440 Hz carrier, a 5 Hz modulator, and ±50 Hz deviation. Switching modes stops playback and loads that mode’s defaults.

02

Play Quietly and Adjust

Keep the browser output and device volume low. Use each slider or its numeric field. In AM, compare zero depth with 50% and 100%. In FM, compare zero deviation with a small nonzero value.

03

Inspect or Save

Read the signal relationship above the waveform. Stop freezes the display. Export creates five seconds of the selected settings, with short fades, so you can inspect the result in the spectrum tool.

Amplitude Modulation Explained

AM varies carrier amplitude while leaving carrier frequency fixed. The conceptual equation is output(t) = A × [1 + m × sin(2πfmt)] × sin(2πfct), where fc is carrier frequency, fm is modulation frequency, and m is depth from zero to one. This modulation generator uses A equal to half the selected output gain, reserving enough headroom for the envelope maximum at full depth.

At zero depth, the output is an unmodulated sine. At 50%, the envelope moves between half and one-and-a-half times A. At 100%, it reaches zero and twice A without reversing polarity. Depth above 100% would create overmodulation, where the envelope can become negative; this first version deliberately caps the control at 100%.

Frequency Modulation Explained

FM varies instantaneous frequency while keeping the nominal amplitude constant. Here, instantaneous frequency equals fc + Δf × sin(2πfmt). The deviation Δf is the distance in hertz from the carrier to either extreme. A 440 Hz carrier with ±50 Hz deviation moves between approximately 390 and 490 Hz. A 5 Hz modulator repeats that excursion five times each second.

The oscillator accumulates phase continuously as frequency changes. Simply substituting a changing frequency into an unrelated sine calculation would give the wrong phase trajectory. The modulation generator uses Web Audio frequency-parameter modulation for that integration. Setting deviation to zero produces a stable sine carrier regardless of the modulator rate.

Carrier Frequency vs Modulation Frequency

Carrier frequency sets the central reference; modulation frequency sets the speed of change. Raising a 1000 Hz carrier to 2000 Hz moves the reference higher. Raising a 5 Hz modulation rate to 10 Hz makes the modulation repeat twice as fast. Neither action is the same as increasing modulation depth or deviation. The signal diagram shows these separate roles using the current settings.

Modulation Depth in AM

Depth is a relative amplitude ratio, expressed as a percentage. It does not specify how loud your speakers will be. With the default 10% output level and 50% depth, the AM envelope ranges from 0.025 to 0.075 digital amplitude. At 100% depth it spans zero to 0.10. Keeping this fixed headroom makes depth comparisons predictable without clipping the generated samples.

For a sine carrier whose frequency is above the modulation rate, ordinary AM creates sidebands at carrier minus rate and carrier plus rate. A 1000 Hz carrier with a 100 Hz modulator therefore has components at 900, 1000, and 1100 Hz. Their relative magnitudes depend on depth. With lower modulation rates, the sidebands may be too close for a small FFT to resolve.

Frequency Deviation in FM

Deviation is an absolute frequency distance, not a percentage. The ratio Δf/fm is the FM modulation index. Increasing that ratio generally makes more sidebands significant, though individual sidebands can rise and fall. A wider instantaneous range is not the same as a spectrum with only two outer peaks. FM can contain many sidebands spaced by the modulation frequency.

This modulation generator rejects a range that reaches zero or Nyquist, half the sample rate. It also checks an approximate upper significant band using carrier + deviation + rate when deviation is nonzero. That practical guard reduces risky combinations but is not a mathematical guarantee of zero aliasing: FM has infinitely many theoretical sidebands, with most becoming very small.

Slow Modulation vs Audio-Rate Modulation

Rates from 0.1 to 1000 Hz cover slow low-frequency-oscillator behavior and audible modulation. A 0.1 Hz cycle takes ten seconds, so the short waveform window cannot show its entire envelope at once. Around a few hertz, AM resembles tremolo and FM resembles vibrato. At higher rates the ear increasingly hears combined spectral components as timbre rather than individual pulses.

Listening to AM and FM Effects

Begin with a 1000 Hz AM carrier and reduce depth to zero before increasing it slowly. Then switch to FM and compare ±10 Hz with ±50 Hz around 440 Hz. Keep the listening level unchanged during each comparison. The canvas displays actual output samples, with each screen column retaining local sample extremes. Its fixed amplitude scale makes AM envelope changes visible without auto-normalizing them away.

For a spectral comparison, export the modulation generator output and load it into the analyzer. A 100 Hz modulator gives more widely separated sidebands than a 5 Hz modulator. The first and last 15 milliseconds are faded to reduce clicks; analyze the middle of the file when you want a sustained example.

Use the Audio Spectrum Analyzer to view the exported file and choose suitable FFT resolution.

Common Audio and Educational Uses

The modulation generator can illustrate synthesizer building blocks, compare tremolo and vibrato concepts, and supply bounded examples for signal-processing lessons. In an audio or electronics demonstration, document the carrier, modulation rate, depth or deviation, output gain, and sample rate. These settings make the digital example reproducible; they do not calibrate the connected amplifier or loudspeaker.

Audio Modulation vs Radio Transmission

The letters AM and FM describe modulation methods, which are used in many fields. This page is an audio-frequency demonstration and generator. It creates samples for your browser audio output or a WAV file. It does not transmit radio-frequency signals, broadcast a radio station, control wireless spectrum, or turn your device into regulated communications equipment.

Digital Signal and Speaker Limitations

A valid digital frequency may still be poorly reproduced by your playback system. Device resampling, speakers, headphones, and operating-system effects can alter what you hear. High modulation rates or wide FM deviation can create components near the digital bandwidth limit. The modulation generator uses sine carriers to keep examples simple; it offers no square-wave or sawtooth mode with additional carrier harmonics.

Safe Listening and Local WAV Export

Start quietly and keep demonstrations brief. Digital output percentage cannot determine sound pressure at your ears. Do not raise the volume sharply to chase bass or treble that a device cannot reproduce. Stop if a signal is uncomfortable. Reset stops playback and restores the selected mode’s defaults; hiding or leaving the page also stops sound.

Export renders a five-second mono 16-bit PCM WAV locally through the same synthesis graph used for playback. The selected settings remain constant in that file, apart from boundary fades. Export uses the browser sample rate once known, otherwise 48000 Hz. A short export contains only part of an extremely slow modulation cycle. No account, microphone, upload, or server conversion is involved.

Clear answers

Frequently Asked Questions

Can this modulation generator broadcast AM or FM radio?

No. It generates audio-band digital samples only. Browser audio playback and WAV export are not RF transmission or radio broadcasting.

Why is AM quieter than FM at the same output percentage?

AM reserves half the nominal amplitude as headroom for its changing envelope. At zero depth, AM uses half the FM carrier amplitude at the same level. This intentional scaling prevents clipping at full AM depth.

Why does the modulation generator reject my FM settings?

The instantaneous frequency must remain above zero and below Nyquist. The approximate upper significant modulation band must also fit below Nyquist. Reduce deviation, carrier frequency, or modulation rate, then press Play again.

Does exporting capture my live control changes?

No. Export takes the selected settings when you press the button and renders a constant-parameter example. Changing settings during rendering discards that pending export; it does not record the playback session.