pi_portal.modules.integrations.motion.client

Motion integration module.

class pi_portal.modules.integrations.motion.client.MotionClient(log)[source]

Integration with the Motion application.

Parameters:

log (Logger) –

cleanup_snapshot(file_name)[source]

Delete snapshot locally.

Parameters:

file_name (str) – The path to the file to delete.

Raises:

MotionException

Return type:

None

get_latest_video_filename()[source]

Retrieve the filename of the latest video recording.

Return type:

str

Returns:

The path of the latest video file that was created.

Raises:

MotionException

take_snapshot()[source]

Take a snapshot with Motion.

Raises:

MotionException

Return type:

None

exception pi_portal.modules.integrations.motion.client.MotionException[source]

Exceptions for the Motion integration.

with_traceback()

Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.