I can't compiled code

MinhPham
MinhPham Altair Community Member
edited October 2020 in Community Q&A

Hello,

I just got into Altair Embed and I have encountered a problem. I can't compiled code. I will post more pictures below with my config and model. Even a little hint would be appreciated!
Thanks in advance for everything!

<?xml version="1.0" encoding="UTF-8"?>altair_error1.png

<?xml version="1.0" encoding="UTF-8"?>altair_error2.png

Answers

  • Sreeram Mohan_20248
    Sreeram Mohan_20248 New Altair Community Member
    edited July 2020

    Hi , 

     

    Could you please attach the vsm file so that we can investigate further ? Does the code generation fail for all diagrams of only this diagram ?

     

    --sreeram

  • MinhPham
    MinhPham Altair Community Member
    edited July 2020

    Hi Sreeram,
    I cannot compile the code for this diagram but other diagrams can still compile. Below is my vsm file.

    Unable to find an attachment - read this blog

  • Girish Karamadi_22191
    Girish Karamadi_22191 New Altair Community Member
    edited July 2020

    Hi ,

    Codegen is not supported for integrator block when used with Arduino .The attached diagram uses a integrator block so it fails to compile.

     

    <?xml version="1.0" encoding="UTF-8"?>image.thumb.png.3eeed8c7268ad96acbeeff9bf3253f83.png  

     

    Regards,

    Girish

  • MinhPham
    MinhPham Altair Community Member
    edited July 2020

    Hi Girish,

    Do you know any blocks similar to the integrated blocks can be used for arduino?

  • Sreeram Mohan_20248
    Sreeram Mohan_20248 New Altair Community Member
    edited July 2020

    Hi Minh Pham, 

     

    You could try using a fixed point integrator as attached. This would codegen .  Not sure if it helps.

     

    --Sreeram Mohan 

    Unable to find an attachment - read this blog

  • Ric_22025
    Ric_22025
    Altair Employee
    edited July 2020

    Hi Minh Pham,

    I'm attaching a more efficient model that uses a digital integrator in place of your continuous ones that should work fine on the Arduino.

    Ric

    Unable to find an attachment - read this blog