tag:blogger.com,1999:blog-11205850340741080302024-03-16T22:26:22.314-07:00Ravings of an old TechieLilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.comBlogger25125tag:blogger.com,1999:blog-1120585034074108030.post-66182657775991665662023-01-22T13:46:00.002-08:002023-01-22T17:29:26.095-08:00CWvox, A voice keyer for Morse C<p> </p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjaD70qj1mDY9MDzFtNTW35ZYvAwgb2tk2BnpWmmQmpNOdwXn0gSzm6GnxFMp0y9DjZyrbETno7XbiJ9W-o7vy77esUVMY1HyUzrVyJfo3BVnzZ5uWQl9fM2wuuql7uaPsbbudicHiO_Th8q91prbnYspBm3L847J60-Zw086CK2KegkHHubnR6s_rZDw/s800/CWvox%20card.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="600" data-original-width="800" height="428" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjaD70qj1mDY9MDzFtNTW35ZYvAwgb2tk2BnpWmmQmpNOdwXn0gSzm6GnxFMp0y9DjZyrbETno7XbiJ9W-o7vy77esUVMY1HyUzrVyJfo3BVnzZ5uWQl9fM2wuuql7uaPsbbudicHiO_Th8q91prbnYspBm3L847J60-Zw086CK2KegkHHubnR6s_rZDw/w571-h428/CWvox%20card.png" width="571" /></a></div><br /><p></p><p><br /></p><p> Morse Code, often referred to by Ham Radio folks simply as CW, is usually sent using a hand operated switch called a 'Key'. You've seen these somewhere, the old telegraph key. Another device called a 'Keyer' can automatically generate the long and short tones, the dashes and dots Morse is comprised of. A keyer will use a set of paddles, two parts that sit between your index finger and thumb. Press one and a series of long tones is generated, press the other and a series of short tones is generated.</p><p> These two methods are by far the most common way of operating a transmitter to send Morse over the air. They require a bit of practice to get clean code. Orderly tones with proper spacing between them, slightly longer spacing between letters, and even longer spacing between words.</p><p> But what if someone has a problem with their hands, loss of dexterity with their fingers, injury, stroke or disease that prevents them from using a key or paddles? Why not use the voice?</p><p> Every CW operator I've ever met can speak Morse code. We say the words, "Dah" for a dash, and "Dit" for a dot. The naturally spoken length of each corresponds to the correct ratio in length of the long and short tones of proper code. And speaking is one of the most natural things we do.</p><p> Sure, there are other options. A puff key, consisting of a straw that's blown into to 'key' the transmitter. A foot switch. A squeeze switch if you can still clutch your fist reliably. However, these require retraining your brain, can be clumsy at first, maybe hard to ever get clean code with.</p><p> So I set out to design a voice keyer. A simple method of following the voice of spoken Morse and keying a transmitter right along with it.</p><p> I had a few design goals in mind. Keep the circuit simple and cheap. Easy to build and reliable. In order to produce the cleanest keying possible, I decided to do the work in software with an arduino, giving me precise control over the keying for nice clean transmission.</p><p> Here is the schematic: You can right-click on it to download.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi7XIih-ZcSPy4GiIgVHqkH2xPd86NeZnHXXcDU-r8Zh7thZO93p5pylZ_TQKrymIg9SCNpgl04rsowalfTzgk_hpttcyaYlX8daDRu1mwaVJGQIhHEE0IhYTab7sOs6tw_BWda4j0eRCUqckbgiEcKnUzuLoqFLnMfLY-yF62fOvq0PiaZ-pZWmxfBng/s1344/Schematic.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="816" data-original-width="1344" height="380" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi7XIih-ZcSPy4GiIgVHqkH2xPd86NeZnHXXcDU-r8Zh7thZO93p5pylZ_TQKrymIg9SCNpgl04rsowalfTzgk_hpttcyaYlX8daDRu1mwaVJGQIhHEE0IhYTab7sOs6tw_BWda4j0eRCUqckbgiEcKnUzuLoqFLnMfLY-yF62fOvq0PiaZ-pZWmxfBng/w626-h380/Schematic.jpg" width="626" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><br /></div><br /><p>Circuit description:</p><p> The circuit can be powered from a 9 volt battery, it only draws around 30 ma when idle. The input voltage can be from 7 to 12 volts since we use the voltage regulator on the arduino to provide 5 volts for the rest of the circuit.</p><p> Most headsets use a condenser microphone element which will have a built in preamp that needs a small amount of power to operate. R1 provides that power. C1 then blocks the DC but passes the audio to a simple transistor amplifier.</p><p> Q1 is the amplifier. It takes the small, 80-120 millivolt audio from the mic and amplifies it to around 4 volts peak to peak. D1 then clamps the negative swings, leaving us with a purely positive waveform. C3 then smooths the audio to a less choppy DC voltage the arduino can sense and operate on.</p><p> R5 is a linear 10K pot that allows us to set the sensitivity of the mic. You don't want room noise interfering after all.</p><p> Q2 is a simple transistor switch for keying the radio in CW mode. D2 provides transient protection from any spikes that might come in from the radio. Likewise C4 provides a bit of RF protection, bleeding any stray RF to ground.</p><p> SW2 cuts off the keying action when it's not needed. i.e. while adjusting the sensitivity pot, or talking to someone else in the room, etc.</p><p> The LED performs two functions. It's a power light, at around 40% illumination, and switched to full brightness when the radio is keyed as a visual indicator. It's also useful for setting the sensitivity without actually transmitting.</p><p>My completed prototype:</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgMcmttS9bUFqnBsvhCda9sHTgxVuQCK8UjItdt328jmFYs_H1Zs1pdwxii6CDtfpVqpshNjunN_ActlWpwDIsq3xkrBaEGjvu8KrlfDoTQP2-rowKnrkf5tZdQf1s7jXZRck5KwUpZfFBOHu94f59hjRy0dtwPi8N--jE6jsX1ioTcF-P1IoDsMvelWw/s2048/Built%20into%20a%20case.JPG" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1575" data-original-width="2048" height="374" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgMcmttS9bUFqnBsvhCda9sHTgxVuQCK8UjItdt328jmFYs_H1Zs1pdwxii6CDtfpVqpshNjunN_ActlWpwDIsq3xkrBaEGjvu8KrlfDoTQP2-rowKnrkf5tZdQf1s7jXZRck5KwUpZfFBOHu94f59hjRy0dtwPi8N--jE6jsX1ioTcF-P1IoDsMvelWw/w486-h374/Built%20into%20a%20case.JPG" width="486" /></a></div><br /><p><br /></p><p> The software is available on my github page linked below. It's well commented and should be easy to follow.</p><p><span> </span><span> </span><span> </span><span> <a href="https://github.com/loughkb/CWvox">(github arduino software link)</a></span><br /></p><p><span>Software description:</span></p><p><span> At the simplest, the software senses audio from the amplifier and turns on the keying line if the threshold of the audio exceeds the sensitivity value read from the pot. When audio is below that threshold, it turns off the keying line.</span></p><p><span> However, in order to assure clean edges, it also uses timing to 'frame' the keyed event. There is an interrupt routine to provide a timer with a resolution of 1 micro-second. Each time audio is detected, the timer is reset. After some experimentation, I settled on a value of 18 micro-seconds.</span></p><p><span> The voice tails off at the end of the word. That would lead to a short period where keying might rapidly switch on and off. That would be sloppy and probably hard on the transmitter. having that 18 micro-second hang time cleans up the end of the element for nice clean keying.</span></p><p><span>Conclusion:</span></p><p><span> It's a simple circuit to put together with commonly available parts. Should be easy for anyone with basic electronic skills to assemble. I have done a project video, including demonstration of it in use, linked below. I hope it will help someone who enjoys Morse but has had that joy lost due to circumstances. It may also be of interest to CW ops in general. In use I have discovered that it feels completely natural speaking the code and almost less fatiguing than it is to physically operate a key. And it's kind of neat and fun too!</span></p><p><span> <a href="https://youtu.be/GpDYJO81-LE"> (Full project video with demonstration)</a></span></p><p><span> Thanks for your attention and as we hams say, 73. (best wishes)</span></p><p><span>Kevin, KB9RLW</span></p>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com0tag:blogger.com,1999:blog-1120585034074108030.post-46062829673386616012021-11-10T12:24:00.012-08:002023-01-21T15:16:57.351-08:00The CW flea. A simple Morse transmitter using modern electronics.<p></p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjWjqLoHUnMfiLGv4h9_UWwrlG46WAw7EkpPy1QdYPTKP8Bn7asoyQYtmHftsZg65h4CeoMfZE9NjfnCNkCh7qr_6xJ5v5k7RJ5TnGn3FB3qZt_O7hAB56-x2vTF5knp8v7Jd7zuio_Dwt1/s640/CWflea+logo.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="243" data-original-width="640" height="122" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjWjqLoHUnMfiLGv4h9_UWwrlG46WAw7EkpPy1QdYPTKP8Bn7asoyQYtmHftsZg65h4CeoMfZE9NjfnCNkCh7qr_6xJ5v5k7RJ5TnGn3FB3qZt_O7hAB56-x2vTF5knp8v7Jd7zuio_Dwt1/s320/CWflea+logo.png" width="320" /></a></div><br /> <p></p><p>(NOTE: there is a commercial version of this transmitter available through Zachtek at the following link.<br />https://www.zachtek.com/product-page/cw-flea-transmitter)</p><p>Way back in the early days of Amateur Radio, tinkerers would often build their own simple transmitter to use along with a receiver they probably already had. They'd scrounge parts where they could and build something like a crystal controlled oscillator with enough power to be heard over the air.</p><p> At the time, the tools available to such tinkering folk were vacuum tubes and they'd put together something like this.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhOTLvvWSPE1H7fhdH6cYd5tFWGzE3-T2MoEoXWRYgMdrRUHYYEu62Sf6rLqAEGHOFl3XgBiC1J88ptk-uWgTgdkcejKCZ_KrN7yGau2XlEcr7dx_UPDoDoZjLTny5NVXWjvVZ5yxvThMoj/s1280/early+home+built+tx2.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="720" data-original-width="1280" height="271" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhOTLvvWSPE1H7fhdH6cYd5tFWGzE3-T2MoEoXWRYgMdrRUHYYEu62Sf6rLqAEGHOFl3XgBiC1J88ptk-uWgTgdkcejKCZ_KrN7yGau2XlEcr7dx_UPDoDoZjLTny5NVXWjvVZ5yxvThMoj/w491-h271/early+home+built+tx2.jpg" width="491" /></a></div><br /><p> Usually, they would have an external antenna switch, allowing them to switch their antenna from the receiver to their transmitter, using the receiver as a side-tone to monitor their transmission while sending Morse code.</p><p> In my youth, in the 1970's through early 1980's, we didn't have to work with tubes any more, we had transistors! Small discrete components that operated at lower and safe voltages. Some time ago, I built a simple transmitter using the tools I tinkered with, seen here.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEimOxo8K27gPgnDGVlXcs33LZeG5NYZDo-n2kdx31FLT4NrJw_PE3j5PmfjLlCfdo7N3CdDGICmBKmjm6AOermTspxfCB5ytyMmDC8tAHNv8U5bAvP1xGVWQCwe3wjL3iet2tdhteXjqxKL/s2048/close+up+my+tx.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1536" data-original-width="2048" height="339" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEimOxo8K27gPgnDGVlXcs33LZeG5NYZDo-n2kdx31FLT4NrJw_PE3j5PmfjLlCfdo7N3CdDGICmBKmjm6AOermTspxfCB5ytyMmDC8tAHNv8U5bAvP1xGVWQCwe3wjL3iet2tdhteXjqxKL/w452-h339/close+up+my+tx.jpg" width="452" /></a></div><br /><p> It only puts out a few hundred milliwatts, but that's enough. I've made many contacts over the air with it.</p><p> These days, the tinkerers have micro-processors mounted on tiny boards with I/O pins and easy software tools. They build robots, flying drones, all kinds of advanced projects that would look like science fiction to those from earlier times.</p><p> So I had the idea to build that early simple transmitter, only using the modern tools available today. A way that new hams could make their own simple transmitter with the things they're used to working with. I call it the CW flea. CW meaning Continuous Wave. When keyed down, it produces a continuous RF signal that you switch on and off to send Morse with.</p><p> Here is the block diagram of the flea. (click for larger image, right-click to download.)</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguZ2unCq38mpmpIeHsco7GGT8cBdXEzKoRNpQ1d6t96FcGd2jjWM-KGDGNeCZbuDlwcqkvlVU1-pwAfJLWAsdR4ASj4NlLd7W-O_mS83Fhng8WrV0BVYw9XCZXiC2N10ESIfJb160BQ6lB/s1344/Block+diagram.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="816" data-original-width="1344" height="375" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguZ2unCq38mpmpIeHsco7GGT8cBdXEzKoRNpQ1d6t96FcGd2jjWM-KGDGNeCZbuDlwcqkvlVU1-pwAfJLWAsdR4ASj4NlLd7W-O_mS83Fhng8WrV0BVYw9XCZXiC2N10ESIfJb160BQ6lB/w619-h375/Block+diagram.jpg" width="619" /></a></div><br /><p> And here is the main schematic. (click for larger image, right-click to download.)</p><p><b><u>WARNING: Although I shouldn't have to say this. If you build it, be sure you wire the relay right and label your antenna and receiver jacks clearly. Never plug your receiver into the antenna jack! Transmitting into your receiver would damage it.</u></b> </p><div><br /></div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/a/AVvXsEilVofb_8tqRoC907eHkrTqmrT5AiH6Cr7T6lKCMPeYcgqq66qF8gADH4h8MWt0-85ZYhMMKoKor4d3Xch0hl9MNNE9cspw8cPDMqYKfBh3q-ERmEg4OBuyoun-ujDn4Mz1vZQueb4VIOKFp4dxHsX2HEmYjjNN3vugCPMMTOqeg7J5M0wRmNe7DHgtBw=s1344" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="816" data-original-width="1344" height="357" src="https://blogger.googleusercontent.com/img/a/AVvXsEilVofb_8tqRoC907eHkrTqmrT5AiH6Cr7T6lKCMPeYcgqq66qF8gADH4h8MWt0-85ZYhMMKoKor4d3Xch0hl9MNNE9cspw8cPDMqYKfBh3q-ERmEg4OBuyoun-ujDn4Mz1vZQueb4VIOKFp4dxHsX2HEmYjjNN3vugCPMMTOqeg7J5M0wRmNe7DHgtBw=w589-h357" width="589" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><br /></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/a/AVvXsEh1P_8j_JL4r6NOncOEx-FwDEfNR3fvoHy0H4DAf9AzWfekdzvYj7rqKoHnSlRDLIjUHK4RN9tsGC4-qVoeX7Ncheu_b0VTC2abtFosNauQcuBCbKGcah7rSecXgdhfqQ6noa3VGMJsw7CxHBKowbAEVqQR6n7mPMAXJ7UoklDieSTJn5ABcKXQ5tJleg=s1344" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="816" data-original-width="1344" height="355" src="https://blogger.googleusercontent.com/img/a/AVvXsEh1P_8j_JL4r6NOncOEx-FwDEfNR3fvoHy0H4DAf9AzWfekdzvYj7rqKoHnSlRDLIjUHK4RN9tsGC4-qVoeX7Ncheu_b0VTC2abtFosNauQcuBCbKGcah7rSecXgdhfqQ6noa3VGMJsw7CxHBKowbAEVqQR6n7mPMAXJ7UoklDieSTJn5ABcKXQ5tJleg=w585-h355" width="585" /></a></div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: center;"><br /></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiiIFbGbiDGY0voU6p-kmYghP_KtEv_BRTUYWlW56iynfXRu1GMBp2WVAerg4iJNyIabehYZq1MLhvLulYh9oLCOdlJA0RbcLcWJLHXq9QkdL951gX9EqcppI26XcL4l1bj6wEoypSGpGWI/s1094/LP+filter+table+.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="731" data-original-width="1094" height="390" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiiIFbGbiDGY0voU6p-kmYghP_KtEv_BRTUYWlW56iynfXRu1GMBp2WVAerg4iJNyIabehYZq1MLhvLulYh9oLCOdlJA0RbcLcWJLHXq9QkdL951gX9EqcppI26XcL4l1bj6wEoypSGpGWI/w583-h390/LP+filter+table+.png" width="583" /></a></div><br /><p><br /></p><p> I'll build it using the off-the shelf parts available today. The micro-controller will be an Arduino Nano, widely available and built on a board with pins for all of the I/O right on the PCB. The Si5351 clock generator will be the VFO, controlled by the Arduino. It's available on a PCB as well, through adafruit or etherkit. The power amplifier is novel, borrowed from another design by a small company called Zachtek. (I'm collaborating with Harry over at Zachtek on this project, he'll be producing a ready-for-air version of the flea.) The P.A. uses a 74LS244 octal liine driver. With all 8 stages paralleled, the little chip will produce 300-500 milliwatts of power out.</p><p> Since we're dealing with RF here, a low pass filter will be required and will have to be made with a few toroids and capacitors. Along with a single NPN transistor to drive the relay, a voltage regulator and a few capacitors and resistors, the hardware build should be fairly simple to put together.</p><p> I'm focusing on simplicity so tuning the transmitter will be a bit different than commonly done. Instead of a knob and calibrated scale, tuning will be through two push buttons. </p><p> Tuning: The Si5351 has three separate clock outputs, I'll be using two of them. One will go to the P.A. and provide the actual signal to air. When you depress the code key, the arduino will switch the relay to connect the antenna to the output of the power section, also grounding the receiver output. However, when you depress one of the tuning buttons, the second output will be switched on, allowing you to hear the signal from the vfo in your receiver. One button will move the frequency up, the other, down.</p><p> You'll simply move the frequency with the buttons until you hear it in your receiver. Adjusting it for the tone pitch you're used to for CW operating, or matching the pitch of the station you wish to call. Since the CW portion of any of the amateur bands is narrow, it shouldn't take more than a few seconds to dial the transmitter in.</p><p> Since the whole thing is controlled by software, it's easy to build it for the band you wish to operate on. (It's a single band design) Since I'm releasing it as Open Source, anyone can extend it in any way they choose. I could imagine building it for two bands and adding a pair of relays to select the appropriate low pass filter automatically, for example. </p><p> The software begins with several variables that allow a builder to control how it behaves. Here's the first few lines:</p><p>// Declare variables and flags we will use in the program</p><p>int tuneup = 2; //pin number used for tuning up in freq</p><p>int tunedn = 3; //pin number used for tuning down in freq</p><p>int keypin = 7; // pin number used for key input</p><p>int relaypin = 4; //pin number used for relay control</p><p>int tunecount = 500; //delay between slow tuning and fast tuning</p><p>int tunestep = 5000; //minimum tuning step in hundreths Hertz</p><p>int tuning = 0; //flag to indicate tuning state</p><p>int tunevfo = 0; //flag to indicate tuning vfo state</p><p>int buttonup = 1; //flag for tune up button</p><p>int buttondn = 1; //flag for tune down button</p><p>int tail = 0; // The counter for the keying tail delay</p><p>int taildefault = 1000; // Default to 1 second tail, change if you want.</p><p>int keyed = 1; //flag to indicate keyed state</p><p>int keyedprev = 1; //flag to indicate previous key state after a change</p><p>int unkeyflag = 0; //flag for end of timeout switch back to RX</p><p>long freq = 1403000000; //current frequency in hundreths Hertz.</p><p>long bandbottom = 1400000000; //Lowest frequency in hundreths Hertz</p><p>long bandtop = 1407000000; //Highest frequency in hundreths Hertz </p><p><br /></p><p> As you can see, I've commented the code to make it easy to understand and work with. The bottom three lines there show the default frequency, the bottom and top of the operating range. If one were building it for 40 meters, they could simply change those to 7030000000, 700000000, and 707000000 respectively. </p><p> The full arduino sketch will be available on my github page and linked here:</p><p><a href="https://github.com/loughkb/CW-flea-arduino-sketch">https://github.com/loughkb/CW-flea-arduino-sketch</a></p><p> At the point of writing this, I have built the basics on a breadboard and just finished the software. This blog will continue to grow as the project progresses and I'll be doing videos on my youtube channel about it. Check back in a few days for updates.</p>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com1tag:blogger.com,1999:blog-1120585034074108030.post-90538617211013524272021-06-28T09:50:00.004-07:002021-06-28T09:50:17.402-07:00A simple script to get SDRPlay hardware running on Linux.<p></p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiz5UkW0BQBpe7ynM7u9zHbGM0AbAbyd-bsk8tHKKLTncTkTV7l3aSLqukRqapM4kWo-_uNOjLeUqz3_Ygjg0XvziGLXCyc8Yj9_N-DvqfPac4quUw5K_aquSXSn1RLxw4-ekNomtwZj94I/s278/rspdx.jpeg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="181" data-original-width="278" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiz5UkW0BQBpe7ynM7u9zHbGM0AbAbyd-bsk8tHKKLTncTkTV7l3aSLqukRqapM4kWo-_uNOjLeUqz3_Ygjg0XvziGLXCyc8Yj9_N-DvqfPac4quUw5K_aquSXSn1RLxw4-ekNomtwZj94I/s0/rspdx.jpeg" /></a></div><br /> Recently I contacted SDRPlay about obtaining an RSPdx unit. I wanted to look into simplifying setup under linux. They were still providing scripts based on my work from a few years ago with the RSP2. Linux has moved on, however, and the provided scripts were unreliable on recent distributions.<p></p><p> The old scripts also built several packages from source, which was problematic in some cases and took a long time to complete.</p><p> They responded positively and sent me a unit to play around with.</p><p> Have you ever approached a problem from the wrong angle, spent (wasted) lots of time and only found frustration? Yep, that's what happened. </p><p> About a year ago, SDRPlay updated their API to support their newer hardware. The newer API broke compatibility with the next layer in the software stack on linux. I found a newer version of the gr-osmosdr module, designed to support the new API and started working down that path.</p><p> This quickly lead to frustration. It required a newer version of soapysdr, version 0.8. That, in turn, required newer versions of gqrx, gnuradio, and cubicsdr. I discovered that even in the latest Ubuntu, the repositories still contained 0.7 of Soapy.</p><p> Not really surprising. A distribution is going to be built on the newest versions of things that all work together. It takes time for all packages to catch up to each other, so what we have in the latest release of linux will not necessarily include the absolute latest versions of each component.</p><p> I spent days on what was becoming an increasingly complex project, requiring more and more components to be built from source. I became quite frustrated and was about to give up and send it back when I had a thought.</p><p> A few years ago, when I first tackled the RSP2 I had, Soapysdr was fairly new. Soapysdr is a middle man. Like printer drivers in a modern os, it's a layer that contains sdr hardware drivers and presents the applications with one software interface. Soapy then translates things through it's modules for individual hardware sdrs. </p><p> I realized, it's been a few years, and just over a year since the API was updated. Maybe someone has created a newer soapy module for the new API.</p><p> YES! I found one. And it works!</p><p> So I've developed this one script to get your SDRPlay hardware working on recent debian based linux distributions. Since Cubicsdr and gqrx are both newer and directly support soapy, this means we only have to build the soapy module from source. Everything else can be pulled directly from the repositories.</p><p> This greatly simplifies things!</p><p> I've created two versions of the script. One for X86 machines, and one for Raspberry pi. You only need to run the script, reboot and you're good to go.</p><p> Below are the scripts. Choose the one for your machine, select it and copy. Open an editor on your machine and paste. Save the file to your machine as something like, "sdrplay setup.sh".</p><p> Now, right-click on the script and select properties. Under permissions, check the box to mark it as executable. Open a terminal and run the script. It will ask for your password to install things from the repositories and during the install of the API and soapy modules. If no errors are reported, after a reboot both gqrx and cubicsdr will see your SDRPlay and should work fine.</p><p>Script for X86 based machines:</p><p>#! /bin/sh</p><p>echo "First we need to make sure dependancies are installed."</p><p>echo "There may be several packages to install. This could"</p><p>echo "take several minutes to complete."</p><p><br /></p><p># Install the dependancies</p><p>sudo apt install git cmake build-essential gqrx-sdr cubicsdr libsoapysdr-dev soapysdr-tools gr-osmosdr uhd-soapysdr</p><p><br /></p><p>#Install the API</p><p>cd ~/Downloads</p><p># download the API from the SDRplay website</p><p>wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.07.1.run</p><p># change permission so the run file is executable</p><p>chmod 755 ./SDRplay_RSP_API-Linux-3.07.1.run</p><p># execute the API installer (follow the prompts)</p><p>./SDRplay_RSP_API-Linux-3.07.1.run</p><p><br /></p><p>#Get the sdrplay soapy module and build it.</p><p>cd ~/Downloads</p><p>git clone https://github.com/pothosware/SoapySDRPlay3</p><p>cd SoapySDRPlay3</p><p>mkdir build</p><p>cd build</p><p>cmake ..</p><p>make</p><p>sudo make install</p><p>echo ""</p><p>echo "If there were no errors reported, please reboot your machine."</p><p>echo "Everything should be ready to go."</p><p><br /></p><p><br /></p><p>Script for ARM based machines. (Raspberry Pi)</p><p><br /></p><p>#! /bin/sh</p><p>echo "First we need to make sure dependancies are installed."</p><p>echo "There may be several packages to install. This could"</p><p>echo "take several minutes to complete."</p><p><br /></p><p># Install the dependancies</p><p>sudo apt install git cmake build-essential gqrx-sdr cubicsdr libsoapysdr-dev soapysdr-tools gr-osmosdr uhd-soapysdr</p><p><br /></p><p>#Install the API</p><p>cd ~/Downloads</p><p># download the API from the SDRplay website</p><p>wget https://www.sdrplay.com/software/SDRplay_RSP_API-ARM32-3.07.2.run</p><p># change permission so the run file is executable</p><p>chmod 755 ./SDRplay_RSP_API-ARM32-3.07.2.run</p><p># execute the API installer (follow the prompts)</p><p>./SDRplay_RSP_API-ARM32-3.07.2.run</p><p><br /></p><p>#Get the sdrplay soapy module and build it.</p><p>cd ~/Downloads</p><p>git clone https://github.com/pothosware/SoapySDRPlay3</p><p>cd SoapySDRPlay3</p><p>mkdir build</p><p>cd build</p><p>cmake ..</p><p>make</p><p>sudo make install</p><p>echo ""</p><p>echo "If there were no errors reported, please reboot your machine."</p><p>echo "Everything should be ready to go."</p><p><br /></p>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com5tag:blogger.com,1999:blog-1120585034074108030.post-29514013557786383002021-03-21T10:28:00.002-07:002021-03-21T10:31:34.956-07:00A 6 meter cage dipole using window line.<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhGhcGIrEE4JQuKnF-ohgN7ZJT7Ncvbxwl0dAKX15WlLd07qK5-Fqgvrosm6HoLWJYDXQ4T1naWILxjvNSsOB_x775JPUbqef-7q7jd2gMRVhuH5M1XH7-XwmxcLCxswHrHxMjXBn8ijA6O/s1280/Antenna+still+SM+FB.JPG" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="864" data-original-width="1280" height="385" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhGhcGIrEE4JQuKnF-ohgN7ZJT7Ncvbxwl0dAKX15WlLd07qK5-Fqgvrosm6HoLWJYDXQ4T1naWILxjvNSsOB_x775JPUbqef-7q7jd2gMRVhuH5M1XH7-XwmxcLCxswHrHxMjXBn8ijA6O/w571-h385/Antenna+still+SM+FB.JPG" width="571" /></a></div><br /><p><br /></p><p>It's springtime here, that time of year where 6 meters occasionally opens up. And I need a decent 6 meter antenna. I'd love a beam, but I live in an RV and have very limited space. So a dipole it is.</p><p>I've long been aware of cage dipoles and their broader bandwidth verses a regular dipole. So I thought up a way to make a simple four wire cage dipole for 50 MHz. Here is the design.</p><p></p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj6Pr84ut9QZgFsRiMVm7jn1P9V87-1CBbqpCxfny9Q7JlelGXHU3kkmyaBPRZNePKCJTdsb3JW1S7zuRiGFReTpbUuDMikYQNo7ZMOT-fkrn-1-kZyBZ5e_SZ3Ci87oVGqtL2SUKPYPJti/s1344/cage+dipole+design.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="816" data-original-width="1344" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj6Pr84ut9QZgFsRiMVm7jn1P9V87-1CBbqpCxfny9Q7JlelGXHU3kkmyaBPRZNePKCJTdsb3JW1S7zuRiGFReTpbUuDMikYQNo7ZMOT-fkrn-1-kZyBZ5e_SZ3Ci87oVGqtL2SUKPYPJti/s320/cage+dipole+design.jpg" width="320" /></a></div><br /> <span> </span><span> </span><span> </span><span> </span><span> </span><span> </span><span> </span><span> </span>(Click on image for full size, then right-click on it to download.)<p></p><p>In order to test the increase in bandwidth, I initially just put a singe wire on each leg and swept it with my Blue VNA. <br /><br /></p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhmD80pJHTj4E2nHqwh7TXIDrp0tsDr284-J9c1ptCD4kbTqx1JF8m7VqRqQRlifCQPPxw8-2FLeb2D0zePcq3OPkwk1B_O33YGHF_x88VWhG05yXt7xJrYnt_f_p65F1ZZzGHwi7WpcqWl/s2048/reg+dipole+detail.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1536" data-original-width="2048" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhmD80pJHTj4E2nHqwh7TXIDrp0tsDr284-J9c1ptCD4kbTqx1JF8m7VqRqQRlifCQPPxw8-2FLeb2D0zePcq3OPkwk1B_O33YGHF_x88VWhG05yXt7xJrYnt_f_p65F1ZZzGHwi7WpcqWl/s320/reg+dipole+detail.jpg" width="320" /></a></div><div class="separator" style="clear: both; text-align: center;">(single wire dipole being measured)</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;">And here is the sweep of the single wire dipole, showing a bandwidth of 2.6 MHz between the 2:1 points. One interesting point I noticed. Modeling and literature all point out that a half wave resonant dipole will have ~74 ohms impedance at it's resonant frequency. We measured 73.8 ohms, how about that!</div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjve-TPD_kXV67oC2E71xJXz0wbdAw7GNs1ee2gE2m76_UuUxM-kDpUOMUjt20APgpOVmYkUtYnQCuoCjz_UA_hXI5QWWWgOxYj19crZAZdfTpH8HWKoKG_SN8keCYXikZ9RHa9-kRxTbnW/s1920/reg+dipole+sweep.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1200" data-original-width="1920" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjve-TPD_kXV67oC2E71xJXz0wbdAw7GNs1ee2gE2m76_UuUxM-kDpUOMUjt20APgpOVmYkUtYnQCuoCjz_UA_hXI5QWWWgOxYj19crZAZdfTpH8HWKoKG_SN8keCYXikZ9RHa9-kRxTbnW/s320/reg+dipole+sweep.jpg" width="320" /></a></div><div><br /></div>Then I finished building the cage and swept it again.<div><br /></div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiCwQ86wq-v-B1BvuDVqfEvCO96vKF2I4mMkzTBvMS9zY8E3KljitzD8PO2Q4wt9B1nCpJPvTzhrLDW31Yz8ppLqWF6WlYz5J09AxcGnnumyPabmox-cl01mkTaFew0F21EbFJi-RewNyc4/s2048/sweeping+cage+.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1536" data-original-width="2048" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiCwQ86wq-v-B1BvuDVqfEvCO96vKF2I4mMkzTBvMS9zY8E3KljitzD8PO2Q4wt9B1nCpJPvTzhrLDW31Yz8ppLqWF6WlYz5J09AxcGnnumyPabmox-cl01mkTaFew0F21EbFJi-RewNyc4/s320/sweeping+cage+.jpg" width="320" /></a></div><div class="separator" style="clear: both; text-align: center;">(The cage version being measured.)</div><div><br /></div>Here's the result. The bandwidth has increased by 77% to 4.6 MHz!<br /><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjUAo5qNpqhqdW5tYVWQC_0QSs0kvgf1rrXTIOHsthjiMO_O4YnKTyFJMQ94n18n9uS4HCYDVFjIeonY-J4MNNnMRHPSXY5E5_0N8M_dypFLNsztWN9YyLAcAyrDiVRNPQxCVgdUBGmPxC0/s1920/cage+sweep.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1200" data-original-width="1920" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjUAo5qNpqhqdW5tYVWQC_0QSs0kvgf1rrXTIOHsthjiMO_O4YnKTyFJMQ94n18n9uS4HCYDVFjIeonY-J4MNNnMRHPSXY5E5_0N8M_dypFLNsztWN9YyLAcAyrDiVRNPQxCVgdUBGmPxC0/s320/cage+sweep.jpg" width="320" /></a></div><br /><div><br /></div><div>So there we go. The cage design not only increased bandwidth, but also slightly lowered the impedance and SWR at it's lowest point. Some might wonder why I didn't trim the antenna to raise the lowest SWR to the center of the band. Well, 99% of my operation on 6 meters is down at the CW/SSB/digital end of the band, so that's where I wanted the lowest SWR.</div><div><br /></div><div>Now I'm all ready for those coming 6 meter openings.</div><div><br /><div class="separator" style="clear: both; text-align: left;"><br /></div><br /></div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com2tag:blogger.com,1999:blog-1120585034074108030.post-37478960722796215602020-12-24T11:25:00.006-08:002021-01-09T14:33:35.341-08:00A durable 2 meter, 3 element Yagi antenna built with PVC pipe and window line.<p>I wanted to build a 2 meter Yagi antenna so I could start playing around on 2 meter SSB and CW.</p><p>Initially, I considered the tape measure Yagi. </p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEilxBffcpOZAjSztbQPrXhfzENQgJwm7plcJUSfqx7pS1UQCT217uA49dwG7mUTYbmapOLQnMoxu4SqmB_bb8RLfrKJjHcv1fsdI8PGm9pGYzMlxl01Z0Wgvp3tWlmDOlY5VEv2go1kmzXX/s1496/tape+measure+yagi.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1156" data-original-width="1496" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEilxBffcpOZAjSztbQPrXhfzENQgJwm7plcJUSfqx7pS1UQCT217uA49dwG7mUTYbmapOLQnMoxu4SqmB_bb8RLfrKJjHcv1fsdI8PGm9pGYzMlxl01Z0Wgvp3tWlmDOlY5VEv2go1kmzXX/s320/tape+measure+yagi.jpg" width="320" /></a></div><br /><p></p><p>I'd helped another ham build one this past summer and I was impressed with it's performance. There is a downside to the design though. In even a mild breeze, the tape measure elements vibrate and sometimes flap around in the wind.</p><p>Also, I live in an RV and travel a lot. My antenna will be up and down often, and packed away every time I travel. It has to be durable since it will undoubtedly get bumped around from time to time.</p><p>I also wanted a fairly wide bandwidth, providing a low SWR across the band so I could operate down in the SSB region or up in the FM area with good performance and no tuning required.</p><p>With durability and bandwidth in mind, I decided to build the structure out of PVC pipe and the elements out of window line. PVC is cheap and strong. If the antenna ever broke from an impact, it would be easy and cheap to repair. The *fat* elements created by the window line should provide for a broader bandwidth.</p><p>Initially, my plan was to use a folded dipole for the driven element. I've seen many commercial Yagi antennas using one. Folded dipoles are less noisy and a bit better at rejecting out-of-band signals, also providing a nice uniform pattern.</p><p>I spent a couple of days working on that idea, but had trouble getting it to work. A folded dipole presents around 450 ohms of impedance at it's feed point so you need a matching network to match to the 50 ohm feedline. However, in a Yagi, the parasitic elements of the reflector and directors change things. Yagi's usually have a lower impedance at the feedpoint of the driven element and I just couldn't get a good match to 50 ohms using a trombone coaxial match.</p><p>Abandoning that approach, I decided to start with the tape measure yagi design and adapt it.</p><p>Pictured here is the resulting antenna and a plot of it's SWR over the 2 meter band.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbdxU__q26IaJFvdn6xxNr79NQC3D1ohyG6WK0H6CeceO_qiv8geOi94SX1yF4qfLyMg_nkSA3gBQ3pv2-PBVWGz-VP32rBZDW67q_sHdozQUSso1uimn1-H4E2ogyeSl6MrRjfugcV6Cy/s1280/Up+horizontal+SM+FB.JPG" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="960" data-original-width="1280" height="326" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbdxU__q26IaJFvdn6xxNr79NQC3D1ohyG6WK0H6CeceO_qiv8geOi94SX1yF4qfLyMg_nkSA3gBQ3pv2-PBVWGz-VP32rBZDW67q_sHdozQUSso1uimn1-H4E2ogyeSl6MrRjfugcV6Cy/w434-h326/Up+horizontal+SM+FB.JPG" width="434" /></a></div><div><br /></div><br /><p><br /></p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEigoosuweBHpuNkZQrEv_ltc_SQy_cP_DmkzqTTOm5UD0O0XciUUvPI3qcpzfACS7lG7JStPGElAqHpcmh0MY4DCpFQpT40T8xZIvnMnXLTubDyOXh3lbOUfo310FL9kn66PMEZc-S1yn-z/s1920/Final+configuration+sweep.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1200" data-original-width="1920" height="297" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEigoosuweBHpuNkZQrEv_ltc_SQy_cP_DmkzqTTOm5UD0O0XciUUvPI3qcpzfACS7lG7JStPGElAqHpcmh0MY4DCpFQpT40T8xZIvnMnXLTubDyOXh3lbOUfo310FL9kn66PMEZc-S1yn-z/w475-h297/Final+configuration+sweep.jpg" width="475" /></a></div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: left;">As you can see, it's a success! Performance is quite good. Comparing the yagi, when rotate vertically, to a slim jim, I saw a big improvement in signal strength with a repeater that is 60 miles, or 96 kilometers away.</div><div class="separator" style="clear: both; text-align: left;">Slim Jim: Repeater received signal strength, S3-S4. Minimum power required to hit the repeater, 3 watts.</div><div class="separator" style="clear: both; text-align: left;">Yagi: Repeater received signal strength, S5. Minimum power required to hit the repeater, 1.5 watts.</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;">A single S-unit indicates approximately 6db. That's 6db over the 3db gain of the slim jim, so the gain with the Yagi is around 9db. Pretty good! I tuned it to favor the lower end of the band a bit since I would mostly be using it down there for SSB and CW. You can see by the plot from my Blue VNA that the bandwidth is good and broad as I'd hoped.</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;">Here is the design of my antenna with dimensions. Click image for larger view, right-click on image to save it to your computer.</div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhC7D5cyYIb12Zqo7i-7_T6s15FZ8xOzamvfkplctUzi3NiaUXUW9GqqRIxewgQZdaw1RODVM1_yVeJUUto6r8anfup4_t6C0U3kldp_0cA2xenX0OTdB3QrCBVRYrGaR_beIbNxRYWjEd6/s1920/Yagi+design+drawing.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1166" data-original-width="1920" height="282" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhC7D5cyYIb12Zqo7i-7_T6s15FZ8xOzamvfkplctUzi3NiaUXUW9GqqRIxewgQZdaw1RODVM1_yVeJUUto6r8anfup4_t6C0U3kldp_0cA2xenX0OTdB3QrCBVRYrGaR_beIbNxRYWjEd6/w492-h282/Yagi+design+drawing.jpg" width="492" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: left;"><div class="separator" style="clear: both; text-align: center;"><br /></div></div><div class="separator" style="clear: both; text-align: left;">Design notes: (Pipe dimensions are in inches, I'm not sure of the metric equivalents,)</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;">The physical structure is common PVC pipe and fittings that you can buy at any hardware store.</div><div class="separator" style="clear: both; text-align: left;">The boom is made with 3/4 inch PVC pieces. The element supports are 1/2 inch pieces.</div><div class="separator" style="clear: both; text-align: left;">The T pieces at the ends of the boom are 3/4 to 1/2 adapter T's</div><div class="separator" style="clear: both; text-align: left;">I couldn't find a cross part with 1/2 inch and 3/4 inch holes, so I used a 3/4 inch cross and adapters to go down to the 1/2 inch element supports.</div><div class="separator" style="clear: both; text-align: left;">The mast connects to a PVC slip on part used to hang PVC pipe from a ceiling. It slides onto the 3/4 inch boom pipe and has a threaded opening. A 3/4 inch pipe to thread adapter allows the antenna to be screwed onto the mast when setting up the antenna. </div><div class="separator" style="clear: both; text-align: left;">I cut the ends of the element supports at a 45 degree angle to eliminate the pipes from whistling when there's wind. (plus it just looks cool!) I also put the elements on the inside edge at the ends so I could set the antenna down without damaging the wires. <br />*<b>Be sure you cut the boom pieces so the distance between the actual elements are correct!</b>*</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;">Window line:</div><div class="separator" style="clear: both; text-align: left;">I suggest first cutting three lengths of window line, using the lengths specified in the drawing. Then fit them against the element supports, trimming out the middle part where the window line wires go around the boom. Once that's done, short the ends as shown before mounting them to the supports. <i><u>Make sure they are perfectly centered on the supports with exactly the same distance from the center of the boom to each end of the element.</u></i></div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;">Elements notes: (It's a finicky antenna, be certain to get all dimensions precisely correct!)</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;"><span> Director and Reflector:</span><br /></div><div class="separator" style="clear: both; text-align: left;"><span><span> Cut the window line middle part out in the center so the wires go around the boom cleanly.</span><br /></span></div><div class="separator" style="clear: both; text-align: left;"><span><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg5Tt90Zt0W3Dz6T0z4RH-EIe5Zeyz3NDmSnMVbDzhZP5KE2duj8EidxdtF_2JeCpnlRjfhjO71fZoXsIBrPuEeaik80rgX-lLvfnsOOiLLZ5RxVowEvJIcBTnFSYoc6KQ3rFGDXCLt7qbz/s1280/line+around+boom.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="449" data-original-width="1280" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg5Tt90Zt0W3Dz6T0z4RH-EIe5Zeyz3NDmSnMVbDzhZP5KE2duj8EidxdtF_2JeCpnlRjfhjO71fZoXsIBrPuEeaik80rgX-lLvfnsOOiLLZ5RxVowEvJIcBTnFSYoc6KQ3rFGDXCLt7qbz/s320/line+around+boom.png" width="320" /></a></div><div class="separator" style="clear: both; text-align: left;"><span> All elements ends:</span><br /></div><div class="separator" style="clear: both; text-align: left;"><span><span> The ends of each element have the two wires of the window line shorted together, electrically making the window line act like one fat conductor. I found it best to bare a bit of the window line and then make a shorting wire out of a short piece of 14 gauge solid copper wire. This way, during tuning, if you have to shorten the element, all you need to do is shave a bit more insulation off the window line. Then heat the solder connections and slide the shorting wire down a bit, trimming off the stub remaining.</span><br /></span></div><div class="separator" style="clear: both; text-align: left;"><span><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgZkI9Acz5PCtq_r1pNvALQAYwwEDb9aZfARfWV7gsODi3TeQFHdlQjhUuBNnmiv8SRqtbP3j_YoeHrW03xB0Oeb9mmzZAL1hS1OfENCg7wdaakCPsZUwNMWc6ia3nUmrByKBcpsv48WMfF/s1280/element+ends.JPG" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="502" data-original-width="1280" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgZkI9Acz5PCtq_r1pNvALQAYwwEDb9aZfARfWV7gsODi3TeQFHdlQjhUuBNnmiv8SRqtbP3j_YoeHrW03xB0Oeb9mmzZAL1hS1OfENCg7wdaakCPsZUwNMWc6ia3nUmrByKBcpsv48WMfF/s320/element+ends.JPG" width="320" /></a></div><span> </span><div class="separator" style="clear: both; text-align: left;">All elements, mounting to the PVC:</div><div class="separator" style="clear: both; text-align: left;">Short screws of any type can be used. You want the window line tight against the PVC for nice and straight elements. Use a drill bit just slightly smaller than the diameter of the threads on your screws and you can drill through the window line middle into the pvc, then thread the screw in. It will bite into the PVC and provide a strong mount.</div><div class="separator" style="clear: both; text-align: left;">Also, it is very important to make sure the element is centered on the boom. The more precise you are here the better the performance. Measure from the center of the boom out to the end of the element and make sure it's the same distance to each end.</div><div class="separator" style="clear: both; text-align: left;">You also want to make sure the window line stays flat and parallel to the other elements. Make sure your holes are centered in the window line and they follow a straight line along the pipe.</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;">When cutting the 3/4 inch boom pieces, <i><b>make sure the distance between the window line elements is correct.</b></i> The 3/4 pipe will go into the cross and T pieces about 1 inch.</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: left;">Hairpin match and coax connection to driven element:</div><div class="separator" style="clear: both; text-align: left;">Pictured here is the center of the driven element and the connection to the coax and hairpin, notes below the photos.</div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgFReSUZKxo6IkC63QZ3C78S-Ehm6p_3FdhuF__fqe8KlS_otKaErFOIkNSWwRze_PMYF3y7zY1XsGBxKwTJUyNKyAEb2I3iE37Mp_A8pWjbTMcazXNXq-l04S2T4_dcq8hdNdcZ6Cnlmc-/s1280/Center+detail+SM.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="960" data-original-width="1280" height="363" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgFReSUZKxo6IkC63QZ3C78S-Ehm6p_3FdhuF__fqe8KlS_otKaErFOIkNSWwRze_PMYF3y7zY1XsGBxKwTJUyNKyAEb2I3iE37Mp_A8pWjbTMcazXNXq-l04S2T4_dcq8hdNdcZ6Cnlmc-/w485-h363/Center+detail+SM.JPG" width="485" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXHxecOuU3RdqjLA38yoKFo7o6qQZHe7lbRRgD7uiDV-QEOnvwLPIOFI7QxKzzOM1QjSYbbKT_ktBAgrpaFOhu6-bGVmQT2YXcY6qIOck_EVsi-M7c76aJrRx7lTXDiTX1TG1JMCZKiooi/s1280/center+top+side.JPG" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="591" data-original-width="1280" height="228" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXHxecOuU3RdqjLA38yoKFo7o6qQZHe7lbRRgD7uiDV-QEOnvwLPIOFI7QxKzzOM1QjSYbbKT_ktBAgrpaFOhu6-bGVmQT2YXcY6qIOck_EVsi-M7c76aJrRx7lTXDiTX1TG1JMCZKiooi/w492-h228/center+top+side.JPG" width="492" /></a></div><div class="separator" style="clear: both; text-align: left;"><span><br /></span></div>I used eye ends and ground lugs to make the connection between the coax, hairpin and window line. (more on the hairpin further down.)</span></div><div class="separator" style="clear: both; text-align: left;"><span>Additionally, there are two short pieces of 14 gauge solid wire to make the connection to the other side of the window line. The gap there matches the gap at the connections, about 1 inch.</span></div><div class="separator" style="clear: both; text-align: left;"><span>I used a long screw to make the strain relief for the coax. It also stands the coax off of the antenna when it's vertical. You don't want the coax in line with the antenna elements.<br />Also, it's a good idea to seal up the coax end with silicone or liquid tape to prevent moisture from getting into the coax. (I hadn't yet sealed it when I took this picture.)</span></div><div class="separator" style="clear: both; text-align: left;"><span><br /></span></div><div class="separator" style="clear: both; text-align: left;"><span>Hairpin:</span></div><div class="separator" style="clear: both; text-align: left;"><span>This is the most finicky part of the antenna. The tape measure design called for 5 inches or 12.7 centimetres length of 12 or 14 gauge wire. I used 14 gauge solid copper wire. You want to use solid wire so it maintains it's shape.</span></div><div class="separator" style="clear: both; text-align: left;"><span>Also, that length is to the connection point, so if you use eyes like I did, the actual wire will be about 4.75 inches or 12 centimetres.</span></div><div class="separator" style="clear: both; text-align: left;"><span>The shape of the hairpin matters and is part of the tuning. (next section) I started with a semi-circular shape. You will end up pinching it down during tuning.</span></div><div class="separator" style="clear: both; text-align: left;"><span><br /></span></div><div class="separator" style="clear: both; text-align: left;"><span>Tuning:</span></div><div class="separator" style="clear: both; text-align: left;"><span>You'll need an antenna analyser to tune it. The antenna will have to be away from metal objects also. A short temporary mast of 5 or 6 feet should keep it well up from the ground.</span></div><div class="separator" style="clear: both; text-align: left;"><span>First, we need to make sure the resonant point is where you want it in the band. To shift it you adjust the length of the driven elements. If you followed my design precisely, it should be around 145Mhz right off. </span></div><div class="separator" style="clear: both; text-align: left;">If you need to move the resonant frequency up, you will shorten the elements <b>slightly</b>.</div><div class="separator" style="clear: both; text-align: left;"><i><b>Note! It doesn't take much change!</b></i> Shaving only 1/4 inch off the driven element will shift it by around 1.5 to 2 MHz!</div><div class="separator" style="clear: both; text-align: left;"><span>If you do need to change the length of the driven element slightly, you will probably want to also change the reflector and director elements by exactly the same amount.</span></div><div class="separator" style="clear: both; text-align: left;"><span><br /></span></div><div class="separator" style="clear: both; text-align: left;"><span>Once you have the lowest SWR point at the frequency desired, we can fiddle with the hairpin to tweak the match and get the lowest SWR at resonance.</span></div><div class="separator" style="clear: both; text-align: left;"><span>Start to pinch in the shape and check SWR. You should be able to get it right down to almost 1:1 at the resonant point. This won't change the resonant frequency, just the impedance match.</span></div><div class="separator" style="clear: both; text-align: left;"><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRDazQk7MiNJPHmTZtVoMBlJ7zTdRXKtuc70oxGT4kDdDCp-iqt7KSYiKEMVi0h3nPmHE2cvkHLz9Y0qdzu2Tt1AljWojDKcx7IGAdoX0IvmixLPa5t2exRHSeit0ZXSlSC8TB_RHMIQGm/s2900/hairpin+pinch.JPG" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="900" data-original-width="2900" height="140" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRDazQk7MiNJPHmTZtVoMBlJ7zTdRXKtuc70oxGT4kDdDCp-iqt7KSYiKEMVi0h3nPmHE2cvkHLz9Y0qdzu2Tt1AljWojDKcx7IGAdoX0IvmixLPa5t2exRHSeit0ZXSlSC8TB_RHMIQGm/w482-h140/hairpin+pinch.JPG" width="482" /></a></div><div class="separator" style="clear: both; text-align: left;"><br /></div>Additional notes:</div><div class="separator" style="clear: both; text-align: left;">For SSB or CW, you'll want the Yagi horizontal. For FM and repeaters higher up in the band, the orientation should be vertical. The PVC hanger that I use allows the antenna to easily be rotated. To lock it in place, I drilled a hole through the hanger into the boom and inserted a screw. I drilled a second hole into the boom when rotated the other way. This way you can change the orientation by backing out the screw, rotating the antenna and putting the screw back into the other boom hole to lock it.</div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjhh6rF-u6ES2TMnpqhGxJXaRePdsTvXlJOFEKb5TG-wzBMwEmBS0khHYqUQEInmZMMCh5D4H5rCi1jKEAQIGz-fyvjh-il8ng0ELmzC4coQV9OQv7skx3-GqZru8c4u56iPIvysiBMJVfg/s1280/boom+mount+detail.JPG" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="960" data-original-width="1280" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjhh6rF-u6ES2TMnpqhGxJXaRePdsTvXlJOFEKb5TG-wzBMwEmBS0khHYqUQEInmZMMCh5D4H5rCi1jKEAQIGz-fyvjh-il8ng0ELmzC4coQV9OQv7skx3-GqZru8c4u56iPIvysiBMJVfg/s320/boom+mount+detail.JPG" width="320" /></a></div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: left;">I'm very pleased with the operation of the antenna. I'm sure it will give me many years of use and contacts. For my use on my RV, I use broom holders to allow me to snap it on the side with a short 3/4 PVC mast and easily rotate it to point in the direction I choose. (pictured below)</div><div class="separator" style="clear: both; text-align: left;"><br /></div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjKUHjv3fZeNPVmlydpLDJja5P_zacGus6uGFuCqhpYGI4Rb3-JgDojdrmhJbg6CEZsYUGNKtIi4_YKUANxjkqLSvK0etwylfc8iu8nmhUHuU74muIMqU8mu3KtLlfhw98h9GAXhqO_xUUA/s2472/antenna+on+RV.JPG" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" data-original-height="2472" data-original-width="1016" height="320" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjKUHjv3fZeNPVmlydpLDJja5P_zacGus6uGFuCqhpYGI4Rb3-JgDojdrmhJbg6CEZsYUGNKtIi4_YKUANxjkqLSvK0etwylfc8iu8nmhUHuU74muIMqU8mu3KtLlfhw98h9GAXhqO_xUUA/s320/antenna+on+RV.JPG" /></a></div><br /><div class="separator" style="clear: both; text-align: left;"><br /></div></span>I've been able to hit repeaters that I could hardly hear with the slim jim and am starting to play around with making SSB and CW contacts. I also did a video on this project with some demos of the antenna in action. Linked below.</div><div class="separator" style="clear: both; text-align: left;"><span><a href="https://youtu.be/hh9beU335s4" target="_blank">Youtube video about this, click here.</a><br /><div class="separator" style="clear: both; text-align: left;"><br /><span><br /><div class="separator" style="clear: both; text-align: center;"><br /></div><br /><div class="separator" style="clear: both; text-align: left;"><br /></div><br /><span><br /></span></span></div><br /><span><br /></span></span></div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com12tag:blogger.com,1999:blog-1120585034074108030.post-79454138074973157322018-06-16T11:25:00.001-07:002018-07-05T16:13:11.676-07:00A simple arduino controlled 630 meter CW transmitter for amateur radio. This year, two new experimental bands became official, the 2200 meter band and the 630 meter band.<br />
<br />
I wanted to start experimenting with the 630 meter band, 472kHz to 479kHz, but I don't have a radio capable of transmitting on that band. So I decided to build one.<br />
<br />
Where to begin? Well, a CW transmitter is the easiest choice. All you need to do is turn a carrier on and off with a Morse code key, so you only need an oscillator and a power amplifier.<br />
<br />
While searching around for other projects on that band, I found a wonderfully simple power amplifier circuit already designed by Rog, GW3UEP over in Whales. His original write up can be found here:<br />
<br />
<a href="http://www.gw3uep.ukfsn.org/25W_QTX/472_25W_QTX/472_kHz_25W_PA.htm">GW3UEP PA</a><br />
<br />
I've also been looking for a use for an Si5351 clock generator break-out board I was given last year. It's a versatile little chip, capable of generating up to three simultaneous outputs from 100kHz up to 200Mhz. It generates a square wave, and the power amplifier expects a square wave, so they should work well together.<br />
<br />
After a couple of weeks of work, I had a completed and working transmitter capable of producing around 6 watts of power.<br />
<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjgngOz40cWOR3jCPo5ZSTDpW_hV2r6wR1cxCRhFiktweuDET2EJBYZF4SU5ajq01ustaQyruUzkhz0mCWE4DYdwkWP7FFpttEjcHBbdKmcdfc5_OJZl4G1NbG6_SnVUqqKxwJdL2rNhDX7/s1600/TX+guts.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1205" data-original-width="1600" height="481" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjgngOz40cWOR3jCPo5ZSTDpW_hV2r6wR1cxCRhFiktweuDET2EJBYZF4SU5ajq01ustaQyruUzkhz0mCWE4DYdwkWP7FFpttEjcHBbdKmcdfc5_OJZl4G1NbG6_SnVUqqKxwJdL2rNhDX7/s640/TX+guts.JPG" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<br />
<br />
Theory of operation:<br />
<br />
The arduino and Si5351 will generate a signal within the band, from 472 to 479 kHz. A Morse code key or electronic keyer will be used to switch the signal on and off. <br />
<br />
Frequency selection is accomplished by a single potentiometer and a spot tuning push button. When you press the button, a low level signal will be sent out of the receiver output jack, allowing you to dial the transmitter to your desired frequency. The band is so narrow, only 7kHz wide, that this tuning method is very quick and easy.<br />
<br />
Keying of the transmitter is accomplished by first switching a relay that grounds the receiver output jack to protect your receiver, waiting a microsecond, switching a T/R relay that powers up the amp and switches the antenna jack to the amplifier, waiting a microsecond, and finally turning on the Si5351 output at the desired frequency.<br />
<br />
Releasing the Key will turn off the Si5351 output.<br />
<br />
A timer is employed for a 'tail', waiting 1 second before releasing the relays to switch back into receive mode. This is to prevent the relays chattering away with every dit and dah while sending. That timeout can be changed in the software, and could theoretically allow for full break-in operation if you don't mind banging your relays constantly. That's up to you, I like having a bit of a tail. Since this timer is software controlled, there's nothing stopping you from adding an additional pot and modifying the software to make the tail adjustable if you choose.<br />
<br />
<br />
Here is the schematic of the completed unit.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgRB-1ab3EqwLV7WwpEXFi7NPckQ-7FWB4YHQKP1oRdkeZsastq9VS0JdPjniThF7uQBufquoRKe7qYuPGw0lDs6-sQ8BaAg9nebYNtKt62idp8btyPehfOGVXIGy9X_KsaWmDrtwpPwzpr/s1600/schematic.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1169" data-original-width="1600" height="466" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgRB-1ab3EqwLV7WwpEXFi7NPckQ-7FWB4YHQKP1oRdkeZsastq9VS0JdPjniThF7uQBufquoRKe7qYuPGw0lDs6-sQ8BaAg9nebYNtKt62idp8btyPehfOGVXIGy9X_KsaWmDrtwpPwzpr/s640/schematic.jpg" width="640" /></a></div>
<br />
<br />
Circuit description:<br />
<br />
12-13.6 volts DC comes in and is immediately filtered by a .01uf capacitor to prevent RF leaking back out the power line. There's also a large diode right at the power connector in reverse bias to protect the radio from reverse polarity connection. You should have a 2-3 amp fuse in your power cord for safety.<br />
<br />
The power is routed directly to the two relays and a power switch. I ran it directly to the relays due to the physical layout in my unit, but you could run the relay feed through the power switch as well if you choose.<br />
<br />
Beyond the power switch we have a 7805 regulator to provide 5V to the arduino nano and Si5351 board. <b><i>You should put a small heat sink on the 7805, it will get pretty warm.</i></b><br />
<br />
The arduino is the brains of the machine, providing frequency control and keying. It takes input from three items. The spot tuning push button, a pot for tuning, and a jack for connecting your Morse code key or electronic keyer output. <b>The tuning pot can be any value from 1K up to 10K.</b><br />
<br />
Connected to the arduino we have an Si5351 break-out board. These are available from etherkit or adafruit at a low cost.<br />
<br />
<a href="https://www.etherkit.com/rf-modules/si5351a-breakout-board.html">Etherkit link</a><br />
<br />
<a href="https://learn.adafruit.com/adafruit-si5351-clock-generator-breakout/overview">Adafruit link</a><br />
<br />
The output of the Si5351 is low, around 3.3 volts. Not enough to switch on the power MOSFET in the amplifier, so I needed a simple driver to bring that voltage level up to around 11 volts. This is accomplished through a single NPN transistor. You can use any generic switching transistor like the 2N3904 or 2N2222.<br />
<br />
Additionally, the second output of the Si5351 is used for spot tuning and runs to a wire that's wrapped around the receiver output's center conductor. When that output is enabled, plenty of signal couples to the receiver out for you to hear it and tune to your frequency.<br />
<br />
Keying is accomplished by simply switching the CLK0 output of the Si5351 on and off.<br />
<br />
The power amplifier is a class E amp. The incoming signal switches the MOSFET on and off at frequency. The resulting high power square wave is smoothed by L2 and C2 into a sine wave. The low pass filter provided by L3 and C3-C4 will suppress the second order and above harmonics by more than 50db as required by the FCC's rules. The second order harmonic falls around 900kHz, within the AM broadcast band, so it's important to suppress that to prevent interference.<br />
<br />
<b>I built it as the author designed it, Manhatten style on a flat piece of PCB. There is a small heat sink on the MOSFET and I cut the copper around the sink to isolate it from ground. This is IMPORTANT since the MOSTFET's tab is at V+ and would cause a short if not isolated. Also be sure to isolate the mounting screw on the back side of the board.</b><br />
<br />
The three coils are easy to wind. Use magnet wire and follow the turn counts listed in the schematic. If you have a 3D printer, I designed coil forms at the correct dimensions that can be downloaded from thingiverse at the link below.<br />
<br />
<a href="https://www.thingiverse.com/thing:2963989">3D printable coil forms.</a><br />
<br />
Two relays are employed. RLA1 is a DPDT type. One half of it switches power on to the MOSFET, the other half switches the antenna jack from the receiver output to the amplifier output.<br />
RLA2 is a DPST type that grounds the receiver output jack during transmit in order to protect your receiver from excessive RF from the amplifier.<br />
<br />
<b> NOTE: </b> It should be possible to adapt this transmitter to any of the amateur bands by changing L2, L3, and C2-C5, then modifying the arduino software for the different frequency range. You'll have to research class E RF amplifiers to calculate the appropriate values.<br />
<br />
<br />
Software:<br />
<br />
The arduino software can be downloaded from github here:<br />
<br />
<a href="https://github.com/loughkb/630-meter-TX-arduino-code">630 meter arduino sketch</a><br />
<br />
You <b>WILL </b>need to add the etherkit Si5351 library in your arduino IDE. Go to the sketch menu and select 'Include Library' 'manage libraries'. In the library manager, type 'etherkit' into the search box and add the Etherkit Si5351 library. This library will work with the adafruit break out board as well. I chose this library since it allows you to pass a direct frequency rather than the complicated method adafruits library requires.<br />
<br />
I have liberally commented the software to make it easier to follow. <br />
<br />
The first section and setup routine define variables that are used through the program, setup the hardware I/O pins, and defines an interrupt routing.<br />
<br />
The rest of the program can be broken down into three sections. The main loop, the interrupt routine, and a tuning function.<br />
<br />
The main loop handles the keying and tuning. It checks the spot button and if pressed, calls the tuning function. I ONLY change the tuning while the button is pressed. This is to prevent 'jitter' of your frequency while transmitting. It then checks for key down or key up and switches the relays, turns the Si5351 output on or off as needed.<br />
<br />
The tuning function reads the tune pot and calculates a number from 0 to 7000, the width of the 630 meter band. The resulting number is added to 472000, the bottom edge of the band, and stored in the variable 'freq'. 'freq' is then multiplied by 100 to bring it to the value the etherkit library expects, in 1/100ths of a Hz.<br />
<br />
The interrupt routine is set to run 1000 times a second and is used to decriment a counter for the tail delay. I used an interrupt routine for precision since I know it will run exactly 1000 times a second. I can then use a variable as a timer within the program.<br />
<br />
<br />
<b>Video: (please watch these before you ask questions, you'll probably find your answers.)</b><br />
<br />
I produced a series of videos on the transmitter. You can follow the entire process, my trials and errors through the project. Skip right to the last video if you just want to see the finished design.<br />
<br />
Video #1 is me talking about the idea and initial design of the transmitter<br />
<a href="https://www.youtube.com/watch?v=Knxxeo8-UU8">Video 1, the design.</a><br />
<br />
Video #2 is my initial hardware build in a small case.<br />
<a href="https://www.youtube.com/watch?v=Vvmg7DTQXiA">Video 2. hardware nearly done. (or so I thought!)</a><br />
<br />
Video #3 is a talk about the arduino software and a <b>demo of the operation of the hardware.</b><br />
<a href="https://www.youtube.com/watch?v=GenH4x6QqnQ">Video 3. The software is done.</a><br />
<br />
Video #4 is the final hardware build of the complete and working unit.<br />
<a href="https://youtu.be/Hcv-WN3O_Zs">Video 4. The hardware redesign and demo</a><br />
<br />
This little transmitter performs extremely well and I'm very happy with the results. If you choose to build it, I'm sure you'll find it to be a nice little workhorse. <br />
<br />
73, and maybe see you on the air sometime.<br />
<br />
Kevin, KB9RLWLilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com6tag:blogger.com,1999:blog-1120585034074108030.post-51228212943432132912017-06-03T15:38:00.001-07:002020-12-06T07:50:02.222-08:00Step by step install of the SDRPlay RSP2 under Ubuntu 16.04 and other debian based linux.<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_-c7cAcI5gOSt1Pf6cdVDyCotcUGK9bic4j-LFWYsG2j7_f77O1xflLFqsDVOiQwwgAV4GGLZyqlgDYpDakeXYfpEvvdJCj3Oj2HJu6JlHI0GTN7_G6oTDv-Yfir7z1w_GL2lsPJHBEbm/s1600/sdrtux.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="426" data-original-width="730" height="186" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_-c7cAcI5gOSt1Pf6cdVDyCotcUGK9bic4j-LFWYsG2j7_f77O1xflLFqsDVOiQwwgAV4GGLZyqlgDYpDakeXYfpEvvdJCj3Oj2HJu6JlHI0GTN7_G6oTDv-Yfir7z1w_GL2lsPJHBEbm/s320/sdrtux.jpg" width="320" /></a></div>
<br />
The SDRPlay RSP2 is an excellent bit of kit. A highly sensitive SDR with multiple antenna inputs, input filtering, 10 Mhz bandwidth, and a range from 2Ghz all the way down to 1Khz. On the windows side, they provide a very nice SDR program called SDR uno.<br />
<br />
Those of us not running windows, however, have a few choices in software. GQRX is a popular program, built on GNU-radio. There's a couple of others that escape my mind, but the newcomer, CubucSDR, is starting to stand out.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEifleR4cnrAkOAckUG6LmoIWBu3auRv2sjHdEYAbNnnI5Croy4zBZke0bU8KucPCw6nGkzrsm_j5__k6146CVaDKqDkdn1jPSKdNOlRrPU3I_143iEtJY7_fjm9bkmEWGUWQrsew5k8TmQz/s1600/CubicSDR.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="674" data-original-width="1282" height="210" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEifleR4cnrAkOAckUG6LmoIWBu3auRv2sjHdEYAbNnnI5Croy4zBZke0bU8KucPCw6nGkzrsm_j5__k6146CVaDKqDkdn1jPSKdNOlRrPU3I_143iEtJY7_fjm9bkmEWGUWQrsew5k8TmQz/s400/CubicSDR.png" width="400" /></a></div>
<br />
After much searching and experimenting, I have come up with a list of steps that will build and install the needed support frameworks and software to get you up and running with CubicSDR and your SDRPlay. <br />
CubicSDR manual is here, worth reading through, you might get confused in the software without it.<br />
<a href="http://cubicsdr.readthedocs.io/en/latest/index.html">http://cubicsdr.readthedocs.io/en/latest/index.html</a><br />
<br />
There are a few software packages that are needed for the SDRPlay to work. SoapySDR is a framework for talking to several SDR hardware types, Cubic relies on it. We'll also need the specific soapy module for the SDRPlay, and a few other packages needed to build cubic.<br />
<br />
I have created two scripts that largely automate the installation. You can download them using the following link:<br />
<br />
<a href="https://github.com/loughkb/SDRplaylinux">Click to go to the github page.</a><br />
<br />
<br />
And here's a video where I talk about this whole project.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<iframe allowfullscreen="" class="YOUTUBE-iframe-video" data-thumbnail-src="https://i.ytimg.com/vi/V8lb3FGpSCA/0.jpg" frameborder="0" height="266" src="https://www.youtube.com/embed/V8lb3FGpSCA?feature=player_embedded" width="320"></iframe></div>
<br />
Now, the instructions.<br />
<br />
You will need to create a folder on your desktop named 'sdrplay' and put these script files there. You will also need to download the driver for linux from the SDRPlay site and also place it in that folder. Do not install it yet! <br />
<br />
Open a terminal and change into your newly created directory with the command:<br />
<br />
cd ~/Desktop/sdrplay<br />
<br />
Now, you can run the first script. This will install build software from ubuntu's repositories, along with dependencies needed by the packages we will be building. It will also clone sever github projects, including soapySDR and CubicSDR.<br />
<br />
The script MUST be run as root, so use sudo to execute it:<br />
<br />
sudo ./Install_script-pt1.sh<br />
<br />
It will take awhile and will ask you to type 'y' once for the installs. Once it's completed, you will need to run the installer from the SDRPlay site. Again, you need to make sure you run their script as root with sudo. If it's not executable, you can run:<br />
<br />
sudo chmod +x ./{scriptname}<br />
<br />
(where {scriptname} is the name of the downloaded file)<br />
<br />
It will show you a license agreement you need to spacebar through and hit 'y' to accept.<br />
<br />
After their script is done, you can run the install script part two, again with sudo:<br />
<br />
sudo ./Install_script-pt2.sh<br />
<br />
This one will also take awhile while building CubicSDR. Once done, you should be all ready to go! CubicSDR won't automatically be added to any menus, you'll have to do that yourself. You can also run it from within the terminal by simply typing CubicSDR. If you had the SDRPlay plugged in during this installation, unplug it for a few seconds and then plug it back in. When you run Cubic, it should find the unit and list it for selection.<br />
<br />
ADDENDUM: These scripts also work on the raspberry Pi 3 with the current version of raspian. Obviously you need to download the raspberry pi version of the hardware driver from the SDRPlay site. <br />
There's just one extra step to get pulse audio working under raspian. You need to modify one of the autostart scripts.<br />
In a terminal, type:<br />
<br />
sudo pico /etc/xdg/autostart/pulseaudio.desktop<br />
<br />
Scroll down and find the line:<br />
<br />
Exec=start-pulseaudio-x11<br />
<br />
Change that line to:<br />
<br />
Exec=/bin/sh -c "Sleep 5; start-pulseaudio-x11"<br />
<br />
Ctrl-o to write the changes, Ctrl-x to exit. Now reboot the pi and the pulse audio server will start. This probably fixes other things that rely on pulse as well.<br />
<br />
Have fun!<br />
<br />
Kevin, KB9RLW<br />
<br />
The scripts are pasted below. you can follow through their steps manually with copy/paste into your terminal. (don't forget sudo). Or you can copy each in it's entirety and paste it into an editor, save it, mark it as executable and then run it.<br />
<br />
#/* script 1 below /*<br />
<br />
#! /bin/bash<br />
# This script should install and build all needed stuff for<br />
# using the SDRPlay on Ubuntu 16.04 or later. It must be<br />
# run as root. <br />
#<br />
# First we install needed dependancies.<br />
<br />
apt-get install git build-essential automake cmake g++ swig<br />
apt-get install libgtk2.0-dev libpulse-dev libpython-dev python-numpy.<br />
apt-get install mesa-utils libeglw1-mesa libglw1-mesa-dev<br />
apt-get install freeglut3-dev freeglut3<br />
<br />
# Now we'll git the projects we need<br />
<br />
git clone https://github.com/jgaeddert/liquid-dsp<br />
wget https://github.com/wxWidgets/wxWidgets/releases/download/v3.1.1/wxWidgets-3.1.1.tar.bz2<br />
tar -xvjf wxWidgets-3.1.1.tar.bz2 <br />
git clone https://github.com/pothosware/SoapySDR.git<br />
git clone https://github.com/pothosware/SoapySDRPlay.git<br />
git clone https://github.com/pothosware/SoapyRemote.git<br />
git clone https://github.com/cjcliffe/CubicSDR.git<br />
<br />
# Build liquid-dsp<br />
<br />
cd liquid-dsp<br />
./bootstrap.sh<br />
./configure --enable-fftoverride<br />
make -j4<br />
make install<br />
ldconfig<br />
cd ..<br />
<br />
# Build wxwidgets<br />
<br />
cd wxWidgets-3.1.1/<br />
mkdir -p ~/Develop/wxWidgets-staticlib<br />
./autogen.sh<br />
./configure --with-opengl --disable-shared --enable-monolithic --with-libjpeg --with-libtiff --with-libpng --with-zlib --disable-sdltest --enable-unicode --enable-display --enable-propgrid --disable-webkit --disable-webview --disable-webviewwebkit --prefix=`echo ~/Develop/wxWidgets-staticlib` CXXFLAGS="-std=c++0x" --with-libiconv=/usr<br />
make -j4<br />
make install<br />
cd ..<br />
<br />
echo "."<br />
echo "First part of installation done. Now run the SDRPlay file you"<br />
echo "downloaded from their site. Be sure to use sudo to run it!"<br />
<br />
#/* end of script 1 /*<br />
<br />
<br />
#/* script 2 below /*<br />
<br />
#! /bin/bash<br />
# This script should install and build all needed stuff for<br />
# using the SDRPlay on Ubuntu 16.04 or later. It must be<br />
# run as root. <br />
#<br />
# This is part two.<br />
# Here we build SoapySDR<br />
<br />
cd SoapySDR<br />
mkdir build<br />
cd build<br />
cmake ..<br />
make -j4<br />
make install<br />
ldconfig<br />
cd ..<br />
cd ..<br />
<br />
# Now we build the SDRPlay module for Soapy<br />
<br />
cd SoapySDRPlay<br />
mkdir build<br />
cd build<br />
cmake ..<br />
make<br />
make install<br />
cd ..<br />
cd ..<br />
<br />
# And we build SoapyRemote<br />
<br />
cd SoapyRemote<br />
mkdir build<br />
cd build<br />
cmake ..<br />
make<br />
make install<br />
cd ..<br />
cd ..<br />
<br />
# And finally, we build Cubic. This takes awhile!<br />
<br />
cd CubicSDR<br />
mkdir build<br />
cd build<br />
cmake ../ -DCMAKE_BUILD_TYPE=Release -DwxWidgets_CONFIG_EXECUTABLE=~/Develop/wxWidgets-staticlib/bin/wx-config<br />
make<br />
make install<br />
cd ..<br />
cd ..<br />
rm -R ~/Develop<br />
<br />
# now we change permissions on these root-owned folders so the user can<br />
# delete them at their leisure.<br />
<br />
chmod -R 0777 ./*<br />
<br />
# And we're done. Cubic should work with the SDRPlay. The user can<br />
# run it from the terminal with CubicSDR or add this command to a menu.<br />
<div>
<br /></div>
<div>
#/* end of script 2 /*</div>
LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com87tag:blogger.com,1999:blog-1120585034074108030.post-19915949087931325632017-05-01T09:18:00.001-07:002017-05-21T15:04:29.300-07:00The Arduino based Super Simple Keyer I decided to build my own keyer. I needed a new Arduino project and this seemed like the perfect one. I had a few ideas for the design. <br />
<br />
I wanted a keyer that would take multiple inputs, paddles, straight key, and computer keyboard. The idea being you can send however you like, without needing to change around cables, just send. <br />
<br />
There are many arduino morse projects around already. I suppose I could have just downloaded an existing one, dropped it in and ran with it. But I wanted to tackle the challenge of coding it myself. <br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<iframe allowfullscreen="" class="YOUTUBE-iframe-video" data-thumbnail-src="https://i.ytimg.com/vi/0FU66Joi6_Y/0.jpg" frameborder="0" height="266" src="https://www.youtube.com/embed/0FU66Joi6_Y?feature=player_embedded" width="320"></iframe></div>
<br />
<br />
Once I'd sorted the hardware out, I started to work on the software. It turned out to be a bigger challenge than I'd expected! It's tricky, the timing of reading the paddles and keying. I came up with an interesting solution to timing when it comes to keying the rig.<br />
<br />
You see, the main loop in the arduino sketch can vary in how fast it executes, based on how much work it has to do. My solution was to use a timer in the chip and schedule an interrupt.<br />
<br />
All processors have timers for this. They run at a set speed and can interrupt the processor, forcing it to execute a small routine at precise intervals. This is useful in robotics, for example, like in a flying drone. You would need adjustments to the motor speeds to be occurring fast and regularly.<br />
<br />
So, in my keyer, there is an interrupt that is running a keying routine once every millisecond. That's 1000 times per second, precisely. That allows me to control the timing of the keying exactly and produce clean, consistent Morse out to the radio. This routing watches a buffer that I load with events using the characters period, dash, and comma. Period and dash are obviously the Morse elements, and the comma is a delay equivalent to a dot. <br />
<br />
So to send an 'A' for example, you'd load the event buffer with .,-, dot comma dash comma. The interrupt routine would immediately key the transmitter with cleanly spaced precise Morse.<br />
<br />
The hardware is extremely simple. The schematic is below. The pins chosen are arbitrary and can be changed to suit your build if needed. They are referenced in the first few lines of the code and you change those to reflect the pins you use. The keying is handled by a simple transistor switch. You could use an opto-isolator if you wish, but I've had no trouble keying modern rigs this way.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjJ_PG11VpzB2Uq6TDqZkdBT6xBFCnesUlrLFIh0xzgldXb8sBGJLv6PpshFTWWXaQhgFsD2ljxxO56e-llmUdVefu4nRDx67h5QqtZ8WIGfCk9fpTceF9qnDxjSWTHvom84U-b_9tWQbc-/s1600/Schematic.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="252" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjJ_PG11VpzB2Uq6TDqZkdBT6xBFCnesUlrLFIh0xzgldXb8sBGJLv6PpshFTWWXaQhgFsD2ljxxO56e-llmUdVefu4nRDx67h5QqtZ8WIGfCk9fpTceF9qnDxjSWTHvom84U-b_9tWQbc-/s320/Schematic.png" width="320" /></a></div>
<br />
<br />
<br />
<br />
The software is below. Simply copy and paste it into the Arduino IDE to upload it to your board. Upon startup it will briefly key the radio for a fraction of a second and then be ready to accept input. I wired an additional input jack for a straight key. That was simply parallel to the keying output and done for convenience. <br />
<br />
For keyboard input, the code monitors the serial input. When the Arduino is powered by a USB connection to your computer, it will create a serial port. Simply run a terminal program and connect it to that port to allow you to send keyboard CW. You want to set your terminal program to 9600 baud, no parity, 1 stop bit and 8 data bits. Type to send at the current speed. Simple.<br />
<br />
The code is up to version 1.4. Paddle routines have been heavily worked on, 2 memories have been added. shft-alt-1 to load memory one, alt-1 to send memory one. Same for memory 2, shft-alt-2 and alt-2.<br />
<br />
Code pasted below:<br />
<br />
/*<br />
<br />
Super Simple Keyer Ver 1.4 Arduino based keyer<br />
Written Apr. 30, 2017 by Kevin Loughin, KB9RLW<br />
<br />
Ver 1<br />
Initial release, keyer working ok, not iambic<br />
<br />
Ver 1.2<br />
First iambic code, dependent on timing, not perfect<br />
<br />
Ver 1.3<br />
Rewrite of keyer logic, iambic and dot dash buffering working!<br />
<br />
Ver 1.4<br />
Tweaked paddles a bit. Added 2 memories. shft-alt-1 to set mem 1, shft-alt-2 to set memory 2<br />
alt-1 to send memory 1, alt-2 to send memory 2.<br />
Tweaked character spacing for keyboard decode. Added BT using the minus sign. <br />
<br />
*/<br />
<br />
// Pins we're going to use. Change as needed.<br />
const int wpmraw = A7; //Pot sense for speed<br />
const int dotin = 4; //dot sense pin<br />
const int dashin = 2; //dash sense pin<br />
const int keyout = 13; //keying output<br />
<br />
// declaring variables we'll use in program<br />
<br />
int delayval = 150; //delay between elements in milliseconds<br />
String event = ""; //event contains the elements currently being sent, .=dot -=dash ,=space<br />
String memory1 = ""; //user memory 1<br />
String memory2 = ""; //user memory 2<br />
String membuff; // buffer for memory sending<br />
int dotlen = 150; //current dot length in milliseconds<br />
int dashlen = (dotlen * 3); //dash length in milliseconds<br />
int active = 0; //keying handler flag<br />
int delaycount = 0; // delay counter in interrup handler<br />
int dotstate = 1; // dot paddle input pins reading<br />
int dotread = 0;<br />
int dashstate = 1; //dash paddle input pins reading<br />
int lastdotstate = 1;<br />
int lastdashstate = 1;<br />
int dashread;<br />
int lastdashdebounce;<br />
int lastdotdebounce;<br />
int eventbuffer = 0; // event buffering<br />
int dashhalf;<br />
int lastchar = 1;<br />
int c;<br />
int dotbuffer;<br />
int dashbuffer;<br />
int dashdelay;<br />
int dotdelay;<br />
int flag;<br />
<br />
void setup() {<br />
// Turn off keying pin right away<br />
<br />
pinMode (keyout, OUTPUT);<br />
digitalWrite(keyout, LOW);<br />
<br />
<br />
// setup input pins<br />
pinMode (dotin, INPUT);<br />
pinMode (dashin, INPUT);<br />
digitalWrite(dotin, HIGH);<br />
digitalWrite(dashin, HIGH);<br />
Serial.begin(9600);<br />
<br />
// setup the interrupt<br />
OCR0A = 0xAF;<br />
TIMSK0 |= _BV(OCIE0A);<br />
}<br />
<br />
<br />
// interrupt handler<br />
SIGNAL(TIMER0_COMPA_vect)<br />
{<br />
if ( event.length() > 0 ) //do we have anything to do?<br />
{<br />
if ( !active ) //are we not currently sending?<br />
{<br />
if ( event.charAt(0) == '.') //do we need to send a dot?<br />
{<br />
digitalWrite(keyout, HIGH); //key on<br />
delaycount = dotlen;<br />
active = 1;<br />
lastchar = 1;<br />
}<br />
if ( event.charAt(0) == '-' ) //do we need to send a dash?<br />
{<br />
digitalWrite(keyout, HIGH); //key on<br />
delaycount = dashlen;<br />
active = 1;<br />
lastchar = 2;<br />
<br />
}<br />
if ( event.charAt(0) == ',' ) //do we need to delay between elements?<br />
{<br />
delaycount = dotlen;<br />
digitalWrite(keyout, LOW); //key off<br />
active = 1;<br />
}<br />
<br />
}<br />
<br />
} <br />
if ( active ) // we're already active, count and reset when done<br />
{<br />
delaycount--;<br />
if ( !delaycount ) //are we done with this element?<br />
{<br />
active = 0;<br />
digitalWrite(keyout, LOW); //just make sure the key is off<br />
event.remove(0, 1);<br />
}<br />
}<br />
}<br />
<br />
<br />
void loop()<br />
{<br />
// read the speed and set timing<br />
<br />
dotlen = ( 200 - (.146 * analogRead(wpmraw)) );<br />
dashlen = ( 3 * dotlen );<br />
<br />
// Read paddle inputs<br />
<br />
// read the dash pin<br />
dashread = digitalRead(dashin);<br />
if ( dashread != lastdashstate )<br />
lastdashdebounce = millis();<br />
<br />
if ( (millis() - lastdashdebounce) > 40 )<br />
{<br />
if ( dashread != dashstate )<br />
dashstate = dashread;<br />
}<br />
lastdashstate = dashread;<br />
<br />
// read the dot pin<br />
dotread = digitalRead(dotin);<br />
if (dotread != lastdotstate)<br />
lastdotdebounce = millis();<br />
<br />
if ((millis() - lastdotdebounce) > 40)<br />
{<br />
if (dotread != dotstate)<br />
dotstate = dotread;<br />
}<br />
lastdotstate = dotread;<br />
<br />
<br />
// Keyer logic<br />
<br />
while (!dotstate || !dashstate ) // if paddles pressed, do<br />
{<br />
if ( event.length() < 3 ) // don't bother unless there's no more than 1 chars in buffer<br />
{<br />
<br />
if ( !dotstate && !dashstate ) // both paddles?<br />
{<br />
if ( lastchar == 1 && ( delaycount < dashlen ))<br />
{<br />
event = String(event + "-,");<br />
lastchar = 2;break;<br />
}<br />
if ( lastchar == 2 && ( delaycount < dashlen ))<br />
{<br />
event = String(event + ".,");<br />
lastchar = 1;break;<br />
}<br />
}<br />
<br />
if ( !dotstate && dashstate ) // only dot paddle<br />
{<br />
if ( lastchar == 1 && ( delaycount < dashlen) && event.length() < 1)<br />
{<br />
event = String(event + ".,");break;<br />
}<br />
if ( lastchar == 2 && event.length() < 3)<br />
{<br />
event = String(event + ".,");break;<br />
}<br />
}<br />
<br />
if ( dotstate && !dashstate ) // only dash paddle<br />
{<br />
if ( lastchar == 1 && (delaycount < dotlen))<br />
{<br />
event = String(event + "-,");break;<br />
}<br />
if ( lastchar == 2 && (delaycount < (dotlen * 2)) & event.length() < 2)<br />
{<br />
event = String(event + "-,");break;<br />
}<br />
}<br />
}<br />
break;<br />
}<br />
delay(12);<br />
<br />
// Keyboard routines<br />
<br />
while(Serial.available())<br />
{<br />
c = Serial.read();<br />
Serial.write(c);<br />
// check for special keys<br />
if ( c == 27 ) // alt key pressed<br />
{<br />
flag = 1;<br />
c = Serial.read();<br />
}<br />
if ( flag && c == 33 ) // shft-alt-1, memory 1 define<br />
{<br />
loadmemory(1);<br />
flag = 0;<br />
c = 0;<br />
}<br />
if ( flag && c == 64 ) // shift-alt-2, memory 2 define<br />
{<br />
loadmemory(2);<br />
flag = 0;<br />
c = 0;<br />
}<br />
if ( flag && c == 49 ) // alt 1, send memory 1<br />
{<br />
sendmemory(1);<br />
flag = 0;<br />
c = 0;<br />
}<br />
if ( flag && c == 50 ) // alt 2, send memory 2<br />
{<br />
sendmemory(2);<br />
flag = 0;<br />
c = 0;<br />
}<br />
<br />
decoder(c); // call the keyboard decoder to load this event<br />
}<br />
}<br />
<br />
void loadmemory(int num) // interact with user to load a memory<br />
{<br />
String inData;<br />
char received;<br />
Serial.println( "." );<br />
Serial.print( "Enter the contents for memory " );<br />
Serial.println( num );<br />
Serial.println();<br />
<br />
while ( received != 13 )<br />
{<br />
if (Serial.available())<br />
{<br />
received = Serial.read();<br />
Serial.write(received);<br />
inData += received;<br />
}<br />
}<br />
if ( num == 1 ) // loading memory1<br />
{<br />
memory1 = inData;<br />
}<br />
if ( num == 2 ) // loading memory2<br />
{<br />
memory2 = inData;<br />
}<br />
Serial.println();<br />
Serial.print( "Memory " );<br />
Serial.print( num );<br />
Serial.println( " loaded with" );<br />
Serial.println( inData );<br />
inData == "";<br />
}<br />
<br />
void sendmemory(int num) // send memory number num<br />
{<br />
if ( num == 1 )<br />
membuff = memory1;<br />
else<br />
membuff = memory2;<br />
Serial.println( "." );<br />
Serial.println( membuff );<br />
for(int leng = membuff.length(); leng > 0; leng--)<br />
{<br />
decoder(membuff.charAt( membuff.length() - leng ));<br />
}<br />
}<br />
void decoder(int in) // function to decode char for sending and load send buffer<br />
{<br />
switch(in)<br />
{<br />
case ' ' : event = String(event + ",,"); break;<br />
case 'a' : event = String(event + ".,-,,,"); break;<br />
case 'b' : event = String(event + "-,.,.,.,,,"); break;<br />
case 'c' : event = String(event + "-,.,-,.,,,"); break;<br />
case 'd' : event = String(event + "-,.,.,,,"); break;<br />
case 'e' : event = String(event + ".,,,"); break;<br />
case 'f' : event = String(event + ".,.,-,.,,,"); break;<br />
case 'g' : event = String(event + "-,-,.,,,"); break;<br />
case 'h' : event = String(event + ".,.,.,.,,,"); break;<br />
case 'i' : event = String(event + ".,.,,,"); break;<br />
case 'j' : event = String(event + ".,-,-,-,,,"); break;<br />
case 'k' : event = String(event + "-,.,-,,,"); break;<br />
case 'l' : event = String(event + ".,-,.,.,,,"); break;<br />
case 'm' : event = String(event + "-,-,,,"); break;<br />
case 'n' : event = String(event + "-,.,,,"); break;<br />
case 'o' : event = String(event + "-,-,-,,,"); break;<br />
case 'p' : event = String(event + ".,-,-,.,,,"); break;<br />
case 'q' : event = String(event + "-,-,.,-,,,"); break;<br />
case 'r' : event = String(event + ".,-,.,,,"); break;<br />
case 's' : event = String(event + ".,.,.,,,"); break;<br />
case 't' : event = String(event + "-,,,"); break;<br />
case 'u' : event = String(event + ".,.,-,,,"); break;<br />
case 'v' : event = String(event + ".,.,.,-,,,"); break;<br />
case 'w' : event = String(event + ".,-,-,,,"); break;<br />
case 'x' : event = String(event + "-,.,.,-,,,"); break;<br />
case 'y' : event = String(event + "-,.,-,-,,,"); break;<br />
case 'z' : event = String(event + "-,-,.,.,,,"); break;<br />
case 'A' : event = String(event + ".,-,,,"); break;<br />
case 'B' : event = String(event + "-,.,.,.,,,"); break;<br />
case 'C' : event = String(event + "-,.,-,.,,,"); break;<br />
case 'D' : event = String(event + "-,.,.,,,"); break;<br />
case 'E' : event = String(event + ".,,,"); break;<br />
case 'F' : event = String(event + ".,.,-,.,,,"); break;<br />
case 'G' : event = String(event + "-,-,.,,,"); break;<br />
case 'H' : event = String(event + ".,.,.,.,,,"); break;<br />
case 'I' : event = String(event + ".,.,,,"); break;<br />
case 'J' : event = String(event + ".,-,-,-,,,"); break;<br />
case 'K' : event = String(event + "-,.,-,,,"); break;<br />
case 'L' : event = String(event + ".,-,.,.,,,"); break;<br />
case 'M' : event = String(event + "-,-,,,"); break;<br />
case 'N' : event = String(event + "-,.,,,"); break;<br />
case 'O' : event = String(event + "-,-,-,,,"); break;<br />
case 'P' : event = String(event + ".,-,-,.,,,"); break;<br />
case 'Q' : event = String(event + "-,.,-,-,,,"); break;<br />
case 'R' : event = String(event + ".,-,.,,,"); break;<br />
case 'S' : event = String(event + ".,.,.,,,"); break;<br />
case 'T' : event = String(event + "-,,,"); break;<br />
case 'U' : event = String(event + ".,.,-,,,"); break;<br />
case 'V' : event = String(event + ".,.,.,-,,,"); break;<br />
case 'W' : event = String(event + ".,-,-,,,"); break;<br />
case 'X' : event = String(event + "-,.,.,-,,,"); break;<br />
case 'Y' : event = String(event + "-,.,-,-,,,"); break;<br />
case 'Z' : event = String(event + "-,-,.,.,,,"); break;<br />
case '0' : event = String(event + "-,-,-,-,-,,,"); break;<br />
case '1' : event = String(event + ".,-,-,-,-,,,"); break;<br />
case '2' : event = String(event + ".,.,-,-,-,,,"); break;<br />
case '3' : event = String(event + ".,.,.,-,-,,,"); break;<br />
case '4' : event = String(event + ".,.,.,.,-,,,"); break;<br />
case '5' : event = String(event + ".,.,.,.,.,,,"); break;<br />
case '6' : event = String(event + "-,.,.,.,.,,,"); break;<br />
case '7' : event = String(event + "-,-,.,.,.,,,"); break;<br />
case '8' : event = String(event + "-,-,-,.,.,,,"); break;<br />
case '9' : event = String(event + "-,-,-,-,.,,,"); break;<br />
case '.' : event = String(event + ".,-,.,-,.,-,,,"); break;<br />
case '-' : event = String(event + "-,.,.,.,-,,,"); break;<br />
case '/' : event = String(event + "-,.,.,-,.,,,"); break;<br />
}<br />
}<br />
<br />
<br />
<br />LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com8tag:blogger.com,1999:blog-1120585034074108030.post-66697265854251771462017-01-05T14:14:00.000-08:002017-01-06T16:56:25.294-08:00Giving a voice to someone who's lost the ability to speak.As they say, necessity can be the mother of invention. <br />
<br />
In December of 2016 I lost my best friend of over 30 years. He had suffered a major stroke and was in a coma for just over a week. He came out of the coma, but could not speak, and could only move his hands a bit and feet. He was in there, he could communicate by squeezing his hand, but that was all.<br />
<br />
I immediately dreamed up a way of giving him a voice back. This project is the result.<br />
<br />
Unfortunately, my friend had a second stroke and didn't survive. I decided to go ahead with the project though, I'm hopeful that it can help someone out there somewhere. I call it, The CW Voice Box.<br />
<br />
Morse code is one of the oldest ways of sending letters with a simple on off signal. Short patterns of long and short tones. An ideal way for someone who can only squeeze, bite, or blink to be able to spell out words. This project is exactly that. You key in Morse code, it speaks the letters. A voice for the voiceless.<br />
<br />
There are other devices out there to accomplish this, it's not a new idea. However, those devices are expensive! With the technology we have today, you can build my voice box for around 45 bucks. Maybe a little more if you want a fancy case.<br />
<br />
The parts list:<br />
<br />
Computer: Raspberry Pi zero. I recommend the starter pack over at Adafruit: $24.95<br />
<a href="https://www.adafruit.com/products/2817">Adafruit Raspi budget pack.</a><br />
<br />
USB sound card: There's many available on Amazon, here's one that works: $5.99<br />
<a href="https://www.amazon.com/external-Adapter-Windows-Microphone-SD-CM-UAUD/dp/B001MSS6CS/ref=sr_1_2?ie=UTF8&qid=1483586524&sr=8-2&keywords=usb+sound+card">USB sound card</a><br />
<br />
8 Gig micro SD card. $7<br />
<br />
5 volt audio amp: There's lots of these to choose from, one example below: $7<br />
<a href="https://www.amazon.com/PAM8403-Digital-Amplifier-Support-Powered/dp/B00FVGJX3I/ref=sr_1_2?s=electronics&ie=UTF8&qid=1483586649&sr=1-2&keywords=5v+audio+amplifier">Audio amp</a><br />
<br />
A speaker of some type. I'll leave that up to you.<br />
<br />
You'll also need some bits of wire, some kind of a case, and an input device. Regarding input devices.... What you need will depend entirely upon the capabilities of the person you are trying to help. There are commercial squeeze bulb switches, bite switches, and other devices available. I'll leave the input method up to you. The only requirement is that the person needs to be able to input long and short signals in a pattern.<br />
<br />
Putting it all together:<br />
<br />
I've already done the hard work on the software. I have built a Raspian image for your Pi zero that will boot directly into the morse decoding speech software. You can download the image from the link below.<br />
<a href="http://bitchen.com/cjvoice/DJvoice.zip,"><br /></a><a href="http://bitchen.com/djvoice/DJvoice.zip">Custom Raspian image zip file.</a><br />
<br />
(Many thanks to bitchen.com for offering to host the file.)<br />
<br />
Write this image to the micro SD card and put it in the pi.<br />
<br />
The starter pack will come with a 2Amp power supply, plug that into the pi. <br />
Using the USB adapter, you can plug in the usb audio dongle to the second micro usb port on the pi.<br />
Your input device will need to connect to GPIO pin 7 on the pi, and also to ground.<br />
<br />
The audio amp will need 5 volts. You can tap that from pin 2 on the pi. It also needs a ground connection.<br />
<br />
Audio from the USB dongle goes to the input of the amp, and obviously the speaker will connect to it's output.<br />
<br />
When you plug in the power supply, the pi should boot and within about 20 seconds it will speak the word "Ready". you're good to go. Simply start keying in Morse and it will speak each letter, number, and some punctuation.<br />
<br />
It will reliably decode Morse from around 5 words per minute speed, up to about 10 words per minute speed. To get an idea of the speed, watch the demo towards the end of my video about the project, linked below.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<iframe width="320" height="266" class="YOUTUBE-iframe-video" data-thumbnail-src="https://i.ytimg.com/vi/In6AC14jUaI/0.jpg" src="https://www.youtube.com/embed/In6AC14jUaI?feature=player_embedded" frameborder="0" allowfullscreen></iframe></div>
<br />
<a href="https://youtu.be/In6AC14jUaI">Full video.</a><br />
<br />
<br />
The software is built upon a great educational python program on the raspberry pi site. I modified the software to make it compatibly with python3, re-ordered it's lookup table for speed, and integrated espeak speech synthesis. The raspian image was further modified to fix espeak errors with alsa, and set to boot to command line and run the decoder on boot.<br />
<br />
The original morse code decoder project on the raspberry site is linked below.<br />
<br />
<a href="https://www.raspberrypi.org/learning/morse-code-virtual-radio/worksheet/">Morse decode I built upon.</a><br />
<br />
My modified source code follows:<br />
<br />
----------------------------------------------------<br />
<br />
#!/usr/bin/python3<br />
# modified code based on a tutorial project on the raspberry pi organizations web site.<br />
# original project can be found here: <br />
# https://www.raspberrypi.org/learning/morse-code-virtual-radio/worksheet/<br />
import pygame<br />
import time<br />
from RPi import GPIO<br />
import _thread<br />
from array import array<br />
from pygame.locals import *<br />
from morse_lookup import *<br />
from espeak import espeak<br />
<br />
pygame.mixer.pre_init(44100, -16, 1, 1024)<br />
pygame.init()<br />
<br />
class ToneSound(pygame.mixer.Sound):<br />
def __init__(self, frequency, volume):<br />
self.frequency = frequency<br />
pygame.mixer.Sound.__init__(self, self.build_samples())<br />
self.set_volume(volume)<br />
<br />
def build_samples(self):<br />
period = int(round(pygame.mixer.get_init()[0] / self.frequency))<br />
samples = array("h", [0] * period)<br />
amplitude = 2 ** (abs(pygame.mixer.get_init()[1]) - 1) - 1<br />
for time in range(period):<br />
if time < period / 2:<br />
samples[time] = amplitude<br />
else:<br />
samples[time] = -amplitude<br />
return samples<br />
<br />
def wait_for_keydown(pin):<br />
while GPIO.input(pin):<br />
time.sleep(0.01)<br />
<br />
def wait_for_keyup(pin):<br />
while not GPIO.input(pin):<br />
time.sleep(0.01)<br />
<br />
def decoder_thread():<br />
global key_up_time<br />
global buffer<br />
new_word = False<br />
while True:<br />
time.sleep(.01)<br />
key_up_length = time.time() - key_up_time<br />
if len(buffer) > 0 and key_up_length >= 1.5:<br />
new_word = True<br />
bit_string = "".join(buffer)<br />
try_decode(bit_string)<br />
del buffer[:]<br />
elif new_word and key_up_length >= 4.5:<br />
new_word = False<br />
sys.stdout.write(" ")<br />
sys.stdout.flush()<br />
<br />
tone_obj = ToneSound(frequency = 800, volume = .03)<br />
<br />
pin = 7<br />
GPIO.setmode(GPIO.BOARD)<br />
GPIO.setup(pin, GPIO.IN, pull_up_down=GPIO.PUD_UP)<br />
<br />
DOT = "."<br />
DASH = "-"<br />
<br />
key_down_time = 0<br />
key_down_length = 0<br />
key_up_time = 0<br />
buffer = []<br />
<br />
_thread.start_new_thread(decoder_thread, ())<br />
<br />
print("Ready")<br />
espeak.synth("Ready")<br />
<br />
while True:<br />
wait_for_keydown(pin)<br />
key_down_time = time.time() #record the time when the key went down<br />
tone_obj.play(-1) #the -1 means to loop the sound<br />
wait_for_keyup(pin)<br />
key_up_time = time.time() #record the time when the key was released<br />
key_down_length = key_up_time - key_down_time #get the length of time it was held down for<br />
tone_obj.stop()<br />
buffer.append(DASH if key_down_length > 0.3 else DOT)<br />
<br />
<br />
------------------------------<br />
<br />
And the morse_lookup.py source as well.<br />
<br />
---------------------------------<br />
<br />
#!/usr/bin/python<br />
import sys<br />
from espeak import espeak<br />
<br />
morse_code_lookup = {<br />
".": "E",<br />
"-": "T",<br />
".-": "A",<br />
"---": "O",<br />
"..": "I",<br />
"-.": "N",<br />
"...": "S",<br />
"....": "H",<br />
".-.": "R",<br />
"-..": "D",<br />
".-..": "L",<br />
"-.-.": "C",<br />
"..-": "U",<br />
"--": "M",<br />
".--": "W",<br />
"..-.": "F",<br />
"--.": "G",<br />
"-.--": "Y",<br />
".--.": "P",<br />
"-...": "B",<br />
"...-": "V",<br />
"-.-": "K",<br />
".---": "J",<br />
"-..-": "X",<br />
"--.-": "Q",<br />
"--..": "Ze",<br />
".----": "1",<br />
"..---": "2",<br />
"...--": "3",<br />
"....-": "4",<br />
".....": "5",<br />
"-....": "6",<br />
"--...": "7",<br />
"---..": "8",<br />
"----.": "9",<br />
"-----": "0",<br />
"..--..": "question mark",<br />
".-.-.-": "period"<br />
}<br />
<br />
def try_decode(bit_string):<br />
if bit_string in morse_code_lookup.keys():<br />
# sys.stdout.write(morse_code_lookup[bit_string])<br />
espeak.synth(morse_code_lookup[bit_string])<br />
# sys.stdout.flush()<br />
<br />
------------------------------------<br />
<br />
<br />
<br />
Please share, I hope this project will get out there and find someone who can use it. I would be absolutely thrilled to hear back from someone who was able to give a voice back to somebody who'd lost theirs.<br />
<br />
Thanks,<br />
<br />
Kevin.LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com5tag:blogger.com,1999:blog-1120585034074108030.post-21939641861564723832016-08-14T11:08:00.000-07:002016-09-15T09:01:17.578-07:00Cheap and easy to build digital modes USB interface for Ham Radio.<div class="separator" style="clear: both; text-align: center;">
The DuinoVOX Arduino powered digital modes USB interface for ham radio.</div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEimobpHtaVzejfHi0DhdmERa8yejyXe0Ls04p35PluJRt-s-gTU4G0otPzJdQ7PB-y8gc0Con0pHQweNF1zEukuM4R_9eHOtdKEPdSdVdCNiP6No732eHTRV7h5OjyHDNgcN4KY-jmsnRSC/s1600/Case+on+table+-+front.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="176" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEimobpHtaVzejfHi0DhdmERa8yejyXe0Ls04p35PluJRt-s-gTU4G0otPzJdQ7PB-y8gc0Con0pHQweNF1zEukuM4R_9eHOtdKEPdSdVdCNiP6No732eHTRV7h5OjyHDNgcN4KY-jmsnRSC/s320/Case+on+table+-+front.jpg" width="320" /></a></div>
<br />
<br />
I wanted a better computer to radio interface than what I was using, straight connection from the computers audio jacks. Being unemployed for awhile, I couldn't afford $100 to buy a Signalink commercial interface, so I built my own. Also, I wanted to use an Arduino in a ham radio project. It came out so well, that I've decided to publish it here. If you build it and like it, please let me know. <br />
Below is the schematic. I did a youtube video on the project, watchable at this link.<br />
<br />
<a href="https://www.youtube.com/watch?v=FHshPd52l-w">https://www.youtube.com/watch?v=FHshPd52l-w</a><br />
<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<iframe allowfullscreen="" class="YOUTUBE-iframe-video" data-thumbnail-src="https://i.ytimg.com/vi/FHshPd52l-w/0.jpg" frameborder="0" height="266" src="https://www.youtube.com/embed/FHshPd52l-w?feature=player_embedded" width="320"></iframe></div>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiICbbejf7l9m6pWxYGcp-VmjEz1GN7jAOfy4Cpf75wRr0CXXe4NBXyoQzzJipy8h9YYrLKbl8nXvpRc2smjw-0_VOFXEXbRs06zekwNMTmy6M-z4H2Gz08B34iPebFCCtmyWnYwIha8Xv1/s1600/Schematic.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="206" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiICbbejf7l9m6pWxYGcp-VmjEz1GN7jAOfy4Cpf75wRr0CXXe4NBXyoQzzJipy8h9YYrLKbl8nXvpRc2smjw-0_VOFXEXbRs06zekwNMTmy6M-z4H2Gz08B34iPebFCCtmyWnYwIha8Xv1/s400/Schematic.png" width="400" /></a></div>
<br />
<b>Circuit Description:</b><br />
<br />
The USB sound dongle can be purchased on Amazon.com for less than $10. Search for "USB sound adapter" and you'll find dozens of them. Look for one with a split plastic case so you can take it apart. You'll need to tap +5V and ground at the USB connector, the outside pins of the 4 pin connector.<br />
You can used 1/8" jacks to plug in to it, or desolder the existing jacks and tap audio right off the PCB with thin coax or other shielded cable.<br />
The audio coming from the USB sound device is low voltage. 1.7 volts P-to-P max volume. Since the Arduino will only sense positive voltage, that's 900mv at best. Depending on the point in time that you sample the signal, you can catch it anywhere from zero on up to .9 V within the waveform. Not great.<br />
So, Q1 is a simple amplifier that takes the input signal up to the full 5V on peaks.<br />
The amplified signal passes through D1 and charges C4. D1 prevents the cap from discharging back through the transistor, so you get an accumulated voltage up to around 4.4V DC during a full volume signal. This gives an excellent range on the input to the Arduino, and allows for sensitivity adjustment to be done in software.<br />
R6 bleeds the capacitor down when the audio stops.<br />
Q2 takes the PTT signal from the Arduino and grounds the radios PTT line to key it into transmit.<br />
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<b>BUILD NOTES:</b></div>
<div class="separator" style="clear: both; text-align: center;">
<b><br /></b></div>
<div class="separator" style="clear: both; text-align: left;">
<b>C1 </b>and<b> C2, </b>I used non polarized caps since I had them on hand, but regular electrolytics will work fine. If you're concerned about isolation, you could use two 600:600 Ohm transformers instead.</div>
<div class="separator" style="clear: both; text-align: left;">
<b>C4</b> is not critical. If you don't have a .22, put two .1 in parallel</div>
<div class="separator" style="clear: both; text-align: left;">
<b>R7</b> and<b> R8</b> don't have to be 10K, can be anything from 10K up, don't have to match either.</div>
<div class="separator" style="clear: both; text-align: left;">
<b>C3</b> can be anything from 1uf up to 10uf</div>
<br />
One important tip on using this interface. On your computer, you'll want to set the playback volume for the interface sound card to maximum, then use the drive control knob to set the audio level to your rig. This gives the vox circuit plenty of audio to work with.<br />
<br />
The Arduino source code is pasted below. You should be able to copy paste it right into the Arduino IDE. If you have trouble, let me know and I'll email the file to you. Thanks and 73.<br />
<br />
<i>If you build this and love it, and you'd like to leave me a tip, my email registered with paypal is </i>loughkb@yahoo.com<br />
<br />
<a name='more'></a><br />
<br />
<span style="font-size: xx-small;">/*</span><br />
<span style="font-size: xx-small;"> DuinoVOX. Ver.3.1.1 Arduino based PTT control for radio interfaces. </span><br />
<span style="font-size: xx-small;"> Written Aug. 2016 by Kevin Loughin. Originally for use</span><br />
<span style="font-size: xx-small;"> in a clone of the Tigertronics Signalink design idea.</span><br />
<span style="font-size: xx-small;"> </span><br />
<span style="font-size: xx-small;"> */</span><br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;">// Naming the pins I'm using for clarity.</span><br />
<span style="font-size: xx-small;">const int audioInPin = A1; // Audio sense</span><br />
<span style="font-size: xx-small;">const int tailsetInPin = A3; // delay time adjustment POT</span><br />
<span style="font-size: xx-small;">const int sensitivity = A5; // threshold set POT</span><br />
<span style="font-size: xx-small;">const int PTToutPin = 13; // output to keying transistor</span><br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;">// declaring variables that we'll use</span><br />
<span style="font-size: xx-small;">int delayvalue = 0; // amount of time in hundreths of a second before dropping PTT</span><br />
<span style="font-size: xx-small;">int threshold = 0; // audio trigger level initial value</span><br />
<span style="font-size: xx-small;">int ptt = 0; // variable for holding current PTT delay countdown</span><br />
<span style="font-size: xx-small;">int audio = 0; // variable that will hold audio sense</span><br />
<span style="font-size: xx-small;">int PTT_ON; // Flag to indicate current PTT status</span><br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;">void setup() {</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>// Turn off PTT right away so we're not keying on startup</span><br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>pinMode (PTToutPin, OUTPUT);</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>digitalWrite(PTToutPin, LOW);</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>PTT_ON = 0; </span><br />
<span style="font-size: xx-small;">}</span><br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;">void loop() </span><br />
<span style="font-size: xx-small;">{</span><br />
<span style="font-size: xx-small;"> // Here we go. First read the pots and set variables</span><br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>delayvalue = analogRead(tailsetInPin) / 5; // yields 0 to 204</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>delayvalue = delayvalue + 2; // adjusted to no less than 2, 1 after first pass through loop</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>threshold = analogRead(sensitivity) * .8; // yields 0 to 819</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>threshold = threshold + 70; // adjusted 70 to 889</span><br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;"> // Check for audio. Set delay if present</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>audio = analogRead(audioInPin);</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>if ( audio > threshold ) // if audio in exceeds sesitivity threshold.</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>{</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> ptt = delayvalue; // set ptt to current delay in hundredths of a second</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>}</span><br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>// PTT control check</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>if ( ptt > 0 ) // if PTT is positive (loop is counting down)</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>{<span class="Apple-tab-span" style="white-space: pre;"> </span></span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> if ( PTT_ON == 0 ) // check that we havn't already turned it on</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> {</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> digitalWrite(PTToutPin, HIGH); // turn on PTT if it's off</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> PTT_ON = 1; // so we don't waste time writing on next pass</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> }</span><br />
<span class="Apple-tab-span" style="white-space: pre;"><span style="font-size: xx-small;"> </span></span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>ptt = ptt - 1; // count down in hundredths of a second</span><br />
<span style="font-size: xx-small;"> }</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>else // the counter reached zero.</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>{</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> if ( PTT_ON == 1 ) // check if we already turned it off</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> {</span><br />
<span style="font-size: xx-small;"> digitalWrite(PTToutPin, LOW); // turn off PTT</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> PTT_ON = 0; // Remeber that we've turned it off</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span> } </span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>}</span><br />
<span style="font-size: xx-small;"><span class="Apple-tab-span" style="white-space: pre;"> </span>delay(10); // wait 10ms before looping again. loop 100 times/second</span><br />
<span style="font-size: xx-small;"> </span><br />
<span style="font-size: xx-small;">}</span>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com112tag:blogger.com,1999:blog-1120585034074108030.post-84200898609400222942015-10-19T10:48:00.000-07:002015-10-19T10:48:17.145-07:00How to properly shuffle virtual cards in software.<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Last night, during one of many bouts with insomnia, I was attempting to bring on sleep by playing a mindless game, Solitaire. I say mindless since it requires only the tiniest bit of skill to play. All you have to do is not miss a play. The game will be won if it is winnable, it depends on the order the cards come out of the deck.</span></div>
<b id="docs-internal-guid-aa499f2c-8132-3fbf-6ade-b6a2c7e3026b" style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">This particular version of the game, installed from the Chrome web store, looked beautiful, had wonderful card animation, nice sound, and terrible card shuffling! After 30 lost games in a row, I was quite annoyed, and further from sleep than when I began.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">How do I know it was bad shuffling? Well it was obvious by the regular discovery of two or three of the same number of card in succession. Three Aces in a row, or fives, etc. This poor shuffle, at least in Solitaire, leads to unwinnable games far more often than winnable games.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">A poor shuffle might be advantageous in Poker, to one player at least, but still a bad thing in the bigger picture.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">I see this often. Poor shuffling in a card game program. I always remember my high school days and a certain programming contest a few friends and I had.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">It was 1983. My high school had several Apple ][+ computers in the library, as well as a couple in the vocational electronics class I was taking. This was the early days of personal computers and almost nobody had one at home. </span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Myself and a few friends, classic nerds of the day, were very much in love with these little machines. We often fought over who would get time on them after class. Our parents had become accustom to us staying after school until the janitor kicked us out and we trudged home to a cold dinner. We amused ourselves with programming contests we’d come up with. Each hoping to achieve the position of alpha male in our geeky clique. </span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">The contest of one particular week grew out of a problem one of our group was having with trying to write a good blackjack game. You see, we were programming in BASIC at the time, and it was not a very fast language. The Apple ][+ had a CPU running at around 1Mhz. BASIC, being an interpreted language was slow, very slow, unbelievably slow by today's standards. Akin to comparing a formula one car to a cart drawn by a donkey.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Doug, the kid working on the blackjack game, was rather cocky. He was similar to Dr. Sheldon Cooper on The Big Bang Theory. Very smart, yes, but so incredibly full of himself that we tolerated him only. His problem was that it took well over two minutes for his card shuffle to complete at the beginning of the game. He proposed a contest to come up with a better sorting routine.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">By the end of the week, when we gathered to present our results, I was the clear winner and not by a narrow margin! There were four of us, not counting Doug. Doug had managed to get his shuffle down to one minute and thirty two seconds while sacrificing a bit of randomness. Faster, but the shuffle was poor with many cards adjacent to their brothers.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">The other three guys varied with one being a bit slower, and the other two beating Doug by just a couple of seconds. All three also had somewhat poor shuffles.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">My shuffle took all of four seconds. Four, yes, only four seconds, in BASIC, on an Apple ][+. Additionally, my shuffled deck was thoroughly shuffled with hardly a single instance of card pairs left. For awhile thereafter, Doug wasn't so cocky.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">No, I didn’t cheat, or use machine language. It was a method that I came up with that I wish all programmers would use in modern card games. Not for the speed, that hardly matters on today's incredibly fast machines. No, I wish programmers would use my method for the thorough randomness of the shuffled deck.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Here’s how it works. Now, I can’t present this in C, or Python, .NET, or any modern language. I’m not going to bore you with BASIC since it’s basically a dead language now. I’m going to attempt to convey the idea, it’s simple enough.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">So first you need the deck to be shuffled. In BASIC I simply loaded an array with numbers to represent the cards, one through fifty two. I guess you'd use a table or something today.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Now, to shuffle them you need a simple loop. The loop with run fifty two times with a counter that’s incremented during each pass. This counter will point to the position in the deck we’re working with.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">For each pass of the loop, you take the current card and exchange it with a random position in the deck. So for pass one, we’re working with the first card in the deck. Pick a random number between one and fifty two and swap those two ‘cards’.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">After only one pass through the loop, you’ll already have a deck that is shuffled better than what most modern card games end up with. And it will happen incredibly fast. Now, run the loop two or three times and you have a properly and thoroughly shuffled deck of cards.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Easy. Simple. So please, programmers, do this and properly shuffle your cards. It will make for a much more realistic flow of the card game.</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1.38; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 14.666666666666666px; font-style: normal; font-variant: normal; font-weight: 400; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Thanks.</span></div>
<br />LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com1tag:blogger.com,1999:blog-1120585034074108030.post-7120405278777125802013-04-10T20:55:00.000-07:002013-04-10T20:55:03.352-07:00A new adventure, 3D printingThis is only the first of many posts to come. I've ordered a 3D printer, of sorts. More like a pile of parts.<br />
<br />
The most common 3D printer design among hobbyists, is the completely open Prusa Mendel. One company sells all of the common parts for a base model as a kit. Not a bad deal if you're inclined towards building things. Their main page is <a href="https://nwreprap.com/">nwreprap.com</a> if you are interested in going this route.<br />
<br />
I will be chronicling my build in this blog, with updates and photos. After the project is complete, I will continue to post updates about modifications, improvements, and projects I accomplish with the 'printer'.<br />
<br />
People call them 3D printers, but really, they are additive cnc machines. Moving a tool head, the extruder, around using the same technique and programming code that industrial milling machines use. <br />
<br />
I'm currently waiting for the parts to arrive. Spending my time researching, planning, and learning software. I'll dedicate a post this weekend to software, there's a lot of ground to cover there. <br />
<br />
Hopefully, I'll be able to start the build next week. Stay tuned!<br />
<br />
<br />LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com4tag:blogger.com,1999:blog-1120585034074108030.post-60460355372396461082012-11-25T16:23:00.000-08:002012-11-26T16:45:57.233-08:00Cheap and silent desktop Linux box!<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>In the tech news in the last couple of weeks, there was an announcement of an intel branded mini-pc. There have been many of these small desktop machines in the last few years. Very small footprints, low power consumption, most are silent due to a fanless design.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>The appeal of such small machines is obvious. Taking negligible desk space, they can sit out of the way, or even be hidden. They can be mounted to the back of a monitor for use as industrial signage, or a pseudo all-in-one design for the desktop. They are ideal for limited space installations like in mobile homes, or a small collage dorm room.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>They're considered cheap, yet are still a bit pricey for a lot of us. Many of them seem to settle around the $300 mark.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>I've found an alternative that is widely available and much cheaper, less than half in most cases. The early intel Mac minis.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>Back in 2006, Apple produced their first intel based mac mini design. Quite a capable box at the time, Apple was always using cutting edge hardware in their designs. This model contains an intel core duo dual core 1.66Ghz cpu, 1Gigabit ethernet, wifi, bluetooth, four usb ports, firewire 400, and DVI video connector.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>Full specs listed here:<br />
<br />
<a href="http://www.everymac.com/systems/apple/mac_mini/specs/mac_mini_cd_1.66.html">http://www.everymac.com/systems/apple/mac_mini/specs/mac_mini_cd_1.66.html</a><br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>The last version of Apples OS that could run on this model was Snow Leopard, 10.6.x. Since the last two versions of their OS, there has been a glut of these machines showing up on eBay, going for as low as $130 to just over $150. I picked one up with a bad hard disk for under $80!<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>Replacing the hard disk is not too complicated, I'll list the steps at the end of this article to help anyone along if they pick up one cheap. These make a GREAT Linux box, I'm writing this on mine right now loaded with Debian testing.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>In my case, I had a unit with a bad HD, as mentioned, so I installed a 32Gig SSD I'd picked up a year or so ago. Installing your favorite Linux is easy, Apples firmware has an emulated bios for their "bootcamp" method of dual booting windows on their machines. When you power up, hold down the 'opt' key if you have a mac keyboard, or the left hand 'alt' key if you have a PC keyboard. The machine will come up to a graphic menu that allows you to choose your boot device. Insert your linux CD/DVD, and after a few seconds you'll see a CD icon appear with "Windows" under it. Arrow over to select it, or click with the mouse and the CD will boot.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>From that point, you go through an installation just as you would on any PC box, and after the install is done and it reboots, it will come right up.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>These machines are a bit pokey under Apples OS, but under Linux, they perform extremely well. All hardware works just fine on any recent Linux kernel. OpenGL performance is not bad at all, making all 3D games that I've tried run smoothly. I've even played full 1080p video files full screen without stutter. The machine is nearly silent as the internal fan can't be heard unless you put your ear right down next to the vents on the back.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>So there you go. For not much money, you can have a tiny desktop Linux PC that is fully capable of just about anything you might need to do. Enjoy.<br />
<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>Here are the steps to get the mini apart for HD replacement.<br />
<br />
1) Remove the case. For this you need a special tool. Apple sells it for $30. Since it's basically just a 1" wide putty knife, you can get one at the hardware store for a couple dollars.<br />
Insert the knife into the seam around the bottom edge of the machine and pry. It will pop loose, and you just work your way around.<br />
<br />
2) Disconnect two cables. At the back, there is a ribbon cable connected to a small board at the back of the CD rom drive. It has a ZIF connector. You pop to small clip up at each side and the ribbon lifts out.<br />
At the front, next to the small coin battery, is a two wire cable with a snap connector into the main board. Pop it out carefully. This is the fan temperature sensor, and if you forget to plug it back in, the fan will run full speed.<br />
<br />
3) Remove the wifi antenna. At the rear corner is the wifi antenna board. Under it you will find two plastic clips. Squeeze them in slightly and you can life off the antenna board. Remove the spring and set it aside.<br />
<br />
4) Remove four screws holding the chassis down on the main board. At each of the four corners of the chassis there is a small Phillips head screw. One is at the bottom of a tube, one is right out in the open, and the remaining two are tucked down inside the corner of the plastic chassis. A penlight will help on those hidden two.<br />
<br />
5) Lift off the chassie. This is only a little tricky. There is an interconnected socket between the two, and the wifi antenna cable snakes down under the fan exhaust at the back. Just work the chassis loose with a gentle rocking and lifting motion, keeping the antenna cable from getting snagged.<br />
<br />
6) Once the chassis is out, turn it over and you'll see the 2.5" sata HD right there. Four screws and you can work it loose from the connectors and lift it out. Drop in your replacement by lining it up with the sata connectors and gently pressing it in until the screw holes line up.<br />
<br />
7) re-assemble in reverse. Take care to guide the wifi cable around the fans exhaust, *carefully* or you'll pop it loose from the wifi board. With the holes lined up, you'll be able to work the interconnection in. The ribbon cable at the back will slide into the ZIF connector and has a line drawn across it that will line up with the edge of the connector when it's all the way in. Alternately press down the little clip edges while holding the cable in.<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>Don't forget that fan connector up front by the battery!<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>The two screws with the hidden holes are just a bit tricky. A small Phillips jewelers screwdriver that has been magnetized helps there.<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>Finally, guide the case back on, watch the flexible ground at the back and use the guides around the back connector areas. Press it down and it will snap back on.<br />
<div>
<br /></div>
LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com5tag:blogger.com,1999:blog-1120585034074108030.post-15731855504990887642012-08-19T19:51:00.001-07:002012-08-19T19:51:42.832-07:00A tablet I can actually use! A couple of years ago, when Apple released the iPad 2, I bought one. At the time, I had an original iPad that I'd bought second hand. I needed it for work, since I support primarily apple products in a company that uses Macs for all of their workstations, over 400 of them at present. Executives there all have ipads, as do many of the employees. The company still, even today, won't provide I.T. with one, so I spent my own money on it.<br />
<br />
I used the iPad 2 for a few months, but ultimately sold it and bought a eeePC netbook. At home, I'd switched from Mac to Linux, and the netbook was FAR more useful than the iPad. Also, I grew tired of having to restart the iPad every couple of weeks due to it acting up in some strange way. (sidebar, Apples iOS devices are built on top of the HFS+ filesystem, which is very broken and corrupts files regularly.)<br />
<br />
I was very happy with the netbook, excepting for portability. A slim tablet is just more convenient to slip into a bag, or carry with you to a coffee shop, diner, or to travel with. I still wanted a tablet for that convenience, but being a tinkerer and linux user, I have to have openness and reliability.<br />
<br />
All of those facts in line, I was very happy to see Google release the Nexus 7, and snapped one up. It fits the bill PERFECTLY! It's smaller seven inch size is ideal. Convenient to carry, easy on the wrists for long reading or gameplay periods. Googles android in it's native form, not hobbled by some carrier or companies crapware piled on top of it. Quad core CPU in the nVidea tegra three chip is really fast, and the one gig of RAM gives the OS plenty of room for speedy app switching.<br />
<br />
This weekend I took it traveling and found it to be excellent and useful on the road. We were going deep into a state park forest for some fishing, far from cell service and full of twisty little roads. A new feature of google maps in the latest android, is offline maps. You can download areas of the maps to the device ahead of time. This, along with the built in GPS proved very useful while finding our way through the park.<br />
<br />
Back at the hotel, on the provided wifi, it made quick work of the usual fair. Checking email, posting some trip pics to facebook, catching up on the news, finding interesting places to visit in a strange city, etc. <br />
<br />
The voice dictation has improved to the point of star trekishness spooky in it's accuracy and speed. It no longer requires network access, residing completely on the device for nearly instant recognition of spoken words with very little post editing required.<br />
<br />
One final point... At the $199 price, you could buy two of these and some software for the same price as a single iPad! I give it a big thumbs up.LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com4tag:blogger.com,1999:blog-1120585034074108030.post-33486849126123298392012-08-01T13:14:00.003-07:002012-08-01T13:14:21.654-07:00Ubuntu 12.04 and Unity<br />
<div style="margin-bottom: 0in;">
Ubuntu 12.04 – all in!</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
Well, I've decided to give Ubuntu's
Unity GUI an honest look. I had already updated both my netbook and
desktop machines to 12.04, but had installed MATE for use as my GUI.
</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
My reasons for installing MATE, were
my years of comfort with Gnome 2.x. I had a configuration I was
happy with. Just the right little additions and behaviors to fit my
way of working. MATE allowed me to hold on to those preferences.
MATE is still a little buggy though, and has caused me a bit of grief
on the netbook especially. Overall, it was close to what I was used
to from gnome 2.3 up to Ubuntu 10.10.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
I decided to spend a little time with
the new Gnome 3. I had looked at it before, but I was not in the
right frame of mind to give it a fair shake. This time, I cleared
my mind of my old habits, and approached Gnome 3 as something new.
No expectations of how things <b>should</b> work. I discovered that
Gnome 3 was actually not terrible. In fact, it struck me as clean,
if not a bit to simplified. I learned a bit about it, discovered
the common shortcuts, and some inconsistencies.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
The experience with Gnome was not bad,
and I decided I could live with using it on my working machines.
Well, what about Unity then? Ubuntu is built by default around
their Unity GUI. I suppose that if I'm exploring these new desktops,
I should give Unity a good look as well.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
Years ago, heck, a decade ago!, I
switched from Windows XP to an eMac running OSX 10.4. Coming from
the Windows world into mac was like stepping into an alien
environment. Everything was strange a different, yet it all fit
together so well. The Apple GUI was clean and shiny. All the parts
reflecting an attention to detail that was consistent throughout the
interface.
</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
Unity has that same feel. The
impression it gives, is of a carefully designed product, throughout.
Ubuntu does not feel like a hobby OS stitched together by a
collaborative effort of pale computer nerds, not by a long shot!
Ubuntu with Unity feels like an expensive commercial product.
</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
I'm going to talk a little bit about a
few of the features of Unity that I think I will quickly become
dependent on and miss on other desktops. First up, the HUD.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
The HUD, Heads Up Display, is a
search tool for menus. We've all been here before, you're in an
application, working away, and you need a certain function. You
can't remember which menu that function is under, so you waste 20
seconds or more digging through menus looking for it. This is where
HUD comes in. A single tap of the 'alt' key brings up a search
field, where you can start typing the name of the menu item you're
looking for. Below the search field, a list begins to populate as
you type, with hits on that keyword, prepended with the path to that
item.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
As an example, in GIMP, if I start
typing “crop” into the HUD, I get a list of items like so:</div>
<div style="margin-bottom: 0in;">
Tools > Transform Tools > Crop</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
Once I train myself to use HUD, I
can see it becoming a time-saver in some larger applications like
Libre Office Writer or Calc. I often find myself searching menus in
those apps for a function.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
Ubuntu One, Canonicals free cloud
service, has grown up a bit in this release. The settings panel is
cleaner and more comprehensive, and the speed of syncing files is
much improved over the earlier versions.</div>
<div style="margin-bottom: 0in;">
I have two work computers, a large
home desktop machine, and a eeepc netbook. Using Ubuntu One, I sync
the contents of my documents and desktop folders. This just works
wonderfully. As an example, this blog entry was something I worked
on over a few days, sometimes at home, and sometimes on my lunch
break at the day job. I'd open the file, work on it awhile and then
close it. No matter if I was home on the desktop, or elsewhere on
the netbook, I always had the current edit of the file.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
Other times, I might run across some
media or image that I want to use later. I would simply drop in on
my desktop, and the next time I sat down at the other computer, the
file was there. Very handy.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
One design element of Unity that I
have mixed feelings about, is the placement of menus in the bar at
the top of the screen. Just as on the Mac's OS, all application
menus will be place in the top of the screen. On my netbook, this is
not so much of a problem since it saves on screen real estate.
Application windows have more space for content. However, on my
desktop with a big 24” hi-res monitor, this results in a LOT of
mouse milage.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
The app menu placement is implemented
through three little programs, so simply removing them will cause the
menus to again be place on application windows. The one line shell
command to accomplish this is as follows.:</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<pre class="western" style="background-color: #f0f0f0; background-position: initial initial; background-repeat: initial initial; border: 1px solid rgb(204, 204, 204); line-height: 0.15in; margin-bottom: 0.2in; padding: 0.08in 0.1in;"><span style="color: #222222;"><span style="font-family: Courier, fixed;"><span style="font-size: x-small;"><i>sudo apt-get autoremove appmenu-gtk appmenu-gtk3 appmenu-qt</i></span></span></span></pre>
<div style="margin-bottom: 0in;">
Doing this on my desktop but not on my netbook allows me to get the
best out of unity in both cases It's the one thing I enjoy most
about a linux desktop, customizable, completely. At work I use a Mac
as my primary workstation and I am responsible for nearly 400 Mac
workstations. Apple makes the decisions about how their GUI looks
and works, you have little choice. The Lion upgrade went a long way
to slowing me down at my job. Lots of frustration and verbal
grumbling over that.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
There are only two 'bugs?' that I have
yet to resolve with Unity. One being multiple desktops don't
automatically switch when you switch focus to apps on other desktops.
Example: I leave Gwibber on a second desktop.. If I go to the
notification menu and notice a new message there, and click on it,
nothing happens. In my mind it seems that the desktop should slide
over to Gwibber.</div>
<div style="margin-bottom: 0in;">
<br />
</div>
<div style="margin-bottom: 0in;">
The other is probably a configuration
setting somewhere that I've yet to find. On my desktop, tapping the
super key does not bring up the menu, nothing happens. This machine
was upgraded from 10.10 to 11.04 to 11.10, finally to 12.04. I
suspect there's some crumbs still hanging around that I have to clean
up. Any suggestions?</div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com0tag:blogger.com,1999:blog-1120585034074108030.post-442493220352411802012-04-28T11:26:00.003-07:002012-04-28T11:26:54.420-07:00TrimSlice server project completed. It took a couple of weeks and several false starts, but my new home file server is running fine and sipping power. <br />
<br />
The TrimSlice is an Nvidea Tegra development board, enclosed in a solid aluminium case. The case is the heatsink for the chips, at least the top of the case is. The board has most of the silicon on the bottom, and is installed in the case with the bottom up, making contact with the top of the case. I believe this was done intentionally, to allow the heat from the chips to radiate away, rather than be trapped beneath the unit and build up.<br />
<br />
I bought the bare bones unit, which does not come with wifi, or a built in SSD. It does have ample connectivity though, with four USB2 ports, a single HDMI port, a micro serial port, one internal micro SD slot, one external standard SD slot, audio out, video in, spidif digital out, and gigabit ethernet. Power is via an included wall wort rated at 12volts at 2 amps.<br />
<br />
Internals: an ARM dual core cpu, 1 gigabyte of memory, with almost 200M set aside as shared video memory for the nvidea tegra2 graphics.<br />
<br />
There are several guides online for installing several of the major linux distros. CompuLabs also provides their own ubuntu remix in live CD image form. You can burn their image to an SD card, boot the device and install to another SD card or Micro SD for use as your system drive.<br />
<br />
I had a rough start. Compulabs download links for their installer was an early version based on ubuntu 10.04, and it is a bit buggy on the bare bones model. What I discovered over time was that their original image was based on the standard model and some assumptions were made about an internal SSD. <br />
<br />
Initially, I couldn't get it to install to any media I tried. It would randomly pause and eventually time out during the archive extraction phase, aborting with an error, "can't write". <br />
<br />
After several tries, I went to their forums and discovered a link to a just released updated version, based on ubuntu 11.04. This image did install ok, and I could boot the unit up as a desktop OS and use it. I played around with it a bit, browsing the web, running libre office, etc. It works well enough, but there is huge delays due to very poor I/O performance to the micro SD I was running off. I eventually installed to a catagory 4 SD card and got better performance, but still very poor compared to other systems I've run off flash memory media.<br />
<br />
I also had problems with filesystem corruption. Over time, the system would get very crashy and unstable. Pulling the card and running fsck against it on my desktop would reveal LOTS of file system errors. This was very disturbing, but I eventually figured out what was going on.<br />
<br />
When you shutdown the TrimSlice, it goes into a standby state of sorts, and doesn't appear to sync the file system. That leads to bad corruption. My work around has been to manually do a sync before shutting down, and I have no more file system issues.<br />
<br />
My application for this little box is a home server, so I really don't need all of the desktop stuff. Using tasksel, I trimmed the OS down to a simple server, and began configuring. Either the arm version of tasksel is a bit broken, or their build of the OS is just a bit too far away from the original. Several services had to be re-installed, and a few things fixed.<br />
<br />
Samba: Although samba was still installed, nmbd does not start automatically on boot. I simply added it to /etc/rc.local. I ended up adding a few things there. Now, I could share directories with samba, but found that I couldn't mount shares from other machines. CIFS support is not present in the kernal! I may eventually build a new kernel to get around this, but it's only a minor omission in my particular application.<br />
<br />
NFS: I had to install nfs-kernel-server, but it worked as expected.<br />
<br />
The ARMel repositories have most of the popular software present, so I was easily able to install ntp, mpd, inyadyn, rtorrent and a few other things. I ended up having to add them to rc.local to get them running at boot.<br />
<br />
One note regarding video. The CompuLabs supplied OS does work well for a desktop OS, but I had trouble with both of the DVI capable LCD monitors I own. The display would come up at the wrong sync rate sometimes, only allowing a quarter of the screen to be viewed across the full monitor. Sometimes unplugging and replugging the hdmi cable would fix it, othertimes not. In my final setup, I don't need video, so it's not a big deal for me.<br />
<br />
The built in serial port is useful. A root terminal is present there at boot, so a simple null modem cable and laptop always gives you a way in to the machine if you're having video or networking trouble.<br />
<br />
Overall, it's working great as a server. It only draws 180-250 milliamps during operation, and doesn't get very warm at all. I suplement it's power source with overflow from my hobby solar setup, so most of the day, it's running completely off solar. The TrimSlice and my external 1TB HD together only draws around 800 milliamps total at 12 volts. Pretty amazing really.<br />
<br />
<br />LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com0tag:blogger.com,1999:blog-1120585034074108030.post-36762269700684608582012-04-08T16:19:00.002-07:002012-04-08T16:33:27.166-07:00Trim Slice. My new home server.I have just ordered a bare bones Trim Slice.<div><br /></div><div><a href="http://trimslice.com/web/">http://trimslice.com/web/</a></div><div><br /></div><div> My plan is to use it as a replacement for my current home fileserver. You see, my current setup is an old MaxTerm thin client with a cirix system-on-a-chip cpu that is basically a really fast 486. The reason for the wimpy hardware is power consumption.</div><div><br /></div><div> I have a small hobbiest solar setup here. Three 15W panels on the roof and a 200Ahr deep cycle battery. I use the power for some lighting, running my ham radios, charging the cell phone, nook ereader, kids ipad, etc. Also, when the battery is topped off, I have a bleed over system that feeds the surplus power into the fileserver. Most days, it runs for 3-4 hrs completely on solar power.</div><div><br /></div><div> The downside of the maxterm, is the I/O speed of it. Even though I upgraded it with a combo 1Gbps ethernet and USB 2 card, it can't feed data at anything much above 100Mbit ethernet speeds. That wimpy CPU just can't handle it. Power wise, the maxterm draws about 1.2 Amps at 12V. That's 14.4 watts.</div><div><br /></div><div> The Trim Slice is a cool gadget. Built around the tegra chips, its a fast CPU, plenty of I/O, including a 1Gbps ethernet port. It will triple the performance potential of my current server, and drop power consumption to 4 Watts!</div><div><br /></div><div> Fortunately, debian comes in an armel flavor, which should run just fine on it. I'll set up the OS on an SD card for the machine to boot off, and my current data drive, which is a 1TB drive in a 12V powered usb connected enclosure, will plug right in.</div><div><br /></div><div> I'll write up an article on the setup of the device, issues that might crop up, and performance info on the finished server.</div><div><br /></div><div> It occurs to me, that this little box could be a minimal desktop system in a classroom, or 12V powered setup like a mobile home. Robot controller? Car computer? Set top media player?</div><div><br /></div><div> I'll get it in about two weeks, check back for my report.</div><div><br /></div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com0tag:blogger.com,1999:blog-1120585034074108030.post-18477079782340732462012-03-26T18:49:00.002-07:002012-03-26T19:09:43.598-07:00I have found my MATE and I am happy.<span ><span style="font-size: 100%;">I have to wonder why MATE has not had more press? </span></span><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><a href="http://mate-desktop.org/" style="font-size: 100%; ">http://mate-desktop.org/</a></div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><br /></div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "> As the three followers of my blog may have noticed, I am unhappy with the direction both Gnome and KDE have taken. The tablet is a great portable media consumption tool, and minimal productivity tool, also a game machine, but really limiting for all around computing.</div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><br /></div><div><span ><span style="font-size: 100%;"> Moving desktop interfaces in the direction of the pinch/swipe/poke/prod tablet interface LIMITS their usability. Point Of Fact. Limit is the key word here. The major desktops have fewer </span>customization options, far fewer gadgets, so to speak. </span></div><div><span ><span style="font-size: 100%;"><br /></span></span></div><div><span ><span style="font-size: 100%;"> One example was the excellent range of panel applets available for gnome. I routinely depend on two in particular, the system monitor and the weather report applets. Having my system load available in a small out-of-the-way graphic with a full system monitor a click away is perfect. Have a small icon showing the termperature and weather, with a full forecast and radar map just a click away, perfect.</span></span></div><div><span ><span style="font-size: 100%;"><br /></span></span></div><div><span ><span style="font-size: 100%;"> Yes, I know, there's widgets to do this. Great big graphic icons living on your desktop, usually covered up by a window, requiring you to move things around to see them... It's not the same, it's not </span>efficient<span style="font-size: 100%;">, it's less of a utility. </span></span></div><div><span ><span style="font-size: 100%;"><br /></span></span></div><div><span ><span style="font-size: 100%;"> Another example with gnome3, unity, or even enlightenment. Where are the scroll bars? What about column titles that let you sort things? I opened the software center in gonme3 on debian testing, and search for a keyword to find the package I'm looking for and there's NO way to sort the list. Why remove something so useful? It makes no sense.</span></span></div><div><span ><span style="font-size: 100%;"><br /></span></span></div><div><span ><span style="font-size: 100%;"> These are just a couple of examples, but I see the same loss of useful things throughout each of the 'modern' desktops I've looked at. Gnome2 was very close to perfect in providing many ways to tuck away useful information that was easily available. These are the things that bring power to a desktop, flexibility and utility.</span></span></div><div><span ><span style="font-size: 100%;"><br /></span></span></div><div><span ><span style="font-size: 100%;"> Dumbing down the desktop may help in reducing confusion for the general consumer market that snaps up ipads so they can *check their facebook while watching Two and a Half Men on the idiot box.* That's fine, but why force those of us still in </span>possession<span style="font-size: 100%;"> of a full mental faculty to give up on the power of a desktop?</span></span></div><div><span ><span style="font-size: 100%;"><br /></span></span></div><div><span ><span style="font-size: 100%;"> Well, a few bright fellows have seen this problem and forked gnome2 in the form of MATE. And I for one, am thrilled. My hat's off to them. If I were a programmer, I would help as much as I could. I am not a programmer, so I will do what little I can and try to spread the word about MATE. </span></span></div><div><span ><span style="font-size: 100%;"><br /></span></span></div><div><span ><span style="font-size: 100%;"> They have instructions for adding their repo to debian, mint, or ubuntu here:</span></span></div><div><a href="http://wiki.mate-desktop.org/download">http://wiki.mate-desktop.org/download</a></div><div><br /></div><div> It works great. Brings back all of the flexibility I was comfortable with in pre-V11 ubuntu. I hope more distros will start adding MATE to their repositories and giving people this choice. Don't settle for the "post PC era" limitations. Demand that you have a choice to remain on a "classic" and powerful, flexible desktop environment. Spread the word, there is a choice again.</div><div><br /></div><div><br /></div><div><br /></div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com13tag:blogger.com,1999:blog-1120585034074108030.post-14618112219971410962011-12-07T20:07:00.000-08:002011-12-07T20:37:01.726-08:00BackupPC, the best backup I've worked with.I am fortunate to work in a large company that uses macs for their workstations. All the shiny gui simplistic user facing stuff aside, under the hood it's BSD Unix, mostly. Sure, Apple has done their best to break Unix, and sometimes they succeed in even bringing down the kernel, but otherwise, it's good enough.<div><br /></div><div> Being Unix, you have wonderful tools like rsync, ssh, and Gzip for easily moving data between machines with compression. You can build your own cron driven backup scheme if you really want to bang out the scripts, or you can run BackupPc. (link at end of post)</div><div><br /></div><div> In my company, we need to maintain a backup of executive machines and some server data. </div><div><br /></div><div> This is a task that could be quite expensive in most enterprise. A powerful server, running an expensive OS from M$. An equally expensive backup program, more money for licenses for the number of clients you'll be backing up.. An expensive DLT tape system or Optical based system. Maintenance heavy with downtime for M$ updates or (this always makes me chuckle) defragging the servers drive for performance..</div><div><br /></div><div> In my case, a bit of ebay browsing netted a Dell PowerEdge 2950 server with 4gig of Ram, dual 2.3Ghz dual-core Xeons, and six SAS drive caddies, for only $400.00 Add six 1TB Western Digital green drives for not quite $800 and you're done with expense.</div><div><br /></div><div> Now we build a RAID5 array with the drives and we're sitting on 4.5 TB of redundant storage. With compression, that's enough for over 100 client machines easy. (more on this in a moment)</div><div><br /></div><div> Hardware acquired, lets look at software. I like Debian as an all around swiss army knife server OS. Everyone has their favorite, we're not going to debate who's OS can beat up who's here. Now, lets think about the discs. We want at least three partitions on our big RAID, one for the system, swap space, and our backup storage.</div><div><br /></div><div> I set up about 40Gig for the root system, that's probably overkill by a long ways, but who knows about what might come down the road over the life of the machine? Swap space, I like to match my RAM size, so 4Gig there, and the rest as an ext3 partition mounted where BackupPC stores its backup data:</div><div>/var/lib/backuppc</div><div><br /></div><div>After formatting the partitions, Debian took only two minutes to install. Two minutes? Yes, that's all. I used the textual installer, and only checked the components I needed, apache, ssh server, base system.. No Gui needed on a real server! That would just waste resources.</div><div><br /></div><div>Configuring BackupPC takes editing a few perl scripts. That might sound daunting, but they are HEAVILY commented, and it's not very hard to understand them. The tricky part is the clients.</div><div><br /></div><div>For BackupPC to work best, you want to let it use rsync as it's method to move data from the clients. For rsync to work best, you want to exchange RSA public keys between the server and the clients. Since my company uses Unix based Macs as workstations, this is simple to set up. Now BackupPC has root access to the clients and can use rsync to pull data efficiently.</div><div><br /></div><div>Internally BackupPC does some nice tricks to save disk space. For each client it backs up, it will look at the files in the backup pool, and remove any duplicates, replacing them with hard links. This is a HUGE space saver in an enterprise where many machines have the same applications installed. Additionally, backup data can be compressed on the fly with gzip, further saving space.</div><div><br /></div><div>In my example, I have 30+ full workstations backed up in less than 1TB of space. More impressive when you count that one of the machines in particular has an insane 780Gig of data on it. (I won't comment on the why, it's not under my control.) most of the machines count toward 20-40Gig of data being backed up. Keep a week of incremental backups and a couple of full backups and I get up to 1.4TB. Still not bad at all.</div><div><br /></div><div>On this older Dell, the performance under linux is so good that the 30 clients get through an incremental backup in just a few hours at night. </div><div><br /></div><div>BackupPC is driven by a web interface that makes it very easy to monitor it and so so very easy to restore from the backup.</div><div><br /></div><div>If a user needs a file, folder, or even their entire home directory restored during disaster recovery, it's quick and easy. In the web interface, you browse through their backups to find the file, folder, etc., then simply check a box next to it and click a button to restore the files. BackupPC then uses rsync again and puts the file right back directly to the clients machine. In seconds.</div><div><br /></div><div>It's a beautiful thing.</div><div><br /></div><div><a href="http://backuppc.sourceforge.net/">http://backuppc.sourceforge.net/</a></div><div><br /></div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com2tag:blogger.com,1999:blog-1120585034074108030.post-34144166269950893102011-11-24T18:01:00.000-08:002011-11-24T18:08:14.269-08:00Download any Flash video you can view, using Linux.<p style="margin-bottom: 0in"> Some time ago, it was possible to grab any flash video you were watching under Linux very easily. The flash player buffers the data, we've all noticed the progress bar at the bottom of the video, filling in ahead of the marker or play head showing where we are in the time line. Where is this data stored?</p> <p style="margin-bottom: 0in"> Up until a year or so ago, that place was /tmp. The systems official temporary directory. While the video was playing, and the buffering indicator had reached the end, indicating the entire video had been downloaded, the Flash video file could simply be copied out of the /tmp folder to your desktop or other destination. This could even be done in the GUI, no need for the terminal.</p> <p style="margin-bottom: 0in"> Then something changed. I don't know if it was an addition to the Flash player, or just Flash developers getting smarter about hiding their temporary data to prevent anyone from obtaining a local copy of the video. Regardless, the simple fact remains that the /tmp folder no longer appears to contain the downloaded video while watching. The key word in that sentence is “appears”.</p> <p style="margin-bottom: 0in"> The file is actually still there, but a bit or flag is set, marking it as a deleted file! Even though the Flash player is actively using the file. Since it is marked 'deleted', the filesystem denies access to it and nothing can see it. Here's where we get tricky with Linux tools...</p> <p style="margin-bottom: 0in"> To illustrate this, I'll open my browser to a video file on CollegeHumor.com. If you want to follow along, here is the link.</p> <p style="margin-bottom: 0in"><a href="http://www.collegehumor.com/video/6653193/occupy-wall-street-vs-the-iphone-line">http://www.collegehumor.com/video/6653193/occupy-wall-street-vs-the-iphone-line</a></p> <p style="margin-bottom: 0in"> Once the video starts, you can pause it or watch, that doesn't matter. What does is the grey filling in of the time line indicating the file is downloading. Once it has filled in completely, open a terminal and type:</p> <p style="margin-bottom: 0in"><span class="Apple-style-span" >lsof | grep Flash</span></p> <p style="margin-bottom: 0in"> lsof is a command that lists all open files on your system, including pipes. We're sending it's long output via the pipe symbol | into the grep command which will filter the output, only passing lines that meet our criteria. In this case, we only want to see lines that contain the text, “Flash”. The output I get is:</p> <p style="margin-bottom: 0in"><span class="Apple-style-span" >npviewer. 12550 loughkb 11u REG 8,1 22889528 13631698 /tmp/FlashXXdNKpIi (deleted)</span></p> <p style="margin-bottom: 0in"> The first string is the name of the process that owns the file, the next number is important, it is the process ID number. Following is my username and then the fourth column contains the other important bit of info, in this case, “11U”. The number 11 will be the name of a link we will find shortly</p> <p style="margin-bottom: 0in"> Now, we'll CD down into the proc folder, a folder that contains live information about everything going on in your system. One could write a book about the contents of /proc, and someone probably has. Without getting technical, the process number we obtained above, will be represented as a directory within /proc. We'll cd down into that folder and a sub folder called “fd”.</p> <p style="margin-bottom: 0in"><span class="Apple-style-span" >cd /proc/12550/fd</span></p> <p style="margin-bottom: 0in"> Now, we'll pull a file listing with details.</p> <p style="margin-bottom: 0in"><span class="Apple-style-span" >ls -l</span></p> <p style="margin-bottom: 0in"> This gives us a file listing, and here we find our Flash video data within a long list of data. My example gives:</p> <p style="margin-bottom: 0in"><span class="Apple-style-span" >lrwx------ 1 loughkb loughkb 64 2011-11-24 20:10 11 -> /tmp/FlashXXdNKpIi (deleted)</span></p> <p style="margin-bottom: 0in"> The lower case letter l at the beginning tells us this is a link to a file named 11 that is linked to FlashXXdNKpli in /tmp. You can see the file is flagged as deleted, even though the Flash player is currently using it.</p> <p style="margin-bottom: 0in"> All we need to do now is copy this linked file out somewhere to get a real copy of the file. I'll copy and rename it to a file on my desktop:</p> <p style="margin-bottom: 0in"><span class="Apple-style-span" >cp ./11 ~/Desktop/flashvid.flv</span></p> <p style="margin-bottom: 0in"> This copies the linked (deleted) file to my desktop as flashvid.flv. Now I have the Flash video file and I can watch it with vlc or any media viewer that plays flash. I can convert it to other formats with Winff, Open and edit it directly in OpenShot, etc.</p> <p style="margin-bottom: 0in"><br /></p> <p style="margin-bottom: 0in"> Isn't Linux great! </p> <p style="margin-bottom: 0in"><br /></p> <p style="margin-bottom: 0in"><br /></p>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com25tag:blogger.com,1999:blog-1120585034074108030.post-25039138327796480832011-11-17T16:16:00.000-08:002011-11-17T16:30:01.255-08:00Unexpected uses of a knoppix thumbdrive system.Knoppix is pretty cool. It's a linux live system on a USB stick, which by itself is not something too impressive anymore. This is something that's been done for years now, with other systems like Damn Small Linux, Puppy Linux, based off the original Knoppix I believe.<div><br /></div><div> But the Knoppix guys really have a good setup. You can encrypt local storage on the stick so that someone else can't get to your data if you lose the drive. You can install applications that are persistent and available the next time you boot the stick. In essence, you have a portable computer that just borrows whatever hardware you boot it on.</div><div><br /></div><div> I made it a habit to keep a knoppix thumbdrive in my pocket. You never know when you might need to kill a virus off some poor windows users system. But recently, I truly realized the utility of this system on a thumb drive..</div><div><br /></div><div> I'd set up Chrome on it as the browser, with sync enabled so it always has my current bookmarks, and extensions. I love that feature of chrome. I can add a bookmark on my desktop, and when I'm on my netbook, my Commodore Vic Slim, or my knoppix system, I'll have the bookmark. Google should take syncing one step further and sync open tabs and the last page you were on before shutting Chrome down. Then I could finish reading that interesting article without having to find it again.</div><div><br /></div><div> As an I.T. professional, I sometimes have to work from home. I have my desktop set up with openVPN to talk to work, and vnc in to my workstation to let me do almost anything I can do while actually at work. Well, why not set up similar on the Knoppix system? So I did.</div><div><br /></div><div> Now, I have an emergency computer of sorts always in my pocket. Lets say that my desktop systems hard disk fails some night, you can't predict hardware failure, and the system drive dying late at night would put me out of commission if I had an urgent call from work.</div><div><br /></div><div> How about when I'm visiting friends or my folks? They all have internet connections, I could pop in the knoppix stick and boot to my system to get to work within a couple of minutes. </div><div><br /></div><div> It's really an ideal solution to always having something to rely on, conveniently bouncing away in my pocket. No need to drag along a netbook, just in case...</div><div><br /></div><div> Check out Knoppix, it's one of the best portable live Linux distros out there.</div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com6tag:blogger.com,1999:blog-1120585034074108030.post-66624983521786907662011-11-05T07:14:00.000-07:002011-11-05T07:29:12.429-07:00I may stick with Ubuntu after all.My last post detailed my disappointment with Canonocles direction toward a tabletesque user interface, and concerns with the 3.x kernel. There were many comments, surprisingly, but I'm sure due to the publication of my story by Lx'er, thanks guys! I found many of the comments interesting and some helpful.<div><br /></div><div> My favorite computer for daily use right now is my Commodore Vic Slim. Presently it's hard disk contains Ubuntu 10.10, with an external drive for beta testing Commodores OS. I can't talk about the Commodore OS yet due to the NDA I'm under, but I will produce a few first look videos as soon as it's released. I have a video overview of the Vic already posted here:</div><div><br /></div><div>http://www.youtube.com/watch?v=XVTQjG-n0TE</div><div><br /></div><div> Lately I have been using the Xfce window manager, and like Linus himself decided, it may be my salvation for my collection of machines if I continue forward with Ubuntu. There's still the bugs with the new kernel, it won't suspend properly, the worrying reports of it killing the display on the model of netbook I own, etc. But Xfce looks to be a useful and fast GUI that still provides the functionality I prefer in a desktop.</div><div><br /></div><div> I have Ubuntu 11.10 running in a VirtualBox VM and I'll be beating it up there for awhile, testing it's limitations and advantages. I already knew about the classic mode of gnome shell and had given it a go, but it still felt overly simplified and limited. That is the key problem I have with all of the tablet style interfaces that are emerging.</div><div><br /></div><div> Sure, the simplified interfaces the big three are working out are easier for non-computer people to work with and make computers more accessible to the general consumer, and I recognize the advantage there for pushing tech into the public's hands. But I'm not those people, I'm an I.T. professional with twenty five years of experience in the computer field and the skills that come with it.</div><div><br /></div><div> It's looking like Xfce will become my home for awhile, if or when I make the move to Ubuntu 11. Thanks for reading. And watch this space in the coming week or two for my first look at Commodores new OS.</div><div> </div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com0tag:blogger.com,1999:blog-1120585034074108030.post-67717618066829712232011-11-02T03:29:00.000-07:002011-11-02T03:48:53.387-07:00Ubuntu, the end is near....I was a huge ubuntu fan. They got it *right* for a few years there, from 9.10 through 10.10 which I currently run on my netbook and desktops. My son's machine is still on 10.04, and now I have a problem.<div><br /></div><div> It seems they just decided that 10.04 is reaching end of life and now I can't perform updates on his machine. Further, the option to easily upgrade to 10.10 is no longer available in the update manager, they want us all to move to 11.10.</div><div><br /></div><div> No thank you. To be fair, I have given 11 a test drive, a long one over two weeks on my Commodore Vic Slim desktop machine. Simply put, I *HATE* unity. It is extremely unfriendly to the desktop user, getting in the way, buggy, too tabletesque if that's a word I can use.</div><div><br /></div><div> Apples iPad is certainly a game changer in the consumer world of popular computing. Now the big three, Apple, Microsoft, and Canonocal are moving their desktop interface in the direction that makes them friendly to a tablet form factor. And there's really nothing wrong with that. I understand that the consumer world likes the convenience of the tablet for media consumption. But there needs to be a classic desktop mode available for those of us that still want to use desktop machines.</div><div><br /></div><div> Gnome 3 is not quite stable yet, I may give it another spin and try harder to adapt and live with the bugs, but I still love Gnome2. It's stable and reliable. I like that my machines just work. I like having a few important bits of information available via panel applets. I like the classic desktop paradigm, it works for me and the way I use my computers.</div><div><br /></div><div> There are still too many problems with the new interfaces and the new kernel. Frankly, I'm afraid to run the new kernel on my MT101T eeePC netbook, I've read about a few people who've had their MT101T bricked by the new kernel and had to send them in to Asus for repair.</div><div><br /></div><div> Soon, Ubuntu 10.10 will reach end of life and lose it's repositories. Soon I will have to migrate to something else and go through the trouble of reloading my machines. Kind of a pain since linux is so stable, I'd hoped to be able to just use my machines until the hardware died.</div><div><br /></div><div> Wouldn't that be nice? To have a system where I could just worry about work I want to accomplish on the computer and not have to worry about the OS and keeping things running? Isn't that supposed to be an advantage of going with Linux on the desktop? Build it and just use it day-to-day without things breaking? I know that's what I want.</div><div><br /></div><div> But these days, software companies and organizations seem to be in a race, a race to introduce new features and out do each other on *new* stuff. Rather, they should be spending time on fixing and trimming and speeding up existing software.</div><div><br /></div><div> Ubuntu 10.10 got many things exactly right and was nearly the perfect desktop for me. But soon, Canonocle will force me to change by dropping support of one of the best Linux desktops that ever came along. This leaves me sad, and very hesitant to recommend Ubuntu to others.</div><div><br /></div><div> So now, the search begins for another desktop OS. And I'm left a little sad.</div>LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com31tag:blogger.com,1999:blog-1120585034074108030.post-81398022716650277122009-12-16T16:36:00.000-08:002017-06-04T16:54:12.342-07:00The sad state of Adobe software.The free software world is remarkable in it's completeness at this stage. There are applications to cover nearly any function or task you might have. Many very powerful applications that rival commercial equivalents. <br />
<br />
For missing free programs, some companies actually develop linux versions of their software, one example is Adobe. They produce a linux version of their Flash player, and it works well enough. Well, let's just say it works well enough to get by.<br />
<br />
It's no secret that the linux version of the Flash player is a huge cpu hog. Actually, the mac version as well, but not as bad. Still, it seems to me that the Flash player uses far more cpu that would be needed to accomplish its task.<br />
<br />
Using VLC, I can play a 720p HD video compressed with the H.264 codec, and VLC will use less than %17 of the CPU on my 2.4Ghz dual core celleron. <br />
<br />
Adobes Flash player will use over %60 of the same chip playing a much lower quality video full screen... By contrast, SecondLife uses only %44 of the same chip when walking around in the world full screen...<br />
<br />
Yes, Adobe Flash player uses more CPU than a full game/3D world program. What the hell Adobe? Did you write your Flash player in Visual Basic? Flash should be a textbook example of BAD programming practices. Adobe should be embarrassed and ashamed.LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com1tag:blogger.com,1999:blog-1120585034074108030.post-74671273840004248612009-12-09T16:36:00.000-08:002017-06-04T16:52:54.142-07:00Switching, away from OSX.This might come as a shock to some of you, but I've switched away from Mac, to Linux. Specifically Ubuntu 9.10, but more on that later.<br />
<br />
This post, my first on this new blog page, will mostly be my history. After all, you need to know a little bit about me in order to give any credence to my comments and thoughts, don't you?<br />
Otherwise, I'm just another random voice speaking away in the global crowd on what we know as "The Internet".<br />
<br />
I started messing around with electronics at a very young age. Back in 1978, at the age of twelve, I received an electronics project kit for Christmas. It was from Radio Shack and was the best toy I ever enjoyed as a kid. I spent days with it, reading books on electronics, wiring up circuits, occasionally making smoke.<br />
<br />
I discover ham radio a little later and dove right in. We lived near the HeathKit company, so I furthered my electronics education by building an HW-8 morse code transciever from Heath as well as working on other old radios I acquired.<br />
<div>
<br /></div>
<div>
Along about this time I also obtained a Sinclair ZX-81 computer kit. Thrilled at owning my own computer, I spent many many hours with the little beast. Typing in BASIC programs on that miserable membrane keyboard, poking in machine code one number at a time, and dealing with a notoriously finicky external 16Kbyte memory expansion. (Hey, it only came with 4K of RAM)</div>
<div>
<br /></div>
<div>
Eventually I moved up to a commodore VIC-20. Combining skills, I built an audio interface between the computer and my Ham Radio to send and receive morse code via the computer. I also wrote a really nice font editor in BASIC on the VIC-20.</div>
<div>
<br /></div>
<div>
At school, we used Apple][+ computers in our library, and built a HeathKit H89 CP/m machine in electronics class. I failed algebra and accounting due to spending my time in those classes writing out BASIC programs in my notebook. I took and nearly failed a computer class at that time also. The instructor was an old mainframe guy, and we didn't get along. It might have had something to do with me writing a word processor in BASIC on the classroom H89, he considered me a "smart-ass".</div>
<div>
<br /></div>
<div>
I probably was. How many teenagers have a clue about humility after all?</div>
<div>
<br /></div>
<div>
At home, I graduated to a Commodore 64 during my senior year at high school. It came with a 1541 floppy drive, and I saved up for a 300 baud commodore modem. Floppies! Finally, no more cassette tapes and 15 minute load times for a single program.</div>
<div>
<br /></div>
<div>
The modem was an interesting beast, with a single small jack on the back that accepted the handset cord from a phone. You would dial the BBS number, wait till you heard the answer tone and quickly disconnect the handset cord, plugging it into the modem.</div>
<div>
<br /></div>
<div>
BBS systems had only just started to show up, and there were two in my area. I spent lots of time on them, running Term40 on the C64. It graphically displayed a full 40 characters across the screen, woohoo. One funny moment was when I talked my dad into taking me to see the movie "War Games" one weekend. He got quite nervous about my BBSing after that.</div>
<div>
<br /></div>
<div>
I graduated High School and moved away for Fort Wayne, Indiana to go to electronics classes at ITT Tech, made other friends with C64s and figured out after a year that I didn't want to pursue electronics engineering as a career. So I dropped out of ITT and went to work for a small mom&pop computer store called Computer Corner. A great little place, it's still in business today.</div>
<div>
<br /></div>
<div>
This was the end of 1985 and computers were just beginning to grow in popularity as a home entertainment device. At Computer Corner, I serviced many different machines from Commodore 64s to Epson QX10 CP/m machines, Kaypro luggables, Osborn, and early IBM PCs.</div>
<div>
<br /></div>
<div>
Although the Apple Macintosh had just come out, that store didn't deal with them, so I had no exposure to the early macs. Commodore, however, came out with newer models, and I gave up eating a few days a week to afford a C128, and eventually, an Amiga 1000. </div>
<div>
<br /></div>
<div>
I stuck with Amigas for several years, what great machines they were. Most people who computed through those times knew of the Amigas amazing graphics and sound abilities, and many know of it's amazing operating system and its preemptive multitasking.</div>
<div>
<br /></div>
<div>
During that time, I serviced Amigas, Atari STs, IBM PCs. Installed the first 10Meg hard disks, then 20, the 30Meg HDs. We were amazed at the storage capacity of those noisy and slow disks.</div>
<div>
<br /></div>
<div>
I left Computer Corner after 5 years to try a few other things. Spent three months driving around the country living in my dads old van, came back to Fort Wayne and worked for a short time for a commercial radio company servicing radios and climbing 400 foot towers.</div>
<div>
<br /></div>
<div>
As winter came on and it got seriously cold up on those towers, I went to work for a small TV station in Auburn Indiana, doing graphics, video editing, and station programming. The station was built around an Amiga 2000 with a NewTek Video Toaster in it. Great times, lots of reward in seeing your creative output broadcast on live TV.</div>
<div>
<br /></div>
<div>
Did I mention they were a small TV station? Really small... So small, that after just under a year, I was informed that they couldn't afford to continue paying me and I was let go.</div>
<div>
<br /></div>
<div>
Next stop was a job at ComputerLand, servicing PCs and Apple Mac computers and peripherals. I didn't like the early macs. Their cooperative multitasking was problematic, and they did a lot of weird things with their filesystem and file forks. I had switched to a PC at home, running OS2 and eventually windows 95.</div>
<div>
<br /></div>
<div>
I was at ComputerLand for 5 years before taking a job in PC support at Essex wire. This was the most educational time of my life, working in a large company. I was responsible for hundreds of workstations at the local offices, and many more at the 11 or so plants Essex had across the country. I built and maintained a couple of windows servers, and had some exposure to an IBM mainframe Essex owned.</div>
<div>
<br /></div>
<div>
At home, I continued to use windows, but was intrigued by things like Minix and eventually Linux. These remained playthings on scavanged hardware though, my desktop machine was running windows 98, then NT, finally windows 2000 and XP. </div>
<div>
<br /></div>
<div>
Essex began to fall apart after a sneaky business deal management pulled off, allowing them to retire on fat stock options while the company began to sell pieces off. This was around 2000, when Apple released OSX. That caught my eye.</div>
<div>
<br /></div>
<div>
OSX, Unix under the hood of a fairly clean and usable GUI. I bought an eMac and switched. I fell in love with OSX. It was more stable than windows, and far more secure. The initial lack of software variety rapidly faded as more and more software began to appear.</div>
<div>
<br /></div>
<div>
Essex began major layoffs around this time, and I was included in the third round. Given a six month severence in the early spring seemed like a good deal. I'd take the summer off and relax a bit, then go find another job. Computer skills still seemed like a very employable skill then. I was wrong.</div>
<div>
<br /></div>
<div>
I took three months off, then started looking for work. There was nothing even close in pay to what I'd been making at Essex, and my personal life was draining with a recent divorce and the responsibility of single parenthood. I ended up working in another mom&pop type office supply company for just over half what I'd made at Essex. This plus the financial ruin left me by the divorce lead to a very tough time.</div>
<div>
<br /></div>
<div>
At work, I built and serviced PCs running XP. At home I continued to enjoy my eMac and do some side work as a photographer.</div>
<div>
<br /></div>
<div>
The office supply company went out of business almost two years after I'd started there, and I ended up working at my current job, back in a PC support role. This time, however, it's at a large company that uses Macs for workstations and mostly Linux for their servers. Talk about a dream job for a computer admin! Great place.</div>
<div>
<br /></div>
<div>
I moved up to a Mac mini, then an intel Mini, and finally to my last machine, an intel iMac.</div>
<div>
<br /></div>
<div>
Whew, that was a long trip down memory lane. But now, if you're still reading this, we've reach the present day, and I've just switched away from Mac, to Linux.</div>
<div>
<br /></div>
<div>
Apple did a great job with OSX, expanding on the services in their GUI and maintaining a very usable and user friendly desktop. Under the hood, they faded out the remnants of NeXTstep and reached a fully certified Unix. They did a few things wrong though, and the recent Snow Leopard version of the OS actually went backwards in a key area, the filesystem.</div>
<div>
<br /></div>
<div>
Apples filesystem is called HFS+. It's not much different from the HFS filesystem they were using on the 'classic' macs back before 2000. The HFS+ filesystem is the Achilles heal of OSX. It's problematic, requiring regular maintenance and repair. Over time, maybe as little as two or three months, a Mac will slow down and maybe start to act strangely. Programs might hang, file associations might change, all manner of subtle weirdness. A pass with a disk utility or directory repair utility will correct several issues, and things will be fine again. For a few more months.</div>
<div>
<br /></div>
<div>
Apple also is suffering a bit of bloat. The OS is getting bigger and in some ways slower. Virtual memory is way overused, with many gigs in VM files existing almost right away after boot.</div>
<div>
<br /></div>
<div>
When talk of the upcoming Snow Leopard began, there was mention of Suns ZFS filesystem and I got a little excited. Maybe we were finally going to get a new filesystem and the stability of the OS would finally be where it should be. After all, a linux machine can run for months or years straight without a reboot or loss of performance.</div>
<div>
<br /></div>
<div>
Snow Leopard arrived, with no optional filesystem. No choice, just HFS+ and its same troubles. Worse yet, rather than moving further away from their resource fork idea, they stepped back to depend on them again. Let me elaborate.</div>
<div>
<br /></div>
<div>
Back in the classic mac days, there was no easy way to associate a file with the program that created it. In the PC world, the three character file extension was the answer. A file ending in .doc was to be opened with Micorosft Word, a file ending in .txt would be opened by notepad.</div>
<div>
<br /></div>
<div>
Apple split a file into two parts, a data fork, and a resource fork. The data fork would contain the files actual data, the resource fork would contain an icon image, and information about the files creator application, etc. This was fine for the time, but relied on their filesystem for this scheme to work.</div>
<div>
<br /></div>
<div>
With OSX, this became less necessary since we had other ways to accomplish this. The time was right to move to a new filesystem.</div>
<div>
<br /></div>
<div>
With Snow Leopard, many tech writers made note of the reduction in disk space required for the OS. And it is quite a reduction, a few Gigabytes of space saved by upgrading. They accomplished this by compressing many of the systems files, and storing the compressed data into the resource fork, decompressing it on the fly.</div>
<div>
<br /></div>
<div>
To me, this is a step backwards, and also means HFS+ is not going away anytime soon. After grumbling over rebuilding my iMacs directory yet again to solve a problem with it not waking from sleep, I started seriously looking at the latest Ubuntu release, 9.10.</div>
<div>
<br /></div>
<div>
Ubuntu has reached the point where even a non-techie computer user could sit down and do most of the things they need to do on a computer, painlessly. Under the hood, it's solid and stable, secure and reliable.</div>
<div>
<br /></div>
<div>
The availability of software through repositories has made it simplicity to find and install software. The quality and variety of open source software rivals and in some cases surpasses commercial software. Projects like WINE allow many popular windows applications to be run without the need for windows. And finally, VirtualBox allows windows to be installed and used almost as an application itself.</div>
<div>
<br /></div>
<div>
For techie types like me, the nearly infinite ways you can customize Linux and your desktop environment is a huge plus. The computer can be made to look, feel, and work in just about any way you'd like. And finally, the filesystem is also a real choice, although the ext4 filesystem default is already far more stable than HFS+ or NTFS. I may use my current machine for years and never have trouble with the filesystem.</div>
<div>
<br /></div>
<div>
Then there's the sense of freedom from using a system that's not owned, controlled, and restricted by any single corporate entity. Sure, Canonical gives you an initial build that they decide is the best combination of things, but you have no limitations on where you take if from there. Once you boot up after install, it's yours to do with as you please. </div>
<div>
</div>
<div>
The final piece to my decision to switch, is hardware. For just over $400 in parts, I was able to build a computer that is in every way outperforming my old iMac. Ubuntu on modern hardware is amazingly responsive.</div>
<div>
<br /></div>
<div>
So there you have it, I switched away from Mac, and have no regrets. </div>
LilFluffyhttp://www.blogger.com/profile/09326915291169469814noreply@blogger.com3