Arduino ran out of memory with basic Simulink Simulation in external Mode

1 vue (au cours des 30 derniers jours)
Julian Schenker
Julian Schenker le 31 Mai 2023
Hey, when I run the Simulink Model for a Distance Sensor ToF (VL53L1X on the I2C) in external Mode the Arduino ran out of Memory. The Programm is only that it save the distance to workspace. With another basic Distance Sensor it works fine.
Thanks

Réponses (1)

Hornett
Hornett le 2 Sep 2024
When using the VL53L1X ToF sensor with Simulink in external mode, running out of memory on an Arduino can occur due to the complexity of the sensor and library. Here are quick tips to address this:
1. Optimize Simulink Model:
- Increase sample time.
- Log only essential data.
- Simplify the model by removing unnecessary blocks.
2. Code Optimization:
- Use smaller data types.
- Look for lightweight VL53L1X libraries.
3. Upgrade Hardware:
- Consider using an Arduino with more memory, like the Mega.
4. Adjust External Mode Settings:
- Optimize buffer sizes and communication settings.
These steps should help manage memory usage effectively.

Catégories

En savoir plus sur Arduino Hardware dans Help Center et File Exchange

Produits


Version

R2023a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by