Wednesday, September 29, 2021

More videos on Fire TV

This is a follow-up to my post when I just bought the Fire TV stick. The app has of course become out-dated after 3 years but it's actually quite easy to update to the latest version thanks to this guide. However, the update would break some add-ons that relies on Python 2. Fortunately, the broken add-on was fixed. Here are the instructions for installing this fixed version. And this is for taking advantage of the availability of Python 3. 

Wednesday, May 22, 2019

尋根

不時和家人說笑:「我們都是蘇東坡的親戚呢」不過其實心底也頗有疑問:蘇東坡是四川人,我家則來自潮州。今天花了點時間Google: 首先從此文得知潮安蘇氏的祖先是後隴蘇氏,亦即是宋朝著名科學家蘇頌的後人,而蘇頌和三蘇同時代,蘇洵曾經和蘇頌相認同宗。而兩家族的祖先都是蘇武父親蘇建。

Friday, July 20, 2018

RSS Video feed on Fire TV

Basically you need to install this app and then add a video source. Unfortunately the latter post has a typo: the URL should start with rss:// instead of http:// It took me half an hour to figure out! And to display Chinese character in file name, you need to click the "System" icon, open "Interface Setting"->Skin->Fonts and change to "Arial based"

Friday, October 03, 2008

SSH to your iPhone without password

Previously I wrote about offline browsing which involves SSHFS that requires you type in the root password of your iPhone everytime. To save some typing, you could setup SSH public/private keys. Here are the steps.

On the host that you mount iPhone's filesystem, execute:
ssh-keygen -t rsa
which generates a public and a private key. The former is ~/.ssh/id_rsa.pub

On your iPhone
1) create a ~/.ssh directory and copy the above public key over. Name it as .ssh/authorized_key.
2) Uncomment the following line in your /etc/ssh/sshd_config:
AuthorizedKeysFile .ssh/authorized_keys

Now you could ssh (and thus sshfs) to your iPhone without password.

Friday, September 05, 2008

Turn off Google Chrome auto-suggest

Here is why and how. I think Google knows enough about me so I'd rather not send even more info to them through the "Omnibox" (or "address bar" for the old school folks) Of course, no one force you to use it instead of Firefox but you are not in if you haven't tried it. I just hope there's a more obvious way to turn off auto-suggest. I thought it would be under "Option" but I had to Google a bit and finally found the above link.

How to read .docx?

The short answer is to ignore them so that nobody will use it anymore. The way this format (OOXML) became an ISO standard was not without controversy.

The long answer is to install a converter. (Microsoft provided one but I haven't tried) After you install this converter on Windows, simply double-click the .docx file on your computer and the converter will automatically convert it to OpenOffice.org's format (.odt) and open it in OpenOffice.org Writer.

Friday, August 22, 2008

iPhone Offline Browsing Step 4: httrack

As I said in my previous post, just install HTTRACK from Synaptic. Then execute:
httrack URL-of-the-site-to-mirror -O /mnt/iphone/ -%v

Once httrack finished, you could open: http://localhost from your mobile Safari to browse those pages. Don't forget to bookmark it!

iPhone Offline Browsing Step 3: sshfs

I want the /var/mobile/Site directory on iPhone to appear like a local drive on the host where I will execute HTTRACK. SSHFS is perfect for this, except there is no Windows port and my Linux box has died. So I installed andLinux Then it won't be easier to install SSHFS and HTTRACK. Simply use Synaptic. And look for these packages. Synaptic will take care of the dependencies for you.

Once SSHFS is installed, create a mount point (an empty directory) which you will use to refer to your remote directory (the one on iPhone) e.g. /mnt/iphone

Then execute:
sshfs root@:/var/mobile/Sites /mnt/iphone

BTW, to "disconnect" (more precisely, unmount), simply:
fusermount -u /mnt/iphone

iPhone Offline Browsing Step 2: lighttpd

Since Safari only works with websites but not local files, the way to get around this is obviously running a website on your iPhone using local HTML files (more precisely, running a HTTP server that serves those files) I installed lighttpd from Cydia for this purpose. Unlike OpenSSH:
1) it's not a featured app so you have to search for it
2) it requires a minimal amount of config (to understand the config, check its wiki. Otherwise you could always cut-and-paste)
3) it requires creating some directories if your iPhone is "virgin"
4) it requires a setup step (add a plist file) to make it start everytime you boot up the phone.

The directories I created are:
- /var/mobile/Sites: directory that stores your local HTML files
- /var/log/lighttpd: directory for log files
- /usr/etc: directory for config files

Basically I followed the steps by this poster except I cut-and-pasted the /usr/etc/lighttpd.conf from this poster in the same thread.

iPhone Offline Browsing Step 1: OpenSSH

One of the most useful "gateway" that opens up access to your phone is the widely used SSH (secure shell)

Once you have OpenSSH installed on your phone, you could connect to your phone from another host using SSH.

I easily found OpenSSH under the Featured App section in Cydia (an iPhone app that helps you to install other Apps. You can think of it as the "unofficial" App Store.)

Once it's installed, it runs in the background automatically. There is no icon for OpenSSH and no need to config it.

iPhone Offline Browsing Step 0: Jailbreak

Having heard all these horror stories of rendering the iPhone unusable after Jailbreak, I still couldn't resist the temptation to make my iPhone at least as good as my old WinMo. And the very first step is jailbreaking. Currently the fastest (and easiet to me) way is using QuickPwn. You could also try the download link here.

Some info that you might find helpful:
1) QuickPwn is supposed to work with 2.0, 2.0.1 or 2.0.2 firmware. Mine is 2.0.1 so I have no experience with the other ones.

2) QuickPwn needs your ipsw from Apple. I found it under "C:\Documents and Settings\\Application Data\Apple Computer\iTunes\iPhone Software Updates" I recommend you to make a copy of it just in case.

3) The real "action" happens inside the command-line window launched by the GUI. Just follow its instructions which involve turning your phone off and then back on (with a special sequence/combo of key pressing) It might sound weird but don't be scared.

Disclaimer: I am not encouraging anyone to jailbreak their phone and you have to understand that QuickPwn is beta software. I am not responsible for any potential damage done to your phone.

iPhone Offline Browsing

This is a 5 part series that describe all the steps it takes to archive a Web site to your iPhone and allows you to browse it offline (by now you all know that your iPhone doesn't always have an internet connection)

Step 0: Jailbreak your iPhone
Step 1: Install OpenSSH
Step 2: Install lighttpd
Step 3: sshfs to mount your iPhone to a PC
Step 4: HTTRACK to archive a your favourite website thru the sshfs mount

BTW, after all these is done, my iPhone could finally match my good old WinMo PDA in terms of offline browsing functionality.

Thursday, August 21, 2008

If your iPhone App refuses to launch......

You iPhone users might have run into this before: after you press the icon of an app, it opens a blank screen and then quickly close itself and go back to the home screen. Worse yet, it happens to all other apps too! You could try what works for me: uninstall the app and re-download it from the AppStore. Not only the downloaded app but also the existing apps will start working again.

This is so tricky that it doesn't sound like a plausible solution but apparently other users have figured this out too so it's probably legit.

Monday, August 18, 2008

Olympics and Globalization

Three Americans, Chris Kaman, J.R. Holden and Becky Hammon, are playing on basketball teams other than USA (Kaman plays for Germany while Holden and Hammon play for Russia)

And by now we are used to the many gymnasts, table tennis and badminton players who were trained in China and play for other countries.

Finally, the arguably biggest name in Chinese volleyball, Jenny Lang Ping, is coaching the American team.

For those who still don't believe in globalization, it's time to turn off the TV (and radio, internet...)

Wednesday, August 13, 2008

Where to find the geotags?

We all know iPhone 3G is capable of geotagging photos taken by the camera. The coordinates are stored in the EXIF data section of the JPG. So, what tool allows you to view the EXIF? JHead is one of such tool on Windows (command line, i.e, runs under DOS prompt) BTW, I googled to find out if GIMP allows you to view EXIF and couldn't find a definitive answer. If you know, please leave a comment here.

Wednesday, August 06, 2008

Apple helps fighting recession?

...... or making inflation worse? I'm no economist. All I know is Apple has altered its "universal connector" (found on iPod and iPhone) in iPhone 3G and made all sorts of accessories incompatible (glad that Apple chose the word "universal" instead of "Plays for sure" :P)

I found that out by plugging my old iPod FM transmitter/charger into my iPhone and it warns that it won't charge. So I googled and confirmed that charging thru the "Firewire" pin is no longer supported (only the "USB" pin works) and you will be surprised to see how many accessories out there uses the Firewire pin (perhaps a relic from the 1st gen iPod. Anyone remember it? It WAS the reason people putting Firewire on their PC!)

Fortunately my old charger was a gift but I feel bad for those who spent $200+ moding their car for iPhone and found that their 3G won't charge (Ridax "saved" the day for them, sort of)

Apple is indeed the best friend of the iAccessory industry. Not so much for the iUsers. And I'm surprised so few people are complaining. I see a lot of posters in various forums simply accept this fact, move on and buy brand new accessories all over again. That should be good for the economy, right?

Tuesday, August 05, 2008

Firmware 2.0.1 is out

I have not tried yet but I saw someone who has not tried and posted about it and got highly ranked by Google so I think I might as well do the same.

I did a quick search and found that it is supposed to reduce lags (especially for Contacts) so it might worth a try. Use at your own risk though!

The microphone is a button!

For my first few days of using the iPhone, I wish there are buttons for (1) accepting phone calls when I'm using the included wired hands-free headphone and (2) pausing music.

It's obvious that I could use the "Software" buttons (i.e., the one on the touch screen) What is not so obvious is that the microphone on the hands-free is THE button for both (1) and (2). (Thanks to this post by Matt Ryall)

Monday, August 04, 2008

Custom ringtone on iPhone

For some reason I always put this on my top priority list for my phone even though I hardly get any phone calls at all! I could use any song from the library on my old phone (SE W800i) However, it's not as simple on the iPhone:
1) convert your song to AAC
2) cut it to under 30 seconds (could do this before Step#1)
3) change the extension of the file to .m4r
4) add the file to iTunes and it should appear in the Ringtone section.

If you think these steps are too complicated, good news for you: the freeware iRinger does all these for you.

Finally, you need to sync the ringtone to your phone. You can't just drag-and-drop from the item you see in Step#4 to your phone in iTunes. Instead, click on the name of your phone on the left pane. You will see the main page for your phone on the right pane. Click the "Ringtone" tab and check the "Sync" radio button (make sure the ringtone you want is selected) Then "Apply" this change.

Now you could choose these ringtones under custom on your iPhone!

How to tell when iPhone 3G is fully charged?

The iPhone is fully changed when the icon in the top bar changes from a lightning bolt to a two prong power symbol. (Thanks to the reply to this post by aristotles. Like the other posters, I also wonder why it has to be so subtle.)