Search found 282 matches

by HyperUniverse
14 Sep 2022 13:56
Forum: mikroC PRO for PIC General
Topic: need slower I2C spped
Replies: 3
Views: 671

Re: need slower I2C spped

. . . there should be no commercial device that cannot handle at least 100 kHz. thanks hexreader yes I was running it at 64MHz I have picked a 75kHz speed and is compiling OK, I'll reprogram the board to see if that improves my problem. I've got 1 meter cable between an airflow sensor and the pic M...
by HyperUniverse
14 Sep 2022 11:00
Forum: mikroC PRO for PIC General
Topic: need slower I2C spped
Replies: 3
Views: 671

need slower I2C spped

Hi, How can I select a slower speed for my I2C? say I'd like just 50KHz, not 100kHZ as the default slowest. And this is especially for a remappable I2C on PIC18F27K40. I2C1_Remappable_Init(100000); // Initialize I2C communication If I simply put the desired frequency I2C1_Remappable_Init(50000); // ...
by HyperUniverse
05 Mar 2022 23:47
Forum: mikroC PRO for PIC General
Topic: PIC18F13K22 UART interrupt
Replies: 5
Views: 1049

Re: PIC18F13K22 UART interrupt

paulfjujo, you got the wrong idea about what I am doing. I have already shown you the Interrupt routine that I am using - the first one in the first post. The one that it bothers you, and you cannot understand it, and you keep posting it thinking that this is the one that I am using in my program, a...
by HyperUniverse
04 Mar 2022 23:21
Forum: mikroC PRO for PIC General
Topic: PIC18F13K22 UART interrupt
Replies: 5
Views: 1049

Re: PIC18F13K22 UART interrupt

the solution is:

Code: Select all

ANSELH.ANS11 = 0 ;
case closed!
by HyperUniverse
04 Mar 2022 22:58
Forum: mikroC PRO for PIC General
Topic: PIC18F13K22 UART interrupt
Replies: 5
Views: 1049

Re: PIC18F13K22 UART interrupt

thanks for answering paulfjujo unfortunately absolutely nothing from your post indicate why my interrupt doesn't trigger. the fact that I did not show you my variables or declarations have got nothing to do with the interrupt not triggering. So, can anybody tell me why the USART Interrupt doesn't wo...
by HyperUniverse
04 Mar 2022 16:55
Forum: mikroC PRO for PIC General
Topic: PIC18F13K22 UART interrupt
Replies: 5
Views: 1049

PIC18F13K22 UART interrupt

Hi, Why isn't my interrupt for UART working? PIC18F13K22 PIR1.RCIF = 0 ; // EUSART Receive Interrupt Flag bit // 1 = The EUSART receive buffer, RCREG, is full (cleared when RCREG is read) // 0 = The EUSART receive buffer is empty PIR1.TXIF = 1 ; // EUSART Transmit Interrupt Flag bit // 1 = The EUSAR...
by HyperUniverse
01 Mar 2022 10:55
Forum: mikroC PRO for PIC General
Topic: OOK RX click not working
Replies: 0
Views: 373

OOK RX click not working

Hi, The sample code for this addon board is not working. I can't receive anything from the OOK TX click board, which I can see on the spectrum analyzer that is sending the right data. More so, when this function is active if(!(ookrx_receiveData(0xCE35, &receivedPacket, 1))) { is eating up from proce...
by HyperUniverse
01 Mar 2022 10:33
Forum: mikroC PRO for PIC General
Topic: I2C unblocking
Replies: 2
Views: 636

Re: I2C unblocking

Yeah, I've got it, thanks
by HyperUniverse
16 Feb 2022 13:20
Forum: mikroC PRO for PIC General
Topic: PIC18F27K40
Replies: 11
Views: 1755

Re: PIC18F27K40

for anybody else interested, the above SPI2 remap works perfectly, But the I2C1 needs to be this way to work: /******* I2C1 **********************************/ RC5PPS = 0x10 ; // MSSP1 (SDO/SDA) Out I2C1 Data Output RC5 SSP1DATPPS = 0b10101 ; // MSSP1 Data In I2C1 Data Input RC5 SSP1CLKPPS = 0b10100...
by HyperUniverse
15 Feb 2022 10:58
Forum: mikroC PRO for PIC General
Topic: PIC18F27K40
Replies: 11
Views: 1755

Re: PIC18F27K40

well, forget about that setting the OSC to: HFINTOSC with HFFRQ = 64MHz and CDIV = 1:1 in Edit Project and then code this in: OSCCON1.NOSC2 = 1 ; OSCCON1.NOSC1 = 1 ; // Int OSC 64MHz OSCCON1.NOSC0 = 0 ; OSCCON1.NDIV3 = 0 ; OSCCON1.NDIV2 = 0 ; // Div / 4 OSCCON1.NDIV1 = 1 ; OSCCON1.NDIV0 = 0 ; gives ...
by HyperUniverse
15 Feb 2022 09:49
Forum: mikroC PRO for PIC General
Topic: PIC18F27K40
Replies: 11
Views: 1755

Re: PIC18F27K40

OK janni, How do I set the clock to whatever I want then? And I want 16MHz, Internal OSC. In Edit Project I can only see: HFINTOSC with HFFRQ = 64MHz and CDIV = 1:1 or HFINTOSC with HFFRQ = 4MHz and CDIV = 4:1 These to me look like I can only set the OSC to either 64MHz or 1MHz, and nothing else. Ca...
by HyperUniverse
14 Feb 2022 16:47
Forum: mikroC PRO for PIC General
Topic: PIC18F27K40
Replies: 11
Views: 1755

Re: PIC18F27K40

How do I set the bits for

Code: Select all

CONFIG1; CONFIG2; CONFIG3; CONFIG4; CONFIG5; CONFIG6
?
it seems the compiler doesn't recognize these at all.

Thanks.
by HyperUniverse
12 Feb 2022 21:15
Forum: mikroC PRO for PIC General
Topic: I2C unblocking
Replies: 2
Views: 636

I2C unblocking

how do I use I2C without blocking the program in case an i2c device is missing or not repsonding?
by HyperUniverse
12 Feb 2022 21:13
Forum: mikroC PRO for PIC General
Topic: PIC18F27K40
Replies: 11
Views: 1755

Re: PIC18F27K40

thanks janni
by HyperUniverse
11 Feb 2022 12:57
Forum: mikroC PRO for PIC General
Topic: PIC18F27K40
Replies: 11
Views: 1755

Re: PIC18F27K40

I think I've got the remapping sorted out: /******************** PIC18F27K40 PPS Mapping *********************************/ PPSLOCK = 0 ; // 0 PPS is not locked. PPS selections can be changed. /******* UART1 *********************************/ RX1PPS = 0b10111; // Default assignment for RX1 is RC7, s...

Go to advanced search