RS232 and Room Groups

MrBeetleMrBeetle Junior MemberPosts: 1
Ok, so I understand RS232 just fine, but I'm having problems understanding the instructions for grouping rooms together.

MSRGs,b8,b7,b6,b5,b4,b3,b2,b1

Create Room Grouping, where:
1) ?s? is the source to associate the rooms with
2) ?b8?... ?b1? is a binary room selection bitmap where all rooms to be grouped have a binary 1 in the room position. The most significant bit in ?b8? is for room 64 and the least significant bit in ?b1? is for room 1.
Notes:
1) A room grouping will be considered invalid if there are not at least two rooms selected for the group.
2) Only one room group can be associated with any given source.

So, my plan was to group some unused rooms together (7&8) when entering the source, and then immedietly adding in the other rooms as needed... So, if they had rooms 1, 3, and 6 grouped, the macro would look something like.

*create room group 7&8 on source 1*
*add room 1 to the group (MARG8,1)*
*add room 6 to the group (MARG8,6)*
*add room 3 to the group (MARG8,3)*

anyone able to explain the binary bit map thing? Basically, what will the string look like to make a group of 7/8... Like MSRG1,000000,000000,000000,000000,000000,000000,001000,000111
or what?

Comments

  • Spire_JeffSpire_Jeff Formerly Caffeinated Programmer Posts: 1,917
    I for bits within a byte to create the group. Something like:

    Group 1, 3, 7, and 8 would be: 11000101

    To make it easier, you could do this:

    DEFINE_CONSTANT
    INTEGER ROOM1 = $01
    INTEGER ROOM2 = $02
    INTEGER ROOM3 = $04
    INTEGER ROOM4 = $08
    INTEGER ROOM5 = $10
    INTEGER ROOM6 = $20
    INTEGER ROOM7 = $40
    INTEGER ROOM8 = $80
    ....
    SEND_STRING dvDEVICE,"'MSRG,",SOURCE,0,0,0,0,0,0,0,ROOM1+ROOM3+ROOM7+ROOM8)


    The 0 just to the left of the ROOM additions would be for rooms 9-16, left of the would be 17-24, and so on.

    Hope this helps,
    Jeff
  • You're right except the bitmask is formatted using decimal numbers similar to an IP address. A valid command to group all 64 zones to source 1 would look like the following:

    MSRG1,255,255,255,255,255,255,255,255

    To group zones 1, 3, 7, and 8 to source 1 would be as follows:

    (the binary bitmask for 1,3,7,8 is 11000101)
    (which written in decimal is 197)

    MSRG1,0,0,0,0,0,0,0,197
  • Spire_JeffSpire_Jeff Formerly Caffeinated Programmer Posts: 1,917
    I believe we are using the same numbers, I am just doing it with HEX code. I find that they hex code is easier to interpret in my mind. If you add 1,3,40,80 in windows calculator set in HEX mode (scientific view), then select DEC mode, you will see that it is 197 decimal.

    Jeff
  • viningvining X Member Posts: 4,354
    What's the trick in getting this sh$t to talk. I'm not in set up mode. I've tried the Duet and the Netlinx modules. Using HyperTerminal I get FPID from the master every 5 seconds. Tried to send strings via hyperterminal to the MA device w/ no joy. Tried MPON & MPOFF for hours until I found a line in a support document that said these commands don't do any thing. I've changed cables and made cables and still no joy. I don't have any keypads on the system right now so maybe I have to go through an initial set up or some thing but you would think I'd be able to talk to it striaght out of the box. I haven't seen any thing that enables or disables RS-232 input or feedback like some systems do but it's a possibility.

    Last night I spent 2 hour setting up an Escient Fireball AVX-552, Sony Changer and an FP-1 for the first time. Mapped network drives to iTUNES and other PC files to share music w/o any incidents. Today I've spent more than double that amount of time and I still not talking to this Matrix Audio P.O.S. You would think AMX could make their own equipment somewhat plug and play. Not to mention that once I do start talking this device I'll likely realize that the modules are crap and have to start from scratch.

    Not happy!
  • viningvining X Member Posts: 4,354
    The baud rate on newer units have been changed to 9600. The documentation still shows the 4800 baud rate and modules apparently haven't been updated to support the higher baud rate either.

    It's not like I had any thing better to do last night than get aggrevated trying to talk to this deivce at the docemented baud rate. They could have put a sticker or taped a piece of paper with the new communication paremeters on the unit but no, that would make to much sense.
  • MSRGs,b8,b7,b6,b5,b4,b3,b2,b1
    Each of the bytes from b8 to b1 contain 8 bits (each bit represents a zone). B1 represents the first 8 zones and b2 represents the second bank of 8 (zones 9-16), b3 is 17-24 etc.

    MSRG1,0,0,0,0,0,0,0,192
    --> create room group 7&8 on source 1 (Zones 7+8 = 11000000 = 128 + 64 = 192)
    MARG8,1
    --> add room 1 to the group
    MARG8,6
    --> add room 6 to the group
    MARG8,3
    --> add room 3 to the group

    btw Jeff, great idea with the constants to do the calcs for you...
  • banobano Senior Member Posts: 159
    vining wrote:
    The baud rate on newer units have been changed to 9600. The documentation still shows the 4800 baud rate and modules apparently haven't been updated to support the higher baud rate either.

    It's not like I had any thing better to do last night than get aggrevated trying to talk to this deivce at the docemented baud rate. They could have put a sticker or taped a piece of paper with the new communication paremeters on the unit but no, that would make to much sense.

    Try calling tech support and asking them to change the baud rate in the comm module and email the revised comm module to you. They did this same thing for me about a year ago when antex changed their baud rate on one of their receivers.
  • viningvining X Member Posts: 4,354
    bano wrote:
    Try calling tech support and asking them to change the baud rate in the comm module and email the revised comm module to you. They did this same thing for me about a year ago when antex changed their baud rate on one of their receivers.
    With the Netlinx Module I just put a wait in DEFINE_START and another wait in the DATA_EVENT online handler to change the baud rate a little while after the module sets it to 4800. That wouldn't work for the DUET module though.

    This was just a quick fix for a small job that originally had volume control which is why I used MA in the first place. I did spend a little more time making the attached GUI for it than I should have especially for likely a one time use. It's a little goofy but I wanted to try something different.

    I recently just wrote a module for the Antex receivers as well with kind of an intersting GUI.
Sign In or Register to comment.