EN RU CN
Encoders not working on PWM or SPI on SimpleBGC 32 Extended
  • I have tried several configurations on using both PWM and SPI from encoder to controller, and get no data from the encoders.

    This is similar to https://forum.basecamelectronics.com/index.php?p=/discussion/comment/9520#Comment_9520, which appears to be unresolved.

    I bought this https://www.iflight-rc.com/index.php?route=product/product&product_id=233&search=8028 kit. Which has the AS5048A encoder and the SimpleBGC 32 Extended controller ( https://www.iflight-rc.com/index.php?route=product/product&path=25_95&product_id=276 ). I have updated the board to '2.63 b0 Extended + ENCODERS' from GUI v2.63 b0.

    For PWM I hook up to the v+, gnd, and rc-p/fc-p/fc-r on the controller using stock included harnesses

    For SPI I hook up to the three SPI ports built into the controller using stock included harnesses

    Here is the debug for the PWM connection (skip autodetection checked or unchecked):
    ----------------------------------
    Device s/n: 01239f8b8584d442ee, MCU s/n: 38363020015734591b002000
    Firmware ver.: 2.63 b0, board ver.:3.6
    error:2
    assert_line: 0
    assert_file:
    COM errors: 3
    Encoder[ROLL] type: AS5048A,B (PWM)
    read errors: 7175
    Encoder[PITCH] type: AS5048A,B (PWM)
    read errors: 7178
    Encoder[YAW] type: AS5048A,B (PWM)
    read errors: 7175
    DRIVERS STATE: OTW=0, DRV_FAULT=1
    TIME SLOTS FREE (us): 1:516, 2:522, 3:206, 4:460, 5:273, 6:266, 7:524, 8:278, 9:525, 10:529,
    TEMPERATURE (C): MCU=34, IMU=25, F.IMU=33, DRIVERS=0, ROLL_M=0, PITCH_M=0, YAW_M=0,
    I2C errors: 1; by device: 0x68=1;
    -----------------------------------

    The debug trace for SPI with skip autodetection checked is the same.

    The debug trace for SPI with skip autodetection checked does not show read errors or any problems.

    On the monitoring tab: In all cases (PWM, SPI, skip autodetection checked or unchecked) the ENC_RAW_R, ENC_RAW_P, and ENC_RAW_Y show value of 0. Various other monitors show reasonable values.

    -----------------------------------------------------------------------------------------------------------

    Since at least one other person is seeing this I suspect its not simply a rare defect. I need to get this resolved or Ill have to return the controller and find another solution.

  • Hello,
    "For PWM I hook up to the v+, gnd, and rc-p/fc-p/fc-r on the controller using stock included harnesses"
    - this connection type is suitable only with regular or Tiny boards.

    The extended board has particulary ports for encoders: http://ybex.com/d/75hqvf74rb9ipuhphiypabfofs2or88rcpcdxbs5.html
    I markered pins which will be used for PWM connection type.
  • Another important thing, there are two types of AS5048 chips: https://media.digikey.com/pdf/Data Sheets/Austriamicrosystems PDFs/AS5048A,B.pdf
    Types differ in available interfaces:
    AS5048A - SPI + PWM
    AS5048B - I2c + PWM
    What type of chip do you have on the board?
  • AndrewSupport: Thanks for responding. As specified in my post:

    "the AS5048A encoder"

    "For SPI I hook up to the three SPI ports built into the controller using stock included harnesses"

    -Mark West
  • Hello,
    Ok. I found similar motor from Iflight with built-in encoder, and discovered there AS5048L
    This is clone of AS5048A chip is compatible with our boards.
    But sequence of pins in the connector is different from sequence of pins in our controller.
    This photo with description will help you connect the encoder correctly: http://ybex.com/d/q3uhyb1tzgsda23jecy4hlfk7pbdyb244g6zxthv.html
  • AndrewSupport: Thank you, Ill work on getting the harness adapted and see what happens.