Code Monkey home page Code Monkey logo

stc's Introduction

STC

系统与接口总线

目录说明

demo01

用汇编程序控制八盏灯亮灭

demo02

书上代码

demo03

用C51编写程序,要求定义一8位全局字节变量cLed,该变量指定定义在data区的20H处,为该变量赋初值0xfe;按仿真图中K3按键, 下降沿触发外部中断0(C语言中的中断矢量号为0), 在中断程序中,每中断一次,用内嵌汇编使cLed占用的单元内容循环左移1位(不带进位的循环),然后用C语句把cLed送到P2口。

demo04

  1. 画出仿真图
  2. 编写程序:定时器1工作于8位自动重装模式,定时器0工作于普通16位定时计数模式; 要求定时器0每1ms中断一次,定时器1每100us中断一次;结合定时器0, 编写1ms软件延时与中断结合的延迟函数,提高定时精度;定时器1中,每中断一次, 使P1.0和P1.1反转(P1.0初值为0,P1.1为1)。主循环程序反复调用延迟函数,每500ms使P2口的8个管脚反转一次

demo05

实现串行输入输出

demo06

矩阵键盘输入LCD显示所按下的值

stc's People

Contributors

duganlx avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.