PIC12F1840 alternate Rx pin not working

A forums to allow bugs and problems with Flowcode v7 to be reported and resolved.

Moderator: Benj

Post Reply
Zane
Flowcode v5 User
Posts: 199
Joined: Thu Sep 10, 2009 10:57 pm
Location: New Zealand
Has thanked: 93 times
Been thanked: 76 times
Contact:

PIC12F1840 alternate Rx pin not working

Post by Zane »

Hi,

I have been using a PIC12F1840. I have the cal UART component in use and have found that when using default Rx pin on RA1 the RX interrupt works as expected allowing a comms interrupt routine to be called however when the alternate Rx pin on RA5 is used the Rx interrupt does not seem to work.

The RS232 UART component is still unable to select the alternate pins. The option is there to change them but when selected they do not update.

Thanks

Zane

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: PIC12F1840 alternate Rx pin not working

Post by Benj »

Hi Zane,

Hopefully this should solve the pin problems for you? Simply copy to your "Flowcode 7/components" directory and restart Flowcode.
RS232.fcpx
(15.51 KiB) Downloaded 265 times
Not sure why the interrupt wouldn't be working. I'll investigate this for you.

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: PIC12F1840 alternate Rx pin not working

Post by Benj »

Think I've cracked it now.

First you need the latest CAL UART copying to the "Flowcode 7/CAL/PIC" folder.
PIC_CAL_UART.c
(32.25 KiB) Downloaded 248 times
Next you need the latest CAL UART component copying to the "Flowcode 7/Components" folder. You also need the latest RS232 component from the previous post.
cal_uart.fcpx
(11.32 KiB) Downloaded 233 times
Let us know how you get on.

Zane
Flowcode v5 User
Posts: 199
Joined: Thu Sep 10, 2009 10:57 pm
Location: New Zealand
Has thanked: 93 times
Been thanked: 76 times
Contact:

Re: PIC12F1840 alternate Rx pin not working

Post by Zane »

Hi Benj

Thanks for creating the fixes for me. I will be able to try them out tomorrow so i will let you know how i get on then.

Thanks

Zane

Zane
Flowcode v5 User
Posts: 199
Joined: Thu Sep 10, 2009 10:57 pm
Location: New Zealand
Has thanked: 93 times
Been thanked: 76 times
Contact:

Re: PIC12F1840 alternate Rx pin not working

Post by Zane »

Hi Benj,

You have worked your magic again. I have tried using both the cal UART and also the RS232 components to send and receive data to the PIC. I have tried using both the default and the alternate pin selections and they all work as required.

Thanks for your help :D .

Zane

Post Reply