Setting up flash properly