diff --git a/entry.sh b/entry.sh index 4315daf..b08603d 100755 --- a/entry.sh +++ b/entry.sh @@ -3,6 +3,6 @@ DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" $DIR/bootstrap.sh $DIR $DIR/venv -$DIR/venv/bin/python $DIR/src/main.py --port 50051 +$DIR/venv/bin/python $DIR/src/main.py $@ --port 50051 exit 0 diff --git a/src/main.py b/src/main.py index 4cc5b4b..950c7b5 100644 --- a/src/main.py +++ b/src/main.py @@ -100,7 +100,7 @@ async def stream_camera(self, client: OakCameraClient) -> None: # Create the stream if response_stream is None: - response_stream = client.stream_frames(every_n=1) + response_stream = client.stream_frames(every_n=self.stream_every_n) try: # try/except so app doesn't crash on killed service @@ -146,7 +146,7 @@ async def stream_camera(self, client: OakCameraClient) -> None: "--address", type=str, default="localhost", help="The camera address" ) parser.add_argument( - "--stream-every-n", type=int, default=4, help="Streaming frequency" + "--stream-every-n", type=int, default=1, help="Streaming frequency" ) args = parser.parse_args()