2140 views|0 replies

3836

Posts

19

Resources
The OP
 

C language (vd6.0) sleep function usage and delay usage [Copy link]

1. Function name: delay
  Function: Pause the execution of the program for a period of time (milliseconds)
  Usage: void delay(unsigned milliseconds);
  Program example:
  /* Emits a 440-Hz tone for 500 milliseconds */
  #include <dos.h>
  int main(void)
  {
  sound(440);
  delay(500);
  nosound();
  return 0;
  }

2.#include<windows.h>
#include <stdio.h>

void main()
{
  printf("begin");
  Sleep(1000);
  printf("end");
  
}
This post is from DSP and ARM Processors
 

Guess Your Favourite
Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list