i think what you are having trouble with is that the function you are calling is not defined at the time you call it.
at the top of you file copy the function prototypes but end them with a ; not the usual braces {}
Search found 348 matches
- 04 Aug 2005 10:11
- Forum: mikroC General
- Topic: Functions - newbie
- Replies: 2
- Views: 2494
- 28 Jul 2005 21:09
- Forum: mikroC General
- Topic: BitTest and While or IF statement
- Replies: 4
- Views: 3441
the
provide the simple goto loop but the compiler provides the loop label names which is a much better situation else you find your code jumping to a point in another function because you forgot you used that name already.
Code: Select all
do{
}while(1)
- 28 Jul 2005 17:29
- Forum: mikroC General
- Topic: BitTest and While or IF statement
- Replies: 4
- Views: 3441
I tend to write something like this if i am looking for performance. good idea get compiler to generate the labels.
Code: Select all
//do something
do
{
//do something else
asm BTFSC INTCON,T0IF
}while(1);
//continue program
- 29 Jun 2005 16:32
- Forum: mikroBasic General
- Topic: How to get money value"$x.xx"?
- Replies: 8
- Views: 4837
- 27 Jun 2005 20:05
- Forum: mikroC General
- Topic: USART with PIC16F874A
- Replies: 10
- Views: 7027
- 24 Jun 2005 17:33
- Forum: mikroC General
- Topic: Compact Flash help
- Replies: 3
- Views: 3404
- 24 Jun 2005 17:29
- Forum: mikroC General
- Topic: USART with PIC16F874A
- Replies: 10
- Views: 7027
I tested the first code with a P16F877A as that is the closest thing i have, it worked fine. I see your point about the TRMT Flag but if the TSR reg is empty it is always because the TXREG is also empty else it would be filled. I think all this means is that you lose out on the double buffering so y...
- 24 Jun 2005 11:46
- Forum: mikroBasic General
- Topic: How to get money value"$x.xx"?
- Replies: 8
- Views: 4837
- 24 Jun 2005 11:38
- Forum: mikroC General
- Topic: USART with PIC16F874A
- Replies: 10
- Views: 7027
So long as you initialize the library properly you should be fine. a few notes about your code. char msg[11] = "Hello World"; is wrong as you need a byte for the null terminator. it is much 'safer' to leave out the array length. char msg[] = "Hello World"; or char * msg = "Hello World"; also rather ...
- 24 Jun 2005 10:51
- Forum: mikroC General
- Topic: USART with PIC16F874A
- Replies: 10
- Views: 7027
- 24 Jun 2005 10:34
- Forum: mikroC General
- Topic: How to combine hi and lo
- Replies: 11
- Views: 7624
I had a little play with these functions and looked at the help files in mikroPascal. I think the functions are very good as they are proper built in functions that insert the correct assembler name not a function call. i feel that the way they are documented in the help file is a little misleading ...
- 23 Jun 2005 09:22
- Forum: mikroC General
- Topic: How to combine hi and lo
- Replies: 11
- Views: 7624
- 22 Jun 2005 15:27
- Forum: mikroC General
- Topic: How to combine hi and lo
- Replies: 11
- Views: 7624
Code: Select all
int range; // declare you int
unsigned short * ptr = ⦥ // obtain a reference to it
* ptr = 234; // load lower byte first
ptr++; // increment the pointer
* ptr = 1; // load the higher byte
- 22 Jun 2005 10:56
- Forum: mikroC General
- Topic: How to combine hi and lo
- Replies: 11
- Views: 7624
would be nice to get access to each byte in ints and longs in the same sort of way we can access individual bits. have you considered using a pointer to byte assigning it the value of range then loading in highbyte adding one (or subtracting one i can't remember which) to the pointer then assigning ...
- 10 Jun 2005 16:56
- Forum: mikroC General
- Topic: Optrex 4x20 LCD witch HD44780 controller
- Replies: 11
- Views: 7969