M2M First Time - Need some Pointers
cheekytigerapps
Junior Member
This is the first time I have to program a Master-2-Master. I was wondering if there are any guides on some basic netlinx code.
The questions I have:
1. How do I define the two masters
2. I am only using the second master to control a TV via IR in a remote room. Do i need to create a second project.
3. Does anyone have a workspace with some basic M2M that they could share.
The questions I have:
1. How do I define the two masters
2. I am only using the second master to control a TV via IR in a remote room. Do i need to create a second project.
3. Does anyone have a workspace with some basic M2M that they could share.
Comments
-
Make sure your system numbers are set differently. (First master :system 1. Second master: system 2 for example)
Put the URL (IP address of the main master ) into the URL list of the subordinate master. Do not put the sub master IP in the main masters URL list. The communication is already bi-directional with the one link.
That will start the m2m communication
In code: to address and use the devices on the sub master just declare a device with the sub master system number.DEFINE_DEVICE dvSerial_Master_1 = 5001: 01: 01 dvSerial_Master_2 = 5001: 01: 02
Sending a string from code in master one to dvSerial_Master_2 will send it out port 1 on master 2 -
Be careful not to create a connection loop. If master 1 connects to 2, and 2 connects to 3, DO NOT connect 3 to 1, or the whole thing will crash and burn. Be very careful none of your routes have any chance of looping like that. I typically pick one master to be the "central," then have everything connect to that master in their individual URL lists. If the network is really big, you can spread it out by having half (or whatever) connect to one, and the rest to the other, then have ONE of those connect to the other as well.
-
I am not sure if it is still needed, but I seem to recall needing a program with at least one non-volatile variable declared in the subordinate master. This is important if you don't plan on adding any code to the secondary master. Altho, if that is the case, you might want to consider an ICSLan device for the remote location.
-
There are no pointers in Netlinx, just references.
Paul
Categories
- All Categories
- 2.5K AMX General Discussion
- 922 AMX Technical Discussion
- 514 AMX Hardware
- 502 AMX Control Products
- 3 AMX Video Distribution Products
- 9 AMX Networked AV (SVSI) Products
- AMX Workspace & Collaboration Products
- 3.4K AMX Software
- 151 AMX Resource Management Suite Software
- 386 AMX Design Tools
- 2.4K NetLinx Studio
- 135 Duet/Cafe Duet
- 248 NetLinx Modules & Duet Modules
- 57 AMX RPM Forum
- 228 MODPEDIA - The Public Repository of Modules for Everyone
- 943 AMX Specialty Forums
- 2.6K AMXForums Archive
- 2.6K AMXForums Archive Threads
- 1.5K AMX Hardware
- 432 AMX Applications and Solutions
- 249 Residential Forum
- 182 Tips and Tricks
- 146 AMX Website/Forums