from evdev import InputDevice
from select import select
dev = InputDevice('/dev/input/event0') # This can be any other event number. On my Raspi it turned out to be event0
while True:
    r,w,x = select([dev], [], [])
    for event in dev.read():
        # The event.code for a scroll wheel event is 8, so I do the following
        if event.code == 8:
            print(event.value)
4c1a751d59046189ee999b2d7b6d20dcd28b12c3
<mask token>

<mask token>
while True:
    r, w, x = select([dev], [], [])
    for event in dev.read():
        if event.code == 8:
            print(event.value)

<mask token>
dev = InputDevice('/dev/input/event0')
while True:
    r, w, x = select([dev], [], [])
    for event in dev.read():
        if event.code == 8:
            print(event.value)

from evdev import InputDevice
from select import select
dev = InputDevice('/dev/input/event0')
while True:
    r, w, x = select([dev], [], [])
    for event in dev.read():
        if event.code == 8:
            print(event.value)

from evdev import InputDevice
from select import select
dev = InputDevice('/dev/input/event0') # This can be any other event number. On my Raspi it turned out to be event0
while True:
    r,w,x = select([dev], [], [])
    for event in dev.read():
        # The event.code for a scroll wheel event is 8, so I do the following
        if event.code == 8:
            print(event.value)