Skip to content

Conversation

@blshukla
Copy link
Contributor

@blshukla blshukla commented Dec 3, 2025

📝 Description

  • Add examples for sending CEC commands in brightscript and javascript

🧪 Steps to Test

Follow steps in README files to deploy the application and test it.

✔️ Dev Complete Checklist

  • PR template filled out
  • Change is tested by submitter
  • PR follows all linting and coding standards
  • Team member has been assigned
  • At least one commit message is in Conventional Commit format

- Added examples for sending CEC commands in brightscript and javascript
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds example implementations demonstrating how to use the roCecInterface to send CEC (Consumer Electronics Control) commands on BrightSign devices. The examples show how to turn a display on and off using both BrightScript and JavaScript.

  • Complete working examples for both BrightScript and JavaScript implementations
  • Each example includes HTML files for display, logic files for CEC commands, autorun scripts for deployment, and comprehensive README documentation
  • Both examples demonstrate sending "Image View On" and "Standby" commands with a 15-second delay

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 9 comments.

Show a summary per file
File Description
examples/cec-interface/javascript/index.js JavaScript implementation for sending CEC commands using the @brightsign/cec package
examples/cec-interface/javascript/index.html HTML page for the JavaScript CEC example with styling
examples/cec-interface/javascript/autorun.brs BrightScript autorun launcher for the JavaScript example with Node.js enabled
examples/cec-interface/javascript/README.md Documentation explaining the JavaScript CEC example usage and setup
examples/cec-interface/brightscript/index.html HTML page for the BrightScript CEC example with styling
examples/cec-interface/brightscript/autorun.brs BrightScript implementation demonstrating CEC command sending using roCecInterface
examples/cec-interface/brightscript/README.md Documentation explaining the BrightScript CEC example usage and setup

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

cec.SendRawMessage(bufferStandby)
print "Sent Standby: " + bufferStandby.ToHexString()

' Optionally, uncomment the block below to repeat the cycle every 15 seconds
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What purpose does this serve? Just curious in what case this may be applicable for a user. I can't think of a situation when applying standby every 15 seconds would be useful.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tbh it was most helpful to me while testing to make sure the display was turning on and off every single time, and not just a one-off thing in the beginning. It may help testing other CEC commands the same way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants