This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
md:openwrt-meshdesk [2021/11/10 17:34] admin [Initial File Preperation] |
md:openwrt-meshdesk [2022/03/14 12:15] (current) admin [Select Packages To Include With Firmware] |
||
---|---|---|---|
Line 1: | Line 1: | ||
====== OpenWRT 21.02.x with MESHdesk packages ====== | ====== OpenWRT 21.02.x with MESHdesk packages ====== | ||
- | <WRAP center round tip 90%> | + | <WRAP center round info 90%> |
Follow these instructions to build the MESHdesk firmware on devices capable of running OpenWRT version 21.02.x | Follow these instructions to build the MESHdesk firmware on devices capable of running OpenWRT version 21.02.x | ||
</WRAP> | </WRAP> | ||
Line 42: | Line 42: | ||
<code bash> | <code bash> | ||
#Do this in the working directory e.g. cd 21.02.0 | #Do this in the working directory e.g. cd 21.02.0 | ||
- | git clone git://git.code.sf.net/p/radiusdesk/openwrt-meshdesk openwrt-meshdesk | + | git clone https://github.com/RADIUSdesk/openwrt-meshdesk.git openwrt-meshdesk |
</code> | </code> | ||
* The package has three main components. Each one is located in a unique folder. | * The package has three main components. Each one is located in a unique folder. | ||
- | - **zzz-MESHdesk** - This is the MESHdesk package which will be build by the SDK. | + | - **MESHdesk** - This is the MESHdesk package which will be build by the SDK. |
- **files** - This is the override structure containing files to override during the build process. | - **files** - This is the override structure containing files to override during the build process. | ||
- **luci-app-meshdesk** - This is the Luci application used to enable central control. | - **luci-app-meshdesk** - This is the Luci application used to enable central control. | ||
===== Copying the three components ===== | ===== Copying the three components ===== | ||
- | * The **zzz-MESHdesk** folder needs to be copied under the **package** folder (openwrt/package). | + | * The **MESHdesk** folder needs to be copied under the **package** folder (openwrt/package). |
<code bash> | <code bash> | ||
#cd to the working directory | #cd to the working directory | ||
- | cp -R ./openwrt-meshdesk/zzz-MESHdesk ./openwrt/package | + | cp -R ./openwrt-meshdesk/MESHdesk ./openwrt/package |
</code> | </code> | ||
* The **files** folder needs to sit directly under the **openwrt** folder (root level). | * The **files** folder needs to sit directly under the **openwrt** folder (root level). | ||
Line 85: | Line 85: | ||
===== Select Packages To Include With Firmware ===== | ===== Select Packages To Include With Firmware ===== | ||
* Select the following packages when building the firmware. | * Select the following packages when building the firmware. | ||
+ | * When selecting a package there are the options to build it as a module (M) or fully include it (*). | ||
+ | * **Make sure you select with the (*) option to fully include the package.** | ||
* Package names in bold are required. | * Package names in bold are required. | ||
* The Mosquitto packages are for MQTT support. | * The Mosquitto packages are for MQTT support. | ||
Line 90: | Line 92: | ||
^ Package ^ Location ^ Comment ^ | ^ Package ^ Location ^ Comment ^ | ||
- | | **zzz-MESHdesk** | Base system | | | + | | **MESHdesk** | Base system | | |
| kmod-batman-adv | Kernel Modules -> Network Support | Keep the default options | | | kmod-batman-adv | Kernel Modules -> Network Support | Keep the default options | | ||
| lua-mosquitto | Languages -> Lua | | | | lua-mosquitto | Languages -> Lua | | | ||
Line 116: | Line 118: | ||
* The next section will cover the files you have to attend to for the specific hardware tweaks. | * The next section will cover the files you have to attend to for the specific hardware tweaks. | ||
- | ===== Initial File Preperation ===== | + | ===== Initial File Preparation ===== |
* Use ssh to gain access to the device in order to tweak these files. | * Use ssh to gain access to the device in order to tweak these files. | ||
==== wan_network ==== | ==== wan_network ==== | ||
Line 171: | Line 173: | ||
</file> | </file> | ||
* Next look at the **/etc/MESHdesk/configs/wan_network** file that is derived from it. | * Next look at the **/etc/MESHdesk/configs/wan_network** file that is derived from it. | ||
- | <file bash network> | + | <file bash wan_network> |
config interface 'loopback' | config interface 'loopback' | ||
option proto 'static' | option proto 'static' | ||
Line 236: | Line 238: | ||
* Next we will look at the ///etc/config/meshdesk// file and tweak it to work with our environment and our hardware. | * Next we will look at the ///etc/config/meshdesk// file and tweak it to work with our environment and our hardware. | ||
- | + | <WRAP center round tip 90%> | |
+ | * There is a growing list of existing sample **wan_network** files under the ///openwrt/package/MESHdesk/files/MESHdesk/configs// folder. | ||
+ | * They have a convention of **network_<firmware_id>** e.g. network_xiaomi_4a_100 | ||
+ | * Simply copy that file over //openwrt/package/MESHdesk/files/MESHdesk/configs/wan_network// | ||
+ | * Those files will have a matching existing hardware section in the //openwrt/package/MESHdesk/files/MESHdesk/meshdesk// file | ||
+ | </WRAP> | ||
==== meshdesk ==== | ==== meshdesk ==== | ||
Line 400: | Line 406: | ||
* If it is a new hardware type add it to the controller as described here: [[2021:rd_full_hardware|Hardwares]] (Again Once Off) | * If it is a new hardware type add it to the controller as described here: [[2021:rd_full_hardware|Hardwares]] (Again Once Off) | ||
* [[md:xiaomi-attach|Attach A Device To Demo1 Mesh]] | * [[md:xiaomi-attach|Attach A Device To Demo1 Mesh]] | ||
+ | |||
+ | ===== The Final Built ===== | ||
+ | * If everything on the device work as intended you can use those tweaked files to build a final version of the firmware for the specific hardware. | ||
+ | * Copy the files to a temporary folder on the machine where you are building the firmware. | ||
+ | * Use the following as a lookup for the location inside the SDK where the tweaked files need to go. | ||
+ | |||
+ | ^On Device ^On SDK ^ | ||
+ | |/etc/MESHdesk/configs/wan_network |openwrt/package/MESHdesk/files/MESHdesk/configs/ | | ||
+ | |/etc/config/meshdesk | openwrt/package/MESHdesk/files/MESHdesk/ | | ||
+ | |/etc/MESHdesk/configs/captive_config.json |openwrt/package/MESHdesk/files/MESHdesk/configs/ | | ||
+ | |/etc/MESHdesk/reporting/report_to_server.lua |openwrt/package/MESHdesk/files/MESHdesk/reporting | | ||
+ | |||
+ | * This brings us to the end of the page on how to build MESHdesk firmware for specific hardware. | ||