This is a Python library to control MCCI Model2450 Brightness And Color Kit.
install python package from python.org
pip --version
python -m pip install --upgrade pip
On Windows:
Development environment
- OS - Windows 10 and 11 64 bit
- Python - 3.7.8
- pyserial - 3.5
pip install pyserial
-
Clone the repository from github
-
Open a terminal window and change directory to
{path_to_repository}/model2450lib
. usingcd
into the root directory where setup.py is located -
To install the library in your local Python
setup, enter the command
python setup.py install
Please navigate to dist/ directory and you will find the files .egg file.
Example: model2450lib-1.0.0-py3.7.egg
Create a Python file and import the class library from package:
from model2450lib import searchmodel
from model2450lib import model2450
import time
dev_list = searchmodel.get_models()
Replace 'COM3' with the appropriate COM port for Model2450
sw1 = model2450.Model2450('COM3')
sw1.connect()
sw1.get_color()
sw1.get_level()
sw1.get_read()
sw1.read_sn()
sw1.get_version()
- v1.0.1 update examples
- v1.0.0 initial release