Removed exports and added empty variable definition.
This commit is contained in:
@@ -93,39 +93,44 @@ ssh_to_host() {
|
||||
}
|
||||
|
||||
hardware_detection() {
|
||||
echo -e "\n\n 🔎 Detecting graphics card on target host..."
|
||||
VGA_INFO=$(ssh_to_host "lspci -nn | grep -i 'vga'")
|
||||
if echo "$VGA_INFO" | grep -iq "intel" 2>/dev/null; then
|
||||
echo -e " ✅ Intel graphics card detected."
|
||||
export TARGET_GRAPHICS="true"
|
||||
TARGET_GRAPHICS="true"
|
||||
elif echo "$VGA_INFO" | grep -iq "amd" 2>/dev/null; then
|
||||
echo -e " ✅ AMD graphics card detected."
|
||||
export TARGET_GRAPHICS="true"
|
||||
TARGET_GRAPHICS="true"
|
||||
elif echo "$VGA_INFO" | grep -iq "nvidia" 2>/dev/null; then
|
||||
echo -e " ✅ NVIDIA graphics card detected."
|
||||
export TARGET_GRAPHICS="true"
|
||||
TARGET_GRAPHICS="true"
|
||||
else
|
||||
echo -e " ⚠️ No dedicated graphics card detected."
|
||||
export TARGET_GRAPHICS="false"
|
||||
TARGET_GRAPHICS="false"
|
||||
fi
|
||||
echo -e "\n\n 🔎 Detecting transconding acceleration on target host..."
|
||||
if ssh_to_host "ls /dev/dri/renderD300" 2>/dev/null; then
|
||||
echo -e " ✅ Transcoding capable card detected."
|
||||
export TARGET_GRAPHICS_RENDERER="true"
|
||||
TARGET_GRAPHICS_RENDERER="true"
|
||||
else
|
||||
echo -e " ⚠️ No transcoding capable card detected."
|
||||
export TARGET_GRAPHICS_RENDERER="false"
|
||||
TARGET_GRAPHICS_RENDERER="false"
|
||||
fi
|
||||
echo -e "\n\n 🔎 Detecting USB Google Coral TPU on target host..."
|
||||
if ssh_to_host "lsusb | grep -iq 'google'" 2>/dev/null; then
|
||||
echo -e " ✅ USB Google Coral TPU detected."
|
||||
export TARGET_USB_CORAL="true"
|
||||
TARGET_USB_CORAL="true"
|
||||
else
|
||||
echo -e " ⚠️ No USB Google Coral TPU detected."
|
||||
export TARGET_USB_CORAL="false"
|
||||
TARGET_USB_CORAL="false"
|
||||
fi
|
||||
echo -e "\n\n 🔎 Detecting Zigbee coordinator on target host..."
|
||||
if ssh_to_host "ls /dev/serial/by-id/ | grep -i 'zigbee'" 2>/dev/null; then
|
||||
echo -e " ✅ Zigbee device found in /dev/serial/by-id/."
|
||||
export TARGET_ZIGBEE_DEVICE=$(ssh_to_host "ls /dev/serial/by-id/ | grep -i 'zigbee'")
|
||||
TARGET_ZIGBEE_DEVICE=$(ssh_to_host "ls /dev/serial/by-id/ | grep -i 'zigbee'")
|
||||
else
|
||||
echo -e " ⚠️ No Zigbee device found."
|
||||
TARGET_ZIGBEE_DEVICE=""
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user