Re: Variation on Ian's KD8CEC uBitx software (based on his 1.04 release for now) and ATU sketch. #ubitx

John <passionfruit88@...>
 

Hello Hidheiko-san,

The S-Meter display needs to read the level  of AGC or an audio level from pin A7 on the Raduino (the unused pin on the Raduino connector).

In the program it is shown in file ubitx_20.ino as:

//To read the AGC voltage on the MAX9814
#define ANALOG_SMETER (A7)

An example of a circuit that would give you a signal strength value is shown in the diagram below, using the 2nd audio amplifier channel of the TDA2822. I show in the blue part what is required.



This was part of the pre-production uBitx diagram but was not implemented in the production version.

The 2N7002 is used as an automatic gain control and can be used or not for that application. 

You would need to insert a trim-potentiometer (10KOhms is good) between ping 6 of the TDA2822 and the VOL-H connection to adjust the sensitivity, plus (VERY IMPORTANT) a voltage divider between the kathode of the diode and the ground to limit the voltage to under 5VDC for the analogue input of the Raduino. I would use 330KOhms in series with 100KOhms to the ground, and connect A7 to the junction of the twe resistors. Tell me if you need me to draw a full diagram.

Further adjustments are available in the software if required as we define the 9 stages of the S-meter display (first stage is zero, then 6 stages for growing bars, 1 stage showing "+" and one stage showing the custom "++" symbol). In ubitx_20.ino  it shows as:

int sMeterLevels[] = {0, 5, 17, 41, 74, 140, 255, 365, 470};
 
The values in the array are the measured values on the analogue input (defined as A7 above) at which we step into a higher "stage" and can go from zero for zero volts to 1023 for a 5V DC value. 

Hope this helps Hidheiko-san,

73, John (VK2ETA)

Join BITX20@groups.io to automatically receive all group messages.