Wednesday, 31 July 2013

Complex Programmable Logical Devices

I already gave an small introduction about CPLDs in part III of the 3 Ghz counter build.
Cplds and Fpgas are very interesting devices for those who ever wanted to design their own integrated circuit but could not afford a million $ to let your prototype actually build.

A Cpld consists of the following elements:
Programmable And/Or matrices the macro cells
Programmable feedback
Input blocks
Output blocks

They distinguish themselves primarily in speed and the amount of programmable cells and pin count .
Unfortunately if you need many programmable macro cells the designers assumed you probably need many in out pins too. But many in out pins mean very small footprint and very home brew unfriendly.

So the hobby engineer is restricted to low cell count packages and therefore only small designs.

What are the advantages of a Cpld over a micro controller.
A Cpld can work massively parallel a  lightning speed.
The I/Os don't need a higher level control structure they work just by the logic assigned between an input and an output. They are often used for data capturing and collecting then they transfer the data to a high speed ram and then a micro controller  analyzes the data. Fast oscilloscopes would be unthinkable without high speed logic, micro controllers are ridiculously slow compared to Fpgas.

How to get started ?
Unfortunately programming and designing code for Cplds is completely different to program a micro controller and full of pitfalls.So the best way is to start small and use a simple low cell count target chip.
This is where Dangerous prototypes comes in, they designed two breakout boards based on the Coolrunner II series.One has a macro cell count of 72 and the other of 64.So you wont be able to run an Arm chip design on them but you could use them as multiplexer, inverter, ... You could reproduce the basic logic design blocks with them and combinations of them. You also get used to Verilog the programming language.
Later one if you decided you like the environment you could easily transit to the bigger high cell count Cplds.

To get started I would suggest the CoolRunner II XC2C64A CPLD with 64 macro cells and an Altera Usb Blaster programmer clone from Ebay.

As a first step I would work trough the Dangerous Prototypes tutorial section.

Cpld devboard and programmer



Links:
Dangerous Prototypes Cpld Board
Cpld Forum
Tutorials

Tuesday, 30 July 2013

Arduino Video Overlay Shield

In 2011 I won a free pcb from Dangerous Prototypes, a Arduino shield you can use to overlay and display data on a video stream.

The Arduino Video Overlay Shield is based on the MAX7456 on screen display chip.
The Arduino compatible shield board overlays text on analog video, therefore
it allows easy overlay of text onto an analog video signal, NTSC or PAL.
Just plug it on an Arduino processor board to get started.
The shield is created by Lowvoltage Labs.

 I wanted to use it to display the subject line and address  of incoming emails while watching tv.
Another use could be a osd system to display flight data on rc planes.

Unfortunately the board needed a 27 Mhz crystal and I could not get my hands on one.
As soon I got one I could not find the board anymore,...
Meanwhile I found it and finally assembled it. The board worked out of the box, except the processors character set is Japanese by default! Luckily I could find a European standard Ascii character set and some code to upload it. The character set text file size is 170 kB and the upload took about three minutes.

Now the hello world output does not look so strange anymore.
A fine board and a interesting new chip, what could you possibly ask for more ?

One final but important note, do not forget to insulate the osd output plug, because it will most certainly short out on the Arduino Usb plug.

Osd shield ready for action
Osd shield top side
Osd shield bottom side, please do not forget the insulation on the video out side plug
Hello world test osd over webcam input


Links:
Dangerous Prototypes Video Shield Announcement
Lowvoltage Labs
Seeedstudio sells assembeled boards
MAX7456 datasheet
Wiki entry
Arduino forum thread

Monday, 29 July 2013

3 Ghz counter and power detector build Part IV Putting the counter into service

After I had soldered the remaining parts like missing passives the lcd display and user buttons the build process was finished.
Before applying power I measured the resistance of the power lines  and some other important points to ensure there are no nasty shorts hiding somewhere.

The big moment applying power.
Nothing except a short blink of the lcd back light happened .
Hmmm
Soon I figured out there is a very nice software power switch  implemented.
You need to press the ok button to switch the unit on.
Very nice, I will implement that logic in my own designs too.
Power switches are so outdated.

So the unit works. As a first test I measured the power and frequency of an fm test generator.
Without calibration the frequency part worked ok but the power measurement was of by 3 db.
To calibrate the unit I need access to the university test lab, which I don't have until September.

First impressions, pros and cons of the unit:

Pros:
Very nice power on design
Usage of qfn components I lover to solder fine pitched smd devices
Cpld design
Open source software for the microchip and the cpld

Cons:
A usb port to export data is missing
The displayed frequency is always drifting
No gate time setting
Silk screen of pcb is horrible , very fuzzy and partly unreadable (the manufacturer promised to take care of this problem though)

In the end I am unfortunately disappointed of the unit.
On the other hand it still will be a help in the spectrum analyzer build process.
I am also thinking about implementing an serial output.
To log the data in a computer could be a big help. You could for example plot the frequency versus power output of a device and visualize the stability of the power in a given range.

Finally the counter in action (Please excuse the flare on the lcd)


Links:
3 Ghz counter and power detector build Part I
3 Ghz counter and power detector build Part II
3 Ghz counter and power detector build Part III
Elektor project page


Sunday, 28 July 2013

3 Ghz counter and power detector build Part III Cpld

The counter not only has a Dsp that needs programming, there is also a Cpld.
Cplds (Complex Programmable Logical Devices ) are very interesting parts.
A Cpld gives you the possibility to create your own integrated circuit.
In a very simplified explanation I would say they are made of thousands of gate arrays and configurable wires which connect between the gates and the pins.
Programming a Cpld is more like routing a pcb than programming a microcontroller.
A common language to describe your circuit is VHDL (Verilog Hardware Definition Language).

Cplds and Fpga (Field Programmable Gate Array) are very powerfull devices.
They can process tasks massively parallel are very fast but also expensive and tricky to program.

Programming a Cpld is usually done via Jtag interface.
I downloaded the Altera programmer and used a 5$ Jtag programmer clone of the Altera Usb Blaster.

Everything worked immediately .
The last step of the counter build is to add the rest of the passive components.

Successful programming of the Cpld
Links:
3 Ghz counter and power detector build Part I
3 Ghz counter and power detector build Part II
Elektor project page
Altera Homepage

Friday, 26 July 2013

3 Ghz counter and power detector build Part II Troubles programming the Dsp

When I populate a new pcb I first solder the chips with the smallest footprints.
Next in order are the bigger ics and power supply chips.

Then I make a break and program the controller.
To program a Pic chip you just need the chip, some decoupling capacitors a pullup resistor  on the reset line and the three programming data lines MCLEAR (reset line),PGC,PGD.
Usually pic chips are super easy to program, compared to the Atmel Avr line they even don't need an oscillator.

So with high hopes I started  the Microchip ide Mplab, connected the programmer to the board (using pogo pins to avoid solderin a connector) and clicked the connect menu entry.


Connecting to MPLAB ICD 2
...Connected
Setting Vdd source to target
ICDWarn0020: Invalid target device id (expected=0xF0F, read=0x0)
...Reading ICD Product ID
Running ICD Self Test
... Failed Self Test.  See ICD2 Settings (Programmer->Settings) (status tab) for details.
MPLAB ICD 2 ready for next operation

Hmmmm
At least one head scratching hours later, no difference.
The Dsp chip simply told me in this working environment we ar on strike, go f*** yourself.
Now what to do if a processor is in working refusal ?
The best way is to negotiating with their local labour union boss, the datasheet.
In a good datasheet there is often a minimal working environment section and voila there is a strange pin number 7 called Vcap/Vdcore.

Hmmmm

After further reading I understood the internal core runs on 2.5V and to avoid an extra power line the chi provides an internal regulator which needs a decoupling capacitor.

Next try:

Connecting to MPLAB ICD 2
...Connected
Setting Vdd source to target
Target Device dsPIC33FJ32GP204 found, revision = Rev 0x3006
...Reading ICD Product ID
Running ICD Self Test
...Passed
MPLAB ICD 2 ready for next operation
Programming Target...
...Validating configuration fields
ICDWarn0046:  Because clock switching is enabled, MPLAB ICD 2 requires the user to cycle target power after a program operation.
...Erasing Part
...Programming Program Memory (0x0 - 0x54FF)
Verifying...
...Program Memory
...Verify Succeeded
...Programming Configuration Bits
.. Config Memory
Verifying configuration memory...
...Programming succeeded

BOOOOOM
Success, the chip is now programmed.
Now that was some heavy lifting , usually troubles appear from the most unexpected direction.

Time for some pictures:
Dsp processor

PLL chip very small footprint

 Log Power measurement , Cpld and Pll chips

Links:
3 Ghz counter and power detector build Part I
Elektor project page

Thursday, 25 July 2013

GPS Locator

I often read about new Gps receiver which are so sensitive the even get a lock indoors.
Every now and then I believe this rumours buy the unit try it at home and of course it does not receive enough satellites to get a lock sometimes it does not even receive one.

A gps receiver at would be grat, I could synchronise my Rubidium oscillator with the 1pps output, or build a timeserver ,...

 The MTK3339 Gps receiver I tested has a pretty fast fix and there is a breakout pad available which fits on the Launchpad. There is even the option to connect a battery to it so it does not lose its satellite data and only needs a warm start.

When you remove the target processor on it you can use the Launchpad as serial to usb converter.
So you plug the Gps pcb on the Launchpad, start a terminal programm on the Pc and watch the Gps data flow.

Unfortunately no Gps lock at home, but nevertheless a very sensitive and fast Gps receiver.

Gps Locator pcb

Gps Locator bottom view

Links:
Booster Pack shop link
Gps receiver

Wednesday, 24 July 2013

Nokia 5110 Msp430 Booster Pack

Texas instruments is becoming my most used development platform.
The launchpad series is great for rapid development and did I mention the debugger is great ?
Since Ti is such a big company it is somewhat hard to gather the information you need, since they have many technical writers and thousands of documents. They also lack some kind of easy tutorial which just gets you started like the one from Embedded Artists for the Nxp line or I simply have not found it yet.

Edit:
Unbelievable there is a great tutorial site from Ti I just found it within minutes after I wrote this blog,...
http://processors.wiki.ti.com/index.php/Getting_Started_with_the_MSP430_LaunchPad_Workshop



On the other hand there is a great user community and if you have some experience with other controllers you will get used to the controller line soon.

The Nokia booster pack is designed by RobG and it is also possible to build it as a  stand alone display.
I decided to do so, but I had great difficulties to get the programmer to recognize the board.
In the end my reset controller consisting of an resistor and a capacity did not work out. After hours of head scratching guess work I removed the capacity and it did work immediately, very strange.
To program the controller I simply put the board on a launchpad with empty target controller socket.

I tried some example code from the designer and the booster pack worked great.

I usually don't like displays without a character generator,  but once you defined the character set you won't notice a difference, so no problem whatsoever.

The Nokia 5110 display is controlled via Spi bus, so update rates are fast and programming is easy once you get used to the concept. There is a nice lecture from Cornell university which helps you understand the basic concepts to use a Spi bus.

Btw. I decided to build a standalone version, because I can implement a full blown easy to use display controller module and then simply connect any circuit to it to use it, even the interface choice is flexible, from simple bit bang mode to serial or I2C anything is possible. I simply like modular approaches.

Finally some pictures:

Nokia 5110 msp430 booster pack

Bottom side

In action

On top of the launchpad to program the controller


Links:
Spi tutorial
Buy pcb from 43oh shop
Build thread

Tuesday, 23 July 2013

WS2812 RGB Led Matrix Booster Pack

The WS2812 is a highly interesting RGB led, since it already has a controller build in and supports daisy chaining.

Now how does it work ?
You can send 3 bytes of information to the led. Every byte corresponds to either the intensity of the colour red green or blue. 255 translates to highest intensity while 0 turns the corresponding colour of.
So f.e. you have 10 leds in a row and send 30 bytes to them. The first led grabs the first 3 bytes and passes the left 27 bytes down to the other leds. But the led not only passes the bytes down, it also reshapes the signal and amplifies it.. You don't need to worry of signal integrity.

The controller also only needs one data line, so there is no clock signal needed.

There is only one problem, the signal has to be short to get reasonable update rates.
So a 1 is translated to a 1.2us long high impulse followed by a 1.3us long low impulse.
While a 0 is translated to a 0.5us long high impulse followed by a 2. us long low impulse.

So the pulses need to be so fast you cannot bit bang them any more you need a built in hardware module.
Some genius developer on the internet suggested to use the built in Spi bus protocol since it supports fast data rates.But there are still some problems waiting to be solved. In hardware Spi a bit always has the same time frame and either a high or a low pulse.

So you have to map your bit to a matching spi sequence.
So first program the bus speed to 2 mhz. Every bit is now 0,5 us long.
A bit with value 1 now translates roughly into 11000
A bit with value 0 translates exactly into 10000

The bit with the value 1 is not exactly mapped but the processor has a tolerance of +-150 nS so we should be fine.

I tested the code with a WS2812 led light strip I built and it worked.

This is a great example of a developers ingenuity, there is a big problem but thinking out of the box and using an hardware bus protocol which has completely different specs but is fast enough saved the day.

I plan to use the led matrix  as a moodlight, but most importantly I wanted to learn how to use this leds.
I want to use them to display sensor data like temperature and humidity. Blue would translate to below comfortable, green ok and red above comfortable level.

RobG Led Matrix Msp430 Booster Pack


Backside JP1 powers module from launchpad

Booster pack in action
 Links:
Buy pcb
Designers forum thread

Monday, 22 July 2013

3 Ghz counter and power detector build

To measure the output of the phase locked oscillators for the spectrum analyzer I needed a fairly accurate frequency counter.

I test a counter usually against my 10 Mhz rubidium source.
Neither a cheap 1 Ghz counter from China nor a self built counter built around pic micro controller produced good results. They were way of,...

This new project which I found on the Elektor homepage raised my curiosity.
Usually I don't like Eektor projects that much,  they tend to use the most expensive components but then deliver a mediocre circuit that does not make use of all the bells and whistles this components could deliver. On the other hand I like the magazine and always  hope this time they hit gold.

First for pre scaling (dividing the input signal down) it uses a cheap pll chip instead of an expensive dedicated pre scaler. (nice!)
Second as counter it uses a CPLD device and provides the VHDL (Verilog hardware description language) sources.
Third it uses a 0.5 ppm crystal oscillator as reference.
Forth it can measure the power level but unfortunately only within an accuracy of 4 db (if the frequency is modulated). I can live with that, power meters almost always have trouble with modulated sigbak sources .

I ordered an empty pcb, luckily I already ad most of the needed parts in my lab.
In the build process I first populated the most difficult parts like the qfn power detector, the input amplifier and than the rest of the integrated circuits.
Then I soldered the passive components.
Afterwards the big components like the display were soldered.

Before power up I checked for short circuits.

Next step is programming the Cpld and the Dsp about which I will tell you in another blog post.


Counter function blocks
             1) Hf input
             2) Dc input
             3) Battery input
             4) Input splitter (Log detector, Counter)
             5) Log Detctor
             6) Preamp
             7) Pll (prescaler)
             8) Oscillator
             9,10) Linear regulators
             11) Reference
             12) Polyfuse circuit protection
             13) Jtag disable
             14) Jtag (Busblaster programmer input)
             15) Icd (Dsp programmer input)
             16) Cpld
             17) Dsp

Links:
Project link



Sunday, 21 July 2013

Meet the Lpcxpresso

Embdedded Artists did an awesome job around the Lpc Arm processor line from Nxp.
32 bit Arm processors are now  available and affordable for everyone.
All you need is some fundamental C experience, an Lpcxpresso board and to read the Embedded Artists tutorial.

For example I read the I2C tutorial section, hooked up an Lm75 I2C temperature sensor and understood enough about the usage of I2C to write my own character display library based on an Newhaven I2C display.

The productivity using this tool set can be breathtaking.
You use templates from Embedded  Artists, expand the code debug it and you are done.

The code red ide is based on Eclipse so you really get a nice development environment.
There is a huge user base on the Internet and some really great forums.

The debugger works great and you always see what is going on with your source code.

For my hardware designs I meanwhile use only controllers from Ti and the Lpc line if I need 32 bit power. I don't want to work without a decent debugger any more.

In the moment I use the following boards:
LPC1115 board
A Arm cortex M0 processor with 64kB flash and 8kB data memory

LPC1669
A Arm cortex M3 processor with 512kB flash and 64kB data memory
It has a built in Ethernet and can interface and offers tons of features.

I also bought the Lpcxpresso experiment kit, which offers example hardware and software to try the most interesting chip features out.

Once I figured the user rights management on my private git server out, I will provide some example code I wrote for this processor, like my lcd library.

LPC 1115 and Lm75 sensor on a breadboard


The new Jtag V2 interface

Lpcxpresso experiment kit



Links:
Embedded Artists
Lpcxpresso experiment kit
Code Red Ide
Nxp
User Forum

Saturday, 20 July 2013

Spectrum analyzer Part IX High Voltage Supply

The workhorses of the spectrum analyzer the phase locked oscillators (PLO) need a control voltage greater than 20V. Scotty's controller pcb already has a switching converter section, but there were some problems  reported on the newsgroup. So Sam Wetterlin designed a new stand alone module for this purpose. It is a switching style design, but creates very little oscillator ripple at its input and output, and little radiation, though it still should be encased with a fence. 

Since I was lucky and got my hand on a pcb set which included also some Wetterlin pcbs I decided to use his design on my analyzer build.#

Soldering the module was pretty much easy and the module worked immeadetly.

#s
Sam Wetterlin's HV module
Links
HV Module Schema File
Pcb files
Sam Wetterlin Webpage


Spectrum analyzer Part I Controller board
Spectrum analyzer Part II Phase Detector
Spectrum analyzer Part III ADC 16
Spectrum analyzer Part IV Logarithmic Detector
Spectrum analyzer Part V Master Oscillator
Spectrum analyzer Part VI DDS 
Spectrum analyzer Part VII The Frame

Spectrum analyzer Part VIII The Mixer Modules 

Friday, 19 July 2013

Spectrum analyzer Part VIII The Mixer Modules

Friday morning the perfect time for a new Spectrum Analyzer build entry.

This time the four mixer modules are finished.
There is unfortunately not much to tell, except since one of them (Mixer 1)  is directly coupled to the input stage, shielding is important.

Mixer 1 is responsible for the input.
Mixer 2 is placed directly behind the cavity filter.
Mixer 3 is responsible for the tracking generator output.
Mixer 4 is needed for the Vna functionality.

Since I am building the full blown analyzer, I had to build all four of them.

Mixer 1 to 4 with brass shielding and matching lids





Links:
Spectrum analyzer Part I Controller board
Spectrum analyzer Part II Phase Detector
Spectrum analyzer Part III ADC 16
Spectrum analyzer Part IV Logarithmic Detector 
Spectrum analyzer Part V Master Oscillator
Spectrum analyzer Part VI DDS 
Spectrum analyzer Part VII The Frame

Thursday, 18 July 2013

Embedded Wifi

More sooner than later even simple electronic products will have to support wifi.
The electronic industry finally has recognised the demand and started to deliver easy to use solutions.

To send some data to a server I am not interested to study osi layers and literally thousands of pages from different rfc papers. I simply want to connect open a socket and send the data somewhere.

Available and affordable solutions: 

TI CC3000 module 

A great pitfall today is to connection to the wifi. Until now you needed a pretty serious gui interface just for that one time operation. Texas Instruments created a very nice solution, they added to their CC3000 wifi interface a program where you can set up your wifi client with your handy.
Their api  called Simple Link is easy to understand and helps you to get everything up and running in a second.
You can buy the CC3000 directly from Ti for 35$ including s&h

Wiznet WizFi220 

The Wiznet devices are around for some time now. The WizFi220 low power "Serial to WiFi” module with additional power amplifier is also easy to use. You even don't need an api to run it, you simply send serial commands from your application to the module and the module does all the magic.
There is also a big user community and many examples are available on the internet.
You can buy the WizFi220 for about 25$ but unfortunately s&h to Europe from Wiznet or their resellers is pretty expensive.

TP-Link TL-WR703N 

The hackers choice. The WR703N is a small router whit an available open wrt port.
Unfortunately this device was until recently only available in China and therefore has a chinese user interface. To find the correct firmware update page is not an easy task.

Once you have taken this hurdle you have a nice little wifi enabled Linux computer.
The unit also provides a serial interface on the pcb, you just have to solder some wires to the pcb and a connector. Then you can talk to the device with an micro controller and run some python scripts on the router side to send your data over wifi.

You can buy this device from Ebay for under 20$

I like all three modules and will soon post about my experiences using them.

Links
Ti CC3000 wiki
Wiznet WizFi220
TP Link TL-WR703N Open Wrt page

Pictures:

From left to right: CC300 Booster Pack, Wizfi220 and Antenna, TP Link TL-W703N

TP Link router inside case



Wednesday, 17 July 2013

SVR transfer reference

More than a year ago I bought a 5,5 digit HP 3478A bench multimeter.
Usually professional tools like this are pretty expensive, but if you are lucky they reach their end of life cycle in  big production companies and then they swamp the second hand market.
I bought the HP 3478A at the right time for about 100$.
There is a big problem with this multimeter, the calibration chip is battery buffered.
If you had bad luck you buy one which has lost it's calibration data and then operates way out of spec.

Recently the 6,5 digit workhorses like the Agilent 34401A are becoming more and more affordable.
I could not resist and bought one at a ham radio flee market.

Unfortunately it is hard to test such precise devices and a new calibration would cost twice as much as the device itself.

So I needed a cheap high precision voltage source to test the meter.
I found one from Geller Labs, which is based on the  AD587LQ (cerdip!) or AD587LN from Analog Devices. Since they also sell  bare pcbs I populated mine using a way cheaper (but also more temp. drifting) version  the AD587KNZ.


To get reproduceable results it is advisable to let the meter and voltage source run for at least half an hour.

Btw. I ignore the least significant digit on a display or when important I round it.
If you round the least significant digit all displays would have produced the perfect result of 10V !
That is why I can live with a more drifting version of the Analog chip and drifting it does unfortunately.
I would like to test a calibrated version with the cerdip chip, but only for curiosity.

Bbtw. 8.5 digit meters are becoming more affordable,....

Svr board with Agilent U1272A multimeter

Agilent 34401 6,5 digit multimeter
HP 3478A 5,5 digit multimeter
















































































Links:

Geller Labs Svr transfer reference

Tuesday, 16 July 2013

Backwoods Logger

The Backwoods Logger is a very useful at displaying graphing and logging pressure, height and degrees , all in the size of a Tic-Tac box weighing about 1 ounce.

It's built-in oled screen can show current data or graphs of data vs time within a scale from the past 2 hours to the past 2.5 days.

Most important, this logger is an open source project.
The logger is based upon a Bosch BMP085 temperature and pressure sensor and an Atmel AVR ATmega328P micro controller.

I built this device about a year ago and often used it.
Unfortunately I once left it in my trousers bag and put it in the wash machine.

Of course it was broken afterwards, the display and the pressure sensor had to be replaced.

I changed them today and now the logger is back and alive again.
Since it is so small I can use it inside an rc controlled glider as an altimeter.

Btw. did I mention it uses an oled display ?!
 


Backwoods logger start up screen

Backside with micro controller and sensor
Washing machine casualities

For more information please visit the project's hompage



Saturday, 13 July 2013

Sorting, sorting , sorting


Usually I store my resistors in a zip bag and there is always the worry  if I already own the right ones for a certain project.

More than a year ago I bought three smd component storage boxes and started to sort my 0603 resistors.
First you have to label all the compartments and then you fill them up with resistors.
Great care is to be taken, wrong placed resistors have to potential to sabotage you project.

Sorting the 0603 resistors was really not a project you would write home about.
But the resistor box turned out extremely useful.
In fact so useful I would not miss this box anymore.
By the time (> 1 year at least) I also forgot about all the hassle.
So I decided today it is time to fill another box, this time 0805 resistors.
To get an idea of the project, i own meanwhile more then 10k of 0805 resistors with about 170 different values.Eight back aching hours later, I finally sorted them in !!!

 
Very useful storage box

more than 10.000 sorted resistors

Friday, 12 July 2013

How to solder QFN chips like the MSP430FR5739

The new MSP430FR chip line has interesting features like embedded non volatile fram and ultra low power consumption. The chip is available in TSSOP38 or QFN40 package.I simply had to try them out.

Usually hobbyists  are repelled by the very small case and the missing pins.
But once you get used to work with the QFN package you start to prefer it over any other packaging.
Since they have no visible pins, they cannot suck the solder up via capillary suction and create ugly shorts.

To solder a qfn chip you buy a breakout board and put a small amount of solder paste at the pcb.
Beside the solder paste you add some solder flux (very important).
Then you place the chip on the board and roughly align it.
With an heat gun you slowly heat the chip and board until the flux starts to melt.
This is a very important phase because the chip will swim on the fluid and align itself correctly.
Now heat it up until the solder past melts and you are done.

The next problem you will face is how to check the correct alignment and if all pins are correctly connected to the board.I use a multimeter for that purpose. Usually the pins have a certain resistance around 5k to 1mega ohm. Measure all pins and if there are shorts suck them away using some solder wick.

Once you get used to Qfn packages and are able to solder the chip  correctly it will only require about two minutes of your precious spare time. Soon you will start to enjoy working with Qfn packages.

MSP430 in QFN package compared to a Dil20 chip

Links
MSP430FR5739
Fram
Demo video

Thursday, 11 July 2013

Meet the Powerscope

Since Ti announced the Launchpad I was very excited to play with this awesome development tool.
It is like a Arduino on steroids, mostly because of it's 16 bit capability and most important it has a debugger.
When your code does not work nothing is more useful than a debugger, maybe  with the exception of a razor sharp brain and years of development experience might not hurt either.

Since the Msp430 line supports low energy consumption and have many different feature sets it is important to verify if the consumption is really as good as it could be. To see exactly what is going on, a scope is the tool of choice, but for a quick estimation the Powerscope is much more comfortable and easier to use.

When measuring very low power devices I would not recommend to use a multimeter, because of their usualy high burden voltage. To circumvent this problem, David Jones from EEVBlog designed the uCurrent , also a great tool.
The Superprobe is a somehow similar device, but it has it's own display so you don't need to connect it to a multimeter.

I also built an usb adapter to attach the Powerscope to a Usb device and measure it's power consumption.
In the attached example pictures I connected the Powersope to an Launchpad which drove a CC2500 radio device.It does not make much sense, because the attached debugger also has a unknown power consumption but it gives an idea of usage and it also shows that the TX mode consumes about 17 mA more than the RX mode .Btw. the code in the moment has no power optimisations what so ever, I was more than happy to get the CC2500 up and running,...

The programming of the Powerscope also was more than easy.
You can either use the Launchpads programmer by removing all the jumpers and insert a programmer cable or you can like me use a Goodfet programmer designed by Travis Goodspeed.
Since I don't like to solder headers just for one time programming, I made a small programming cable with pogo pins. You can use this kind of connection even for debugging.

You can buy an empty pcb at the 43oh store.

Powerscope front side


Powerscope back side

Powerscope connected to Lauchpad in TX mode

Powerscope connected to Launchpad in RX mode

Goodfet 4_1 programmer and programming cable with pogo pins


Links:

Buy Powerscope pcb
Designer thread
Powerscope Code and Info page
Goodfet programmer

Wednesday, 10 July 2013

Spectrum analyzer Part VII The Frame

To be able to test the modules and later insert them in a proper case they have to be secured somehow.
Scotty suggested a double sided raw pcb and to cut holes into it where the future modules will be placed.

Since I did not have such a pcb in my stock but was fortunate enough to find some brass profiles I used these to build my frame.

I cut them to size using the following template on Scotty's website and hardsoldered them.
Unfortunately  they get pretty messed up during the soldering process.
To clean them up you have to bath them in a 40% sulfuric acid solution and wipe them clean afterwards using a polishing cloth.
The last step is to drill mounting holes into the frame's edges.


Frame after soldering
Frame after cleaning
 Links:
Spectrum analyzer Part I Controller board
Spectrum analyzer Part II Phase Detector
Spectrum analyzer Part III ADC 16
Spectrum analyzer Part IV Logarithmic Detector
 
Spectrum analyzer Part V Master Oscillator
Spectrum analyzer Part VI DDS 

Spectrum analyzer Part VI DDS Module(s)

Description (copied from Scotty's web page)

The DDS module is designed and configured with a filter and squaring circuit in the DDS A path.  The filter shown is a 10.7 MHz crystal filter with a 15 KHz bandwidth.  
The squaring circuit of U3 will output a CMOS level, capable of driving a 50 ohm line (J4).  
J3 output is an unfiltered output of the DDS B and will contain all harmonics and aliases of a normal DDS output.  Its output power level is approximately -8 dBm.
For best results, the Clock Input at J1 should be a 5 volt peak to peak square wave, but it will operate at a much lower input.  R3 determines the input impedance of the module.  The input clock frequency must be between 1 MHz and 125 MHz, although the AD9850 is somewhat underrated.

Build process

Soldering the dds chip is somewaht tricky, good magnifying glasses are a must.
Since the DDS chips are serially programmed, I use a different pcb (which I got in a group buy) with only 5 inputs.I think it was routed by Sam Wetterlin but I am not sure.
Studying the schema carefully is highly advisable since there is always a chance that components are placed in a different location.
Because I am building the complete" analyzer, I had to solder two of this modules, the second one is used in the tracking generator.

One of the coming blog posts will be about testing the DDS module and how to shield a Slim module properly.



DDS module rev D with serial input only

 Links:
Spectrum analyzer Part I Controller board
Spectrum analyzer Part II Phase Detector
Spectrum analyzer Part III ADC 16
Spectrum analyzer Part IV Logarithmic Detector

Spectrum analyzer Part V Master Oscillator

DDS Module

Spectrum analyzer Part V Master Oszillator

Description (copied from Scotty's web page)

The Master Oscillator, contains a 64 MHz oscillator and 3 buffered line drivers.
Each output is 5 volt CMOS that can drive a 50 ohm line that is terminated with either, a high impedance load, or 50 ohms.  A 33 ohm resistor is shown as a series element in each output.
The frequency will drift with temperature. I was able to test only one sample. It had a positive frequency/temperature coefficient of .15 parts per million per degree F (9.6 Hz / 1 deg F)

The build was fairly easy you just have to take care of possible cold solder joints around the crystal oscillator. This kind of packaging easily produces cold solder joints.

Since the unit is already tested I already shielded it.

Master Oscillator rev B

MO back side

Side view of shielded oscillator
 Links:
Spectrum analyzer Part I Controller board Spectrum analyzer Part II Phase Detector   Spectrum analyzer Part III ADC 16 
Spectrum analyzer Part IV Logarithmic Detector 

Master Oscillator