diff --git a/files/usr/lib/lua/aredn/info.lua b/files/usr/lib/lua/aredn/info.lua index 2c68e000..331b87e1 100755 --- a/files/usr/lib/lua/aredn/info.lua +++ b/files/usr/lib/lua/aredn/info.lua @@ -487,4 +487,13 @@ function model.getLocalHosts() return hosts end +------------------------------------- +-- Returns Mesh gateway setting +------------------------------------- +function model.getMeshGatewaySetting() + gw=os.capture("cat /etc/config.mesh/_setup|grep olsrd_gw|cut -d'=' -f2|tr -d ' ' ") + gw=gw:chomp() + return gw +end + return model \ No newline at end of file diff --git a/files/www/cgi-bin/sysinfo.json b/files/www/cgi-bin/sysinfo.json index 68b72ea8..c624f9e0 100755 --- a/files/www/cgi-bin/sysinfo.json +++ b/files/www/cgi-bin/sysinfo.json @@ -55,7 +55,7 @@ end info={} -- API version -info['api_version']="1.7" +info['api_version']="1.8" -- NODE name @@ -81,6 +81,9 @@ info['node_details']['firmware_mfg']=fw_mfg -- Firmware version info['node_details']['firmware_version']=aredn_info.getFirmwareVersion() +-- Mesh Gatway +info['node_details']['mesh_gateway']=aredn_info.getMeshGatewaySetting() + -- Mesh RF info info['meshrf']={} local radio=aredn_info.getMeshRadioDevice()