wearablebiosensing / bbm

Brain Body Motion Capture
0 stars 0 forks source link

error on Reza's computer #10

Open ghost opened 6 years ago

ghost commented 6 years ago

Exception in Tkinter callback Traceback (most recent call last): File "c:\python27\Lib\lib-tk\Tkinter.py", line 1541, in call return self.func(args) File "working.py", line 117, in connect filter=sensor_list) File "C:\Users\mrzab\Documents\BBM\bbm-BBM_code\bbm-BBM_code\WorkingCode_fnir-mocap\scripts and files\threespace_mine\threespace_api.py", line 389, in setStreamingTiming if sensor.setStreamingTiming(interval, duration, delay): File "C:\Users\mrzab\Documents\BBM\bbm-BBM_code\bbm-BBM_code\WorkingCode_fnir-mocap\scripts and files\threespace_mine\threespace_api.py", line 1614, in setStreamingTiming fail_byte, t_stamp, data = self.writeRead('_setStreamingTiming', arg_list) File "C:\Users\mrzab\Documents\BBM\bbm-BBM_code\bbm-BBM_code\WorkingCode_fnir-mocap\scripts and files\threespace_mine\threespace_api.py", line 2606, in _wirlessWriteRead result = self.dongle.faWriteRead(self.logical_id, command, input_list) File "C:\Users\mrzab\Documents\BBM\bbm-BBM_code\bbm-BBM_code\WorkingCode_fnir-mocap\scripts and files\threespace_mine\threespace_api.py", line 2925, in faWriteRead packed_data=struct.pack(in_struct, input_list) error: integer out of range for 'I' format code

kabuki4774 commented 6 years ago

The duration your trying to set seems to be quite long lines 113 - 117 ts_api.global_broadcaster.setStreamingTiming( interval=0, duration=22000000000, delay=0, delay_offset=0, filter=sensor_list) the duration appears to be 22000000000 microseconds (~6.1 hours). Please check this is what is really desired. We typically leave that value at 10000000 microseconds (~10 seconds). Perhaps a duration of 600000000 (10 minutes) is more appropriate.

setStreamingTiming(interval, duration, delay) in microseconds

interval: An integer whose value expressed how long in microseconds the wireless sensor should wait before attempting to transmit a packet.

duration: An integer whose value expressed how long in microseconds the wireless sensor should transmit asynchronous packets. Once the elapsed time since the start of the asynchronous session exceeds duration, the sensor will stop transmitting asynchronous packets on its own. If the duration is 0xffff (65535 in decimal), the sensor will transmit packets until either the sensor is powered down or another asynchronous command is sent with a finite duration value. A duration of 0 will effectively stop all asynchronous transmissions from the wireless sensor.

delay: An integer whose value expressed how long in microseconds the wireless sensor should wait before beginning the transmission session.

note: in threespace_api.piy line: 3137

182(0xb6)

def broadcastSynchronizationPulse(self, timestamp=False):
    fail_byte, t_stamp, data = self.writeRead('broadcastSynchronizationPulse')
    if timestamp:
        return (not fail_byte, t_stamp)
    return not fail_byte

could be of use