定制 wpjscc/io 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

wpjscc/io

Composer 安装命令:

composer require wpjscc/io

包简介

Non blocking I/O for PHP

README 文档

README

Build Status License Total Downloads Latest Stable Version Latest Unstable Version

License: The MIT License

Copyright: 2013-2019 Thomas Weinert thomas@weinert.info

Carica Io is a collection of experimental php classes and scripts for non-blocking I/O. It provides the basic building blocks for hardware control using Firmata (Arduino) and GPIO (Raspberry PI).

Basics

The repository provides the API needed for non-blocking I/O. A simple event loop and event emitter are included. The loop implementation is not performance optimized. However it is possible to use an adapter for ReactPHP or AMPHP.

It includes an (incomplete) HTTP server that should be enough for the first steps. It supports GET requests and WebSocket connections.

Related Projects

           +---------------+
           |  Carica\Chip  |
           +-------+-------+
                   ^
                   |
        +----------+----------+
        |                     |
+-------+-------+    +--------+-------+
|  Carica\GPIO  |    | Carica\Firmata |
+-------+-------+    +--------+-------+
        ^                     ^
        |                     |
        +----------+----------+
                   |
           +-------+-------+
           |   Carica\Io   |
           +---------------+

Carica/Io provides the classes for event based programming and a simple web server. It defines interfaces for hardware control (Pin, ShiftOut, ...). Carica/Firmata is a client library for the Firmata protocol it allows to control Arduino boards over a serial or a network connection. Carica/GPIO implements GPIO into PHP using the file system or the WiringPI library for the Raspberry PI.

Carica/Chip implements classes for hardware objects. Like a LED, a RGB-LED, a Servo,...

Usage

You will need to get the loop instance from the factory, attach events and run it.

$loop = Carica\Io\Event\Loop\Factory::get();
$loop->setInterval(
  static function () {
    static $i = 0;
    echo $i++;
  },
  1000
);
$loop->run();

统计信息

  • 总下载量: 3
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2021-08-20

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固