{"id":13667148,"url":"https://github.com/flx/LSM303","last_synced_at":"2025-04-26T15:32:16.729Z","repository":{"id":63910195,"uuid":"166819528","full_name":"flx/LSM303","owner":"flx","description":"LSM303 Accelerometer access through Swift on Raspberry Pi","archived":false,"fork":false,"pushed_at":"2019-01-27T16:29:25.000Z","size":22,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-01T15:19:11.933Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/flx.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2019-01-21T13:33:30.000Z","updated_at":"2020-02-13T12:52:51.000Z","dependencies_parsed_at":"2022-11-29T07:14:34.293Z","dependency_job_id":null,"html_url":"https://github.com/flx/LSM303","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flx%2FLSM303","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flx%2FLSM303/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flx%2FLSM303/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flx%2FLSM303/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/flx","download_url":"https://codeload.github.com/flx/LSM303/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251008765,"owners_count":21522174,"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","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":[],"created_at":"2024-08-02T07:00:32.663Z","updated_at":"2025-04-26T15:32:16.490Z","avatar_url":"https://github.com/flx.png","language":"Swift","funding_links":[],"categories":["Sensors"],"sub_categories":["Networking, IoT, Bus Protocols, …"],"readme":"# LSM303\n\nA Swift driver for the LSM303DLHC controller over I2C, using SwiftyGPIO. The code has been tested with the FLORA sensor sold by Adafruit (https://www.adafruit.com/product/1247).\n\n```swift\nimport Foundation\nimport LSM303\n\nprint(\"start\")\nlet lsm303 = LSM303(for: .RaspberryPi3)\nlsm303.setAccScale(scale: .G2)\nlsm303.setMagGain(gain: .GAIN_1_3)\n\nwhile (true) {\n        lsm303.read()\n        print(\"accel \\(lsm303.accel.x) \\(lsm303.accel.y) \\(lsm303.accel.z) mag \\(lsm303.mag.x) \\(lsm303.mag.y) \\(lsm303.mag.z)\")\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflx%2FLSM303","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflx%2FLSM303","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflx%2FLSM303/lists"}