There are two codes that need to be figured in this puzzle. First you need to count the number of blue books on each shelf. The order is goes like this:
Top right has one book.
Bottom left has two.
Bottom right has three.
Top left has four.
Now you need to count the number of lit candles on each shelf. Press the keypad and enter the number of candles in the order the blue books are placed. As Top right has one book, the number of blue books on this shelf will come first. Then Bottom left, Bottom right and lastly, Top left.
So the answer is : Top right = 5, Bottom left = 3, Bottom right = 4, Top left = 2.
Press the keypad, input 5342 and press OK. You can now proceed to the next level.