Robster
Dodgy hardware mod maker
The clock manager in the MMSP2 is a fairly powerful beastie! 3 independent PLLs with separate prescalers for everything plus most peripheral blocks can connect to any of the PLL sources.
Unfortunately, the datasheet gives no indication of how to determine the numbers but the names of the values (Mdiv, Pdiv, Sdiv) indicates that it's a standard ARM PLL setup... and it is . That is,
Under U-Boot, the three main PLLs are set like this:
Fpll is used as the 920T and 940T clocks, and is divided by 2 to give the memory clock.
Upll isn't used, but I suspect that at approximately 96MHz it's to be divided by 2 or something for the USB peripheral.
Apll is used for the serial port, with an initial divider of 10, a fixed divider of 16, and a programmable divider of 8 to give the final 115200bps speed.
I've trivially modified the trusty old "pllset" program to give Mdiv, Pdiv, Sdiv values for the MMSP2, I'm going to try changing the operating frequency soon and if it works I'll (really, really, really) write all this up properly.
It's a pity that MagicEyes haven't given us any idea what the maximum allowed VCO frequency is for the PLLs, but I'll do some experiments and we might get some sort of idea.
Unfortunately, the datasheet gives no indication of how to determine the numbers but the names of the values (Mdiv, Pdiv, Sdiv) indicates that it's a standard ARM PLL setup... and it is . That is,
Code:
Fpll = (m * Fin) / (p * s)
where
Fin is the crystal frequency, 7372800Hz
m = Mdiv + 8
p = Pdiv + 2
s = 2 to the power of Sdiv
Code:
Fpll: Mdiv = 0x49, Pdiv = 0x01, Sdiv = 0x00 F = 199065600Hz
Upll: Mdiv = 0x60, Pdiv = 0x00, Sdiv = 0x02 F = 95846400Hz
Apll: Mdiv = 0x98, Pdiv = 0x00, Sdiv = 0x02 F = 147456000Hz
Upll isn't used, but I suspect that at approximately 96MHz it's to be divided by 2 or something for the USB peripheral.
Apll is used for the serial port, with an initial divider of 10, a fixed divider of 16, and a programmable divider of 8 to give the final 115200bps speed.
I've trivially modified the trusty old "pllset" program to give Mdiv, Pdiv, Sdiv values for the MMSP2, I'm going to try changing the operating frequency soon and if it works I'll (really, really, really) write all this up properly.
It's a pity that MagicEyes haven't given us any idea what the maximum allowed VCO frequency is for the PLLs, but I'll do some experiments and we might get some sort of idea.