{"id":18063278,"url":"https://github.com/diogob/motion-streamer","last_synced_at":"2026-04-20T09:33:17.305Z","repository":{"id":66479099,"uuid":"489185844","full_name":"diogob/motion-streamer","owner":"diogob","description":"Detects motion from a gstreamer libcamerasrc element and streams it from a Raspberry Pi to a file and network","archived":false,"fork":false,"pushed_at":"2025-01-11T15:27:48.000Z","size":78,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-06-14T10:38:36.222Z","etag":null,"topics":["gstreamer","haskell","opencv","raspberry-pi"],"latest_commit_sha":null,"homepage":"","language":"Haskell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/diogob.png","metadata":{"files":{"readme":"README.md","changelog":"ChangeLog.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-05-06T02:10:14.000Z","updated_at":"2025-03-24T14:40:28.000Z","dependencies_parsed_at":"2024-01-13T01:04:12.443Z","dependency_job_id":"6be903df-63f7-43e5-b973-0b78c41fd7b0","html_url":"https://github.com/diogob/motion-streamer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/diogob/motion-streamer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diogob%2Fmotion-streamer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diogob%2Fmotion-streamer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diogob%2Fmotion-streamer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diogob%2Fmotion-streamer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/diogob","download_url":"https://codeload.github.com/diogob/motion-streamer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diogob%2Fmotion-streamer/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32041438,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-20T00:18:06.643Z","status":"online","status_checked_at":"2026-04-20T02:00:06.527Z","response_time":94,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gstreamer","haskell","opencv","raspberry-pi"],"created_at":"2024-10-31T05:10:29.358Z","updated_at":"2026-04-20T09:33:17.282Z","avatar_url":"https://github.com/diogob.png","language":"Haskell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# motion-streamer\n\n## Building from sources\n\nThere is no binary distribution yet, so you will need to download this repository and compile the sources.\nI have not tested cross-compilation, so I currently install all dependencies in the RPi and compile there.\n\nAlso note that this was written based on my experience with the [Raspberry Pi OS](https://www.raspberrypi.com/software/) Bookworm, so in other operating systems your mileage may vary.\n\n### Required packages to compile\n\n\n```sh\napt install libgirepository1.0-dev libgstreamer1.0-dev llvm libnuma-dev gstreamer1.0-opencv\n```\n\n### Haskell compiler\n\nWhile there is a package for `ghc` and `cabal-install` on Bookworm I had problems compiling under that version.\nThe software was tested using GHC 9.8.2 and cabal 3.12.1.0.\nYou can install from binary packages using [GHCup](https://www.haskell.org/ghcup/).\nOnce you install GHCup try the command `ghcup tui` for a neat terminal ui that will show you all compiler and tool versions available.\n\n### Compile and run the application\n\n```sh\ncabal run motion-streamer\n```\n\nIn case you see the error `motion-streamer: FactoryError` it is probably due to the lack of a `libcamerasrc` element in your gstreamer instalation.\nTo install libcamera on Raspberry Pi OS:\n\n```sh\napt install gstreamer1.0-libcamera\n```\n\nTo install libcamera from sources check their [getting started section](https://libcamera.org/getting-started.html)\n\nYou can still run without libcamera using a test pattern:\n\n```sh\nMS_TEST=true cabal run motion-streamer\n```\n\nYou can also configure the host (defaults to \"0.0.0.0\") and port (defaults to 5000) for tcp video streaming:\n\n```sh\nMS_HOST=localhost MS_PORT=8080 cabal run motion-streamer\n```\n\n## Using the camera\n\nOnce you have the camera setup, you can run the application without the `MS_TEST` flag.\n\n### Streaming the video captured by the camera\n\nUnless you use the `MS_HOST` configuration, the camera will be streaming via TCP to all network interfaces.\nTo watch the stream from any computer where `rpi` is a hostname that points to the RPi running motion-streamer use `gstreamer-launch-1.0` (provided by the package `gstreamer1.0-tools`):\n\n```sh \ngst-launch-1.0 -v tcpclientsrc host=rpi port=5000 ! h264parse ! avdec_h264 ! autovideosink\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdiogob%2Fmotion-streamer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdiogob%2Fmotion-streamer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdiogob%2Fmotion-streamer/lists"}