Cool Duplo Project #27 – Trebuchet
We are dangerously entering the realm of projectiles.
I MacGyver’d a sling with rubber bands & a rubber balloon.
I’m helping the counterweight a bit since Duplos don’t have much mass; there is definitely room for improvement in other regards, the sling release specifically. currently it takes a few trials to get a good trajectory.
Cool Duplo Project #26 – Messing with Spring Loaded Firing Mechanisms
Cool Duplo Project #25 – Spiral Train to Nowhere
Cool Duplo Project #24 – Roller Coaster Tycoon
Resilient SSH Tunnel
[bash]#!/bin/bash
tunnel_entrance_port=13306
tunnel_end=username@re.mo.te.ip
destination=127.0.0.1
destination_port=3306
# Use netcat to connect to tunnel entrance port. If its exit code is not zero, the tunnel needs to be brought up
nc -w1 localhost $tunnel_entrance_port > /dev/null
if [[ $? -ne 0 ]]; then
echo "creating new tunnel for MySQL"
/usr/bin/ssh -f -N -L $tunnel_entrance_port:$destination:$destination_port $tunnel_end
if [[ $? -eq 0 ]]; then
echo " tunnel to $destination through $tunnel_end created successfully"
else
echo " an error occurred creating a tunnel to $destination through $tunnel_end"
fi
fi[/bash]









