Eric

About

Username
Eric
Joined
Visits
6,099
Last Active
Roles
Administrator

Activity

  • RyanM
    Hi Eric,

    In reference to pymetawear logging I am getting this error:

    libmetawear.mbl_mw_logging_download(c.board, 20,pointer(download_handler))
    ctypes.ArgumentError: argument 3: <type 'exceptions.TypeError'>: expected LP_LogDownloadHandler instance instead of LP_LogDownloadHandler

    when I run this:

    from pymetawear.mbientlab.metawear.cbindings import *

    backend = 'pygatt'
    sensor = sys.argv[1]
    c = MetaWearClient(sensor, backend)

    def progress_update_handler(self,entries_left,total_entries):
            self.updates.append(entries_left)

    def unknown_entry_handler(self, id, epoch, data, length):
            data_ptr=cast(data,POINTER(c_uint))

    libmetawear.mbl_mw_logging_start(c.board,1000)
    signal = libmetawear.mbl_mw_acc_get_acceleration_data_signal(c.board)

    c.logger_created = FnVoid_VoidP(c.logger_ready)

    libmetawear.mbl_mw_datasignal_log(signal,c.logger_created)

    time.sleep(5.0)
    libmetawear.mbl_mw_logging_stop(c.board)


    c.progress_update = FnVoid_UInt_UInt(progress_update_handler)
    c.unknown_entry = FnVoid_UByte_Long_UByteP_UByte(unknown_entry_handler)

    download_handler = LogDownloadHandler(received_progress_update =c.progress_upda$

    libmetawear.mbl_mw_logging_download(c.board, 20,pointer(download_handler))

    The following was added to client.py

        def logger_ready(self,pointer):
            self.loggers.append(pointer)


    and 
    self.loggers = [] 
    to __init__


    I suspect it has something to do with the cbindings.py file that I copied over after building the C++ API.

    Would you happen to have any insights on the fix/as to when pymetawear.logging will be up and running?

    Thanks!
    July 14
    • RyanM
      RyanM
      Never mind, I just learned a ton about the Python interpreter and back on some hot leads
  • TomAllen


    Hi Eric,


    I am using the MetaWear CPro. I am trying both of the available apps to log my data on an iPad.



     



    I
    have a query related to sampling frequency, which seems to be a common issue. I set the required sampling
    frequency (e.g. 800 Hz) in the app, log and then download the data. However,
    when I check the time spacing in excel, it does not match the frequency which I
    set in the app. In addition, it is often inconsistent changing with time.

    I am trying to use the sensor to obtain the frequency of an oscillated object, such as a pendulum. To do this I load the acceleration data into Matlab and run an fast Fourier transform to obtain the frequency. When I do this I am using a constant sample rate, as set in the app. However, I am concerned that this might not be correct, based on the time stamp I am getting.

    Please can you clarify.

    Tom

    June 30
  • trt
    trt Eric
    Hi Eric,

    I'm facing issue in Counting steps using two Metawear devices.

    The Board is BMI160. Sample Frequency is 50.  Scale: -2/+2

    I'm using step counter of BMI to calculate steps. Do I need to create different step event for each sensors?

    if yes than when can I assign step event to sensor?

    sometimes i'm getting value twice(if only one step is taken, step event display 2 steps. It's also happen in "MetaWearApiTest" demo project by Mbientlab)

    can you tell me, what is best way to calculate steps for both Left/Right sensors at a time? Also guide me if I'm wrong at any place.

    Thank you in advance for your time.
    January 18
  • rajmishra
    Hi Eric,


    i removed the battery and checked by connecting USB still not able to detect.
    Most possibly there is some problem with the board, in that case can it be repaired?
    what should i do ?

    July 2016
  • gulshan
    How to connect multiple Metawear sensors to an iOS device at the same time and get the combined data for them using Swift language? Please Help!
    July 2016
  • asobol22
    Hi,


    I am working in a similar situation and am a little bit confused on what hardware kit or tools I need to buy. I already bought the nRF51 Bluetooth Smart kit, but don't think it is what I wanted.

    I am trying to code the firmware for the MetaWear device (https://www.mbientlab.com). I already have the Conn 10 point connector soldered to the board, just unsure of what eval/dev kit or alternative solution I need to buy. I thought that maybe I just needed to get a J-Link LITE Cortex 9, but learned you can only get that with a kit. Also, wasn't sure what IDE or SDK I needed to make this possible.

    I am a bit lost as you can tell...can you help clear some of this up? I really appreciate it!

    Adam
    March 2015