OK, here is where I am so far. I removed C91 and C92. I changed the 1.05 Raduino sketch by? adding code to read pin D7. In the original sketch, this was reserved for the TX/RX line monitor, which I don't use. You can use pretty much any other unused Arduino pin if you want. You also need to got through the code and remove references to that particular pin. Make sure you save your sketch under a new filename so as not to lose the original!!!
In the "setup" area, I made sure that pin D7 had the pullup enabled: pinMode(ULSB_SELECT,INPUT_PULLUP); (I #defined D7 as ULSB_SELECT previously)
Then, I added this code in the "loop" function:
if (digitalRead(ULSB_SELECT) == 1) /* if U/LSB switch is high, do LSB,
?if low, do USB */
{
? if (isUSB ==1)
? {
? isUSB = 0;
? setFrequency(frequency);
? updateDisplay();
? }
}
else
{
? if (isUSB == 0)
? {
? isUSB =1;
? setFrequency(frequency);
? updateDisplay();
? }
}
Finally, the little trick that allowed the displayed frequency to be correct for both LSB and USB: I modified this line in the setFrequency() function:
? if (isUSB){
??? si5351.set_freq((bfo_freq + f - 3100) * 100ULL, SI5351_CLK2);
The addition is the "- 3100" after the "freq + f". This keeps the displayed frequency the same, but shifts the actual VFO frequency to put the passband in the right spot.
Now - the caveat! I didn't have any definitive way to test this, as right now, I hear nothing on 7.076 (JT65 freq for 40m), even on the "big" radio. However, I took off the antenna connection of the bitx40, set my IC-718 to the lowest output I could, keyed it up in 7.150 MHz AM, and then tuned up & down from there on the bitx while trying both modes. In either mode, the frequency shift and volume of the received signal seemed to be pretty much the same, as I tuned up & down from the "center" frequency, certainly it should be pretty darned close! Hopefully, I'll see if I can hear some signals later & confirm the operation was a success!