California Education Code Section 78907
The use by any person, including a student, of any electronic listening or recording device in any classroom without the prior consent of the instructor is prohibited, except as necessary to provide reasonable auxiliary aids and academic adjustments to disabled students. Any person, other than a student, who willfully violates this section shall be guilty of a misdemeanor. Any student violating this section shall be subject to appropriate disciplinary action. This section shall not be construed as affecting the powers, rights, and liabilities arising from the use of electronic listening or recording devices as provided for by any other provision of law.
Of course, you can give permission for such recording. If you have no objection, you could announce in the class that recording is allowed. Or you could give permission on request. Keep in mind that such recordings will likely also pick up statements by students asking questions or answering questions in class. Note that the education code makes allowance for students with disabilities who might need to use some kind of recording device.