예제 #1
0
def is_bt_up():
    if connman.is_technology_available('bluetooth') == False:
        journallog('No bluetooth hardware available.')
        #exit()
        return False
    if connman.is_technology_enabled('bluetooth') == False:
        journallog('Bluetooth is disabled.')
        #exit()
        return False
    return True
예제 #2
0
def is_bluetooth_enabled():
    connman_status = connman.is_technology_enabled('bluetooth')
    service_status = osmc_systemd.is_service_running(BLUETOOTH_SERVICE)
    adapterFound = False
    if connman_status and service_status:
        try:
            bluetooth.get_adapter()
            adapterFound = True
        except:  #  catch issue where connman reports BT but Bluez can't find an adapter
            adapterFound = False
    return connman_status and service_status and adapterFound
예제 #3
0
def is_bluetooth_enabled():
    connman_status = connman.is_technology_enabled('bluetooth')
    service_status = osmc_systemd.is_service_running(BLUETOOTH_SERVICE)
    adapterFound = False
    if connman_status and service_status:
        try:
            bluetooth.get_adapter()
            adapterFound = True
        except: #  catch issue where connman reports BT but Bluez can't find an adapter
            adapterFound = False
    return connman_status and service_status and adapterFound
예제 #4
0
def is_bluetooth_enabled():
    connman_status = connman.is_technology_enabled("bluetooth")
    service_status = systemd.is_service_running(BLUETOOTH_SERVICE)
    return connman_status and service_status
예제 #5
0
def is_bluetooth_enabled():
    connman_status = connman.is_technology_enabled('bluetooth')
    service_status = systemd.is_service_running(BLUETOOTH_SERVICE)
    return connman_status and service_status
예제 #6
0
def is_ethernet_enabled():
    return connman.is_technology_enabled(
        'ethernet') or not get_nfs_ip_cmdline_value() == None
예제 #7
0
def is_wifi_enabled():
    try:
        return connman.is_technology_enabled('wifi')
    except:
        return False
예제 #8
0
def is_ethernet_enabled():
    return connman.is_technology_enabled('ethernet')
예제 #9
0
def is_wifi_enabled():
    return connman.is_technology_enabled('wifi')
예제 #10
0
def is_ethernet_enabled():
    return connman.is_technology_enabled('ethernet') or not get_nfs_ip_cmdline_value() == None
예제 #11
0
def is_wifi_enabled():
    try:
        return connman.is_technology_enabled('wifi')
    except:
        return False
예제 #12
0
def is_bluetooth_enabled():
    connman_status = connman.is_technology_enabled('bluetooth')
    return connman_status
예제 #13
0
def is_bluetooth_enabled():
    return connman.is_technology_enabled('bluetooth')
예제 #14
0
def is_wifi_enabled():
    return connman.is_technology_enabled('wifi')