Logic for Third Party

Discussion in 'General Discussion' started by dewet, Sep 13, 2011.

  1. dewet

    dewet

    Joined:
    Oct 20, 2010
    Messages:
    12
    Likes Received:
    0
    Location:
    Cape Town
    Hi All

    I've got a client with a Nuvo Audio system that he wants me to control from the c-bus. I am able to control it with RS232 from the Colour touch screen to the Nuvo Unit. the comands I'm sending to it looks like this.

    once (GetCBusState("Lighting", "Nuvo System", "Amp Z1 ON/OFF") = ON) then

    begin

    SetCBusState("Lighting", "Nuvo System", "Amp Z1ON", ON);

    OpenSerial(1, 1, 57600, 8, 1, 0, 0);

    Format(CommandString, '*Z1ON', RequiredSource:0, #13#10);

    WriteSerial(1, CommandString);

    CloseSerial(1);

    SetStringIBSystemIO("Label Group Text", 254, "Nuvo System", "DLT ZONE 1", 0, 'SOURCE 1');

    end;

    Now my Question is will I be able to do the same on a MK2 with logic and a rs232 pc interface.

    if you can let me know

    thanks

    De Wet
     
    dewet, Sep 13, 2011
    #1
  2. dewet

    Darren Senior Member

    Joined:
    Jul 29, 2004
    Messages:
    2,361
    Likes Received:
    0
    Location:
    Adelaide, South Australia
    It is a good idea to put a delay between the WriteSerial and the CloseSerial commands.

    The C-Touch Mark 2 has the same serial functions. It is not clear what the RS232 PC Interface is for.
     
    Darren, Sep 13, 2011
    #2
  3. dewet

    dewet

    Joined:
    Oct 20, 2010
    Messages:
    12
    Likes Received:
    0
    Location:
    Cape Town
    My Situation is......Ive got a mk2 in the kitchen area. and my nuvo in the tech room. Ive only got a c-bus cable at the mk2. so what i wanted to do is to write the logic on the mk2. Ive got a c-bus cable at the nuvo system, Wanted to connect the pc interface to the nuvo on rs232. but as far as I know is that I can only send hex through the pc interface.

    So at the end of the day I think what i am going to do is to put a pascal controler at the nuvo and do everything from there.
     
    dewet, Sep 13, 2011
    #3
  4. dewet

    Newman

    Joined:
    Aug 3, 2004
    Messages:
    2,203
    Likes Received:
    0
    Location:
    Adelaide, South Australia
    You cannot send custom serial data over a C-Bus network and up through the RS-232 port of a 5500PC. You'll need to use a PAC to do this.
     
    Newman, Sep 13, 2011
    #4
  5. dewet

    Darren Senior Member

    Joined:
    Jul 29, 2004
    Messages:
    2,361
    Likes Received:
    0
    Location:
    Adelaide, South Australia
    The best way to do this is to have the PAC next to the Nuvo and connect the PAC serial port to the Nuvo serial port. Send trigger commands from the C-Touch Mark 2 to the PAC via C-Bus to make things happen in the Nuvo. If you need information to come back as well, then the PAC can read info from the Nuvo and send C-Bus messages so that the C-Touch can display the status.
     
    Darren, Sep 14, 2011
    #5
  6. dewet

    ARC JB

    Joined:
    Dec 21, 2009
    Messages:
    8
    Likes Received:
    0
    Location:
    Hamilton, New Zealand
    Which version of C-touch are you using for serial app?

    Hi Dewet,

    I am working on a serial project with a version 1 C-Touch and seem to be having a great deal of difficulty getting any data out of the DB9 serial port. Could you tell me which version of C-touch you are using please?

    I have also tested the code in a B & W Mk II and it works flawlessly.

    I am wondering if the serial port is disabled on the version 1 C-Touch.

    Thank you.
     
    ARC JB, Nov 16, 2011
    #6
  7. dewet

    Darren Senior Member

    Joined:
    Jul 29, 2004
    Messages:
    2,361
    Likes Received:
    0
    Location:
    Adelaide, South Australia
    I am not surprised you are having trouble. Black and White C-Touch Mark 1 does not support logic.
     
    Darren, Nov 16, 2011
    #7
  8. dewet

    ARC JB

    Joined:
    Dec 21, 2009
    Messages:
    8
    Likes Received:
    0
    Location:
    Hamilton, New Zealand
    Thanks Darren, but I'm not quite that ignorant!

    In NZ we refer to the Colour Touch screen as the C-Touch, sorry if there was any misunderstanding there.
    So it is a Colour touch screen Version 1.

    Thanks
     
    ARC JB, Nov 16, 2011
    #8
  9. dewet

    znelbok

    Joined:
    Aug 3, 2004
    Messages:
    1,151
    Likes Received:
    17
    A couple of options here

    Run a cat5 and send the serial coms over it. I have successfully run serial over 25+meters with no issues at all. As ong as you dont have the baud up too high it will be fine. The Nuvo is not using a fast baud rate.

    Use a ethernet gateway, convert the serial to ethernet and then back to serial at the Nevo.

    Use a device server (Ethernet to serial) at the Nevo and send the serial string over Ethernet directly from teh mk2 (If it has Ethernet, cant remember).

    Cheapest option is the first.

    Mick
     
    znelbok, Nov 16, 2011
    #9
  10. dewet

    NickD Moderator

    Joined:
    Nov 1, 2004
    Messages:
    1,427
    Likes Received:
    64
    Location:
    Adelaide
    Is it possible that it's the cable? It's easy to get TX and RX back to front. If you were testing with the B&W MkII you would have needed a different cable and a gender changer.. with the Colour C-Touch you need a standard serial cable (at least at the C-Touch end).

    The other thing to check is the serial port index and com port number in your logic code. These should both be 1 for the Colour C-Touch and the B&W MkII, but would possibly have been different if you were testing on a PC.

    Nick
     
    NickD, Nov 16, 2011
    #10
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.