Global Cache rs232 - C Bus 5500PC

Discussion in 'Third-Party Solutions' started by chrisd4021, May 12, 2014.

  1. chrisd4021

    chrisd4021

    Joined:
    May 12, 2011
    Messages:
    44
    Likes Received:
    0
    Location:
    South Yorkshire
    Hi All,

    Please be gentle

    Im trying for the first time to send code from a third party app ( rookie remote on iPad ) to Global Cache IP- serial device http://www.globalcache.com/products/itach/ip2sl-pspecs/
    to my PCI 5500PC connected with RS232 cable. to the best of my knowledge the connections and pins test out fine and devices set up as follows

    Data Rate:9600 bits / second

    Data Bits: 8

    Parity: none

    Start bits: 1

    Stop bits:1

    when i send the command from GC to PCI i see a visual indication that the PCI has had a command when the comms illuminates briefly which makes me think the code I?m sending is been received, but is wrong as nothing happens.

    I thought the simple way was to read the commands been transmitted during a scene would be to use c bus diagnostic tool and copy the code as shown here

    movie

    17:23:09 Rx : 0512CA0002070313<CR> "________"
    17:23:09 Rx : = Ctrl: Grp 7 set to 3
    17:23:09 Rx : 05123800012B012E012F01300131013290<CR> "__8__+_._/_0_1_2_"
    17:23:09 Rx : = GA 43 Off; GA 46 Off; GA 47 Off; GA 48 Off; GA 49 Off; GA 50 Off
    17:23:09 Rx : 0512380001330234300125F1<CR> "__8__3_40_%_"
    17:23:09 Rx : = GA 51 Off; GA 52 Set to 19%; GA 37 Off

    which i think translates to

    \0512CA0002070313<cr>
    \05123800012B012E012F01300131013290<cr>
    \0512380001330234300125F1<cr>

    I think i spotted an error in that i need a ?c? before the carriage return <cr> as below after another read of the training manual which i haven?t had chance to try yet

    \0512CA0002070313c<cr>
    \05123800012B012E012F01300131013290c<cr>
    \0512380001330234300125F1c<cr>

    Does this look right or am i going down the wrong path?

    Do I need to do the PCI initialisation as shown in the training manual ( changing groups to match mine) and is this done just once?

    ~~~<cr> A3210038g<cr>

    g.322100AD<cr>

    A3420002g<cr>
    g.3242008C<cr>
    A3300059g<cr>
    g.86xxxx00323000yy<cr>

    If I can get the code working GC to PCI then I think I?d need to write logic on wiser to send back from PCI to GC but I?m sure i read somewhere wiser can?t do this or PCI can?t send them and you need a PAC

    Thank you in advance
     
    chrisd4021, May 12, 2014
    #1
  2. chrisd4021

    rhamer

    Joined:
    Aug 3, 2004
    Messages:
    673
    Likes Received:
    3
    Location:
    Melbourne, Australia
    Your not quite on the right track.

    Firstly, commands that come out of a PCI are not the same format as the ones that go in.

    Yes you do need to initialise the PCI

    You look like you are trying to send a scene trigger command and then send the contents of the scene as well. That's not correct. The scene trigger is used to trigger a scene stored in other C-Bus units. If you want to send the scene yourself, then you don't need the trigger.

    BTW a scene is just a series of standard commands, so if you want to send your own, just send the appropriate commands. (What it looks like is you are not understanding multi group commands which you don't have to use)

    Best bet is to read the quick start guide (formally the public release protocol) it will get you working.

    Cheers

    Rohan
     
    rhamer, May 12, 2014
    #2
  3. chrisd4021

    chrisd4021

    Joined:
    May 12, 2011
    Messages:
    44
    Likes Received:
    0
    Location:
    South Yorkshire
    Hi Rohan,

    Thanks for the fast response. I read the tutorial but not sure where the initialisation fit in to this. do you send the command once and thats it or at set intervals?

    ~~~<cr> A3210038g<cr>
    g.322100AD<cr>
    A3420002g<cr>
    g.3242008C<cr>
    A3300059g<cr>
    g.86xxxx00323000yy<cr>

    think the actual string should look like this?

    light on
    \053800792cc2c<cr>

    light off
    \053800012cc2c<cr>
     
    chrisd4021, May 12, 2014
    #3
  4. chrisd4021

    rhamer

    Joined:
    Aug 3, 2004
    Messages:
    673
    Likes Received:
    3
    Location:
    Melbourne, Australia
    You only need to initialise the PCI once before you start using it.

    Assuming you don't want to receive MMI's do this;

    Code:
    Send                 PCI Reply
    -----------------------------------------------------
    ~~~<cr>                 Nothing
    A3210038g<cr>       g.322100AD<cr>
    A3420002g<cr>       g.3242008C<cr>
    A3300059g<cr>       g.86xxxx00323000yy<cr>
    After you have done that you should be able to send On/Off/Ramp commands and make group addresses change state.

    E.G.
    \0538007988C2g<cr>
    Turn on group address 136 (88 hex) on lighting application 56 (38 Hex)

    Note the C2 is a calculated checksum and will be different for every command, so you need to calculate it as per the instructions in the Quick start Guide.

    The g is a tracking character and can be any lowercase letter from g to z. it is used to match the PCI's acknowledge to a particular command.

    And just in case its not clear <cr> is a single byte ascii 13 (0D Hex) and not 4 characters <cr>

    Regards

    Rohan

    BTW (one for the old timers) Was the "Public Release Protocol" document renamed to "The Quick Start Guide" in honour of its original author ? ;)
     
    Last edited by a moderator: May 13, 2014
    rhamer, May 13, 2014
    #4
  5. chrisd4021

    ashleigh Moderator

    Joined:
    Aug 4, 2004
    Messages:
    2,391
    Likes Received:
    24
    Location:
    Adelaide, South Australia
    Not as far as I know ;)
     
    ashleigh, May 16, 2014
    #5
  6. chrisd4021

    chrisd4021

    Joined:
    May 12, 2011
    Messages:
    44
    Likes Received:
    0
    Location:
    South Yorkshire
    Right thanks to all for your help I have got the commands i need to do what i intended which i'll explain in more detail in a few days just in case anyone has the same scenario but I figured i may help to try and make a check sum calculator as thats a massive pain in the backside working them out so heres my first attempt which works for me, just add group address,of/off, and lighting group address and the rest is do for you (created in numbers not excel so don't know if converting to excel will mess it up). i do need to understand the ramp level element and incorporate that if anyone could shed some light on that part:confused:.

    Screen shot attached
    any constructive comment would help and I'm happy to share ( if thats allowed )
     

    Attached Files:

    chrisd4021, May 21, 2014
    #6
  7. chrisd4021

    chrisd4021

    Joined:
    May 12, 2011
    Messages:
    44
    Likes Received:
    0
    Location:
    South Yorkshire
    so right i understand the ramping now after a little bit of testing and found an error on the calculator that missed a 0 from the off command just in case anyone spots that
     
    chrisd4021, May 21, 2014
    #7
  8. chrisd4021

    chrisd4021

    Joined:
    May 12, 2011
    Messages:
    44
    Likes Received:
    0
    Location:
    South Yorkshire
    Can anyone shed some light( no pun intended) on ramping to off via PCI-rs232.

    turn on
    \0538007988C2c<cr> (works fine)

    turn off
    \05380001883Ac<cr> (works fine)

    Ramp ON to 50% over 8 seconds(works fine)
    \0538001288AAc<cr>

    Ramp OFF to 0% over 8seconds (not working)
    \053800128829c<cr>

    as per the PCI quick start guide RR would be 12(8seconds) and TT would be 00 (0%) or have i got the TT wrong? everything seems to work except ramping down strings..

    Thank you in advance
     
    chrisd4021, Oct 22, 2014
    #8
  9. chrisd4021

    rhamer

    Joined:
    Aug 3, 2004
    Messages:
    673
    Likes Received:
    3
    Location:
    Melbourne, Australia
    Both those ramp commands are too short by 2 bytes.

    Your either missing the checksum or the level by the looks of it.

    Cheers

    Rohan
     
    rhamer, Oct 22, 2014
    #9
  10. chrisd4021

    chrisd4021

    Joined:
    May 12, 2011
    Messages:
    44
    Likes Received:
    0
    Location:
    South Yorkshire
    I think the part I'm not understanding is better explained with this screen shot attached as i'm using a spread sheets to do the donkey work of the calculation and check sums (which seems to work fine with the exemption of ramp off strings) ,but if RR is ramp over 12sec on or off, and TT is the level 7F(50%) and 00(0%) but both strings shown below just ramp on to 50% over 12 secs.

    Tv Blue Ramp on 50% over 12 sec =\0538001A34F6c<cr>
    Tv Blue Ramp off 50% over 12 sec =\0538001A3475c<cr>
     

    Attached Files:

    chrisd4021, Nov 2, 2014
    #10
  11. chrisd4021

    rhamer

    Joined:
    Aug 3, 2004
    Messages:
    673
    Likes Received:
    3
    Location:
    Melbourne, Australia
    I can't vouch for your spreadsheet, but as I said the commands you are issuing are wrong.

    You are missing 2 bytes of information for them to be valid ramp commands.

    Ramp commands are 2 bytes longer than on/off commands, because they contain more information.

    If you are trying to ramp group address 34 hex off over 12 seconds then the command should look like

    \0538001A3400ZZc where ZZ is replaced with the calculated checksum which I can't calculate for you right now as I don't have a calculator handy.

    Notice it is 2 bytes longer than what you are trying to use. I suspect you haven't allowed for this in your spreadsheet.

    Rohan
     
    rhamer, Nov 2, 2014
    #11
  12. chrisd4021

    rhamer

    Joined:
    Aug 3, 2004
    Messages:
    673
    Likes Received:
    3
    Location:
    Melbourne, Australia
    I think you might not understand the ramp command properly.

    You description "ramp off 50% over 12 seconds" does not make sense.

    You can't ramp off and to 50%.

    I think you are thinking that if you want to ramp to a lower level than it currently is, you need to "ramp off". Not true.
    The level is an absolute value and where you are ramping from is of no consequence, nor is the direction it needs to go.

    So you ramp to 00 to turn a load off or FF to turn it on to 100% or 7F to ramp it to 50% brightness, all regardless of what the start level currently is.

    Hopefully that clears it up.

    Rohan
     
    rhamer, Nov 2, 2014
    #12
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.