彭光泽 胡正江 卢涵宇


摘要:随着计算机和通信技术的发展,电子琴等娱乐乐器走入千家万户。本系统采用STC89C51单片机,设计矩阵式键盘模块、LED显示管模块、扬声器模块、主程序部分、显示程序部分、按键检测部分等模块。 经系统仿真,实现了16个独立按键分别代表16个不同的音符,有高有低等功能。本设计电路耦合性好,易操作,成本低,实用性强,便于携带。
关键词: 单片机;矩阵式键盘;LED显示;电子琴
中图分类号: TP208 文献标识码:A
文章编号:1009-3044(2019)17-0235-02
开放科学(资源服务)标识码(OSID):
Abstract: With the development of computer and communication technology, electronic piano and other entertainment instruments have entered thousands of households. This system uses STC89C51 single chip computer to design matrix keyboard module, LED display tube module, loudspeaker module, main program module, display program module, key detection module and so on. Through system simulation, 16 independent keys representing 16 different notes are realized, which have the functions of high, low and so on. The designed circuit has good coupling, easy operation, low cost, strong practicability and portability.
Key words: MCU; Matrix Keyboard; LED Display; Electronic Piano
隨着我国经济快速发展,人民的生活质量逐步提高,娱乐产品走入千家万户。电子琴等电子产品的诞生,丰富了业余生活,让人民的生活多姿多彩。目前热销的有两种电:一种是带有脚键盘的立式电子琴;另一种是教育用的便携式电子琴。这两种电子琴都固有音色,还能模仿其他乐器及自然界的一些声音,还都带有自动节奏和伴奏功能。
本设计以AT89C51微控制器作为主控核心,带有矩阵式键盘模块、LED显示管模块、扬声器模块等硬件电路。硬件设计的独立键盘电路有4*4=16个独立按键,当用户按下按键,在数码管上会相应对应一个字符,16个独立按键分别代表16个不同的音符,有高有低。软件部分主要设计了主程序部分、显示程序部分、按键检测部分。本设计电路耦合性好,易操作,成本低,实用性强,便于携带。
1 系统整体方案设计
系统的整体设计由矩阵式键盘模块、LED显示管模块、扬声器模块、主程序部分、显示程序部分、按键检测部分等部分组成。……