Compare commits

...

8 Commits

Author SHA1 Message Date
yyashvardhan
bf125d0750 Ticket#576: Implement rest of the operate commands 2019-05-01 11:58:24 +05:30
vdutta
26efd8075e PoC#578: [USPD] multiple element set in one set command 2019-04-25 13:08:39 +05:30
vdutta
369a371fd3 Ticket#460: Updated group logic in uspd get operation 2019-04-18 11:43:16 +05:30
vdutta
672a2914ba Ticket#460: Update get and operate command in uspd 2019-04-17 18:32:32 +05:30
vdutta
24a4cea696 Ticket#460: Updated output format of uspd 2019-04-11 14:29:16 +05:30
vdutta
02700e01c7 Ticket#460: Updated search by reference logic in uspd 2019-04-10 13:01:40 +05:30
vdutta
e280e6e2ac Ticket#460: Added operate in uspd 2019-04-09 18:21:32 +05:30
vdutta
9f454afaef Ticket-460: USP extention for TR-069
Description:
 - First draft of the changes

Test Done:
 - Below ubus call tested
   ubus call usp get '{"path":"Device.WiFi.SSID.[BSSID==\"00:22:07:6D:5E:DD\"].SSID"}'
   ubus call usp get '{"path":"Device.IP.Interface.*.IPv4Address.*.IPAddress"}'
   ubus call usp get '{"path":"Device.WiFi.AccessPoint.[SSIDReference+BSSID==\"00:22:07:6D:5E:DD\"].SSID"}'
   ubus call usp set '{"path":"Device.WiFi.AccessPoint.[SSIDReference+BSSID==\"00:22:07:6D:5E:D\"].SSID", "value":"Test-2G"}'

Not Covered:
 - Operate command
 - Alias based addressing
 - Searching with List of References
2019-04-05 19:41:38 +05:30
2 changed files with 65 additions and 0 deletions

46
usp/Makefile Normal file
View File

@@ -0,0 +1,46 @@
#
# Copyright (C) 2019 Iopsys
#
include $(TOPDIR)/rules.mk
PKG_NAME:=uspd
PKG_VERSION:=1.0.0
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=e9aa8a42f1da90b44fbd6bca3f4131a24fe79efb
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/uspd.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
include $(INCLUDE_DIR)/package.mk
define Package/uspd
SECTION:=utils
CATEGORY:=Utilities
TITLE:=TR069 extention for USP
DEPENDS:=+libubox +ubus +icwmp-curl
endef
define Package/uspd/description
Ubus based backend for TR-369/USP which can be used by other USP agents
running on top of it.
endef
TARGET_CFLAGS += \
-I$(STAGING_DIR)/usr/include \
-D_GNU_SOURCE
#define Build/Prepare
# $(CP) -rf ./uspd/* $(PKG_BUILD_DIR)/
#endef
define Package/uspd/install
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/uspd.init $(1)/etc/init.d/uspd
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/uspd $(1)/usr/sbin/
endef
$(eval $(call BuildPackage,uspd))

19
usp/files/uspd.init Normal file
View File

@@ -0,0 +1,19 @@
#!/bin/sh /etc/rc.common
START=94
STOP=10
USE_PROCD=1
PROG=/usr/sbin/uspd
start_service() {
procd_open_instance
procd_set_param command ${PROG}
procd_set_param respawn
procd_close_instance
}
reload_service() {
stop
start
}