Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| network:firmware:meshdesk [2024/02/17 11:47] – created system | network:firmware:meshdesk [2025/04/15 05:18] (current) – system | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| <nav type=" | <nav type=" | ||
| * [[: | * [[: | ||
| - | * [[:radius:rad_kick|A]] | + | * [[:network:firmware: |
| </ | </ | ||
| + | |||
| + | ---- | ||
| + | |||
| + | ====== OpenWRT 24.10.x with MESHdesk packages ====== | ||
| + | <alert type=" | ||
| + | Follow these instructions to include the MESHdesk package on devices that can run OpenWRT version 24.10.x | ||
| + | </ | ||
| + | ===== Minimum hardware requirements ===== | ||
| + | * The minimum hardware requirements are: | ||
| + | * **16M Flash** | ||
| + | * **64M RAM** | ||
| + | * Although the system can potentially support hardware with fewer resources, support is no longer practical in 2024. | ||
| + | * The hardware does not need to be equipped with a radio. | ||
| + | * Hardware without radios can be managed with APdesk. | ||
| + | * Mediatek and Atheros / Qualcomm SOC devices are supported. | ||
| + | * Other target systems are also supported, but have not yet been thoroughly tested. | ||
| + | * If you are not sure if your hardware works, please visit the OpenWrt website and check it. The list of supported hardware is constantly expanding. | ||
| + | * Next, let us look at the steps you need to take to compile OpenWrt with the included MESHdesk package. | ||
| + | |||
| + | <panel type=" | ||
| + | ===== Steps when adding new hardware ===== | ||
| + | ==== Explanation of our modus operandi (MO) ==== | ||
| + | * To introduce a new device we will: | ||
| + | - We create an initial firmware image for development that contains all the required packages and files, but with centralized management <wrap em> | ||
| + | - Then we flash a device with this image and make the device-specific adjustments so that the device works as expected with central management. | ||
| + | - We can then use these optimized files to create a production image for the device that contains the device-specific files. | ||
| + | * This approach allows us to: | ||
| + | * Minimize the risk of bricking the device (a factory reset resets the device to a normal running OpenWrt) | ||
| + | * Allow fine tuning of the device without having to create and flash a new firmware image every time we make a change. | ||
| + | |||
| + | ------ | ||
| + | |||
| + | ==== First development firmware ==== | ||
| + | These steps are performed <wrap em>ONLY ONCE</ | ||
| + | - Build OpenWRT with the MESHdesk package (MESHdesk disabled). | ||
| + | - Flash your device. | ||
| + | - Prepare the **wan_network** file for this specific device. | ||
| + | - Prepare the **meshdesk** config file for this specific device. | ||
| + | - Prepare the **captive_config.json** file for this specific device. | ||
| + | |||
| + | <alert type=" | ||
| + | To better structure the documentation, | ||
| + | </ | ||
| + | <wrap em>This is a one-time process. Once you have customized the files, you can skip this step in the future and simply use the device-specific files if you need to create new firmware for the same hardware.</ | ||
| + | |||
| + | ------- | ||
| + | |||
| + | ==== Production Firmware ==== | ||
| + | - Create OpenWRT firmware with the MESHdesk package, which contains the device-specific files for | ||
| + | - wan_network | ||
| + | - captive_config.json | ||
| + | - meshdesk | ||
| + | - Flash your device with the production firmware. | ||
| + | </ | ||
| + | * So without further ado, let us start with the first development firmware. | ||
| + | * We will take a Xiaomi 4A 100M access point as an example device. | ||
| + | * You can use the hardware of your choice and simply apply the same principles. | ||
| + | |||
| + | ===== Checkout the MESHdesk code ===== | ||
| + | * Most of the packages you can include when building OpenWrt firmware are either part of the SDK or can be included via the package feeds, which are also part of the SDK. | ||
| + | * You can also include packages that are not part of the SDK or the feeds. | ||
| + | * The MESHdesk package is one such package. | ||
| + | * The MESHdesk package is hosted on Github as part of a git repository. | ||
| + | * This git repository also contains the other elements that we will use in the development of our firmware (the Luci application and some additional files) | ||
| + | * Check out the **openwrt-meshdesk** package from the Github repository. | ||
| + | < | ||
| + | #Do this in the working directory e.g. cd 24.10.1 (on the same level as the openwrt directory) | ||
| + | git clone https:// | ||
| + | </ | ||
| + | * The repository consists of three main components. Each of them is located in its own folder. | ||
| + | - **MESHdesk** - This is the MESHdesk package that will be included in the SDK. | ||
| + | - **files** - This is the overwrite structure that contains files to be overwritten during the build process. | ||
| + | - **luci-app-meshdesk** - This is the Luci application that allows you to enable or disable centralized control of the device. | ||
| + | |||
| + | ===== Copying the three components ===== | ||
| + | * The **MESHdesk** folder must be copied under the **package** folder (openwrt/ | ||
| + | <code bash> | ||
| + | #cd to the working directory | ||
| + | cp -R ./ | ||
| + | </ | ||
| + | * The **files** folder needs to sit directly under the **openwrt** folder (root level). | ||
| + | <code bash> | ||
| + | #cd to the working directory | ||
| + | cp -R ./ | ||
| + | </ | ||
| + | * The **luci-app-meshdesk** folder needs to be copied under the **feeds/ | ||
| + | <code bash> | ||
| + | #cd to the working directory | ||
| + | cp -R ./ | ||
| + | </ | ||
| + | ===== Updating the available packages ===== | ||
| + | * Since we added a Luci application, | ||
| + | * After copying the packages, enter the following command: | ||
| + | <code bash> | ||
| + | #cd to the working directory | ||
| + | cd ./openwrt | ||
| + | scripts/ | ||
| + | #Install the package to make it visible | ||
| + | scripts/ | ||
| + | </ | ||
| + | * The result is that the Luci application MESHdesk is listed as one of the available Luci applications. | ||
| + | |||
| + | ===== Select Packages To Include With Firmware ===== | ||
| + | <panel type=" | ||
| + | {{: | ||
| + | </ | ||
| + | * The OpenWrt SDK has a cursors interface (similar to Midnight Commander for the old school readers 8-O) | ||
| + | * To start this cursors interface, you have to change from the working directory to the **openwrt** directory. | ||
| + | * Then issue the following: | ||
| + | <code bash> | ||
| + | #cd to the working directory | ||
| + | cd openwrt | ||
| + | make menuconfig | ||
| + | </ | ||
| + | * Here you select the hardware architecture of the device for which you want to create the firmware and its model. | ||
| + | * Also select the following packages when creating the firmware. | ||
| + | * When you select a package, you have the option of building it as a module (M) or including it completely (*). | ||
| + | * **Make sure you select the (*) option to fully include the package.** | ||
| + | * The package names in bold are required. | ||
| + | * The Mosquitto packages are for MQTT support. | ||
| + | * The Batman packages are for Mesh support. | ||
| + | |||
| + | <panel type=" | ||
| + | ^ Location | ||
| + | | Base system | ||
| + | | Base system | ||
| + | | Kernel Modules -> Netfilter Extensions | ||
| + | | Kernel Modules -> Network Devices | ||
| + | | Kernel Modules -> Network Support | ||
| + | | Languages -> Lua |lua-mosquitto | ||
| + | | Languages -> Lua |**libiwinfo-lua** | ||
| + | | Languages -> Lua | **luasocket** | ||
| + | | Libraries | ||
| + | | Luci -> Collections | ||
| + | | Luci -> Modules | ||
| + | | Luci -> Applications | ||
| + | | Luci -> Applications | ||
| + | | Luci -> Themes | ||
| + | | Luci -> Libraries | ||
| + | | Luci -> Libraries | ||
| + | | Luci -> Libraries | ||
| + | | Luci -> Libraries | ||
| + | | Network -> Captive Portals | ||
| + | | Network -> File Transfer | ||
| + | | Network -> Firewall | ||
| + | | Network -> Routing and Redirection | ||
| + | | Network -> WirelessAPD | **wpad IEEE 802.1x Auth/ | ||
| + | | Network | ||
| + | |Network | ||
| + | |Network | ||
| + | </ | ||
| + | |||
| + | <panel type=" | ||
| + | ^ Location | ||
| + | | Kernel modules -> USB Support | kmod-usb-net-cdc-mbim | ||
| + | | Kernel modules -> USB Support | kmod-usb-net-qmi-wwan | ||
| + | | Kernel modules -> USB Support | kmod-usb-serial-option | optional - for AT commands | | ||
| + | | Kernel modules -> USB Support | kmod-usb-serial-qualcomm | ||
| + | | Kernel modules -> USB Support | kmod-usb-serial-sierrawireless | ||
| + | | Kernel modules -> USB Support | kmod-usb-wdm | ||
| + | | Network -> WWAN |uqmi | | | ||
| + | | Utilities | ||
| + | | Utilities -> Terminal |minicom | ||
| + | |||
| + | |||
| + | |||
| + | </ | ||
| + | |||
| + | * Once you have selected these packages, you can save the configuration and run **make** to create the firmware. | ||
| + | * The finished firmware can then be found in the **openwrt/ | ||
| + | * In our case we will use // | ||
| + | * The firmware you have just created is then a standard OpenWrt and you can flash your hardware like a normal OpenWRT and then access it via **192.168.1.1**. | ||
| + | * Username and Password is **root** and **admin** for Luci and ssh. | ||
| + | * The next section covers the files you need to be attend to for the specific hardware tweaks. | ||
| + | |||
| + | ==== Note on Warnings | ||
| + | |||
| + | * When you run the **make** command, you may see these warnings. | ||
| + | * They are harmless and can be ignored. | ||
| + | <code bash> | ||
| + | WARNING: Makefile ' | ||
| + | WARNING: Makefile ' | ||
| + | WARNING: Makefile ' | ||
| + | WARNING: Makefile ' | ||
| + | WARNING: Makefile ' | ||
| + | WARNING: Makefile ' | ||
| + | WARNING: Makefile ' | ||
| + | make[2]: Entering directory '/ | ||
| + | make[2]: ' | ||
| + | make[2]: Leaving directory '/ | ||
| + | make[1] world | ||
| + | make[2] target/ | ||
| + | make[3] -C target/ | ||
| + | </ | ||
| + | |||
| + | |||
| + | |||
| + | ===== Files to tweak ===== | ||
| + | Use ssh to gain access to the device to modify these files. | ||
| + | < | ||
| + | * {{fa> | ||
| + | * {{fa> | ||
| + | * {{fa> | ||
| + | </ | ||
| + | |||
| + | |||
| + | * Once the customizations are complete, we can test everything. | ||
| + | * Log in to your device with Luci (http:// | ||
| + | * The following image shows how to point the device to the controller via the GUI. | ||
| + | <panel type=" | ||
| + | {{: | ||
| + | </ | ||
| + | * Point the device at your controller and restart it. | ||
| + | * If all goes well, it will be displayed under New Arrivals - Hardware. | ||
| + | * If it is a new hardware type add it to the controller as described here: Hardware (Again Once Off) | ||
| + | |||
| + | ===== The Production Built ===== | ||
| + | * If everything works as intended on the device, you can use these optimized 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 table to find the location for the optimized files in the SDK. | ||
| + | |||
| + | <panel type=" | ||
| + | ^On Device | ||
| + | |/ | ||
| + | |/ | ||
| + | |/ | ||
| + | |/ | ||
| + | </ | ||
| + | * This brings us to the end of the page that describes how to create MESHdesk firmware for specific hardware. | ||
| + | |||