Sunday, August 13, 2017

G-works Gas Saver R1

I've recently bought G-works Gas Saver R1 to transfer gas between gas canisters for backpacking (the lightweight ones with isobutane/propane mix). I'm happy to report it worked great. I've successfully emptied a 220 g (8 oz) canister that had about 30 g of fuel left into a small (110 g/4 oz) empty canister. Then I took a completely full 8 oz canister and transferred 70 g of fuel from it to the small canister.

It's necessary to create a difference in temperatures between the canisters. I put my receiving canister in a bowl of ice. I didn't heat the donor canister. The 30 grams of gas from the almost empty canister transferred to the completely empty canister within a minute. The 70 grams of gas from the full canister transferred within maybe 20 seconds. I had a kitchen scale on hand and frequently checked the receiving canister to ensure it's not over capacity.


This worked great, the process is quick and easy, and I expect to use this nifty device extensively.

Transferring gas. An empty receiving canister sits in a bowl of ice. I haven't done anything (i.e., heat) with the donor canister.

Testing the result with my Kovea Spider stove. The flame is not visible in the photo but it was burning nicely.

Friday, May 16, 2014

Using your own router with CenturyLink/Qwest fibre

CenturyLink recently started offering FTTP-based Internet connections in our part of Seattle. The network is GPON (a type of passive optical network). Prices are $30 for 40/5 Mbit, $50 for 100/50 Mbit, $60 for 1000/1000 Mbit (the last one is actually a really good price). The first price is introductory, only for the first 12 months (no word on what it is going to be afterwards) but the other prices will supposedly stay. No word on data limits. $50 installation fee.

The connection from ONT (Optical Network Terminal, the termination device on the optical network) to the socket in my wall is Ethernet which is nice. But nothing is too simple, this is still CenturyLink, so there are two problems:

  • Your router has to use PPPoE to connect to the ONT. Your traffic goes through this tunnel.
  • Your router has to support VLAN and tag Ethernet frames going to ONT with VLAN tag 201.
The requirement for VLAN tagging seems to come from the ONT vendor (Calix?), I found it in their deployment guide but lost the link since. PPPoE seems to be supported on most modern router but VLAN tagging seems to be very rare. Of course except for the CenturyLink-branded router (ZyXel FR1000Z) which CenturyLink will happily lend you for a paltry $7/month. Thanks, but no thanks.

My router, TP-Link TL-WDR3600 does support PPPoE but unfortunately doesn't support VLANs. This was promptly solved by flashing OpenWrt which (mostly) supports VLAN and setting VLAN to 201. There are two ways this VLAN support works. First, there is a hardware switch which can be controlled with swconfig command. I couldn't get this to work. I made it work by naming the WLAN interface on the router (the one used to connect to the ONT) "eth0.201". See screenshot below. This apparently causes the Linux network stack to mark frames with VLAN tag 201. Without this, the ONT refuses to talk to the router.


And that's all there is to it. Setting up PPPoE is simple.

Update May 2016: I've moved and my new location luckily has CL Fibre too. It turns out that installation is free if you sign up for a PrismTV trial so I did. I've promptly disconnected their router and connected mine. It's interesting that no authentication is required if your ONT is marked for Prism! You just choose dynamic DHCP on your WAN and you're ready. No VLAN tagging, no PPPoE authN.

Thursday, February 14, 2013

Computer Graphics class projects (CSI 4341)


Computer Graphics class projects, OpenGL

This was Fall 2012 class on computer graphics with Dr. Fredrik Niemela. Here are videos of some of the class projects I did. Note that some parts (e.g. meshes for chess pieces) are not my work.

Virtual landscape

Clock

Moving Chess

(Note: the meshes for chess pieces were provided by Dr. Niemela)

Raytraced Chess

(Note: the meshes for chess pieces were provided by Dr. Niemela)

Thursday, January 10, 2013

New MySQL database

New database "x" with new user "x" with password "p".

CREATE DATABASE x CHARACTER SET utf8 COLLATE utf8_unicode_ci ;
CREATE USER 'x'@'localhost' IDENTIFIED BY 'p';
GRANT ALL ON u.* TO 'x'@'localhost';

Use collation specific to your language, e.g. "utf8_czech_ci" if you want better sorting accuracy.

File permissions with ACL


Default group privileges for new files and directories:

setfacl -R -d -m g::rwX <path>

Don't forget to do chmod g+s to set setuid bit so that file objects inherit group.