{"id":21651795,"url":"https://github.com/mignon-p/hs-wiringpi","last_synced_at":"2025-10-07T14:20:20.509Z","repository":{"id":56882593,"uuid":"78509038","full_name":"mignon-p/hs-wiringPi","owner":"mignon-p","description":"A Haskell binding to the wiringPi library, for using GPIO on the Raspberry Pi.","archived":false,"fork":false,"pushed_at":"2020-01-08T11:53:56.000Z","size":208,"stargazers_count":14,"open_issues_count":1,"forks_count":4,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-08-19T10:24:15.590Z","etag":null,"topics":["gpio","haskell-bindings","raspberry-pi","wiringpi"],"latest_commit_sha":null,"homepage":null,"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/mignon-p.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-01-10T07:32:08.000Z","updated_at":"2024-05-12T23:10:16.000Z","dependencies_parsed_at":"2022-08-20T23:10:47.812Z","dependency_job_id":null,"html_url":"https://github.com/mignon-p/hs-wiringPi","commit_stats":null,"previous_names":["mignon-p/hs-wiringpi","ppelleti/hs-wiringpi"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/mignon-p/hs-wiringPi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mignon-p%2Fhs-wiringPi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mignon-p%2Fhs-wiringPi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mignon-p%2Fhs-wiringPi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mignon-p%2Fhs-wiringPi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mignon-p","download_url":"https://codeload.github.com/mignon-p/hs-wiringPi/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mignon-p%2Fhs-wiringPi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278788111,"owners_count":26045895,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"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":["gpio","haskell-bindings","raspberry-pi","wiringpi"],"created_at":"2024-11-25T07:49:35.133Z","updated_at":"2025-10-07T14:20:20.458Z","avatar_url":"https://github.com/mignon-p.png","language":"Haskell","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Hackage](https://img.shields.io/hackage/v/wiringPi.svg)](https://hackage.haskell.org/package/wiringPi)\n\nThis is a Haskell binding to the [wiringPi library][1], which allows\nyou to interface with the [GPIO][4] pins on the [Raspberry Pi][2].\nUnlike some other solutions for using the Raspberry Pi's GPIO pins,\nwiringPi provides access to more advanced features, such as enabling\nthe internal pull-up or pull-down resistors.\n\n## Usage\n\nTo use this library, you must either run as root, or set the\n`WIRINGPI_GPIOMEM` environment variable.  (Set it to anything; the\nvalue does not matter.)  However, [PWM][7] will not work if\n`WIRINGPI_GPIOMEM` is set.\n\nThis library will only build on the Raspberry Pi.  Before building\nthis library, you must install the \"wiringPi\" C library on your\nRaspberry Pi, like this:\n\n    sudo apt-get install wiringpi\n\nTested on a Raspberry Pi Model B, with [Raspbian Jessie Lite][3],\nusing the system-provided Haskell compiler.  (GHC 7.6.3.)\n\n## Pin Numbering\n\nWiringPi allows each pin to be identified by one of three names.  A\npin can be identified by its physical pin number, by its Broadcom GPIO\nnumber (this is the one most commonly used in the Raspberry Pi\ncommunity), or by its wiringPi pin number.  The `Pin` type has three\nconstructors (`Wpi`, `Gpio`, and `Phys`), allowing you to call a pin\nby any of its three names.  These names are synonymous and\ninterchangeable.\n\nThe following diagram illustrates the three names of each pin, and\nalso identifies which pins can be placed in `PWM_OUTPUT` mode or\n[`GPIO_CLOCK`][8] mode.\n\n![Pinout](https://raw.githubusercontent.com/ppelleti/hs-wiringPi/master/pin-diagram.png)\n\nSimilar diagrams are available on [the wiringPi site][5] or on\n[pinout.xyz][6].\n\nOne additional wrinkle is that some very early Raspberry Pis use\ndifferent Broadcom GPIO numbers for a few of the pins.  WiringPi\nautomatically takes this into account, but it means that equality for\n`Pin` actually depends on which board revision you have.\n\n## Licensing\n\nThis Haskell binding is licensed under the 3-clause BSD license, and\nthe examples in the `examples` directory are in the public domain.\nHowever, be aware that the wiringPi C library itself is licensed under\nthe LGPLv3+.\n\n## Examples\n\nThere are several examples in the `examples` directory.  You can run\neach example by wiring up a circuit on a breadboard as specified by\nthe comments in the example.  Or, for something more permanent and\nprofessional-looking, you can use the\n[hs-wiringPi test board](https://github.com/ppelleti/hs-wiringPi-test-board).\nThe hs-wiringPi test board can be used with all of the examples,\nexcept for `wpi-fishdish`, which requires the\n[Fish Dish](https://www.pi-supply.com/product/fish-dish-raspberry-pi-led-buzzer-board/)\nboard instead.\n\n[1]: http://wiringpi.com/\n[2]: https://www.raspberrypi.org/\n[3]: https://www.raspberrypi.org/downloads/raspbian/\n[4]: https://en.wikipedia.org/wiki/General-purpose_input/output\n[5]: http://wiringpi.com/pins/\n[6]: https://pinout.xyz/pinout/wiringpi\n[7]: https://en.wikipedia.org/wiki/Pulse-width_modulation\n[8]: https://pinout.xyz/pinout/gpclk\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmignon-p%2Fhs-wiringpi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmignon-p%2Fhs-wiringpi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmignon-p%2Fhs-wiringpi/lists"}