[SOLVED] Installing MIOS in openHAB2

Hi. I am trying to install MIOS on OpenHAB2 on a Rasp Pi. I get that it doesn’t work using the Paper UI as it is a v1 binding. However I am really struggling with this and have come across a rather basic issue. So apologies in advance. I think I am supposed to load the scripts at https://github.com/openhab/openhab1-addons/tree/master/bundles/binding/org.openhab.binding.mios/examples/scripts . However 1. I cannot find the box with the URL to copy as shown in various online instructables. so 2. I copied the URL by right clicking on the file and “Copy link address” instead and used that but when i used git clone i then get an error that it cannot find the file e.g.
sudo git clone https://github.com/openhab/openhab1-addons/blob/master/bundles/binding/org.openhab.binding.mios/examples/scripts/miosLoad.sh
Cloning into ‘miosLoad.sh’…
fatal: repository ‘https://github.com/openhab/openhab1-addons/blob/master/bundles/binding/org.openhab.binding.mios/examples/scripts/miosLoad.sh/’ not found
What am i doing wrong please? Should I just hand create these script files?

Look here https://www.openhab.org/addons/bindings/mios1/#mios-bridge-binding

Thanks. The problem i get is once i get to the step " Item Generation : MiOS Item Generator". it takes me to GIT HUB where the scripts are stored. But I do not know how to install the scripts and I can’t find any instructions on line that correspond with what i see on this page.

The main page/README for that Github repo tells you what to do.

It says in the “OS Requirements” section that “These scripts are intended to be run on a Linux, Unix or MacOS X system.”

It’s followed by a ‘How To Use’ section that explains what the two main scripts do and how to use them.

Thanks. I think there is a bit missing between these two sections which is how to actually install them. How To Use is what to do with them after they are installed or cloned. This is the bit I do not know how to do (I think)…

You don’t install them… you clone the repo to a machine and then run them - they are scripts, not programs. The README gives “an example of what it’s like to run these command line scripts in sequence”…

Basically clone the repo to the appropriate machine, go into the directory where the cloned files are and in a terminal window type in ./miosLoad.sh <ip address of vera> once that has finished you can then run ./miosTransform.sh house to convert the output from the first file into something that OpenHAB can read (house.items).

UPDATE: If cloning the files to the local machine is an issue, you can view the ‘RAW’ file format and then copy and paste them. BUT you will need to get ALL the files in this particular repo directory.

Yes it is the cloning step that fails:

sudo git clone https://github.com/openhab/openhab1-addons/blob/master/bundles/binding/org.openhab.binding.mios/examples/scripts/miosLoad.sh

Cloning into ‘miosLoad.sh’…
fatal: repository ‘https://github.com/openhab/openhab1-addons/blob/master/bundles/binding/org.openhab.binding.mios/examples/scripts/miosLoad.sh/’ not found

As you suggest I will create .sh files and copy the script code into them manually and see whether that works.
Thanks again.

I have now worked out that i need to clone the entire addons github. once i did that and tracked them down in openhabian and found the mios directory i am now up and running.