JBL Portable Bluetooth Speaker

Standard

JBL-Speaker-01

A couple of months ago I finally decided it might be convenient to have a portable Bluetooth speaker that I could use to play music from my phone or other device. The idea was that it would be something I could use when we’re playing a card game or outside grilling. After scrolling through numerous reviews on Amazon I encountered this little device, which I eventually received as a gift from my wish list.

The JBL Micro Wireless Ultra-Portable Speaker provides amazing sound considering its size. According to the documentation it will run on battery for about five hours, though some reviewers have experienced longer usage times. It’s also possible to use the device while recharging it.

Considering its size and relatively low cost (about $50), I am very impressed by this piece of tech. So was my wife. The first time I tried it out she immediately stated that she wants one. Friends have made similar comments when showing it to them.

There are other very similar JBL models. This particular one has a built-in bass port.

It’s been useful in cases when I didn’t expect it. For example, the turn-by-turn navigation instructions from Google Maps sounded excellent.

JBL-Speaker-02

 

Using a Belkin Bluetooth Car Hands-Free Kit with an iPhone 5

Standard

Belkin-Bluetooth-02

I recently switched from an iPhone 4 to an iPhone 5 and as a result I now have access to Siri. I’ve seen others attempt to use Siri and until I upgraded my phone I didn’t have much of an interest in using it. However, after a week I realized that it is very useful in one situation: driving.

In order to use Siri while driving I would have had to touch the phone. Not only is it distracting and potentially dangerous, it’s also illegal in the state that I live in. Unfortunately, I do receive phone calls and text messages while driving so I decided to look into purchasing a hands-free kit to use with the phone.

Continue reading

Triggering Music from mControl

Standard

The title of this post is more general than the actual task. Specifically, I implemented a new method to play a different song for each weekday the first time a motion sensor is triggered.

A while back I  played a song from iTunes whenever a specific event was detected in mControl (I’ve used two different methods to handle this). After I upgraded from version 2 to version 3 of mControl I held off on adding this capability back into the macros. The method for using iTunes worked fine but this time around I wanted to find something simpler to use that could be enhanced via scripting.

This time I used a free command-line utility called cmdmp3 that can play an MP3 file. In mControl I added a new item to a macro (Run Application), which executes a batch file that contains the necessary command-line parameters to play the songs. The batch file actually plays a different song for each weekday.

I’ve included the basic framework for the batch file. The code used to get the current day of the week and then run specific sections of the batch file was obtained from a forum post.

The batch file could use some refinement. For example, I had planned to place each song path in its own variable, but I had some problems getting the variables to work properly as parameters for cmdmp3. If I had worked that out then each section would simply have a song variable assigned to another variable that would serve as the parameter for cmdmp3.

Eventually I’d like to make the song selection randomized, which would considerably shorten the necessary code for the batch file by eliminating the test for the day of the week along with the related sections.

@echo off
for /f %%a in ('date /t') do set DAY=%%a
if %DAY%==Sun goto :sun
if %DAY%==Mon goto :mon
if %DAY%==Tue goto :tue
if %DAY%==Wed goto :wed
if %DAY%==Thu goto :thu
if %DAY%==Fri goto :fri
if %DAY%==Sat goto :sat

:sun
c:\tools\cmdmp3win.exe "filepath"
goto next

:mon
c:\tools\cmdmp3win.exe "filepath"
goto next

:tue
c:\tools\cmdmp3win.exe "filepath"
goto next

:wed
c:\tools\cmdmp3win.exe "filepath"
goto next

:thu
c:\tools\cmdmp3win.exe "filepath"
goto next

:fri
c:\tools\cmdmp3win.exe "filepath"
goto next

:sat
c:\tools\cmdmp3win.exe "filepath"
goto next

:next

Everything after “:next” can include whatever you may want to add after the song is played. If you don’t need to add anything then you can simply leave it as it is.

Updated 11/21/2011: I seem to have run into a familiar problem – executing external programs from within mControl. The batch file itself is sound but either mControl has a bug or the other program I’m using to execute external applications isn’t working properly. It may just be a configuration issue but I’ll need to spend some time on it before I can provide a proper solution for making this work from mControl.