⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 main.c

📁 Embedded C 这本书的范例光碟程式
💻 C
字号:
/*------------------------------------------------------------------*-

   Main.c (v1.01)

  ------------------------------------------------------------------

   Robot example (see Chapter 9).


   COPYRIGHT
   ---------

   This code is associated with the book:

   EMBEDDED C by Michael J. Pont 
   [Pearson Education, 2002: ISBN: 0-201-79523-X].

   This code is copyright (c) 2001 by Michael J. Pont.
 
   See book for copyright details and other information.

-*------------------------------------------------------------------*/

#include "Main.h"
#include "Simple_EOS.H"

#include "PC_IO_T1.h"
#include "Stepper.H"

/* ............................................................... */
/* ............................................................... */

void main(void)
   {
   // Set baud rate to 9600: generic 8051 version
   PC_LINK_IO_Init_T1(9600);

   // Set up steppers
   STEPPER_Init();

   // Set up sEOS (5ms tick)
   sEOS_Init_Timer2(5);   

   while(1) // Super Loop
      {
	  // Enter idle mode to save power
      sEOS_Go_To_Sleep();  
      }
   }

/*------------------------------------------------------------------*-
  ---- END OF FILE -------------------------------------------------
-*------------------------------------------------------------------*/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -