code: func TogglePin(pin Pin) {
  	p := uint8(pin)
  
  	setReg := p/32 + 7
  	clearReg := p/32 + 10
  	levelReg := p/32 + 13
  
  	bit := uint32(1 << (p & 31))
  
  	memlock.Lock()
  
  	if (gpioMem[levelReg] & bit) != 0 {
  		gpioMem[clearReg] = bit
  	} else {
  		gpioMem[setReg] = bit
  	}
  	memlock.Unlock()
  }
docs: // TogglePin: Toggle a pin state (high -> low -> high)