苦苦寻找 终于找了重要的东西 分享一下

import matplotlib.pyplot as plt
import numpy as np

plt.close('all')

Fs = 10 # 每秒样本数量
fc = 30 # 载波频率 30 Hz, 30 cycles/sec
T = 1 # 演示模拟 1秒
t = np.arange(0, T, 1/Fs)
Td = 0.1 # Bit 持续时间

data = np.array([1,1,1,1,0,0,0,0,1,0])

# FSK waveform generation
f = fc + fc*data/2
data = np.sin(2*np.pi*f*t)


figure, axis = plt.subplots(2)
axis[1].plot(t, data, 'r')
axis[1].set_title("FSK")
plt.tight_layout()
plt.show()

你可能感兴趣的:(FSK,python,学习)