Si5351/Prop/BITX40 ham radio project
Jonathan
Posts: 1,023
in Propeller 1
Hi All,
I'm working on a ham radio project that uses the Si5351 clock chip. The target is the VFO of a BITX40, SSB 5 watt HF transceiver. A quick shout out, any hams who want a ton of fun for $60 go check out the BITX40. Very fun and hackable rig. The radio currently use an Arduino that comes with it, so of course we need to ditch that and get a Prop in charge! So, I got a Si5351 board from QRP labs to play with. I got it up and running with the Si5351 object in the OBEX. But it is way off frequency. I did some fooling around with the Arduino/Si5351 and while it is a little off and needs some correction, once corrected it is spot on. Meaning that the offset is consistent over a wide range of frequencies. Whereas the one I have hooked up to the Prop is WAY off and the offset is NOT consistent over a range of frequencies. For example:
MHz
2 = 2.16
4 = 4.32
8 = 8.64
Or rather, seems consistent as a percentage. Any ideas what could be causing it? Is it possible that it is a coding issue? Or is the Si5351 having issues?
I'm working on a ham radio project that uses the Si5351 clock chip. The target is the VFO of a BITX40, SSB 5 watt HF transceiver. A quick shout out, any hams who want a ton of fun for $60 go check out the BITX40. Very fun and hackable rig. The radio currently use an Arduino that comes with it, so of course we need to ditch that and get a Prop in charge! So, I got a Si5351 board from QRP labs to play with. I got it up and running with the Si5351 object in the OBEX. But it is way off frequency. I did some fooling around with the Arduino/Si5351 and while it is a little off and needs some correction, once corrected it is spot on. Meaning that the offset is consistent over a wide range of frequencies. Whereas the one I have hooked up to the Prop is WAY off and the offset is NOT consistent over a range of frequencies. For example:
MHz
2 = 2.16
4 = 4.32
8 = 8.64
Or rather, seems consistent as a percentage. Any ideas what could be causing it? Is it possible that it is a coding issue? Or is the Si5351 having issues?
Comments
2.16*25/27 = 2
That suggests your maths based on 25MHz, but the board instead uses a 27MHz Xtal ?
Thanks brother! Now I have to go and try to add the needed commands to the driver as I need access to functions not in the OBEX driver. So I'm sure I'll be back with more questions! But at least I can start fooling with it and look forward to have a Prop controlled BITX40.
https://github.com/NT7S/Si5351
could be useful reference ?
Thanks. I have been looking at the library used by the Arduino and the Si data sheet and yikes! Pretty tough for a bottom feeder coder like myself. I'll confess that I am feeling a little daunted after getting off to a good start. I'll see if I can unravel enough of the C to figure out what I need. Which luckily isn't anything fancy, just control over two fo the outputs and setting the output drive level and a couple other things. I'm surprised that there isn't a more complete library for this chip.
Thanks for the help and wish me luck! If I can't get it to run on the Prop alone I can maybe use the Arduino to run the clocks and the prop for everything else. A clumsy two layered solution to be sure.
Jim
Let's start getting the VFO/BFO working. Grab a Si5351 board from QRP labs, or there are others out there. Once we get that working with the BITX, we are off to the races. Sadly I know with my limited programming the Si5351 is going to be a heavy lift for me. Once I get that working, the rest of the menu code etc will be easy.
So yeah, anyone wanting to jump in on a Prop/BITX40 collaboration chime in!
Taking a quick look at the Ardunio code, it does not use floating point, but it does use 32*32->64 and 64/32 -> 32 math operations.
It sparingly uses uint64_t, and calls do_div(uint64_t,uint32_t)
The PropC docs do show uint64_t, uint_least64_t, uint_fast64_t , so a PropC expert may know how to port the 64:32 mixed code.
True, but you can prove the code works on AVR, then port to Prop, and confirm it still works
And while code is code, not all of us are created equal in our ability to create it! I'm more of a hardware guy.
And as to QRO, there are plenty of ways to do that. I get over 50 watts out of a SB-200 driving it with the BITX. You can get more drive than claimed with a higher PA voltage and a good heat sink.
The Si5351 uses fractions in two places, one in the VCO feedback, which will be somewhat averaged, but they can also use fractions in the VCO output divider.
I'm not quite sure how SiLabs get their claimed jitter, give the VCO MHz and output divider fractions, but I have seen mention of locking the post VCO divider to integer only, to improve Jitter.
That does give compromises on Synth Steps, because you now have only one fractional choice, not two.
This is the Data sheet: and this is how ClockBuilder creates 74.25, 24.576, and 48 MHz. In two cases, N is fractional.
The current BITX VFO tunes in 100Hz increments. This is fine but I wouldn't mind 10Hz increments. The low end would be 3.5MHz, so we don't run into the issues of the lower end of the Si5351 where some tricks need to be pulled. The high end would be 14.35MHz.
The BFO is less particular, for LSB it is set to ~ 12MHz and USB I think it is ~ 19MHz.
Yes, but there is some 64/32 code, that I think Spin has no native support for, so that would need some PASM support in a 'maths cog'.
Then, there is a question of how slow Spin will be, as some of the code scans, looking for a 'best result' fit.
Yes, but there is some 64/32 code, that I think Spin has no native support for, so that would need some PASM support in a 'maths cog'.
Then, there is a question of how slow Spin will be, as some of the code scans, looking for a 'best result' fit.
-Phil
http://forums.parallax.com/discussion/163409/silabs-si5351-clock-generator-spin-driver
seeing what can be done on the 2m band (although I'm a long lapsed amateur (G1XMO), I recently
bought a spectrum analyser, which has rekindled an RF interest.
I might start playing with the dirt cheap AD9833 modules (10 bit DDS upto about 10MHz) and direct quadrature
SSB with a pair of them.
[ No problem with frequency resolution with DDS ]
Mark, if you do play with the AD9833 keep me informed! Sounds like a fun project! Renew yer ticket too!