Python should work now
This commit is contained in:
parent
1da83b8393
commit
26696599b3
|
@ -57,12 +57,12 @@ class _SSS7(object):
|
||||||
return tmp == 1
|
return tmp == 1
|
||||||
|
|
||||||
def has_received(self):
|
def has_received(self):
|
||||||
return _LIB_SSS7.libsss7_get_received()
|
return _LIB_SSS7.libsss7_has_received()
|
||||||
|
|
||||||
def get_received(self):
|
def get_received(self):
|
||||||
payload = [0] * LIBSSS7_PAYLOAD_SIZE
|
payload = _SSS7_PAYLOAD_TYPE()
|
||||||
_LIB_SSS7.libsss7_get_received(payload)
|
_LIB_SSS7.libsss7_get_received(payload)
|
||||||
return payload
|
return [payload[i] for i in range(0, LIBSSS7_PAYLOAD_SIZE)]
|
||||||
|
|
||||||
def stop(self):
|
def stop(self):
|
||||||
_LIB_SSS7.libsss7_stop()
|
_LIB_SSS7.libsss7_stop()
|
||||||
|
|
|
@ -25,10 +25,11 @@ def main():
|
||||||
print "Send failed"
|
print "Send failed"
|
||||||
|
|
||||||
|
|
||||||
#while(!bus.hasReceived());
|
while not SSS7.has_received():
|
||||||
#byte[] data = bus.getReceived();
|
sleep(0.1)
|
||||||
#String str = new String(data);
|
|
||||||
#System.out.println(str);
|
print to_string(SSS7.get_received())
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
SSS7.stop()
|
SSS7.stop()
|
||||||
|
|
Loading…
Reference in New Issue