This is the command to control Building Automation Stackable Card for Raspberry Pi
Don't forget to enable I2C communication:
sudo raspi-configcd
git clone https://github.com/SequentMicrosystems/megabas-rpi.git
cd megabas-rpi/
sudo make installNow you can access all the functions of the BAS board through the command "megabas". Use -h option for help:
megabas -hIf you clone the repository, any updates can be made with the following commands:
cd megabas-rpi/
git pull
sudo make installFor cards version 5.0 and up, input types are not dipswitch selectable, as for the previous versions, but software selectable. The default setting of the Inputs type is 0-10V, to change it:
- Make sure you have the latest
megabascommand installed, as explained above. - Run the command
megabas <stack> incfgwr <channel> <value>, where- stack = 0 - 7, Stack level selectable from ID0, ID1, ID2 dipswitches
- channel = 1 - 8, Channel number you need to modify
- value = 0 for 0-10V, 1 for 1K Thermistor or Dry contact, 2 for 10K Thermistor
For more info on the commands' parameters run megabas -h incfgwr and megabas -h incfgrd.
The input type settings are saved into the card's nonvolatile memory, so will be preserved after power-down.
The board can act as Modbus RTU slave device, checkout modbus instructions

