Python lib to enable data acquisition from CE3000/CE3100 Controller Yamato Checkweighers
The followings show the details of command given for data communication.
Command | Detail | (Status) |
---|---|---|
DC | Clear TOTAL data | Implemented, not tested * |
DS | Request TOTAL data w/o clear | Implemented |
DT | Request TOTAL data and clear | Implemented, not tested * |
AS | Request 500 Weight Data | Implemented |
PN | Request PROGRAM number change | Not Implemented * |
* Destructive Commands
git clone https://github.com/imar-ie/checkweigher.git
cd checkweigher
All dependencies are provided as part of the standard library, except for PyYAML, this can be installed by either:
pip install -r requirements.txt
or
pip install pyyaml
Can be used via the command line or as a module, options are the same for both
yamatocheckweigher.py [-h] [-p PORT] [-cf] [-c {DC,DS,DT,AS}] [-v] ip
The checkweigher's IP address
Device port
Default: 1001
Command to be issued
Options: {DC,DS,DT,AS}
Default: DS
Config file to be used Default: ./configs/yamatocheckweigher.yaml
show program's version number and exit
show this help message and exit
python yamatocheckweigher.py 192.168.1.123 -p 1234 -c AS
from yamatocheckweigher.yamatocheckweigher import Checkweigher
cw = Checkweigher('127.0.0.1', 1234, 'config.yaml')
cw.connect()
total = cw.DC()
fivehundred = cw.AS()
cw.disconnect()