Search found 8 matches
- 07 Feb 2010 05:27
- Forum: mikroC General
- Topic: I sTUcK.. HelP me PLs
- Replies: 2
- Views: 1935
Re: I sTUcK.. HelP me PLs
thx Sobrietytest.. thx a lots..
- 31 Jan 2010 12:28
- Forum: mikroC General
- Topic: can someone help me explain
- Replies: 1
- Views: 915
can someone help me explain
unsigned char BCD2UpperCh(unsigned char bcd)
{
return ((bcd >> 4) + '0');
}
unsigned char BCD2LowerCh(unsigned char bcd)
{
return ((bcd & 0x0F) + '0');
}
what means by "return ((bcd >> 4) + '0');" and "return ((bcd & 0x0F) + '0');"..
help
{
return ((bcd >> 4) + '0');
}
unsigned char BCD2LowerCh(unsigned char bcd)
{
return ((bcd & 0x0F) + '0');
}
what means by "return ((bcd >> 4) + '0');" and "return ((bcd & 0x0F) + '0');"..
help
- 31 Jan 2010 05:36
- Forum: mikroC PRO for PIC General
- Topic: help.. button coding
- Replies: 21
- Views: 6922
sorry, wrong typing.. i using PIC 16F877A.. here is my simulation url: http://i265.photobucket.com/albums/ii235/papela87/psm.jpg i need to assigned the 3 button as: 1st button = set time 2nd button = set hour 3th button = set minutes how do i do that?.. did i need to use adc command?.. because i pla...
- 31 Jan 2010 05:19
- Forum: mikroC General
- Topic: I sTUcK.. HelP me PLs
- Replies: 2
- Views: 1935
I sTUcK.. HelP me PLs
unsigned short read_ds1307(unsigned short address ); void write_ds1307(unsigned short address,unsigned short w_data); void myFunction(void); unsigned short sec; unsigned short minute; unsigned short hour; unsigned short day; unsigned short date; unsigned short month; unsigned short year; unsigned sh...
- 30 Jan 2010 09:47
- Forum: mikroC PRO for PIC General
- Topic: RTC..
- Replies: 0
- Views: 1429
RTC..
/* clock code for DS1307 */ #define sw1 porta.F0 #define sw2 porta.F1 #define sw3 porta.F2 #define on 0 #define off 1 unsigned short read_ds1307(unsigned short address ); void write_ds1307(unsigned short address,unsigned short w_data); unsigned short sec; unsigned short minute; unsigned short hour; ...
- 30 Jan 2010 08:51
- Forum: mikroC PRO for PIC General
- Topic: help.. button coding
- Replies: 21
- Views: 6922
Re: how to put button command for rtc clock
how to put button command for the above command?...
i want to when i press one button, the time will change..
i want to when i press one button, the time will change..
- 30 Jan 2010 08:50
- Forum: mikroC PRO for PIC General
- Topic: help.. button coding
- Replies: 21
- Views: 6922
how to put button command for rtc clock
/* clock code for DS1307 rtc for pic 16f887a */ unsigned short read_ds1307(unsigned short address ); void write_ds1307(unsigned short address,unsigned short w_data); unsigned short sec; unsigned short minute; unsigned short hour; unsigned short day; unsigned short date; unsigned short month; unsigne...
- 30 Jan 2010 07:33
- Forum: mikroC PRO for PIC General
- Topic: help.. button coding
- Replies: 21
- Views: 6922
help.. button coding
void main(){ char oldstate = 0; TRISB = 0xff; TRISD = 0; do { if (Button(&PORTB, 1, 1, 1)) oldstate = 1; if (oldstate && Button(&PORTB, 1, 1, 0)) { PORTD = ~PORTD; oldstate = 0; } } while(1); // endless loop } what mean by "if (Button(&PORTB, 1, 1, 1))"?.. i'm pic beginner.. someone teach me pls..