1
USB Infrared Toy / Re: Searching for code examples: python IR Toy MooVee micro
Please, respond if you have any suggestions to overcome the buffer underrun after sending the last string (with length = 8 chars) in the package:
Code: [Select]
#run selftest
written hex(ord(byte)) : 1 0x56
respons byte no 1 chr(ord()): V
respons byte no 2 chr(ord()): 2
respons byte no 3 chr(ord()): 2
respons byte no 4 chr(ord()): 2
written hex(ord(byte)) : 1 0x54
respons byte no 1 chr(ord()): F
respons byte no 2 chr(ord()): A
respons byte no 3 chr(ord()): 2
respons byte no 4 chr(ord()): 0
written hex(ord(byte)) : 1 0x53
respons byte no 1 chr(ord()): S
respons byte no 2 chr(ord()): 0
respons byte no 3 chr(ord()): 1
written hex(ord(byte)) : 1 0x24
written hex(ord(byte)) : 1 0x25
written hex(ord(byte)) : 1 0x26
set the modulation frequency
written hex(ord(byte)) : 1 0x6
written hex(ord(byte)) : 1 0x4e
written hex(ord(byte)) : 1 0x0
==========================
The Packet to be send:
Amount of strings
(with length 62 chrs (except the last one is shorter and ends with 0xFF 0xFF))
to be sent: 2
Iterative part with:
written hex(ord(byte)) : 1 0x3
respons byte no 1 hex(ord()): 0x3e
send string - 0 with length: 62
respons byte no 1 hex(ord()): 0x3e
send string - 1 with length: 8
respons byte no 1 hex(ord()): 0x3e
#'t' = 0x74 for the amount of bytes send
respons byte no 1 hex(ord()): 0x74
respons byte no 2 hex(ord()): 0x0
respons byte no 3 hex(ord()): 0x46
#Here we seem to have and 'F' (for buffer underrun) instead of 'C' for succes
respons byte no 4 hex(ord()): 0x46
respons byte no 5 hex(ord()): 0xff
respons byte no 6 hex(ord()): 0xff
respons byte no 7 hex(ord()): 0xff
respons byte no 8 hex(ord()): 0xff
respons byte no 9 hex(ord()): 0xff
respons byte no 10 hex(ord()): 0xff
==========next packet===============
resetting:
written hex(ord(byte)) : 1 0x0
written hex(ord(byte)) : 1 0x0
written hex(ord(byte)) : 1 0x0
written hex(ord(byte)) : 1 0x0
written hex(ord(byte)) : 1 0x0
end
------------------
(program exited with code: 0)
Press return to continue