> mostly stupid bash tricks_ 

c u t u p @ c u t u p . o r g


[770 wlan dynip] last modified: 09/18/2007 05:51 pm

I wanted to have my 770 do dynamic dns update. In the past, due to ignorance of anything better I've just written a shell script that gets cronned every 15 mins or so that sees if anything's changed, and if so updates my IP with curl. But the 770 doesn't have cron.

So I went looking for some sort if interface up hook. /etc/init.d/ was the only place I knew to look - but it turns out that scripts in there just get called when the interfaces go up, not when a wlan connection happens, so that was no dice. I couldn't find anything else, and ended up finding someone had ported a working cron to 770, so for a while I just used that.

Then today, I found out about dbus, which led me to /etc/udhcp, and bingo, that was it. I added a line that calls my dynip script at the appropriate spot in /etc/udhcp/udhcp.script, which seems to be the one that actually runs, and it works great - only checks/updates on wlan connect.

[770 scripts] last modified: 09/12/2007 05:20 pm

I got a Nokia 770 recently - fun thing to play with. I've stuck some of the stuff I've been working on in svn.

I managed to get a semi-working scratchbox and to compile some stuff I was missing and couldn't find. The one I really wanted was diff, and I managed to get that compiled, so theres cmp, diff, diff3, and sdiff. Also threw in cal.

I also managed to get nvi compiled. The busybox vi is pretty terrible, and vim seems kind of overkill for a 770 plus the port to 770 advertises itself as fairly tricky and incomplete. I haven't noticed any issues with this binary so far.

Also a little lan manager script (lan) that can show internal and external IP and wlan name. You need curl and wireless-tools for that.

Finally, my famous command line twitter client tweaked to use /bin/sh :)

[All Posts] [top]