Acrylic Column #1 (Bubble Display testing)

I finished test column #1 today. I was able to cut the extruded acrylic tube using a miter saw with no major difficulties, and pulled it across a piece of sandpaper on a glass backing to try to ensure that the end was perfectly flat. I had to use a good amount of solvent to weld the 1″ square bottom plate to the bottom of the square extruded acrylic tube. Even after my initial weld, it had some pinhole leaks that would “weep” water. I fixed them by turning the tube sideways and wiping a liberal amount of solvent along each of the four seams, allowing it to seep into the gaps (and/or melt acrylic into the gaps.)

A 1" square tube of acrylic with a bottom plate cemented to it.

As far as I can tell Continue reading

Missed Schedule for wordpress posts due to .htaccess password protection blocking wp-cron.php

I recently set up a private blog that is fully password protected using an .htaccess file. (Users have to enter a username and password to view anything on the blog.) Everything was working well until we tried to set up posts scheduled to publish in the future. They would not post. The dashboard would show “Missed Schedule” and we would have to publish them manually.

After lots of head scratching, I finally figured out what was causing this. Apparently wordpress will call the wp-cron.php file every time a user views a page. HOWEVER, because the web server is doing this, and not the user’s browser, if the wp-cron.php file is protected by a .htaccess user authentication system it will not load (because wordpress doesn’t have the correct username/password!). So none of your scheduled actions will take place.

The solution is to allow (only) that file to be loaded without the normal username/password check in your .htaccess file like this:

#Require username and password for all files!
AuthName "Enter your username and password:"
AuthType Basic
AuthUserFile /home/yourdirectory/.htpasswd
Require valid-user

#Exclude the wp-cron.php file!
<files wp-cron.php>
Order Allow,Deny
Allow from all
Satisfy any
</files>

Of course, if your blog is password protected, the wp-cron.php file won’t get hit until somebody logs in to view the blog…but at that point any tasks that are pending will activate.

Spare One Phone – Dead on Arrival – Two Red LEDs

Spare One Phone with both indicator LED's glowing solid red

UPDATE: I called the company twice (once on Monday and again on Tuesday) and on Tuesday after asking a few questions they shipped me a new phone (arrived on Saturday and worked correctly!) and a label to ship back the defective unit. (I also emailed them on Sunday, and received an email reply 8 days later, after already receiving the replacement phone…so I would recommend persistent phone calls (it took a few tries to get to a human instead of voice-mail) over email.

Original post:
I purchased a SpareOne phone, which is a very simple GSM handset that is powered by a single AA battery. It has even less functionality than the Motorola MotoFone F3, as it has no display other than two indicator LEDs, so you can’t send or receive SMS messages. It comes with an Energizer Ultimate Lithium battery which has a 15 year shelf life (if you keep the battery disconnected from the phone with the provided plastic pull strip) and offers “up to” 10 hours of talk time on a single battery. My invoice number was 393, so it looks like I was within the first few hundred orders.

Unfortunately, when I received the phone and pulled the battery guard out, instead of turning on it just lit up both LED’s solid red (which I assume is some type of error code, although it is not mentioned in the small instruction sheet that came with the phone. I have tried a new battery, veracious press combinations of the ON button, and the keylock button, etc, but have gotten none of the feedback beeps demonstrated in the “how to” videos.

I will be calling their support line on Monday to see if they have any advice for how to re-set it, or return it for a replacement.

Boost Converter Schematic

Schematic showing a 2 phase boost controller with voltage and current sense
I have drawn up a schematic (click to enlarge) of the high current and sensing portions of my maximum power point tracking (MPPT) 2-phase boost converter battery charger circuit.  The schematic does not include the micro-controller, MOSFET gate driver IC, and associated power supplies, as those items are on the (relatively) low-power side of things.

What do all of these things do?

  • L1, Q1, and D1 – These three components make up the heart of the boost converter. When Q1 turns on, power builds up in L1 as the current rises. When Q1 turns off, all of that power exits via the only available route (out past D1) and the voltage is boosted as the inductor (L1) resists the current change. If you turn Q1 on and off very quickly (under control of the micro-controllers’ PWM output via a MOSFET gate driver) it raises the output voltage higher than the input voltage.
  • Continue reading

Using the Microchip PIC Kit 1 with Linux

Microchip PICKit 1

The PICKit 1 is a combination programmer and development board for midrange PIC micro-controllers. In addition to being able to program FLASH pic devices, it also allows them to run and access 8 (charlieplexed) LED’s, a pushbutton switch, and a potentiometer. It’s a great little board for learning the basic of micrcontroller programing, but unfortunately it is not supported by Microchip’s new MPLAB X software (that is written in Java, and supports Linux/Mac in addition to Windows).

You CAN however use the PICKit 1 under linux. The piclab software is supposed to support it (I have not tested this). I use version 1.6 of the PicKit1 flash usb programmer for unix. Even the newest 1.6 version reports checksum errors after writing the hex file, but it does work correctly.

To make it work as an external program in MPLABX I had to select the “format HEX file for download” option under the Linker so that it would not fill all 2048 flash bytes when the program was smaller than that. I am able to manually run the usb_pickit command after building to flash the code, but it’s kind of annoying, as that program has a problem verifying the checksum and reports an error every time (which is interpreted as a build failure) plus, I have to run mplab X with root permissions to be able to access my USB port.

Solar Panels on the Electric Truck

Two 175 watt solar panels mounted to the bed cover of my electric pickup truck.
I purchased two used GE Energy GEPVc-175 watt solar panels and mounted them to the bedcover of my truck using 10-24 machine screws and T cone washers as rubber vibration dampers. Each panel weighs 31 pounds, and is rated to deliver up to 175 watts of power in full sun (at around 36 volts each, or 73.4 volts at 4.7 Amps in series). I am still waiting on a group of Georgia Tech ECE students for the magic box that does maximum power point tracking (MPPT) and voltage boosting to charge my 120 volt battery pack, but I hope to be generating 1-3 miles of my daily commute from the sun soon. As my daily commute is 4 miles, this can be a significant percentage of my total energy usage.
Diagram showing the panel layout over bed cover support structure.

I have calculated that in the summer the panels are far enough behind the cab that they will not be shadowed by it, even if I have to park facing south. In the winter and early spring / late autumn I need to park facing north to avoid shading a strip of the solar panels.
I still need to figure out a way to tilt the panels towards the sun to collect as much energy as possible. This is especially critical during winter, when the solar angle is way off of vertical. As the bed cover tilts, AND the bed of the truck can tilt (the other way) I figure I can work something out (with a few pieces of wood cut to the correct height, or linear actuators if I want to get fancy.

Ferrofluid Sculpture test 2

After buying some strong rare earth magnets I re-tried my ferrofluid levitating sculpture. The main problem is that the ferro-fluid moves to the poles of the magnets (top and bottom, with gravity favoring the bottom) and does not surround the sides of the magnets. It was also hard to get enough small magnets to fit under the main magnet (as they repel each other), so I had to include a screw in the middle to get the weight correct.

Note: Working with Ferro-fluid is dirty and messy. If magnets snap together they can throw dark oily fluid which stains just about anything. Be sure to have lots of paper towels on hand, jars/shields under/around everything, and don’t work in a nice room. Dish detergent and abrasive scrubbing will eventually get it off of most surfaces that are not porous. Wear disposable rubber gloves and use disposable pipettes. Wear disposable clothes. Don’t use any of your wife’s kitchen appliances or instruments that you can’t afford to replace.

Update: After floating under the magnetic levitation for 24 hours, the ferro-fluid became much less “spiky” and eventually the drops at the end of the magnets became spherical.

Also, cleaning ferrofluid from a magnet is almost impossible.

Tracking individual battery voltages

Line graph that shows the voltage of six batteries dropping under load. All six batteries follow the same deep V pattern, staying within 0.1 volt of each other.

This graph shows the voltage (multiplied by 10, so 65=6.5 volts, and 50 = 5.0 volts) batteries 1-6 of my electric pickup while accelerating. My first battery (blue) is consistently 0.1 volt below the others, so I am keeping an eye on it. But this graph shows that although it is a 1/10th of a volt lower, it does not sink lower than the other batteries under load, so it appears to be holding up well so far.

The graph also shows off my new (to me) Pak Trakr system. The Pak Trakr system connects to each battery in your pack with small remotes that daisy chain together. Each remote monitors six batteries and transmits the voltage levels once a second to a display and optional serial data logger.


Ubuntu 10.04 AMD Radeon M6 chipset and Extron Electronics video multiplexer

After working perfectly for 4.5 weeks with the same podium setup, my Thinkpad X31 laptop refused to output VGA video to the Extron Electronics video multiplexer box at school.
It appears that the Extron Electronics box is not sending out proper Extended Display Identification Data (edid) which tells the laptop what resolutions it supports. My xrandr command finds the data for my laptop video display screen, but not for the VGA-0 port:

VGA-0 connected (normal left inverted right x axis y axis)
LVDS connected 1024x768+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
   1024x768       60.0*+   60.0
   800x600        60.3     59.9
   640x480        59.9     59.4

I have no idea why this started today. I don’t remember applying any patches to X-org in the last two days, and the technicians in charge of the podium swear that they didn’t change out anything.

I figured out a fix to make it (mostly) work. Tell xrandr to go ahead and force the VGA-0 port to a specific resolution with the following command:

 xrandr --addmode VGA-0 1024x768

This mostly works, but the sync signal is slightly off, leaving a black bar of 20-30 pixels on the left side of the screen. It is also annoying to have to run that command every time I want to display to the podium.

NetMedia iViewHD 2M POE Camera Review with ZoneMinder

Small silver camera
I have recently purchased a NetMedia iViewHD 2M power over Ethernet (POE) camera (retail price $105) for use with ZoneMinder.

This small camera must be hard-wired into a switch that provides power over Ethernet (which will cost another $80-100, but allows you to power up to 4 POE devices). I bought mine used, and don’t plan on buying more. The one I bought would reset to factory defaults (requiring you to upload a new “website”) every few months, and after a year of use it died completely (won’t respond to DHCP address assignments). At used prices the NetMedia iViewHD 2M could be a good deal for daytime shots, despite my nighttime image quality complaints below, if the one you buy lives longer than mine, but I can’t recommend it.

Continue reading