Hi,
I am attempting to set up a PIC32MX575 @ 80MHz
I am using 8MHz crystal, so looking on other forums and the datasheet, i need to divide by 2and multiply by 20.
FPLLIDIV = DIVIDE BY 2
FPLLMUL = MULTIPLY 20
FPLLODIV = DIVIDE BY 1
FPBDIV = DIVIDE BY 2
Clock speed is set to 80MHz for timing.
With my flowchart turning an LED on and off with 1 second intervals, i am getting real life at 0.5 seconds. So its running 2x faster.
Since flowcode should be set up for 80Mhz this seems to indicate that my hardware is running at 160Mhz?
Changing FPLLIDIV to DIVIDE BY 4 corrects to clock, but by the numbers, flowcode is set up for 40Mhz with a clock speed setting of 80MHz,.
So something is off somewhere.....
Am i on the right track here, or am i missing something?
I have attached the .fcfx file for you to take a look at if it helps. Its current setup is FPLLIDIV / 2 which is running 2 x fast.
PIC32MX575 @ 80MHz
-
- Posts: 12
- http://meble-kuchenne.info.pl
- Joined: Sun Jun 20, 2021 11:55 am
- Has thanked: 2 times
- Been thanked: 1 time
-
- Valued Contributor
- Posts: 192
- Joined: Wed Dec 02, 2020 7:28 pm
- Has thanked: 77 times
- Been thanked: 64 times
Re: PIC32MX575 @ 80MHz
Have you tried setting the serial speed of the computer to twice your target speed or half of it to see it that produces the correct output? That would prove your theory.
Re: PIC32MX575 @ 80MHz
Good shout Kersing.
So, in order to get the serial to work, i am sending at 9600 from the PIC but receiving on the terminal at 4800. 2x slower
So heres what i have now set up.
8MHz crystal.
FLOWCODE CLOCK SPEED SET TO 80MHz
FPLLIDIV = DIVIDE BY 4
FPLLMUL = MULTIPLY 20
FPLLODIV = DIVIDE BY 1
FPBDIV = DIVIDE BY 1
All of the above i work out to running at 40Mhz, even tho Flowcode is set to 80mhz. This allows a 1 second LED blink to run on hardware properly.
Changing FPLLIDIV to /2 allows the UART to run at the correct speed of 9600. But the LED now blinks at 0.5 second intervals.
Since the UART works at the correct speeds, is this likely just a delay code issue?
So, in order to get the serial to work, i am sending at 9600 from the PIC but receiving on the terminal at 4800. 2x slower
So heres what i have now set up.
8MHz crystal.
FLOWCODE CLOCK SPEED SET TO 80MHz
FPLLIDIV = DIVIDE BY 4
FPLLMUL = MULTIPLY 20
FPLLODIV = DIVIDE BY 1
FPBDIV = DIVIDE BY 1
All of the above i work out to running at 40Mhz, even tho Flowcode is set to 80mhz. This allows a 1 second LED blink to run on hardware properly.
Changing FPLLIDIV to /2 allows the UART to run at the correct speed of 9600. But the LED now blinks at 0.5 second intervals.
Since the UART works at the correct speeds, is this likely just a delay code issue?
-
- Posts: 261
- Joined: Thu Dec 10, 2020 2:35 pm
- Has thanked: 36 times
- Been thanked: 17 times
Re: PIC32MX575 @ 80MHz
Hello Cushion
have a look at the settings in Excel that will already help you
greetings SpeedPic32
have a look at the settings in Excel that will already help you

greetings SpeedPic32
-
- Posts: 261
- Joined: Thu Dec 10, 2020 2:35 pm
- Has thanked: 36 times
- Been thanked: 17 times
Re: PIC32MX575 @ 80MHz
Hello Kissen
sorry my tool translated your name with
write this into a C code field
UxBRG=108; // set uart 1 to 9600
x is to be replaced by your rs232 number
replace the number 108 with the value BRG0 or BRG1 from the tool brg nr then everything should work
greetings SpeedPic32
unzip the brg zip and start the exe
sorry my tool translated your name with
write this into a C code field
UxBRG=108; // set uart 1 to 9600
x is to be replaced by your rs232 number
replace the number 108 with the value BRG0 or BRG1 from the tool brg nr then everything should work
greetings SpeedPic32
unzip the brg zip and start the exe