You can use tc to shape bandwidth like so
This class will shape certain addresses to a certain speed.
We also need to setup a filter so that any packets marked as such go through this rule
tc class add dev eth0 parent 1:1 classid 1:5 htb rate 256kbps ceil 256kbps prio 1
tc filter add dev eth0 parent 1:0 prio 1 handle 5 fw flowid 1:5
Once that class is setup, you need to setup iptables to mark the specific packets you want to shape.
Next, create the mangle table that's needed.
iptables -t mangle -N shaper-out
iptables -t mangle -N shaper-in
iptables -t mangle -I PREROUTING -i eth0 -j shaper-in
iptables -t mangle -I POSTROUTING -o eth0 -j shaper-out
Next setup the marks that we need to shape certain IP addresses. mark 5 is the one that is shaped to 256.
iptables -t mangle -A shaper-out -s 10.0.0.5 -j MARK --set-mark 5
iptables -t mangle -A shaper-in -d 10.0.0.5 -j MARK --set-mark 5
That should shape 10.0.0.5 to 256kbps.
Reference (my blog) - http://sirlagz.net/2013/01/27/how-to-turn-the-raspberry-pi-into-a-shaping-wifi-router/