Being a firmware shop we obviously could not go the normal way with X10 publisher. We used our own shutter relay prototype to drive the two lamps. The relay module is normally driven with I2C -bus, but we simply used the data and clock signals to transfer pulses from pc's serial bus. The I2C bus is running at +3VDC level, so we needed to shift the 12v levels found on serial port to that level. Don't worry, the +3VDC level is isolated, so 'it should be fairly safe'. If you want help with similar hw setup, feel free to contact us.
All we did from that point was a couple of simple python scripts to drive a short pulse on DTR or RTS according the build result. This was easy with a little help from pySerial module. Shutter relay connected the lamps according the last detected pulse. These scripts are called via <execute>-publisher in CruiseControl's config.xml.
<onfailure>
<execute command="python pulse_rts.py">
</execute>
</onfailure>
<onsuccess>
<execute command="python pulse_dtr.py">
</execute>
</onsuccess>
Next steps:
- Write an actual publisher for DTR/RTS signals in Java
- Use our rf comm devices to transfer the build status
- Hook another lamp to indicate the ongoing build process
- Write a LonWorks publisher similar to X10
Mark Michaelis described their similar effort. They are a bit ahead of us.
No comments:
Post a Comment