how can use more than 1 integrator in simulink for arduino support package?

Hi, i have some problem with arduino support package. i designed my model in simulink as an state-space model and connect analog read block for reading data.but when we run it simulink cannt generat all code. finaly i understand this package cannt generat more than one itegrator block. so how can i solve this problem?

Answers (1)

Can you post the actual error message, type of Arduino and the version of MATLAB you are using? That will help a lot of the experts to narrow down the issue. I say this because, I have used more than one integrator block on my Arduino Simulink models just fine.

10 Comments

of curse , i took a picture from my simulink and attach hear.1.jpg
Thanks for sharing the error message, can you share what type of Arduino board you are using?
Also, if you double click the Data Type conversion block, what is the Output data type?
yeh. my Arduino board is Mega2560. also i tested this model with Uno too
when I set the Output data type to 'Inherit: Inherit via back propagation' I dont get any errors on my MKR1000 board. Can you try this?
If this fails, then try starting with a simple model with no integrators and no data type conversions and add blocks till you run into the error message again and post the error message along with the model.
i did these many time. that model i attach there was a simple model. the main model is more complex. i just when insert second integraro see this error.
Can you please share your simple model here, so that others can try and reproduce the error on their end?
I am not able to reproduce this error on R2018b, it might be a version related issue. Can you reach out to MathWorks Technical Support to see what is going on? They might be able to assist you better. Sorry for not being able to help further
I do not have that version installed, hence the request to reach out to TS.

Sign in to comment.

Categories

Asked:

on 15 Nov 2018

Community Treasure Hunt

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

Start Hunting!