Was the keyboard was going through the powered hub, or the Pi is powered by the hub? You really want to power the Pi from a 1 Amp USB wall-wart. We've got this one
, but if you've already got an iPhone charger or something like that, give it a try. See here for a list of power adapters
that work (and don't work!) with the Pi.
Be aware that the Pi does a lot of power management
. If you're not using something, the Pi will try to turn it off. For example, the USB/network chip is powered down if not in use. Running a GUI will cause the GPU on the processor to be powered up. I'm not sure about the HDMI chip, but that may also be powered down if nothing's plugged in.
You might want to check your setup against the RPi Verified Peripherals pageThe RPi Troubleshooting page
is also pretty good starting place if you're seeing problems that look power-related.
You might also try a different SD card. Apparently, there is quite a range in power draw between different cards. The RPi SD Cards page
also lists some cards with reported problems.