Download the PHP package dept-of-scrapyard-robotics/pwm-rgb-fan without Composer

On this page you can find all versions of the php package dept-of-scrapyard-robotics/pwm-rgb-fan. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package pwm-rgb-fan

PWM RGB Fan

A modern PHP 8.3+ library for controlling PWM-driven fans with integrated RGB LEDs on embedded Linux devices. This package extends pwm-fan-control by adding synchronized RGB LED control, combining fan motor and lighting into one elegant API.

Features

Requirements

Installation

Install via Composer

This will automatically install the required dependencies:

Install Required Extensions

Before using this library, ensure both extensions are installed:

  1. php-pwm extension
  2. phpixel extension

Core Concepts

RGBPWMFan

An RGBPWMFan extends PWMFan and adds synchronized RGB LED control. It automatically selects the appropriate RGB controller (DoubleDots for 2-LED fans, PixelChannel for others) and provides methods that control both fan and LEDs together.

Basic Usage

API Reference

Construction

Creates a new RGBPWMFan instance.

Example:

Combined Control Methods

setSpeedWithColor()

Set fan speed and RGB color simultaneously.

speedIndicator()

Automatically set RGB color based on current fan speed. Blue (0%) → Red (100%).

temperatureVisual()

Adjust both fan speed AND RGB color based on temperature. Creates gradient: Blue (cool) → Cyan → Green → Yellow → Red (hot).

RGB Effects

breathe()

Synchronized breathing effect - fan speed and RGB brightness fade together.

rainbow()

Rainbow color cycle at specified fan speed.

spinningRainbow()

Spinning rainbow effect (best for 2-LED fans). Creates illusion of rotating colors.

party()

Random colors and fan speeds for party effect.

shutdown()

Gracefully fade out both fan and RGB simultaneously.

Direct RGB Access

getRGBChannel()

Get the underlying RGB channel for direct manipulation using neopixel-php methods.

Inherited Methods

All methods from PWMFan are available:

Basic Control:

Effects:

Temperature:

Presets:

Usage Examples

Example 1: Basic Combined Control

Example 2: Temperature-Based Control

Example 3: RGB Effects

Example 4: Direct RGB Control

Testing

The library includes a comprehensive Pest v4 test suite.

Running Tests

Included Examples

The package includes three comprehensive examples:

Troubleshooting

Extensions Not Found

Solution: Install both php-pwm and phpixel extensions.

PWM or SPI Device Not Found

Solution:

Wrong RGB Colors

Solution: Try different NeoPixelType values:

License

MIT License. See LICENSE file for details.

Credits

This library combines:

Contributing

Contributions are welcome! When contributing:

Support

For issues related to:


All versions of pwm-rgb-fan with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
ext-pwm Version *
ext-phpixel Version *
ext-sockets Version *
phpdafruit/neopixel-php Version ^0.2.0
dept-of-scrapyard-robotics/pwm-fan-control Version ^0.2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package dept-of-scrapyard-robotics/pwm-rgb-fan contains the following files

Loading the files please wait ...