PIC18F47Q84 USART over 3

Discuss PIC and electronic related things

Moderators: David Barker, Jerry Messina

Post Reply
Mikeclx
Posts: 20
Joined: Mon Feb 09, 2009 5:36 am
Location: New Zealand

PIC18F47Q84 USART over 3

Post by Mikeclx » Sat May 06, 2023 3:41 am

I have got a board im putting together and need a boat load of USARTS,
I selected the PIC18F47Q84 as it has 5 :)
Im am starting to write my program and get an error due to the following line in 18f47q84.bas
#const _usart = $03 // 3 USART(s) available

the error says "18f47q84 does not support USART4" (and 5)

Everything i have read says it has 5

apart from changing this #const _usart to say 5 it looks like there would be other changes i would need to make to USART4 and 5 .bas files.

Is there a reason before i go reinventing the wheel (if indeed i can work out how to do that) on why you limited SF to 3 on this device?

attached is the part in the datasheet saying it has 5

Thanks,

Mike
Attachments
5USART datasheet.jpg
5USART datasheet.jpg (42.65 KiB) Viewed 1492 times

Jerry Messina
Swordfish Developer
Posts: 1473
Joined: Fri Jan 30, 2009 6:27 pm
Location: US

Re: PIC18F47Q84 USART over 3

Post by Jerry Messina » Sat May 06, 2023 12:05 pm

Is there a reason before i go reinventing the wheel (if indeed i can work out how to do that) on why you limited SF to 3 on this device?
Simply a mistake on my part... looks like I didn't catch the full featured/limited featured part of things on the Q83 and Q84 parts.
Just fyi - the Q43 has support for 5 too.

Here are update Q83/Q84 device files (unzip them into the 'Includes' folder) and usart4/usart5 files (unzip into the 'Library' folder).
That should do it, but I didn't test them other than try to compile, so if any issues pop up yell.

Thanks for catching that!
Attachments
Q83_Q84_device_files.zip
(115.14 KiB) Downloaded 44 times
usart4_usart5_v23.zip
(12.97 KiB) Downloaded 50 times

Mikeclx
Posts: 20
Joined: Mon Feb 09, 2009 5:36 am
Location: New Zealand

Re: PIC18F47Q84 USART over 3

Post by Mikeclx » Sat May 06, 2023 8:43 pm

Awesome,
Thanks Jerry for this and everything you do for swordfish you’re a legend.

I have been doing more research.
I can see how the mistake was made as MAPS actually seems to be wrong and lists it as having 3 UARTs and page 1 of the datasheet lists it as having 3/2 as UART/UART with protocol support. Everywhere else in the datasheet refers and implies it has 5

I have emailed the MAPS team and Microchip support to get the information corrected.

It was one of those moments where I was starting to question if it had 3 or 5 and was hopping Microchip had not lead me down a dead end with incorrect info in datasheets (again)

I’ll report back if it all works correctly has I should have my PCB assembled in the next few days.

Mike

Post Reply