GPFSEL_MASK
val &= ~(GPFSEL_MASK << shift);
val |= ((func & GPFSEL_MASK) << shift);
func = (reg >> ((pin % 10) * 3)) & GPFSEL_MASK;