{"id":21027172,"url":"https://github.com/ivanhao/raspberry-code","last_synced_at":"2025-08-25T23:07:09.840Z","repository":{"id":35486133,"uuid":"39755333","full_name":"ivanhao/raspberry-code","owner":"ivanhao","description":null,"archived":false,"fork":false,"pushed_at":"2016-02-03T09:22:31.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-13T18:51:41.669Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ivanhao.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-07-27T04:38:01.000Z","updated_at":"2016-02-03T09:21:56.000Z","dependencies_parsed_at":"2022-09-12T13:00:20.775Z","dependency_job_id":null,"html_url":"https://github.com/ivanhao/raspberry-code","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ivanhao/raspberry-code","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhao%2Fraspberry-code","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhao%2Fraspberry-code/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhao%2Fraspberry-code/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhao%2Fraspberry-code/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ivanhao","download_url":"https://codeload.github.com/ivanhao/raspberry-code/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanhao%2Fraspberry-code/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272144649,"owners_count":24881141,"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-08-25T02:00:12.092Z","response_time":1107,"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":[],"created_at":"2024-11-19T11:48:40.986Z","updated_at":"2025-08-25T23:07:09.801Z","avatar_url":"https://github.com/ivanhao.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# raspberry-code\n  This codes are records for my raspberry Pi using wiringPi.Including servos,temperature's sensor and so on.\n\n## first \n\nyou must install wiringPi in your Raspberry Pi.\n\n###download wiringPi:\n\n`git clone git://git.drogon.net/wiringPi`\n\n###make and install: \n\n```\ncd wiringPi\n\n./build\n```\n\n\n\n\n# raspberry-code\n这些是树莓派上用wiringPi的一些代码记录。\n\n## 首先\n\n你要在树莓派上安装wiringPi。\n\n###下载 wiringPi：\n\n  `git clone git://git.drogon.net/wiringPi`\n\n###安装：\n\n  `cd wiringPi`\n  \n  `./build`\n  \n###使用：\n用vi或者nano新建一个blink.c的文件：\n\n`vi blink.c`\n\n内容如下：\n```\n#include \u003cwiringPi.h\u003e\nint main( )\n{\n    // 初始化wiringPi\n    wiringPiSetup();\n    int i = 0;\n    // 设置IO口全部为输出状态\n    for( i = 0 ; i \u003c 8 ; i++ )\n        pinMode(i, OUTPUT);\n       \n    for (;;)\n    {\n        for( i = 0 ; i \u003c 8 ; i++ )\n        {\n            // 点亮500ms 熄灭500ms\n            digitalWrite(i, HIGH); delay(500);\n            digitalWrite(i, LOW); delay(500);\n        }\n    }\n   \n    return 0;\n}\n```\n编译：\n```\nblink:blink.o\n gcc blink.c -o blink -lwiringPi\nclean:\n rm -f blink blink.o\n ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivanhao%2Fraspberry-code","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fivanhao%2Fraspberry-code","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivanhao%2Fraspberry-code/lists"}