You can read the CheerLights color from Perl with CheerLights::API. The module provides methods for getting the current color, its hexadecimal value, and a history of recent colors.

Read a Color, Make Something With It
The module’s get_current_color() method returns the color name and hex value.
Use get_current_hex() when you only need the hex value, or get_color_history(5) to request five recent entries with their timestamps.
A Perl script could print the latest color in a terminal, use it on a webpage, or pass it to another part of your project.
The GitHub repository includes the module and usage examples. Start there for installation details and the method documentation.
Discover more from CheerLights
Subscribe to get the latest posts sent to your email.

