Monday, September 28, 2009

554 5.3.5 Local configuration error

I spent a few hours tonight trying to get rid of this error from sendmail on Linux. I added the new domain to the file below and all is good.


/etc/mail/local-host-names


This was a BlueQuartz server that should do everything for you from the web interface. Once in a while, it gets confused. The domain was listed in the file as www.example.com. I added example.com

Thursday, September 10, 2009

How to use a Voice Memo as a ringtone on the iPhone

You need to use terminal or SSH.

The voice memos are located in this folder as .m4a files.
/private/var/mobile/Media/Recordings

My ringtones are located in this folder as .m4r files. (Is this folder different for everyone?)
/private/var/stash/Ringtones.z8OJCu

Copy the m4a files to the ringtone folder and rename them as m4r. It worked but I might look for a GUI file manager next time.

Monday, August 3, 2009

iPhone + T-Mobile + Google Voice


(first photo with my iPhone)

I just wanted to jot this down in case I need it again soon.

  • Purchased an iPhone 3G from Ebay.
  • Plugged in an old AT&T sim card with no service to get to the home screen.
  • Used iTunes to upgrade the phone to 3.0.
  • With instructions from iphone-hacks.com, I ran Redsn0w to jailbreak and ultrasn0w to unlock.
  • Installed Google Voice with Cydia and it works!

You can not get 3G with T-Mobile but Edge works. Email works great, Safari is a little slow, Youtube is very slow.

Friday, May 22, 2009

Free AIS message decoder.

This will decode AIVDM and AIVDO messages from the command line. I was inspired by the Joe Petrix decoder in Basic and tried to do the same thing in c++.

Source code
Sample program output:
c:\>ais-decode
Enter AIS string. (Example !AIVDM,1,1,,A,1000vV@P00Idw98ATMk00?wj0<0n div="div" f="f">
AIS string: !AIVDM,1,1,,A,15LWgHpP00qdupBATUBbk?v00H0p,0*2E
ais_string= !AIVDM,1,1,,A,15LWgHpP00qdupBATUBbk?v00H0p,0*2E

message type = 1
repeat indicator = 0
MMSI = 365555555
navagation status = 8
rate of turn = 128
speed over ground = 0
position accuracy = 1
longitude = -88.043930
latitude = 30.708603
course over ground = 2764
true heading = 511
c:\>
Update: 2012
I just added an OSX binary.

Thursday, March 12, 2009

Tracking network printer usage with SNMP.

First I need a list of printer names or IP addresses. This is what I used but my printer descriptions all have the IP address listed.

net view \\printserver > printerlist.txt

          (sample printerlist.txt)
          printerA Print IP: 192.168.3.1
          printerB Print IP: 192.168.3.5

I installed Net-SNMP and created checkusage.bat.

for /F "tokens=4" %%a in (printerlist.txt) do (
echo %%a
snmpget -v 1 -c public %%a 1.3.6.1.2.1.43.10.2.1.4.1.1
)


This will give output like.

192.168.3.1SNMPv2-SMI::mib-2.43.10.2.1.4.1.1 = Counter32: 288975192.168.3.5SNMPv2-SMI::mib-2.43.10.2.1.4.1.1 = Counter32: 19710

I tried this with various HP, Minolta, Savin, Ricoh and Canon printers. Now I can run this monthly and import into a spreadsheet.

What I really need are the counters for color and B/W. I can not find those with SNMP.

Wednesday, February 18, 2009

How to restart all the computers on your network with PsShutdown.

net view > computers.txt

I used Wordpad to cleanup this file. Replace all "\\" with nothing. Replace all " " with nothing. There were a lot of extra spaces in the file and psshutdown did not like this. If descriptions show up in your file, you may need to use Excel for the cleanup.

psshutdown -c -r @computers.txt >> log.txt

Tuesday, August 5, 2008

How to combine many jpeg pics to make a video.

I used Zoneminder to pull an image from an Axis camera every 15 seconds. This captured 124k jpeg files. I then found this forum with help on creating the video. Here is the command I used to combine the jpegs into an avi.

mencoder "mf://??/*.jpg" -mf fps=25 -o output.avi -ovc lavc -lavcopts vcodec=mpeg4

And this is a sample of my video.