Search found 7 matches
- Thu Sep 27, 2007 12:13 am
- Forum: Computer Programming
- Topic: Need help on using AVR CodeVision C compiler
- Replies: 14
- Views: 15684
According to their info, the time needed to handle parameter passing in a function call is longer than the delay provided by the function delay_us( ). So it only accept constant expression for that function to work correctly. Although they didn't help to solve my programming need, at least I know th...
- Wed Sep 26, 2007 2:54 am
- Forum: Computer Programming
- Topic: Need help on using AVR CodeVision C compiler
- Replies: 14
- Views: 15684
- Mon Sep 24, 2007 12:26 am
- Forum: Computer Programming
- Topic: Need help on using AVR CodeVision C compiler
- Replies: 14
- Views: 15684
- Mon Sep 24, 2007 12:23 am
- Forum: Computer Programming
- Topic: Need help on using AVR CodeVision C compiler
- Replies: 14
- Views: 15684
- Sun Sep 23, 2007 12:28 am
- Forum: Computer Programming
- Topic: Need help on using AVR CodeVision C compiler
- Replies: 14
- Views: 15684
the content of delay.h is as follows: // CodeVisionAVR C Compiler // (C) 1998-2000 Pavel Haiduc, HP InfoTech S.R.L. #ifndef _DELAY_INCLUDED_ #define _DELAY_INCLUDED_ #pragma used+ void delay_us(unsigned int n); void delay_ms(unsigned int n); #pragma used- #endif I wonder whether this is compiler bug...
- Fri Sep 21, 2007 3:28 am
- Forum: Computer Programming
- Topic: Need help on using AVR CodeVision C compiler
- Replies: 14
- Views: 15684
the function was declared as void delay_us(unsigned int n) in the header file delay.h I need to pass a variable to this function to control the delay according to my actual need. But when I pass a variable to this function, it produce an error saying that it only accept constant expression! Just can...
- Thu Sep 20, 2007 1:37 am
- Forum: Computer Programming
- Topic: Need help on using AVR CodeVision C compiler
- Replies: 14
- Views: 15684
Need help on using AVR CodeVision C compiler
Dear all,
Is it possible to pass a variable parameter to the function delay_us( )
which accept only constant expression?
If it's impossible, I think this function has no great use.
Thanks a lot
Eddy Lau
Is it possible to pass a variable parameter to the function delay_us( )
which accept only constant expression?
If it's impossible, I think this function has no great use.
Thanks a lot
Eddy Lau