Help sorting XML data (from a Current Cost meter using multiple sensors/clamps)

    Mar 28 2011 | 12:24 pm
    I've been trying to output XML data from a Current Cost energy monitor (with multiple sensors/clamps attached).
    I had successfully managed to output the tag using the excellent 'CC128 Pachube' tool by nnimar ( However, I'm having difficulty outputting the separately when using multiple clamps/sensors.
    Attached is a text file of the XML code (showing the multiple sensor data) and shown below is a simple patch which allows the text file to be read and outputted line by line (using a simplified version of the 'CC128 Pachube' tool by nnimar). Hopefully this will replicate the problem I'm having.
    Ideally, I'd like to output the 'watts' value separately for 0 and 1 etc..
    I've been trying to do it with [zl] [route] [select] [regexp] etc..but I'm probably missing something really obvious.
    Previously I'd managed to separate the data by uploading each sensor to Pachube (giving each sensor its own XML file and then reading each file separately), however it would be a great help if I can read the data directly from the Current Cost Meter itself.
    Many thanks if anyone can help!

    • Mar 28 2011 | 3:01 pm
      I think i've managed to get it working correctly by using [pack] and then using [route 0], [route 1] and [route 2] to send each sensor value to an outlet. Will test it out later with the actual Current Cost XML code.
      Here is the updated patch.