I saw a similar post or someone was talking about it. He actually set it up via Simplefoc Studio. I would start with that the day I got the card.
In fact I thought that the PID would make the wheel behave differently depending on the mode chosen. That the PID settings were not exactly the same for the two modes. Since the two modes do not do the same. But I think it’s obviously no use.
I wanted to know if you knew what the BLDCDriver3PWM and BLDCDriver6PWM driver part is for. As the name suggests, is it to run the engine with PWMs? But does this only apply to sensorless motors ? Just curious about that.
I can somewhat answer the part about 3 pwm and 6 pwm, there are different driver ic’s or dedicated drivers for bldc motors.
Some accept a pwm signal for U V W (positive side) from the MCU, but then the mosfet driver or motor driver ic just generates the negative side signal for the actual switching mosfets on its own (negative side is basically the inverse of the positive side signal).
For 6 Pwm the MCU generates a dedicated pwm signal for positive U V W and for Negative U V W, this gives you more controll over what the driver ic does
Hi @JorgeMaker ! Sorry for the absence and for not responding earlier.
I ordered the Board Infineon bldc shield ifx007t :
I am trying to run my motor without the hall sensor at the moment. I am using the Open_loop_velocity_example library. I modified it slightly to match the PIN assignment.
So I modified the code from BLDCDriver3PWM(9, 5, 6, 8); to BLDCDriver3PWM(11, 9, 10, 6);. And now we have this in general :
// Open loop motor control example
#include <SimpleFOC.h>
// BLDC motor & driver instance
// BLDCMotor motor = BLDCMotor(pole pair number);
BLDCMotor motor = BLDCMotor(11);
// BLDCDriver3PWM driver = BLDCDriver3PWM(pwmA, pwmB, pwmC, Enable(optional));
BLDCDriver3PWM driver = BLDCDriver3PWM(11, 9, 10, 6);
// Stepper motor & driver instance
//StepperMotor motor = StepperMotor(50);
//StepperDriver4PWM driver = StepperDriver4PWM(9, 5, 10, 6, 8);
//target variable
float target_velocity = 15;
// instantiate the commander
Commander command = Commander(Serial);
void doTarget(char* cmd) { command.scalar(&target_velocity, cmd); }
void setup() {
// driver config
// power supply voltage [V]
driver.voltage_power_supply = 24;
driver.init();
// link the motor and the driver
motor.linkDriver(&driver);
// limiting motor movements
motor.voltage_limit = 12; // [V]
motor.velocity_limit = 50; // [rad/s] cca 50rpm
// open loop control config
motor.controller = MotionControlType::velocity_openloop;
// init motor hardware
motor.init();
// add target command T
command.add('T', doTarget, "target velocity");
Serial.begin(115200);
Serial.println("Motor ready!");
Serial.println("Set target velocity [rad/s]");
_delay(1000);
}
void loop() {
// open loop velocity movement
// using motor.voltage_limit and motor.velocity_limit
motor.move(target_velocity);
// user communication
command.run();
}
For the moment I am testing without the hall sensors because it is necessary to order special resistors on this board. I’ve ordered the PowerShield board on JLCPCB and the Mosfets BTN8962 on Aliexpress. I am waiting for this card to test the hall sensor .
Ok, but I don’t understand which one should I put ? I’ve tried without anything but It doesn’t work too.
Maybe this is not the correct number : BLDCMotor motor = BLDCMotor(11); because I don’t know the specs of my motor.
But I have no movement, not even shaking.
I thought it would be easier without sensors but it’s visiblment more complex … I look forward to receive my PowerShield cards to test with the hall sensors.
Yes I did it but didn’t work either. I’ve tried all the combinaisons. I’m waiting for the PowerShield board. I tried with another motor (only 2 poles) and it worked. I think I have to use the hall sensors of mine …
I will keep you informed in the coming days.
Seems like I’m a masochistic pyromaniac cause my BTN just arived from Aliexpress (I don’t know if it work for the moment ).
Interesting, I am very curious how it works, since all official Infineon driver distributors are completely out of stock until end of 2022. I was told under very good authority that the aliexpress chips are partial rejects where they take the bad batches and instead of crushing them for recycle they run them through the packaging machines after hours and sell them on aliexpress. The chips definitely work but most of the time the sputtering or doping or silicon temperature regime was partially wrong, which means the timing and current profiles are off. So they will work but you may experience overheating and lower current profiles, and occasionally the chip will pop.
What you are saying seems logical to me. I will tell you how the fleas behave. The packaging looks fine.
This is something I was dreading, I ordered more for this reason. It’s about doing tests. I don’t need anything very specific. Only something that does the job.
You got me so curious I also ordered from two vendors. I want to use them for testing. They sell them for like a dollar a chip, that’s really suspicious, because the cheapest I could find from official distributors was around $5 retail.
The infineons board is very very similar to the powershield, or better said powershield is very similar to the infineons board;
It will definietely work with the simplefoc
Just make sure to provide the enable pins to the BLDCDriver3PWM constructor (btw you’mm have to do this for both of the boards)