Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problems with SI5351B-GM1 only two outputs working and they don't match. #92

Open
zindello opened this issue May 2, 2023 · 1 comment

Comments

@zindello
Copy link

zindello commented May 2, 2023

Describe the bug
I am having strange issues when using the SI5351B-GM1

Setup:
Microcontroller: Seedstudio Xiao ESP32-C3
Crystal: TXC 7M-27.000MEEQ-T (Per the recommended crystals)
Si5351 Chip: SI5351B-GM1 (16QFN)

To Reproduce
Using the supplied library, I can init the library and communicate with the chip, however when setting outputs strange things happen.

Setting an output on CLK0 does nothing
Setting an output on CLK1 provides output on the CLK0 pin
Setting an output on CLK2 provides an output on the CLK1 pin
Setting an output on CLK3 does nothing
Setting an output on CLK4 does nothing (Given there is no CLK4 this is expected)
Setting an output on CLK5 does nothing
Setting an output on CLK6 does nothing
Setting an output on CLK7 does nothing

Expected behavior
CLK0-CLK3 all output as expected.

Additional context
I feel like this might be the result of the 16QFN chip having it's registers configured a little differently and as such the library isn't setting the registers properly? It would be neat if I could use this library to set the registers on this chip as I really don't want to write a library to do what this one does myself. Im going to dig into the datasheet and the library to see if I can figure out what's going on.

@zindello
Copy link
Author

zindello commented May 3, 2023

Ok, further to this I think I've found the problem.

The "A" version of the chips all have registers for 8 clocks, whether they use them or not, so the library works for all of those versions.

The "B/16QFN" version of the chips however have four clock outs, but the registers are in different places, mostly however within the same address spaces.

Why use the 16QFN version? They're roughly half the cost of the 20QFN chips.

So far I've been able to establish that.

CLK0 is in the place where CLK1 is on the other versions - This works if you use CLK1 in the library
CLK1 is in the place where CLK2 is on the other versions - This works if you use CLK2 in the library
CLK2 is in the place where CLK5 is on the other versions - This works if you use CLK5 in the library
CLK3 is in the place where CLK7 is on the other versions - However this doesn't work if you use CLK7 in the library.

So it looks like everything works except for CLK3. I had a look at the library and it looks like you're using binary maths to figure out the location of a bunch of the registers, bit shifting the clock number to hit the right register value to set the register you need to for each clock. Unfortunately for the B revision chips this won't work as the registers are in strange places. See attached screenshots of the data sheets.

https://www.skyworksinc.com/-/media/Skyworks/SL/documents/public/data-sheets/Si5351-B.pdf

Screenshot 2023-05-03 at 5 08 34 pm

Screenshot 2023-05-03 at 5 08 29 pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant