While my screen is unplugged it will randomly go back to being partially dimmed. I change my Power Option to "Max Performance" so it doesn't dim the screen but after a couple minutes the screen dims. I increase the brightness and then a couple minutes later it dims again.
Go into your Power Options and adjust the default brightness for your power profile. The computer is resetting to the power profile's default. If your computer came with any extra power management software (Compal uses a program called Smart WatchDog), make sure that it is either disabled or also set appropriately.