PIC16F18875 - mappable pins
Moderator: Benj
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
PIC16F18875 - mappable pins
Afternoon All,
I am using the above device and found that the TX pin for the EUSART is mapable independent upon the function
see this post
viewtopic.php?f=68&p=84523#p84517
is this something that can be done ?
Steve
I am using the above device and found that the TX pin for the EUSART is mapable independent upon the function
see this post
viewtopic.php?f=68&p=84523#p84517
is this something that can be done ?
Steve
Success always occurs in private and failure in full view.
- 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: PIC16F18875 - mappable pins
Hi Steve,
I believe this has already been done on the 16F18875. It seems to already be in the files here.
viewtopic.php?f=63&t=18760
I'll double check that there isn't a problem lurking.
I believe this has already been done on the 16F18875. It seems to already be in the files here.
viewtopic.php?f=63&t=18760
I'll double check that there isn't a problem lurking.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: PIC16F18875 - mappable pins
Hi Ben
I am using that update, I could be doing something wrong
Steve
I am using that update, I could be doing something wrong
Steve
Success always occurs in private and failure in full view.
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: PIC16F18875 - mappable pins
found it helps if you look properly !
one question can you turn off RXR & RX ? as I am not using these pins
Steve
one question can you turn off RXR & RX ? as I am not using these pins
Steve
- Attachments
-
- mappable pin.JPG (58.75 KiB) Viewed 11500 times
Success always occurs in private and failure in full view.
- 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: PIC16F18875 - mappable pins
Hi Steve,
Disable RX for UART1
Disable RX for UART2
After initialising the UART component you can use this line of C code to disable the RX functionality, this should give you I/O type control back over the RX pin.one question can you turn off RXR & RX ? as I am not using these pins
Disable RX for UART1
Code: Select all
cr_bit(RCSTA, CREN);
Code: Select all
cr_bit(MX_UART2_RCSTA, CREN);
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: PIC16F18875 - mappable pins
thanks ben
Steve
Steve
Success always occurs in private and failure in full view.
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: PIC16F18875 - mappable pins
I could be wrong with this one ...
When using the PPS settings
http://ww1.microchip.com/downloads/en/D ... 01802D.pdf
Reading the data sheet for the device, Table 13-1, Table 13-2 and Table 13-3 seem to summarise what you can do on each peripheral input and output to connect the peripheral to an actual device pin. Each peripheral has a table 13-2 and a 13-3 so you can select which actual device pins the peripheral connects its inputs and outputs to.
When opening the properties tab on a component you get a drop down menu it looks like it is possible to select a pin that the component does not connect to.
Is it possible to grey out pins that cannot be selected ? so you cannot select an incorrect pin
apologies if i have mis understood
Steve
When using the PPS settings
http://ww1.microchip.com/downloads/en/D ... 01802D.pdf
Reading the data sheet for the device, Table 13-1, Table 13-2 and Table 13-3 seem to summarise what you can do on each peripheral input and output to connect the peripheral to an actual device pin. Each peripheral has a table 13-2 and a 13-3 so you can select which actual device pins the peripheral connects its inputs and outputs to.
When opening the properties tab on a component you get a drop down menu it looks like it is possible to select a pin that the component does not connect to.
Is it possible to grey out pins that cannot be selected ? so you cannot select an incorrect pin
apologies if i have mis understood
Steve
Success always occurs in private and failure in full view.
- 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: PIC16F18875 - mappable pins
Hi Steve,
You're right these devices seem to have the banked remap methodology of the PIC32/STARM devices. I'll see if I can get this fixed so only the valid pins are shown. Looks like I missed this when developing these devices. Hopefully not too hard to fix.
You're right these devices seem to have the banked remap methodology of the PIC32/STARM devices. I'll see if I can get this fixed so only the valid pins are shown. Looks like I missed this when developing these devices. Hopefully not too hard to fix.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- 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: PIC16F18875 - mappable pins
Right I believe I have it all fixed now.
First you need this updated component in your "Flowcode 7/components" directory.
Next you need these updated definitions extracting to your "Flowcode 7/FCD/PIC" directory.
Let me know how you get on.
First you need this updated component in your "Flowcode 7/components" directory.
Next you need these updated definitions extracting to your "Flowcode 7/FCD/PIC" directory.
Let me know how you get on.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: PIC16F18875 - mappable pins
Cheers Ben will have a go later and get back to you
Steve
Steve
Success always occurs in private and failure in full view.
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: PIC16F18875 - mappable pins
Hi Ben,
the list looks better
I am still having a problem with coms not working on this device, Have tried a couple of different output selections Tx on C5,C6,C1
not sure if its my settings or something else - the program works on an ECIO 40 P
Could you have a look please ?
Steve
the list looks better
I am still having a problem with coms not working on this device, Have tried a couple of different output selections Tx on C5,C6,C1
not sure if its my settings or something else - the program works on an ECIO 40 P
Could you have a look please ?
Steve
- Attachments
-
- Basic Vdrive Test3- pic.fcfx
- (18.65 KiB) Downloaded 236 times
Success always occurs in private and failure in full view.
- 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: PIC16F18875 - mappable pins
Hi Steve,
I've just tried on a 16F18877 using the remap and this is working nicely for me. Is the chip otherwise running correctly apart from the comms?
I've just tried on a 16F18877 using the remap and this is working nicely for me. Is the chip otherwise running correctly apart from the comms?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: PIC16F18875 - mappable pins
Hi Ben
Thank you for looking for me. I believe so I am just testing little bits of code at the moment to get them working then I will piece it all together
I have used IOC (1 & 2) and ADCS so far they appear to work fine
Steve
Thank you for looking for me. I believe so I am just testing little bits of code at the moment to get them working then I will piece it all together
I have used IOC (1 & 2) and ADCS so far they appear to work fine
Steve
Success always occurs in private and failure in full view.
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: PIC16F18875 - mappable pins
Hi Ben
Not had chance to have a go yet might be a few days, weather has put us on alert and very busy at work
Steve
Not had chance to have a go yet might be a few days, weather has put us on alert and very busy at work
Steve
Success always occurs in private and failure in full view.