#!/usr/bin/python
"""
Return disk usage, in bytes
"""

import os

def disk_usage(path, diskUsage='all'):
    st = os.statvfs(path)
    free = st.f_bavail * st.f_frsize
    total = st.f_blocks * st.f_frsize
    used = (st.f_blocks - st.f_bfree) * st.f_frsize

    if diskUsage == 'free':
        diskUsage = free
    elif diskUsage == 'total':
        diskUsage = total
    elif diskUsage == 'used':
        diskUsage = used
    elif diskUsage == 'all':
        diskUsage = free, total, used
    else:
        diskUsage = None

    return diskUsage

print disk_usage('/', 'free')

@@ -15,16 +15,29 @@
 hon%0A%22%22%22%0A
+disk_usage : 
 Return d
@@ -559,34 +559,269 @@
 ge%0A%0A
-print disk_usage('/', 'free'
+def getdf():%0A    p = os.popen(%22df -h%22)%0A    return p.read()%0A%0Adef getfree():%0A    p = os.popen(%22free%22)%0A    return p.read()%0A%0Adef getuptime():%0A    p = os.popen(%22uptime%22)%0A    return p.read()%0A%0A%0Aprint disk_usage('/', 'free')%0Aprint getdf()%0Aprint getfree()%0Aprint getuptime(
 )%0A

update rpiMonitor.py : df -h, free, uptime