<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def brightness(frames):
 """parse a brightness message"""

        reader = MessageReader(frames)
        res = reader.string("command").uint32("brightness").assert_end().get()
        if res.command != "brightness":
            raise MessageParserError("Command is not 'brightness'")
        return (res.brightness/1000,)