Wednesday, September 24, 2014

Arduino DDS Signal Generarator - Modifications

              Well, I was thinking about how to reduce the "wire mesh" from the Signal Generator. One option is to interface the 20x4 LCD using an I2C expander. I can use the MCP23017 16I/O or a PCF8574 from NXP. Decision is to go ahead with the PCF8574. 

Next target is to improve the Keypad handling.   Here also I can use the same chip to handle a 4x4 matrix keyboard

There are libraries available for I2C LCD and Keypad targeting the PCF8574.

Next experiment is to evaluate the libraries before making any change to the code...:)


Sunday, September 21, 2014

Arduino DDS Signal Generator

An attempt to create a Signal generator for my BitX MK2 testing..

I had considered the following requirements

   1) Tuning based on an Encoder;
   2) 20x4 LCD
   3) Memory for specific channels
   4) Arduino based
   5) Keyboard for frequency entry
   6) DDS chip as frequency generator.

I prefer to use the optical encoder instead of a mechanical one. Mechanical encoder fails to work after continuous operation. Sometimes I need to open the mechanical encoder and clean it for a better control. 

Regarding the LCD, initially I thought of using an I2C/Serial LCD, but I could not find one in the local market. So I decided to use the 20x4 LCD which was lying in the junk for a while. Today I saw one convertor for LCD in KO7M's blog ( I am not sure whether it is I2C or RS232 version).

My plan was to use a Atmega328(with preloaded arduino boot loader) , but this needs a PCB and supporting components :). Finally I decided to go ahead with an Arduino Mega 2560R3. This is a nice board with 256KB of flash well enough for my application.

A flexible 3x4 keyboard is used in the build, in future it will be replaced with a 4x4 keyboard ( depending on the pin availability in Mega 2560)

Sometime back I had procured a DDS board from It uses the AD9850 DDS chip and a 125 MHz crystal oscillator. The DDS board needs a 3.3 volt power supply, which I realized at a later point :). I didn't had a 3.3 v regulator ( through hole type) , so I used 2 1N4147 diodes in series and connected to the DDS power pin. For time being this can solve the heating issue of DDS board.

For testing the Radio I need to generate an LSB /USB signals ( to be frank this is also not needed, but it will be good as the frequency display in the Radio and the Signal generator will match).In the Firmware I have considered an option to switch the LSB/USB frequencies too.

Once this is completed then I can extend the features of this signal generator by adding the RIT, additional input for Tx/Rx indication, Tx Power lever in LCD etc.

It looks like a wire mesh :), but the build is working fine...
May be it is worth to show some LCD Screen shots

I have written a calibration routine for the DDS and the values are stored in the EPROM of Mega 2560.

I have used the Encoder Library from I have made couple of modifications in the original library based on my requirements.

Another custom library used in the project is to drive the DDS Chip.

I don't use a Git repository , so f anybody interested to try this build or expand it for your requirements please drop me a mail to vinodes "at" aol "dot"com ( don't forget to replace the "at" and "dot" :) ) I will be happy to give the source code and the libraries.

Problems observed :

1) When the DDS chip is operational for some time (say for one hour) the frequency is shifting for a couple of Hz. This may not be a problem if it is used in a radio. But for a signal generator point of view, it should be rock solid. I doubt the DDS board, it is a made in China borard , it costs only INR 500. If I have to buy a DDS chip from Farnell then I have to pay almost double money :)

One solution for this problem is to use the SiLabs Si570 which works from 10MHz to 160 MHz ( needs 3.3 v Power + an I2C level shifter) .
Trigger for another project :).........


Tuesday, April 8, 2014

BitX -Completed......

BitX (G6LBQ) MK2  project is almost completed..(

I haven't started to build a PA stage. Not considering a high power PA stage for this transceiver. A PA with 10-20W output will be good enough for this.

Since the Tx stages are not functional, I haven't connected LPF and microphone at all.

I am operating ( receiving to be precise) the BitX using a PIC based DDS VFO. I am not happy with its performance. Since the BITX IF is set to 11.0592 Mhz , the VFO frequency should be rxFreq + 11.0592Mhz.  VFO is low in amplitude at the high end of HF. Redesigning the LPF at the VFO final stage can solve the this issue up to some extend. I don't want to do any changes this VFO.

Next task is to build a nice VFO based on the arduino, possibly use the Arduino Mega itself as it has lot of program memory and EEPROM to store user settings.
One option is to drive the locally available AD9850 DDS board from the Arduino, or it will be better to use the Si570. Si570 is bit costlier as compared to the AD9850 module , but the stability and frequency range of this little monster Si570 will override the cost factor.