Skip to main content
Visitor II
March 21, 2024
Question

The pwm is generating ramp signals when using sensor with i2c interface

  • March 21, 2024
  • 1 reply
  • 1156 views

hello everyone, I am trying to combine a H-bridge-based motor controller and a sensor connected by i2c with stm32g032k8txx. They both work when i run on different microcontrollers, but when I combine them, the sensor is working fine but the PWM of the STM32 gets abnormal, like the output is something like a ramp signal (the motor initially starts at a slow speed and gradually increases to a high speed and stops. After some time, it starts again). Please help me if anyone knows about this problem.

    This topic has been closed for replies.

    1 reply

    Technical Moderator
    March 21, 2024

    Hello,

    You need to provide more details about your HW/Schematics it could be a conflicting HW ressources. If you're using CubeMx share your .ioc file.

    Visitor II
    March 22, 2024

    @mƎALLEm i have attached the ioc file of the project so please check

    Technical Moderator
    March 22, 2024

    You need to check your HW before going to check the Software.