Gilbert Cell Mixer in LTSpice…

December 29, 2009 | General | By: Mark VandeWettering

Well, I went ahead and built the Gilbert cell mixer from the Elmer 101 pages in LTSpice. I’m not sure I understand the biasing that it uses, but it does seem to work. I’ll think about it more later.

gilbert

Bounced a signal through HO-68

December 29, 2009 | Amateur Radio, Amateur Satellite | By: Mark VandeWettering

This morning I got another chance at HO-68, the newest Chinese amateur satellite that was operating in FM mode. I wasn’t sure what the problem was: I had the PL tone setup right and the signals seemed strong enough. On this pass, I fought to try to find a slot to transmit, and finally at the end of the pass, confirmed that I was indeed able to get into the bird. I made the following recording of the pass, and you can hear me in the downlink twice near the end of the recording, calling (without response) to VA7VW and W7JPI. The satellite was actually configured to turn off its transponder while it was still high in the sky here (it is on for a pass over Europe, the North Pole, and then down over the states) so I think I was the last person active before it went off.

2009-12-29-HO68-FM, recording by K6HX in CM87

Elmer 101: Understanding the SW-40+

December 29, 2009 | Amateur Radio | By: Mark VandeWettering

I was surfing around the web today looking for an LTSpice model for the NE602, and came across the Elmer 101 FAQ, which is basically an explanatory supplement for the Small Wonder Labs SW40. I haven’t read this carefully yet, but it looks awesome, including much discussion of how the various circuits were designed and work, along with hints on how you might simulate them with PSpice (or LTSpice, presumably).

The Hila Trebuchet

December 28, 2009 | Link of the Day | By: Mark VandeWettering

I like trebuchets. Former Pixarian and RenderMan engineer Dan apparently located some plans for building small trebuchets from the Hila Science Camp:

The Hila Trebuchet.

And here’s a short YouTube video showing him test firing four of them. Cool!

Bonus video (unrelated to the above): Dan also posted a link to this video, showing video shot from an RC airplane while people on the ground tried to shoot at it with fireworks:

Modelling the NT7S code practice oscillator with LTSpice

December 27, 2009 | Amateur Radio | By: Mark VandeWettering

As I was chatting on the QRP Echolink conference tonight, the subject of code practice oscillators came up.   I think it was Bob, AD7BP who first mentioned the  NT7S Code Practice Oscillator which I hadn’t seen before, but seemed like a very simple and easy to assemble circuit.  We also discussed the fact that the latest issue of QST has started to use LTSpice in their Hands On Radio column.   As I was waiting for my turn at the round table, I went ahead and entered the circuit into LTSpice to see how it worked.     Here’s the schematic I came up with.

nt7s

Go ahead and click on it to make it bigger.   There are some small changes.    I went ahead and added a load resistor R9 (I set it to 32 ohms here, with the idea that the oscillator would be hooked to a set of low impedance earphones) and instead of modelling the key switch, I instead powered it with a pulsed voltage.   I was mainly interested in seeing what the shape of the output signal was, so I set it up to a transient analysis.   Sure enough, it generates a nice sine wave.    I set the input pulses to be about 50ms long, which should be about the same as the dits at 24wpm.

Here’s the resulting simulated circuit:

NT7S Code Practice Oscillator Waveform

NT7S Code Practice Oscillator Waveform

Running an FFT on this output data shows that the oscillator frequency is right around 680 Hz, with an output power of about 0.5mw, and the second harmonic over 20db down, and the 3rd harmonic 30db down.   I’d say that qualifies as a pretty reasonable waveform.  I thought that the output power was a bit low, but the oscillator is normally used with either ear buds, or with an external amplifier.   I suspect it will work reasonably well.

It was a fun experiment in using LTSpice.

Addendum: It dawned on me that simulating the keying by pulsing the input voltage wasn’t entirely correct: in the original circuit, the keying is provided by grounding the 560 ohm resistor, while power is continuously applied.   Even intuitively, one might see how that makes a difference, because various capacitors in the circuit will remain continuously charged.   This morning, I decided to go back to a straight DC power supply for Vcc, but then installed a small switching transistor between the 560 ohm resistor and ground, and fed <em>that</em> with a pulse through a current limiting resistor.   The waveform cleans up a bit at the beginning: we have a nicely shaped ramp up, without the overshoot that we saw previously.

Addendum: I was wondering if I could use this information to find out what this circuit would really sound like: in other words, I wanted to convert the raw LTSpice output into a .WAV file that you could play back on your PC.   It turns out that LTSpice can export the waveform in an ASCII format, which includes a bunch of lines which have two numbers: a time, and a value.   The slightly annoying thing is that the times are not evenly spaced.   So, I wrote a tiny chunk of Python that takes in this file, and resamples it to evenly spaced times.   I write this out again as an ASCII file, adding a small header so that the “sox” sound utility can read it, and convert it into a wav.    I then use my normal “lame” command line mp3 encoder to convert it into an mp3 file.

The following sound file was converted from the real data, and consists of three groups of ten dits, sent at 24 words per minute, with some space in between:

Simulated sounds of the NT7S code practice oscillator

I also found out that sox can actually draw spectrograms of wav files. It’s not quite as versatile as the homebrew code that I wrote, but it works. Here, the individual dits kind of run together, but it shows that the second harmonic is at least 40db below the primary frequency, so the dits are pretty clean:

Spectrogram of the NT7S Code Practice Oscillator

Spectrogram of the NT7S Code Practice Oscillator

Movie Review: Sherlock Holmes

December 27, 2009 | General | By: Mark VandeWettering

I’ve mentioned before that I’m a pretty big fan of Sherlock Holmes. Every couple of years, I dust off my copy of his stories and read them, or load them as audio books onto my iPhone and listen to them all over again. I could go on and on, but let’s just say “I’m a fan”, probably in a way that differs in relatively small degrees from fans of Marvel comics, or DC comics, or Star Wars, or Star Trek.

So, it was with some trepidation that I went to go see the new Christmas release of Sherlock Holmes starring Robert Downey Jr, Jude Law and Rachel McAdam. It’s never easy to see something that you hold in such esteem “reinterpreted”. I’m pleased to say that on the whole, I found their reinterpretation to be reasonable, if not entirely faithful to the original corpus of work. The only truly serious deviation would be the introduction of Irene Adler as romantic interest and as a thief. Irene Adler makes an appearance in Conan Doyle’s first Sherlock Holmes story, A Scandal in Bohemia, which begins:

To Sherlock Holmes she is always the woman. I have seldom heard him mention her under any other name. In his eyes she eclipses and predominates the whole of her sex. It was not that he felt any emotion akin to love for Irene Adler. All emotions, and that one particularly, were abhorrent to his cold, precise but admirably balanced mind. He was, I take it, the most perfect reasoning and observing machine that the world has seen, but as a lover he would have placed himself in a false position. He never spoke of the softer passions, save with a gibe and a sneer. They were admirable things for the observer — excellent for drawing the veil from men’s motives and actions. But for the trained reasoner to admit such intrusions into his own delicate and finely adjusted temperament was to introduce a distracting factor which might throw a doubt upon all his mental results. Grit in a sensitive instrument, or a crack in one of his own high-power lenses, would not be more disturbing than a strong emotion in a nature such as his. And yet there was but one woman to him, and that woman was the late Irene Adler, of dubious and questionable memory.

This basic tenet of the psyche of Sherlock Holmes is tragically violated in this interpretation, where there is a romantic back story between Adler and Holmes. I understand why a screenwriter might choose to introduce this in the interest of marketability, but I think it rather seriously undermines the basic premise of all the Sherlock Holmes stories. There are a number of other subtle variances from the canonical tales, but none seem as serious to me.

But I tried to drop my rigid requirements for faithfulness, and view the movie in the same way that the recent reinterpretation of Star Trek by J. J. Abrams might be viewed: are the characters interpreted in a rich, robust way which isn’t completely at odds with the original characters. And, with the exception I listed above, I’d say “yes”, but not as successfully as was done with Star Trek. Downey Jr. and Law give solid performances, but not inspired ones (we’ve seen better work from both of them). I found Rachel McAdams to be almost a distraction from the plotline, and one that really doesn’t pay off emotionally or even structurally. There are a couple of very odd continuity changes in the movie which I found inexplicable (and unable to explain without giving away too much of the plot), but on the whole, I still enjoyed the film.   If you want to see a truly great, faithful adaptation of the original stories, stick to the  version starring  Jeremy Brett and David Burke:

Sherlock Holmes (1984 TV Series) – Wikipedia, the free encyclopedia

But if you want to see some appealing, attractive and talented actors give decent performance in a decent but not outstanding script, and if you can overlook the deviations from the original, you’ll probably be entertained and amused enough to justify the ticket price.

I give it a 7 out of 10.    If I was less of a nutcase over Sherlock Holmes, I might give it another point, but I think that even barring my adoration for the original material, there are some issues with the script and story which kept it from being a stronger film.    When I saw <em>Iron Man</em>, I was thinking about why I liked it afterwards, and had a difficult time describing why I enjoyed it, and this movie is similar, except with perhaps a little less compelling action sequences, and an even less convincing love story.  Still, it’s an amusing time at the movies.

A Practical Guide to Sous Vide Cooking

December 26, 2009 | Cooking and Recipes | By: Mark VandeWettering

Okay, I’ll admit it: I like cooking, and I’ve begun to read a bit upon the subject of so-called “molecular gastronomy”. I was also watching Iron Chef America, and saw (not for the first time) a chef use the “sous vide” technique of cooking: where a protein is sealed in a vacuum bag and placed in a temperature controlled water bath to cook. This is an interesting technique because it prevents eggs and meats from being overcooked, even with very long cooking times. The temperature simply never rises high enough to cause the chemical reactions which overcooking typically causes. You can (for instance) place eggs in 148 degree Fahrenheit water for 75 minutes, and they won’t overcook. If you place an egg in 135 degree Fahrenheit water for at least 75 minutes, you can pasteurize an egg (it won’t solidify).

Anyway, there is a lot to this, and I’d been thinking I should look up more details on this technique. And of course, the Internet delivers.

A Practical Guide to Sous Vide Cooking.

Lots of interesting stuff here, including instructions on cooking beef, pork, fish and eggs, and important food safety considerations.

Don’t worry, I’ll be back to radio stuff soon.

Christmas… and Radio!

December 25, 2009 | Amateur Radio | By: Mark VandeWettering

Yep, it’s Christmas again, and I’m such a geek, I can imagine all sorts of things that link it back to radio stuff. If you follow the link below, you’ll find that one of the first (if not the first) audio broadcasts was made on Christmas Eve, 1906, by Canadian scientist Reginald Fessenden. These first radio transmissions were made down at the very bottom of the radio spectrum, at frequencies of just a few kilohertz, and were produced by an alternator, which served as a mechanical oscillator to produce continuous waves. Very cool. You can read more about Fessenden on his Wikipedia page:

Reginald Fessenden – Wikipedia, the free encyclopedia.

Oh, and Merry Christmas!

My first attempt at the FM transponder on HO-68

December 24, 2009 | General | By: Mark VandeWettering

The new Chinese amateur radio satellite, formerly XW-1, now designated HOPE-1 or HO-68, made a pass with its FM transponder active around 10:00AM local time here. I was unable to get a signal through, no doubt in small part to some incompetence on my part, but also judging by the amount of doubling and piling on, from the virtual assault of RF that it was bombarded with. Nevertheless, I did get a pretty good recording of 12 minutes of the pass. The quickness with which it faded makes me believe that its transponder was simply deactivated, rather than just gone over the horizon, but I haven’t had a chance to go back to double check. As you will hear, there is no difficulty at all hearing the satellite: it’s very loud.

MP3 recorded using my Kenwood TH-D7AG and an Arrow Antenna

Gutenberg Gem: The Adventures of Sherlock Holmes, by Sir Arthur Conan Doyle

December 24, 2009 | Gutenberg Gems | By: Mark VandeWettering

Yes, Christmas is upon us again, and this year we are treated to a movie release about a character near and dear to my own heart: Sherlock Holmes. While I am rather fond of Robert Downey Jr., Jude Law, and even Rachel McAdams, I can’t help but think that this reinterpretation of the classic stories is going to make more than a little uncomfortable. If you enjoy the classic Sherlock Holmes, you can do worse than reread the originals, and in particular The Adventure of the Blue Carbuncle which appropriately enough, takes place on the second morning after Christmas, when Watson arrives at Baker St. to wish Holmes “the compliments of the season”.

The Project Gutenberg eBook of The Adventures of Sherlock Holmes, by Sir Arthur Conan Doyle.

If you’d rather have an MP3 of the classic story, try this excellent version that is also part of Project Gutenberg’s collection.

The Adventure of the Blue Carbuncle, part one.
The Adventure of the Blue Carbuncle, part two.

Milhouse takes Quiz #10 – Double Cross

December 22, 2009 | Checkers | By: Mark VandeWettering

Checker expert Jim Loy has a number of quizzes on his website, including the following one that I found as part of my earlier post on the Double Cross opening:

Quiz #10 – Double Cross.

Here are the moves that milhouse chose with a hard time limit of 30 seconds per move, along with the resulting points awarded…

5-9 (+5),16-20 (+5), 8-11 (+5), 11-16 (+5), 5-9 (+5), 5×14 (+3), 7-11 (+2), 6-9 (+5), 7-10 (+10), 1-6 (+10), 9-13 (+10), 3-7 (+15), 13-17 (+10), 6×13 (+5)

The moves marked in bold are moves which differed from Jim’s main line.   Milhouse scores an impressive 95 out of a hundred.  The only move which causes it to not score a perfect 100 is the position where Milhouse chose to play 7-11 instead of the preferred 4-8 line.

Let’s look at the position…


Red to move, Jim suggested that 4-8 is the right move, Milhouse played 7-11.   Who is right?

Red to move, Jim suggested that 4-8 is the right move, Milhouse played 7-11. Who is right?


I’ve just begun to toy around with analyzing this, but both Milhouse and Cake seem to not like the response that is given in the line. Milhouse isn’t smart enough to see the line as won when it tried 7-11, but after 4-8 22-18, it sees itself as up a full man in only a 17 ply search.

I’ve sent an email to Jim Loy for more expert analysis. We’ll see what he has to say about the matter.

But still, 95/100 is pretty good. 🙂

Dusting off my checkers program Milhouse…

December 22, 2009 | Checkers | By: Mark VandeWettering

I noticed that Martin Fierz released a new version of his Checkerboard program, so I thought I’d set it sparring against my own program, milhouse. The Cake engine it ships with walks all over my program, but it managed this win against Simple Checkers.

[Event ""]
[Date ""]
[Black "Milhouse"]
[White "Simple Checkers"]
[Result "1-0"]
1. 9-14 23-18 2. 14x23 27x18 3. 5-9 32-27 4. 12-16 27-23 5. 16-20 23-19 6. 20x27 31x24 7.
10-14 26-23 8. 7-10 24-20 9. 8-12 28-24 10. 1-5 22-17 11. 9-13 18x9 12. 5x14 25-22 13. 6-9
23-18 14. 14x23 22-18 15. 13x22 21-17 16. 23-26 30x23 17. 3-8 17-14 18. 10x17 19-15 19.
2-7 23-19 20. 17-21 18-14 21. 9x18 15-10 22. 7x14 19-15 23. 22-25 29x22 24. 18x25 15-10
25. 25-30 10-6 26. 14-18 6-1 27. 18-23 1-6 28. 23-27 6-10 29. 27-32 10-14 30. 12-16 14-18
31. 32-28 18-14 32. 28x19 14-10 33. 30-26 10-7 34. 19-15 7-10 35. 15x6 *

Addendum: I did some quick analysis using both Cake and Milhouse this morning, trying to locate the bad moves that each engine made. I haven’t stared at it too deeply, but it appeared that Simple Checkers walked into a poor opening which I suspect that if I looked hard, I could find in one of my checkers references. Cake finds the first 5 moves in its book, but then Simple Checkers plays 5. … 23-19, which is out of book. Still, upon a 31 ply search, Cake scores the position at -126, which is over a full man down, which would be tough to overcome.


 White to move, but is already behind. Simple Checkers has walked into a poor opening.   Cake and Milhouse both agree that this position is weak, and White is already almost a full man down.

White to move, but is already behind. Simple Checkers has walked into a poor opening. Cake and Milhouse both agree that this position is weak, and White is already almost a full man down.


Addendum: As I suspected, the opening is a known weak one for White, and it begins right back at the second move of the game, although the opening is still part of the standard 3 move opening set, so some possibilities remain. The opening is called the Double Cross, and is considered weak for White (in particular, 1. … 23-18 is not considered a proper response.) Jim Loy has a nifty page full of openings with some insightful commentary, and shows a Tinsley/Fortman game where this opening was featured, with an interesting cook played by Tinsley.

Addendum: Jim Loy has some interesting analysis of the Double Cross opening here.

Gutenberg Gem: Letters of a Radio-Engineer to His Son, by John Mills

December 20, 2009 | Amateur Radio, electronics, Gutenberg Gems, Public Domain Resources | By: Mark VandeWettering

I love old books, even  on technical subjects like radio.  Often, by looking at the books of the past, we find them more accessible (because there was less knowledge, they assume less as a precursor) and also possess considerable historical interest.

Letters of a Radio-Engineer to His Son is a nice little book by John Mills Sr. to his son back in 1922, which begins simply with:

My Dear Son:

You are interested in radio-telephony and want me to explain it to you. I’ll do so in the shortest and easiest way which I can devise. The explanation will be the simplest which I can give and still make it possible for you to build and operate your own set and to understand the operation of the large commercial sets to which you will listen.

I’ll write you a series of letters which will contain only what is important in the radio of to-day and those ideas which seem necessary if you are to follow the rapid advances which radio is making. Some of the letters you will find to require a second reading and study. In the case of a few you might postpone a second reading until you have finished those which interest you most. I’ll mark the letters to omit in this way.

All the letters will be written just as I would talk to you, for I shall draw little sketches as I go along. One of them will tell you how to experiment for yourself. This will be the most interesting of all. You can find plenty of books to tell you how radio sets operate and what to do, but very few except some for advanced students tell you how to experiment for yourself. Not to waste time in your own 4experiments, however, you will need to be quite familiar with the ideas of the other letters.

It’s a delightful little book, which talks about electrons, and waves, capacitance and inductance, audion tubes and continuous waves.  It’s not mathematical, but neither is it just handwaving.  It strikes a nice balance, and should be accessible to anyone with basic science knowledge. Check it out.

The Project Gutenberg eBook of Letters of a Radio-Engineer to His Son, by John Mills.

Actor Mickey Morton

December 16, 2009 | General | By: Mark VandeWettering

Mickey Morton had a brilliant career.   Can anyone guess why I might have stumbled across his curriculum vitae today?

Hint: I’ve just watched arguably the worst two hours in television history.

Chinese Amateur Satellite XW-1 launched, beacon has been heard…

December 15, 2009 | Amateur Satellite, General | By: Mark VandeWettering

This morning, a quick check of my email and blog roll indicated that the Chinese had launched XW-1, probably the most interesting amateur satellite to launch this year (sorry SO-67).    It carries a payload with both linear and FM transponders, and it seems to have a higher orbit than current LEO satellites.    It should orbit around 1200km, whereas the popular AO-51 has an altitude of  only 700-800km, which should translate into a significantly larger footprint.

A couple of amateurs have recorded MP3s of the CW telemetry downlink already.

Here’s one.

And another.