{"id":21221942,"url":"https://github.com/amid68/virtual-character-device-driver","last_synced_at":"2026-04-14T17:32:11.029Z","repository":{"id":263478788,"uuid":"890354852","full_name":"Amid68/Virtual-Character-Device-Driver","owner":"Amid68","description":null,"archived":false,"fork":false,"pushed_at":"2024-11-18T18:37:17.000Z","size":5,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-03T10:28:52.965Z","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":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Amid68.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-18T12:34:09.000Z","updated_at":"2024-11-18T18:37:21.000Z","dependencies_parsed_at":"2024-11-19T05:35:10.073Z","dependency_job_id":null,"html_url":"https://github.com/Amid68/Virtual-Character-Device-Driver","commit_stats":null,"previous_names":["amid68/virtual-character-device-driver"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Amid68/Virtual-Character-Device-Driver","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Amid68%2FVirtual-Character-Device-Driver","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Amid68%2FVirtual-Character-Device-Driver/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Amid68%2FVirtual-Character-Device-Driver/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Amid68%2FVirtual-Character-Device-Driver/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Amid68","download_url":"https://codeload.github.com/Amid68/Virtual-Character-Device-Driver/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Amid68%2FVirtual-Character-Device-Driver/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31808505,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-14T11:13:53.975Z","status":"ssl_error","status_checked_at":"2026-04-14T11:13:53.299Z","response_time":153,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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-20T22:37:00.657Z","updated_at":"2026-04-14T17:32:11.009Z","avatar_url":"https://github.com/Amid68.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Virtual Character Device Driver\n\n## Overview\n\nThis project implements a virtual character device driver for Linux, allowing interaction between the kernel and user space via a virtual device file (`/dev/virtchar`). It demonstrates key concepts in Linux driver development, such as registering a device, handling file operations, and managing memory.\n\n## Project Structure\n\n```\nvirtchar/\n├── Makefile\n├── README.md\n├── include/\n│   └── virtchar.h\n└── src/\n    ├── virtchar.c\n    └── virtchar_ops.c\n```\n\n## Building the Module\n\nRun the following command in the project root directory:\n\n```bash\nmake\n```\n\n## Installing the Module\n\nLoad the module into the kernel:\n\n```bash\nsudo insmod virtchar.ko\n```\n\nVerify that the module is loaded:\n\n```bash\nlsmod | grep virtchar\n```\n\n## Creating the Device File\n\nThe module now automatically creates the device file `/dev/virtchar`. If not, you can create it manually:\n\n```bash\nsudo mknod /dev/virtchar c \u003cmajor_number\u003e 0\nsudo chmod 666 /dev/virtchar\n```\n\nReplace `\u003cmajor_number\u003e` with the major number assigned to the device (check `dmesg` logs).\n\n## Testing the Driver\n\n**Write to the Device:**\n\n```bash\necho \"Hello from userspace\" \u003e /dev/virtchar\n```\n\n**Read from the Device:**\n\n```bash\ncat /dev/virtchar\n```\n\n**Check Kernel Logs:**\n\n```bash\ndmesg | tail -n 20\n```\n\n## Uninstalling the Module\n\nTo remove the module from the kernel:\n\n```bash\nsudo rmmod virtchar\n```\n\nClean the build files:\n\n```bash\nmake clean\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Famid68%2Fvirtual-character-device-driver","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Famid68%2Fvirtual-character-device-driver","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Famid68%2Fvirtual-character-device-driver/lists"}