Hi Ankita,
I understand you are using the prebuilt bidirectional DC-DC converter block and are facing issues when transitioning to boost mode i.e., when the reference voltage is higher than the input (battery) voltage.
In the implementation of the Bidirectional DC-DC Converter block (especially in examples under Simscape > Electrical > Specialized Power Systems), the key point is that this converter requires explicit control logic for both buck and boost modes. Unlike unidirectional converters, it doesn’t automatically transition between modes unless directed by control signals.
You can read more about modelling DC-DC converter logic in Simulink, using the following documentation link:
The observed behavior typically indicates that the converter is not actively switching into boost mode when the output reference exceeds the input voltage. Based on problem description and Simulink model structure, here are a few aspects you can consider while designing the switching logic:
1. Separate Duty Cycle Expressions for Buck and Boost:
These two modes follow different principles as shown below:
- Buck Mode: Duty cycle 'D_buck ≈ Vout / Vin'
- Boost Mode: Duty cycle 'D_boost ≈ 1 - Vin / Vout'
It's essential that these expressions are conditionally computed based on the desired reference vs. input voltage. A Switch block in Simulink can be used to select between the two based on the comparison 'Vref > Vin'.
2. Mode Detection Logic: Implement logic to detect the operating mode (buck vs. boost) using 'Compare To Constant' blocks. You may add hysteresis using 'Relay' blocks or custom logic to prevent rapid toggling when 'Vref' is close to 'Vin'.
3. Switch Signal Routing:
The converter topology typically uses the following modes:
- Buck Mode: High-side switch (S1) is PWM controlled, and low-side (S2) is used for freewheeling.
- Boost Mode: Low-side switch (S2) is PWM controlled, while S1 stays ON during conduction.
If both switches are controlled with the same PWM or no gating logic differentiates the operation, the converter won’t transition to boost correctly. You can use 'conditional control' or 'Enabled' subsystem blocks to generate mode-specific PWM signals.
You can read more about the functioning and various examples on modelling Buck-Boost Converters in Simulink, using the following documentation links:
While using the Simscape Electrical Specialized Power Systems library, it can be observed that prebuilt converter blocks may not inherently support full boost behavior without user-defined control logic. You can consider examining the gate signal generation closely and ensure the correct switch is modulated in each mode.
If the current PI controller is directly used to derive the PWM signal without switching between buck and boost logic, it would not generate the correct duty cycle for boost, resulting in output voltage clamping at the battery level, which is consistent with your observations.
Hope this helps!