Broken Remote

January 24, 2009

AppServ 2.6.0 on localhost

Filed under: internet, web — Tags: , , , , , — Broken Remote @ 11:48 pm

If you’re running the newest version of AppServe (2.6.0)  as a local web server, take note:

When installing, do not install to “localhost”. Instead, you must use 127.0.0.1. If you have already installed it, browse to phpmyadmin/config.inc.php and change the server host line from localhost to 127.0.0.1.

See the third post on this forum. I’ve pasted in the post below:

The problem is that you are trying to use named pipe connection. You should use the tcp connection, so localhost -> 127.0.0.1

http://hu2.php.net/function.mysql-connect
Note: Whenever you specify “localhost” or “localhost:port” as server, the MySQL client library will override this and try to connect to a local socket (named pipe on Windows). If you want to use TCP/IP, use “127.0.0.1″ instead of “localhost”. If the MySQL client library tries to connect to the wrong local socket, you should set the correct path as Runtime Configuration in your PHP configuration and leave the server field blank.

Simply modify this line in the phpmyadmin/config.inc.php

$cfg['Servers'][$i]['host']          = ‘localhost’;

to this:

$cfg['Servers'][$i]['host']          = ‘127.0.0.1′;

it worked for me;)

I had this problem recently and that fixed it. If you don’t fix it, you won’t be able to open phpmyadmin or connect to any databases.

I’m also getting this error, but I haven’t troubleshooted that one yet :)

Strict Standards: date() [function.date]: It is not safe to rely on the system’s timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected ‘America/New_York’ for ‘-5.0/no DST’ instead

January 19, 2009

Make: Technology on Your Time

Filed under: blog, electronics, internet — Tags: , , — Broken Remote @ 2:42 pm
Logo

I thought I’d just highlight my favorite website/blog – frequent features of various DIY and other electronic or similar projects found on the web or submitted. It’s sort of the Lifehacker for the hardware-inclined. :)

I usually check the Blog a couple quick times a day: http://blog.makezine.com/

There is a ton of content and it is updated often. They even have a store with several neat little gadgets and such. Check it out!

January 13, 2009

Digital TV Is Coming…

Filed under: tv — Tags: , , , , — Broken Remote @ 12:25 am

Everyone knows that the switch to digital television is coming, it’s been advertised for long enough. Unfortunately, though, there aren’t a lot of places that adequately describe just what the switch is about. Granted, most people probably don’t care that much, but I do.

PBS describes things well: http://www.pbs.org/opb/crashcourse/digital_v_analog/

Go there and read for the most detail, but here’s a quick overview. Analog broadcasts transmit a standard NTSC quality picture and two (stereo) sound channels. It uses 6Mhz per channel. Digital broadcsts transmit up to HD quality signals with 5.1 channel audio.  Somehow digital signals have to transmit a lot more data in the same amount of space. This is done by compressing the digital video signal using MPEG-2 compression. MPEG-2 has been reported to get up to 100:1 compression, but it’s probably closer to 50:1 on average.

So, with 1/50th of the video data to send (well, not quite since the video is higher resolution), there’s more room for the improved audio quality and potentially a lot of other data.

Keep in mind that TV will still be broadcast over the airwaves, just using the new digital format. Most current antennas will continue to work, so you probably don’t need a new one.

Also, there’s now the potential for one station to “multicast,” which means send multiple signals at once. You may have seen channels like 7-1, 7-2, etc on your new TV. That’s one channel broadcasting multiple signals at once. Generally they are the standard definition and high definition signals, but it’s possible to broadcast different shows at once.

A converter box has nothing to do with your antenna. Yes, you plug your antenna into it, but you only need the box if your TV doesn’t have a digital tuner. If you have cable or satellite, you don’t need a converter box, even if your TV doesn’t have a digital tuner – this is because the cable/satellite box does the converting for you. Those TVs that do not have a digital tuner and are not on cable/satellite require the converter box to convert the digital signal from the antenna into an analog signal your TV can read.

Fun, huh? Digital TV is really going to change things. There’s a whole bunch of extra space to send other signals. Imagine interacting with your TV (kind of like the way you can play games through your cable box), way advanced picture-in-picture features, and more. It will be a while yet, but TV of the future is going to be something else. Watch out for commercials that let you play a trivia game or educational channels that let kids learn to count by selecting numbers in the right order.

We’ll see what’s to come…here’s a nice PDF of the broadcast spectrum: http://www.ntia.doc.gov/osmhome/allochrt.pdf

January 10, 2009

Christmas Light Show

Filed under: electronics, video — Tags: , , , — Broken Remote @ 2:50 pm

Here’s a video of a Christmas light show myself and another guy did as part of an undergraduate course. The actual hardware was already created for us, so we didn’t have to worry about the high voltage switching and all that. Our job was to write a program in MASM to write out through a parallel port to control the switches.

This video is a little overboard for what the lab required, but we thought why not do something really neat with this since we have it in front of us. See the video below, or read some more details about how it works below the video.

Like I said, the program was written in MASM. That’s the Microsoft Assembly Language. This worked OK, but MASM isn’t ideal for this sort of project. Since we ran this program on a Windows machine, there are a lot of timing issues. If you watch the video a couple times you’ll pick up on some of them. Windows is an interrupt-based operating system, so our program wasn’t guaranteed to run like we wanted it. In the end we had to run it with realtime priority in Windows XP to get any sort of reasonable result.

The program was written as one giant data table. Here’s an example of that code:

                BYTE    01110111b, 01110111b, 11100111b,  MAIN_EIGHTH    ; Da, da, da, da, da, da, daaa (second time) (start in center and go out to bottom bars then back in) [Q]
                BYTE    01110111b, 01110111b, 11100111b,  MAIN_EIGHTH + MAIN_ADJUST_A   ; |
                BYTE    11111111b, 11111111b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11111111b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11111111b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11111111b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11111111b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11111111b, 11101111b,  MAIN_EIGHTH    ; |

                BYTE    11111111b, 11101110b, 11101111b,  MAIN_EIGHTH    ; | [QLP]
                BYTE    11111111b, 11101110b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11101110b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11101110b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    01110111b, 01100110b, 11100111b,  MAIN_EIGHTH    ; | Dum dum
                BYTE    01110111b, 01100110b, 11100111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11101110b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11101110b, 11101111b,  MAIN_EIGHTH    ; | 

                BYTE    01110111b, 01000100b, 11100111b,  MAIN_EIGHTH    ; | [QLPKO]
                BYTE    01110111b, 01000100b, 11100111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11001100b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11001100b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11001100b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11001100b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11001100b, 11101111b,  MAIN_EIGHTH    ; |
                BYTE    11111111b, 11001100b, 11101111b,  MAIN_EIGHTH    ; |

The three bytes at the beginning are data bytes that control the lights. The most significant three bits of the third byte are unused. The last byte, seen as MAIN_EIGHTH above, is a delay. We have several constants defined that define delay in milliseconds. MAIN_EIGHTH represents 1/8 of a beat in the primary portion of the song. We used quarter notes and sixteenth notes here and there too. The MAIN_ADJUST_A is a small adjust to help synchronize things. This segment is fairly clean, but other segments have tons of adjustments made to them. Ideally, this program should have been written on an embedded system, but that wasn’t part of the project.

To execute the program, there is a while loop that shifts the first three bytes out serially, then calls a delay routine. In the end, you get pretty good results.

January 5, 2009

How People View the Web

Filed under: web — Tags: , , — Broken Remote @ 12:35 pm

I found this interesting study on the web about what people look at on web sites. The results indicate that people read in an “F” pattern. Here’s a quote from the study:

In our new eyetracking study, we recorded how 232 users looked at thousands of Web pages. We found that users’ main reading behavior was fairly consistent across many different sites and tasks. This dominant reading pattern looks somewhat like an F and has the following three components:

  • Users first read in a horizontal movement, usually across the upper part of the content area. This initial element forms the F’s top bar.
  • Next, users move down the page a bit and then read across in a second horizontal movement that typically covers a shorter area than the previous movement. This additional element forms the F’s lower bar.
  • Finally, users scan the content’s left side in a vertical movement. Sometimes this is a fairly slow and systematic scan that appears as a solid stripe on an eyetracking heatmap. Other times users move faster, creating a spottier heatmap. This last element forms the F’s stem.

The study is more for web developers than anyone else, but it’s still very interesting to read through.

Blog at WordPress.com.