mirror of https://github.com/OpenIPC/firmware.git
Ruby integration part 4 (#1340)
parent
5a2e3329ae
commit
9d0e4924fa
|
@ -20,7 +20,18 @@ define LINUX_PATCHER_CONFIG_ATHEROS
|
||||||
endef
|
endef
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifeq ($(OPENIPC_VARIANT),rubyfpv)
|
||||||
|
define LINUX_PATCHER_CONFIG_TIMERS
|
||||||
|
$(call KCONFIG_DISABLE_OPT,CONFIG_HZ_100)
|
||||||
|
$(call KCONFIG_ENABLE_OPT,CONFIG_HZ_1000)
|
||||||
|
$(call KCONFIG_ENABLE_OPT,CONFIG_HZ)
|
||||||
|
$(call KCONFIG_SET_OPT,CONFIG_HZ,1000)
|
||||||
|
$(call KCONFIG_SET_OPT,CONFIG_HZ_1000,y)
|
||||||
|
endef
|
||||||
|
endif
|
||||||
|
|
||||||
define LINUX_PATCHER_LINUX_CONFIG_FIXUPS
|
define LINUX_PATCHER_LINUX_CONFIG_FIXUPS
|
||||||
|
$(LINUX_PATCHER_CONFIG_TIMERS)
|
||||||
$(LINUX_PATCHER_CONFIG_ATHEROS)
|
$(LINUX_PATCHER_CONFIG_ATHEROS)
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,7 @@
|
||||||
config BR2_PACKAGE_RUBYFPV
|
config BR2_PACKAGE_RUBYFPV
|
||||||
bool "rubyfpv"
|
bool "rubyfpv"
|
||||||
select BR2_PACKAGE_LIBPCAP
|
select BR2_PACKAGE_LIBPCAP
|
||||||
select BR2_PACKAGE_LIBSODIUM
|
|
||||||
select BR2_PACKAGE_IW
|
select BR2_PACKAGE_IW
|
||||||
select BR2_PACKAGE_DATALINK
|
|
||||||
default n
|
default n
|
||||||
help
|
help
|
||||||
Ruby package
|
Ruby package
|
||||||
|
|
|
@ -5,6 +5,10 @@
|
||||||
|
|
||||||
chip=$(ipcinfo -c)
|
chip=$(ipcinfo -c)
|
||||||
fw=$(grep "BUILD_OPTION" "/etc/os-release" | cut -d= -f2)
|
fw=$(grep "BUILD_OPTION" "/etc/os-release" | cut -d= -f2)
|
||||||
|
echo "Chip: " > /tmp/ruby_boot.log
|
||||||
|
echo ${chip} >> /tmp/ruby_boot.log
|
||||||
|
echo "Firmware: " >> /tmp/ruby_boot.log
|
||||||
|
echo ${fw} >> /tmp/ruby_boot.log
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
start)
|
start)
|
||||||
|
@ -13,11 +17,12 @@ case "$1" in
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "Starting Ruby..."
|
echo "Starting Ruby..."
|
||||||
|
echo "Starting Ruby..." >> /tmp/ruby_boot.log
|
||||||
/usr/sbin/ruby_start
|
/usr/sbin/ruby_start
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
echo "Stopping Ruby..."
|
echo "Stopping Ruby..."
|
||||||
|
echo "Stopping Ruby..." >> /tmp/ruby_boot.log
|
||||||
/usr/sbin/ruby_stop.sh
|
/usr/sbin/ruby_stop.sh
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
|
@ -1,7 +1,5 @@
|
||||||
kill -9 `pidof ruby_start`
|
pidof ruby_start | xargs kill -9 2>/dev/null
|
||||||
kill -9 `pidof ruby_vehicle`
|
pidof ruby_rx_commands | xargs kill -9 2>/dev/null
|
||||||
kill -9 `pidof ruby_rx_rc`
|
pidof ruby_tx_telemetry | xargs kill -9 2>/dev/null
|
||||||
kill -9 `pidof ruby_rx_commands`
|
pidof ruby_rt_vehicle | xargs kill -9 2>/dev/null
|
||||||
kill -9 `pidof ruby_tx_telemetry`
|
pidof ruby_logger | xargs kill -9 2>/dev/null
|
||||||
kill -9 `pidof ruby_rt_vehicle`
|
|
||||||
kill -9 `pidof ruby_logger`
|
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
8.3
|
||||||
|
|
|
@ -6,14 +6,10 @@ endef
|
||||||
|
|
||||||
define RUBYFPV_BUILD_CMDS
|
define RUBYFPV_BUILD_CMDS
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_start)
|
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_start)
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_initradio)
|
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_logger)
|
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_logger)
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_timeinit)
|
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_rt_vehicle)
|
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_rt_vehicle)
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_tx_telemetry)
|
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_tx_telemetry)
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_rx_rc)
|
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_rx_commands)
|
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_rx_commands)
|
||||||
(cd $(@D); $(TARGET_CC) -s ruby_start.c -o ruby_vehicle)
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define RUBYFPV_INSTALL_TARGET_CMDS
|
define RUBYFPV_INSTALL_TARGET_CMDS
|
||||||
|
@ -22,23 +18,20 @@ define RUBYFPV_INSTALL_TARGET_CMDS
|
||||||
$(INSTALL) -m 755 -d $(TARGET_DIR)/usr/bin
|
$(INSTALL) -m 755 -d $(TARGET_DIR)/usr/bin
|
||||||
$(INSTALL) -m 755 -d $(TARGET_DIR)/root/ruby
|
$(INSTALL) -m 755 -d $(TARGET_DIR)/root/ruby
|
||||||
|
|
||||||
cp $(RUBYFPV_PKGDIR)/files/S99ruby $(TARGET_DIR)/etc/init.d
|
cp $(RUBYFPV_PKGDIR)/files/S73ruby $(TARGET_DIR)/etc/init.d
|
||||||
chmod 755 $(TARGET_DIR)/etc/init.d/S99ruby
|
chmod 755 $(TARGET_DIR)/etc/init.d/S73ruby
|
||||||
|
|
||||||
install -m 0755 -D $(@D)/ruby_start $(TARGET_DIR)/usr/sbin/ruby_start
|
install -m 0755 -D $(@D)/ruby_start $(TARGET_DIR)/usr/sbin/ruby_start
|
||||||
install -m 0755 -D $(@D)/ruby_initradio $(TARGET_DIR)/usr/sbin/ruby_initradio
|
|
||||||
install -m 0755 -D $(@D)/ruby_logger $(TARGET_DIR)/usr/sbin/ruby_logger
|
install -m 0755 -D $(@D)/ruby_logger $(TARGET_DIR)/usr/sbin/ruby_logger
|
||||||
install -m 0755 -D $(@D)/ruby_timeinit $(TARGET_DIR)/usr/sbin/ruby_timeinit
|
|
||||||
install -m 0755 -D $(@D)/ruby_rt_vehicle $(TARGET_DIR)/usr/sbin/ruby_rt_vehicle
|
install -m 0755 -D $(@D)/ruby_rt_vehicle $(TARGET_DIR)/usr/sbin/ruby_rt_vehicle
|
||||||
install -m 0755 -D $(@D)/ruby_tx_telemetry $(TARGET_DIR)/usr/sbin/ruby_tx_telemetry
|
install -m 0755 -D $(@D)/ruby_tx_telemetry $(TARGET_DIR)/usr/sbin/ruby_tx_telemetry
|
||||||
install -m 0755 -D $(@D)/ruby_rx_rc $(TARGET_DIR)/usr/sbin/ruby_rx_rc
|
|
||||||
install -m 0755 -D $(@D)/ruby_rx_commands $(TARGET_DIR)/usr/sbin/ruby_rx_commands
|
install -m 0755 -D $(@D)/ruby_rx_commands $(TARGET_DIR)/usr/sbin/ruby_rx_commands
|
||||||
install -m 0755 -D $(@D)/ruby_vehicle $(TARGET_DIR)/usr/sbin/ruby_vehicle
|
|
||||||
|
|
||||||
cp $(RUBYFPV_PKGDIR)/files/ruby_stop.sh $(TARGET_DIR)/usr/sbin
|
cp $(RUBYFPV_PKGDIR)/files/ruby_stop.sh $(TARGET_DIR)/usr/sbin
|
||||||
chmod 755 $(TARGET_DIR)/usr/sbin/ruby_stop.sh
|
chmod 755 $(TARGET_DIR)/usr/sbin/ruby_stop.sh
|
||||||
cp $(RUBYFPV_PKGDIR)/files/tweaksys $(TARGET_DIR)/usr/bin
|
cp $(RUBYFPV_PKGDIR)/files/tweaksys $(TARGET_DIR)/usr/bin
|
||||||
cp -r $(RUBYFPV_PKGDIR)/files/licences $(TARGET_DIR)/root/ruby/
|
cp -r $(RUBYFPV_PKGDIR)/files/licences $(TARGET_DIR)/root/ruby/
|
||||||
|
cp $(RUBYFPV_PKGDIR)/files/version_ruby_base.txt $(TARGET_DIR)/usr/sbin
|
||||||
endef
|
endef
|
||||||
|
|
||||||
$(eval $(generic-package))
|
$(eval $(generic-package))
|
||||||
|
|
Loading…
Reference in New Issue