When using an Input module, all switches needs to be connected in STAR towards the Input module. To allow customers to also use BUS connected switches, we've developed hardware and firmware to make this possible. For these BUS connected switches, we've decided to use the CAN protocol since this protocol is designed for environments with high distortion which makes this a very reliable solution.
We've 2 types of hardware designs that we've made:
- CAN Control: This is the CAN gateway that will convert RS485 message to CAN messages. When using CAN switches, 1 CAN controller is needed.
- CAN Switch: This is the hardware that will contain up to 8 switches, temperature sensor, humidity sensor and up to 8 leds. It will have 2 PCB designs:
- CAN Switch for Niko: Niko switches have a small PCB behind their switches. To make an Openmotics CAN switch, just change the Niko PCB by an Openmotics PCB.
- General CAN Switch: This small PCB will contains all the connections to connect any kind of switch.
How does it work
The CAN control unit is connected to the RS485 bus and to the CAN bus and will convert the messages between CAN and RS485. The CAN control unit is the start of the CAN bus. The CAN switches will be connected to the BUS starting at the CAN Control unit and going from 1 switch to the other.
The limit of the Openmotics system is 240 inputs and 240 outputs, the same limit applies on the "used" CAN switches. The definition of "used" CAN switch is important: Every single switch (and for example a Niko CAN switch has 6 single switches) behaves independently, if the switch is never used, it won't take any of the 240 possible inputs). Once a single switch is pressed for the first time, it will register in the CAN Control and will take 1 input. Once 8 single switches are registered, one full virtual input module is used. As of the 9th registered input, a second virtual input module is created. The same applies for the sensors: Once a single switch is pressed, the sensor (temperature, humidity etc) for that CAN switch will be registered in the CAN control module. When more then 8 sensors are registered, a second virtual sensor module will be created.
The CAN control will manage all the virtual Openmotics Input and Sensor modules.
When looking in the portal or in maintenance mode, you will not see any CAN modules but you'll see normal Input and Sensor modules. The CAN control will manage all the created virtual Input and Sensor modules.
How to set this up?
Once the wiring is done, enabling the CAN switches is very simple:
- Just press the switches you're going the use. Once a switch is pressed, the led of that switch will go ON to indicate that the switch is registered in the CAN controller. The built-in sensors will be automatically registered once 1 button of that module is pressed.
- Once you've pressed all the switches you want to use, start discovery mode (via maintenance mode or via the portal) and the status led of all modules will go on including the status led of the CAN Control module.
- Press the init button on the CAN control unit to create all the virtual input and sensor modules in the Gateway module.
- Stop discovery mode
Your CAN switches are ready for use and can be used like any switch connected to an input module.