Reply 100 of 116, by rasz_pl
feipoa wrote on 2024-10-29, 09:42:// the following results in 93.5 MHz, 1.60 v to 4.08 V
si5351_freq(85000000, 0);
// output a bit off
si5351_freq is supposed to run same calculations and program same registers as this calculator https://rfzero.net/documentation/tools/si5351 … frequency-tool/
8.5MHz is not a bit 😀 one thing that comes to mind is wrong crystal set in tiny5351.h, I set it to #define SI_XTAL_FREQ 25000000
feipoa wrote on 2024-10-29, 09:42:si5351_PLL(24, 2, 3, R_DIV_NA);
si5351_Multisynth(7, 2549, 10000);
// correct output, but changes to si5351_PLL() don't alter the clock output. Numerator stuck at 616.66667?
I was messing with si5351_PLL and left it broken, maybe fixed now
feipoa wrote on 2024-10-29, 09:42:// following results in error 'm' not declared
si5351_freqInt(m, SI_R_DIV_8 or SI_R_DIV_16, 0);
you tried to execute syntax example?
feipoa wrote on 2024-10-29, 11:31:I haven't spent a lot of time with it, but from what I've seen, it works as it should. increment/decrement function fine. With a power cycle, the previous operating frequency is saved accordingly. If the frequency is taken out of the limit region, e.g. 100 MHz, it still climbs as expected.
its all barebones and as simple as possible, I added some defines
feipoa wrote on 2024-10-29, 11:31:When I power cycled the frequency returns to the starting frequency of 66 Mhz, but only when I've exceeded the upper stop (as expected).
both buttons at the same time should also reset to starting freq
feipoa wrote on 2024-10-29, 11:31:I found the 500 ms delay a bit long between button pushes for testing, so I adjusted it to 300 ms. I also took the starting frequency to 80 MHz.
there is also additional delay when programming frequency
>delayMicroseconds(500); // Allow registers to settle before resetting the PLL
which I dont know if its needed, I just discovered Linux has driver for this PLL https://github.com/torvalds/linux/blob/master … lk/clk-si5351.c and
1 resetting PLL is only needed when using multiple clock outputs to maintain phase offsets
2 linux doesnt do any delays https://github.com/torvalds/linux/blob/c1e939 … k-si5351.c#L946
looks useless, removing it
feipoa wrote on 2024-10-29, 11:31:It may not be related, but when I set the delay to 200 ms and adjusted the upper stop to 110 Mhz, I had issues programming the ATtiny85. After powercycling the Arduino Uno, and praying, I was able to write ATtiny85 again.
coincidence, programmer puts attiny in special programming mode using Reset pin and no code should affect that. Btw you can program attiny to run at 1MHz, its going to be doind nothing for all its life anyway. no point burning precious hundreds of miliamps 😀
https://github.com/raszpl/FIC-486-GAC-2-Cache-Module for AT&T Globalyst
https://github.com/raszpl/386RC-16 memory board
https://github.com/raszpl/440BX Reference Design adapted to Kicad
https://github.com/raszpl/Zenith_ZBIOS MFM-300 Monitor