We started producing shows as Today with a Techie 9 years, 7 months, 21 days ago. Our shows are produced by listeners like you and can be on any topic that "are of interest to Hackers". If you listen to HPR then please consider contributing one show a year. If you record your show now it could be released in 20 days.
In addition to my piece here, I also want to use this opportunity to point out an excellent podcast about vim, that's complementary to the series on HPR.
I was pleased to see recently that Thomas Gideon's The Command Line podcast is back from a hiatus and want to make sure that others are aware. His 12th of April podcast is an essay entitled "Hope and Fear in the World of vim" where he discusses his use of vim throughout his career as a programmer. You can find this podcast at thecommandline.net
The text editor yi was written long ago by Bill Joy in the late 70's before the advent of the PC keyboard and cursor keys, so the default key mappings for left/down/up/right being H,J,K and L are not immediately familiar to a pc keyboard user.
The original UNIX machine for which vi was written used the AD-M3A terminal where H,J,K and L had the cursor arrows engraved.
Vi is installed as a default choice on many distros, and where it is not, there is invariably a package available that can be easily added.
Some, if not most, distros come vim installed by default (vim by the way stands for vi improved). This does have the cursor keys mapped nicely for a modern PC keyboard as well as the original keys. Vim is always aliased as vi, so if it's been installed when you enter vi you get vim.
Vi is a pretty light weight bit of code whereas VIM has more dependencies so sometimes vi is still preferred as the default install package. For instance Debian and many of its derivatives have vi rather than vim installed by default.
If you are distro hopping or working on other peoples systems you can generally rely on having vi available, but you can't be sure to get vim so it is useful to be conversant with the vi key mappings, along with a working knowledge of some of the basic commands. Then you will never be at a loss for a text editor when needing to hack around in a Linux box.
For me as an occasional user of vi the most challenging keys to remember to use are the H,J,K and L. cursor keys, since muscle memory has my fingers diving for the arrow keys. This is where the game Nethack comes in, which is what this article/episode is really about.
Nethack is a terminal based dungeon adventure games which uses the same cursor keys as vi and other old UNIX programs. Play this game for a few hours and you will ever struggle with vi cursor keys again.
The goal of the game is to retrieve the 'Amulet' from the lowest level of the dungeon and return to the surface with it for your god.
Nethack presents as a text based adventure with each level gradually being revealed to you in the on-screen character based level map. As you travel through the dungeon more of the level is revealed. As you play, your character gains more experience and levels up its capabilities.
You play as one of a number of types of character, and race. These include many of the usual dungeons and dragons types, archaeologists most likely inspired by Indiana Jones and tourists which definitely owe much to Terry Pratchet. Each role and race has their own initial characteristics, default inventory items, levelsof resilience and ability to learn various skills. For instance a wizard will advance his spell making capabilities faster than a footpad.
Although seemingly a simplistic terminal based game there's more going on in Nethack than is at first apparent. Originally released in 1987 it was actively developed with improvements to game play features until 2003. Since then there have been minor updates and ports for different platforms have been added, however there is rumoured to be a release with further game play improvements some-time this year.
The game has real depth and subtlety that is gradually revealed the more you play. It is not an easy game to win (from my experience to date that may not even be possible) but the more you play it the better strategies you will devise and the more rewarding the game becomes. There's more complexity to this game than almost any modern 3d HD graphic adventure.
Although there is a Nethack Wiki where information about how to play can be sought, the true elite apparently learn through playing. I'd suggest having a go, then when you become familiar with YASDs (yet another stupid death), there's a lot of them, you will have enough experience to answer a few burning question with the Wiki in order to be able to play a more satisfying game.
Although a challenging game, it is not a difficult game to play once you have remembered a few keyboard commands. And this game can be played just about anywhere. Because the game has GPL license there are many ports and flavours available. It is possible to play on most platforms: I have tried it on Linux, Android and even as a Google Chrome app, although the IOS port was not usable on our old iPad or a colleague's new iPhone.
There are various ports for the Windows platform, some of which replace the character based interface with Windows 3.1 style tile interface or a 3d isometric graphic interface. Personally I'd prefer to stick with the traditional character interface since the graphics don't really add anything to the game play. In fact when I play the game on Windows laptop, I use a minimal Debian install running on VirtualBox. I have set it up to auto-run Nethack and shutdown when exiting the game. Then I launch the VM directly with a shortcut containing the virtualbox command on the desktop.
This is how I set up my Nethack VM:
First I created a VirtualBox VM with 1 core 256M of RAM and an 8GB hard drive (I could have easily got away with 2GB actually).
Then I installed a minimal install of Debian, configured networking and installed nethack using apt-get install.
Once nethack was installed I disabled networking so I don't have to wait for a network connection to time-out when if my machine is not online.
To make Debian auto-start with a particular user account you can edit the /etc/inittab and alter one of the tty invocations. I changed the line:
To login my account 'steve'
1:2345:respawn:/sbin/mingetty –autologin steve tty1
To get Nethack to run on start-up, and the vm to shutdown on exiting the game edit the user's .bashrc file and append these three commands to the end of the file
clear # this ensures that the screen is clean prior to running the game
nethack # to run the game
sudo shutdown -h now # to close the VM when you exit the game
Because Nethack is a terminal based game it doesn't hammer the battery in portable machines, making it an ideal travel game for a commuter.
Even if you are not a gamer its worth a look at Nethack, it might be the one computer game that really grabs your attention.
Andrew Conway and Dave Morriss, who each have a lifetime membership with Magnatune, talk about the label and share some favourite tracks.
When first set up music could be bought from Magnatune through a download interface on the website with a "pay what you like" pricing model. Later it was possible to purchase physical CDs and in 2007 complete albums and individual tracks could be bought through Amazon.com.
Magnatune moved to a membership plan in 2008 and in 2010 dropped the CD printing service. The subscription model offers monthly or lifetime membership. Members can download as much as they want, or with a streaming membership can stream as much as they want. Many download formats are available and all music is without DRM.
Magnatune encourages buyers to share up to three copies with friends. All of the tracks downloaded free of charge are licensed under the Creative Commons Attribution-NonCommercial-ShareAlike (BY-NC-SA) License.
It's legal to play Magnatune music on a non-commercial podcast without paying collecting society fees to organisations such as ASCAP, BMI or SoundExchange.
- Dave #1:
- Album: Mokhov, "Future Hope"
- Track: Echo Love (3:56)
- Genre: Electronica
- Link: http://magnatune.com/artists/albums/mokhov-futurehope
- Andrew #1:
- Album: Mystic Crock, "Difference"
- Track: The Difference (Calming Down) (9:04)
- Genre: Ambient, Electronica
- Link: http://magnatune.com/artists/albums/mysticcrock-difference/
- Dave #2:
- Album: Yumi Kurosawa, "Beginning of a Journey"
- Track: Inner Space (2:30)
- Genre: World, Other
- Link: http://magnatune.com/artists/albums/yumi-beginning
- Andrew #2:
- Album: Sandeep Bhandari, "Dive Volume 1"
- Track: Rich In Loss (5:27)
- Genre: Electronica
- Link: http://magnatune.com/artists/albums/sandeep-diveone/
- Dave #3:
- Album: Kalabi, "Music for Televisions Vol 2"
- Track: Organoid (3:41)
- Genre: Electronica
- Link: http://magnatune.com/artists/albums/kalabi-mtvtwo/
- Andrew #3:
- Album: Robert Rich, "Due Acque - Live Archive Vol 2"
- Track: Due Acque part 07 (7:08)
- Genre: Ambient, New Age
- Link: http://magnatune.com/artists/albums/rrich-due/
The picture we mentioned when discussing the artist Kalabi
See also http://www.museumwaalsdorp.nl/en/airacous.html if you want more.
- Wikipedia entry on Magnatune: https://en.wikipedia.org/wiki/Magnatune
- Magnatune site: https://magnatune.com/
- Wikipedia entry on Creative Commons: https://en.wikipedia.org/wiki/Creative_Commons_license
- John Buckman's blog: http://john.redmood.com/
- Web-based Magnatune player: http://greattuneplayer.jit.su
Joining commands together
In this episode I want to look at more movement commands and how to use them in conjunction with commands that change things in the file. I also want to add some more elements to the configuration file we have been building over the last few episodes.
I have covered a lot of ground in this episode, introducing a number of new subjects. This is partly because I felt the series needed to get to the point where you could start to make full use of Vim if you are following along, and partly because the episodes up to this point have been moving a little too slowly! I hope the change in pace and length hasn't put you off.
Since the notes explaining this subject are particularly long, they have been placed here: http://hackerpublicradio.org/eps/hpr1776_full_shownotes.html and an ePub version is also available here: http://hackerpublicradio.org/eps/hpr1776_full_shownotes.epub.
- Vim Help:
- Using Help: http://vimdoc.sourceforge.net/htmldoc/helphelp.html
- Motion: http://vimdoc.sourceforge.net/htmldoc/motion.html
- Searching: http://vimdoc.sourceforge.net/htmldoc/pattern.html
- Insertion: http://vimdoc.sourceforge.net/htmldoc/insert.html
- Changing: http://vimdoc.sourceforge.net/htmldoc/change.html
- Options: http://vimdoc.sourceforge.net/htmldoc/options.html
- Graphical Cheat Sheet: http://www.viemu.com/a_vi_vim_graphical_cheat_sheet_tutorial.html
- Vim Hints Episode 3 http://hackerpublicradio.org/eps.php?id=1734
In this review of the Sonic Pi software I have mentioned a couple of programs that I wrote the listings are here:
============================ The Hippopotamus Song ============================ use_bpm 180 # use_transpose -12 use_synth :fm 2.times do play_pattern_timed [:D3,:G3,:G3,:G3], [1,1,1,1] # 1 extra note from bar an bar 2 play_pattern_timed [:G3,:D3,:B2,:G2], [0.5,0.5,1,1] # 3 play_pattern_timed [:a2,:b2,:c3], [1,1,1] # 4 play_pattern_timed [:b2,:b2,:a2], [2,0.5,0.5] # 5 play_pattern_timed [:g2,:g3,:g3], [1,1,1] # 6 play_pattern_timed [:fs3,:g3,:e3], [1,1,1] # 7 play_pattern_timed [:d3,:d3], [4,1] # 8 9 play_pattern_timed [:g3,:g3,:g3], [1,1,1] # 10 play_pattern_timed [:g3,:d3,:b2,:g2], [0.5,0.5,1,1] # 11 play_pattern_timed [:a2,:b2,:c3], [1,1,1] # 12 play_pattern_timed [:b2,:b3,:a3], [2,0.5,0.5] # 13 play_pattern_timed [:g3,:fs3,:e3], [1,1,1] # 14 play_pattern_timed [:a3,:fs3,:e3], [1,1,1] # 15 play_pattern_timed [:d3,:d3], [4,1] # 16 17 play_pattern_timed [:a3,:a3,:a3], [1,1,1] # 18 play_pattern_timed [:e3,:e3,:e3], [1,1,1] # 19 play_pattern_timed [:a3,:a3,:a3], [1,1,1] # 20 play_pattern_timed [:e3,:a3], [2,1] # 21 play_pattern_timed [:c4,:b3,:a3], [1,1,1] # 22 play_pattern_timed [:a3,:b3,:gs3], [1,1,1] # 23 play_pattern_timed [:a3,:d3], [4,1] # 24 25 play_pattern_timed [:e3,:fs3,:g3], [1,1,1] # 26 play_pattern_timed [:fs3,:d3,:d3], [1,1,1] # 27 play_pattern_timed [:e3,:fs3,:g3], [1,1,1] # 28 play_pattern_timed [:fs3,:d3,:d3], [1,1,1] # 29 play_pattern_timed [:c4,:b3,:a3], [1,1,1] # 30 play_pattern_timed [:g3,:fs3,:e3], [1,1,1] # 31 play_pattern_timed [:fs3],, sustain_level: 0.6, sustain: 1, decay: 3 # 32 sustain note into next bar play_pattern_timed [:g3,:fs3], [1,1] # 32 play_pattern_timed [:e3,:d3,:fs3], [1,1,1] # 33 play_pattern_timed [:g3,:d3],[3,3] # 34 35 play_pattern_timed [:c3,:b2,:a2], [1,1,1] # 36 play_pattern_timed [:d3], # 37 play_pattern_timed [:g3,:fs3,:g3], [1,1,1] # 38 play_pattern_timed [:e3,:a3,:g3], [1,1,1] # 39 play_pattern_timed [:fs3,:e3,:fs3], [1,1,1] # 40 play_pattern_timed [:d3,:d3],[2,1] # 41 play_pattern_timed [:b3,:b3,:a3], [0.5,1.5,1] # 42 play_pattern_timed [:g3,:d3,:d3], [0.5,1.5,1] # 43 play_pattern_timed [:c4,:c4,:b3], [1,1,1] # 44 play_pattern_timed [:a3,:e3,:d3], [0.5,1.5,1] # 45 play_pattern_timed [:e3,:fs3,:g3], [1,1,1] # 46 play_pattern_timed [:d3,:b2,:g2], [1,1,1] # 47 play_pattern_timed [:a2],, decay: 3 # 48 play_pattern_timed [:a2,:b2,:a2], [1,1,1] # 49 play_pattern_timed [:g2],, decay: 3 # 50 play_pattern_timed [:g2], # 51 sleep 2 end ======================================= The HPR Outro theme - hack on this improve it and make a show ======================================= in_thread do use_bpm 180 use_transpose 24 use_synth :beep 19.times do play_pattern_timed [:a,:as,:a,:a], [0.5],release: 0.02, amp: 0.3 # play_pattern_timed [:as,:f,:as,:a], [0.5],release: 0.02, amp: 0.3 # end end use_bpm 180 sample :elec_hi_snare sleep 0.5 sample :elec_hi_snare sleep 0.5 sample :drum_bass_hard sleep 0.5 use_transpose -0 use_synth :saw 2.times do play_pattern_timed [:a,:a,:a,:a], [0.5,1,0.5,1] # 3 play_pattern_timed [:a,:as,:a], [1,1,1] play_pattern_timed [:c5], , decay: 2 # 6 play_pattern_timed [:a,:a,:a,:a], [0.5,1,0.5,1] # 3 play_pattern_timed [:a,:as,:a], [1,1,1] # 6 play_pattern_timed [:f], , decay: 2 # 6 end use_synth :dsaw play_pattern_timed [:f], play_pattern_timed [:c5],, decay: 1.5 play_pattern_timed [:as,:a,:as],[1,1,1] play_pattern_timed [:a], play_pattern_timed [:c5],, decay: 1.5 play_pattern_timed [:f], play_pattern_timed [:c5],, decay: 1.5 play_pattern_timed [:as,:a,:as,],[1,1,1] play_pattern_timed [:a], play_pattern_timed [:f],, decay: 1.5 play_pattern_timed [:f], play_pattern_timed [:c5],, decay: 1.5 play_pattern_timed [:as,:a,:as],[1,1,1] play_pattern_timed [:a], play_pattern_timed [:c5],, decay: 1.5 play_pattern_timed [:f], play_pattern_timed [:c5],, decay: 1.5 play_pattern_timed [:as,:a,:as,:a],[1,1,1,1] play_chord [:c4,:f], decay: 4 ===========================------------------------------------------------------------
- Flashing a router with alternate firmware
- Provide additional features
- Improve performance
- Privacy (gets rid of unwanted spyware)
- The DD-WRT Router Database: http://www.dd-wrt.com/site/support/router-database
- Tomato Firmware for Linksys WRT54G/GL/GS: http://www.polarcloud.com/tomato
- OpenWRT firmware: https://openwrt.org/
How: Steps for My Latest Hack
- Find used Netgear WNDR3400 router on shelf at local Goodwill store, priced at $3.99.
- Use my smartphone to check the dd-wrt database to see if this router is hackable.
- Grin broadly upon seeing the green "Yes" beside router WNDR3400.
- Double-check that power supply is included, find an AC outlet and plug in to be sure it powers on and my phone sees its ESSID. Yep and yep.
- Take router to cashier and purchase.
- Do hard reset of router to clear any previous configuration.
- Hook a laptop up to router using ethernet patch cable (turning off WiFi adapter on laptop).
- Access router's configuration in web browser at default router address of 192.168.1.1 just to confirm that it works.
- Go back to the dd-wrt router database and find the router again, then download the corresponding "mini" and the "mega" versions of dd-wrt firmware (The mega version has the most features—including USB support, which I wanted—but on many routers, including this one, you have to install the mini version first or else you could brick the router)
- Read over the dd-wrt wiki page for this specific router just to see if there's anything unusual about the hack. There's not.
- Go to the router's stock configuration page again and find the "Firmware upgrade" button.
- Click the button and choose the "mini" version of the dd-wrt firmware, and click upgrade, then wait while crossing fingers until it says firmware successfully upgraded.
- Refresh the configuration page at 192.168.1.1 and see the new dd-wrt configuration interface.
- Pat myself on the back because I have just hacked another router. Hray!
- Find the upgrade firmware area on the new dd-wrt interface, and this time choose the "mega" firmware file and submit, then wait and cross fingers as before. Celebrate when it works.
- Configure newly hacked router as wireless bridge (this is NOT going to be my main router), enable the USB and printer support, hook up our formerly-usb-only printer to the router, and configure household computers to be able to print wirelessly to the newly-networked printer.
- Enjoy kudos from appreciative family.
has been a free speech advocate, economic justice organizer and civil liberties defender. After working in Massachusetts politics for fifteen years, she then became involved in the free software movement at the Free Software Foundation.
Defensive Publications info: http://www.linuxdefenders.org/?page_id=150
Seattle GNU/Linux Conference http://seagl.org/ IRC on Freenode in #seagl. Were very excited to be returning to Seattle Central College for SeaGL on Friday October 23rd and Saturday October 24th, 2015. SeaGL is a grassroots technical conference dedicated to spreading awareness and knowledge about the GNU/Linux community and free/libre/open-source software/hardware. Cost of attendance is free. Attendee Registration will not require the use of non-free software. You may attend SeaGL without identifying yourself, and you are encouraged to do so to protect your privacy.
- Gnu Media Goblin http://mediagoblin.org/
- Join us on IRC:#mediagoblin on irc.freenode.net
My blogsite as well as just one of the many posts on my site that deal with what I appreciate about my life in general
Label Tracks in Audacity
I don't know if I'm ignorant and everyone else already knows about this, but I decided to record a quick show about Audacity "Label Tracks," something I discovered while working on another HPR episode today.
The label track is one of the most useful things I've found in a long time. It allows you to annotate your audio project so that you can quickly see important spots or summarize the contents of whole segments and see at a glance what they are about without hunting all over the place and playing things back, trying to find the part where you were talking about X,Y, or Z. You can also export the labels as a plain text file with exact timestamps. I have not tried this, but according to the documentation you can also use labels to mark the beginnings of separate songs in a long track and export multiple separate files at once from a single source based on the labels.
To add a label track, go to the
Tracks menu and select
Add New --> Label Track, and it will add the label track to the bottom of your list of tracks. To add a label, either stick the cursor where you want the label to be and press
ctrl+b to add text, or select a region to label by clicking and dragging over a region in the label track, then do
ctrl+b to start typing the label text.
- Audacity Label Tracks Documentation: http://manual.audacityteam.org/o/man/label_tracks.html
In this episode I talk about how you can take advantage of the OpenDyslexic font as a user, and also how as a content provider you can use it to help your readers. Incidentally, we also talked about this for a while during episode 1418, one of the 2013 New-Year shows.
- OpenDyslexic's Website: http://opendyslexic.org/
- Debian, Ubuntu package name:
- Fedora package name:
- Arch package name:
- Chrome Browser Extension
- Firefox Browser Add-on
- CSS3 Web Fonts Documentation: http://www.w3schools.com/css/css3_fonts.asp
- Download dyslexic-friendly version of counterpoint books: http://jonathankulp.org/gratis.html
Transcript Performed by Dragon Dictate [dumped "as is"]
Hi everybody! This is John Kulp In Lafayette, Louisiana. I am going to do a rather strange episode today. What I'm doing is demonstrating the dictation software that I use on the office computer that I have here at work. If you listen to my previous episodes, then you have heard me speak of the blather speech recognition program that I use on my Linux desktop, but as you may also remember, blather is not a dictation tool. Blather is a tool where you have to set up commands that will run other commands. In other words, you have to configure everything from scratch. I do have some capabilities for dictation on my Linux desktop, but they involve using the Google Web speech API and a special dictation box that I have set up, and these are not at all good for longform dictation. For serious dictation, such as writing letters and memos and other longform text, you really need a proper dictation tool. These are available built into the operating systems of Windows and Mac OS 10, but I normally use the Dragon naturally speaking software instead. I have found that it is more accurate and more powerful than the built-in versions that you can get on either Windows or Mac. That doesn't mean you shouldn't try out the built-in speech recognition on Windows and Mac, you definitely should, because I think you would be very impressed with him. I know for sure that the version on Windows learns from your voice and from the corrections that you make to the text that you were spoken, and eventually becomes very powerful in recognizing your speech. The biggest problem that I had with the Windows speech recognition was that it was a huge memory hog and frequently brought my system to a grinding halt. This is not good. Blather never does that, but then again bladder cannot take dictation. The latest system that I use for dictation is on a fairly recent Mac Mini running the nuance Dragon Dictate software. This is a very powerful dictation program that learns from your speech patterns and you can also add words to the vocabulary so that it will get them right when it hears them. This is especially important to do if you have frequently used unusual words, such as a name with an alternate spelling from what is normally in the program's dictionary. One of the great things about the Mac Dragon Dictate program, also, is its ability to do transcriptions of audio files. In fact the reason I am speaking this way is that I plan to use the transcription of this recording as the show notes verbatim without any corrections. The difficulty that most people have with dictation software at least initially is doing things like punctuation and capitalization. You have to remember to do these things or else your transcript will come out without any punctuation or capitalization, unless the words that you are speaking are known proper nouns. It also capitalizes automatically at the beginning of the sentences, so that if you use periods frequently then you will have capitalized words after those periods. You can see that I'm having trouble speaking this text in a fluent way, and this is one of the other difficulties that people have when initially using transcription software. It works best when you can express complete thoughts without pausing, because it learns from the context of your words. It has algorithms that calculate the possibility of one word or another based on the context, and so it is much better to speak entire sentences at one than it is to pause while trying to gather your thoughts. This is a major difference from trying to write at the keyboard, where it does not matter at all if you pause for seconds or even minutes while you think of what you want to write next. Anyhow, I highly recommend using some kind of dictation software if you suffer from repetitive strain injuries like I do. This will save you many thousands of keystrokes. Even if it's only using the speech recognition that's available on your phones over the web, that's better than nothing. The disadvantage of any of these services that have to send your recording over the web to get a transcription and then send it back into your device is that they will never learn your voice and your particular speech patterns. In order for that to work best, you really have to use a dedicated standalone speech recognition program that resides locally on your computer and saves your profile and learns from your speaking. Well, I guess that is about it for today, I hope you have enjoyed hearing this brief lesson on dictation. See you next time!
- Dragon Dictate for Mac
- Video Screen Capture of Dragon Dictate Transcribing this episode: https://youtu.be/jlkpz2nhZ38
- Music bumpers are from Kimiko Ishizaka's The Open Goldberg Variations: http://www.opengoldbergvariations.org/, used by permission of their CC0 1.0 Universal (CC0 1.0) Public Domain Dedication license.