GithubHelp home page GithubHelp logo

Comments (7)

HamedJafarzadeh avatar HamedJafarzadeh commented on July 22, 2024 1

Thanks @trojanobelix . I can confirm that this commit fixes the problem. Although user should note that a variable without default value might have any random values if they use them before assigning a value first.

from canopeneditor.

trojanobelix avatar trojanobelix commented on July 22, 2024

Can not reproduce. Can you provide the xdd and the object index that is missing.

from canopeneditor.

HamedJafarzadeh avatar HamedJafarzadeh commented on July 22, 2024

Here is a sample. Object x2000 does not add subobject 0x02 to the generated files.
MissingValuesXdd.zip

from canopeneditor.

trojanobelix avatar trojanobelix commented on July 22, 2024

Do you expect more than this (from your file)?

.x2000_testrecord = {
        .highestSub_indexSupported = 0x02, <===========
        .testsubwithvalue = 0x00000000
    }

   OD_obj_record_t o_2000_testrecord[3]; <================== SUM(Subs 0,1,2) =3

  .o_2000_testrecord = {
        {
            .dataOrig = &OD_RAM.x2000_testrecord.highestSub_indexSupported,
            .subIndex = 0,
            .attribute = ODA_SDO_R,
            .dataLength = 1
        },
        {
            .dataOrig = &OD_RAM.x2000_testrecord.testsubwithvalue,
            .subIndex = 1,
            .attribute = ODA_SDO_RW | ODA_MB,
            .dataLength = 4
        },
        {
            .dataOrig = NULL,
            .subIndex = 2, <===================
            .attribute = ODA_SDO_RW | ODA_MB,
            .dataLength = 4
        }
    }

from canopeneditor.

HamedJafarzadeh avatar HamedJafarzadeh commented on July 22, 2024

Thanks for your response.

According these sub objects, should we see .testsubwithoutvalue somewhere ? and be able to access it like OD_RAM.testrecord.testsubwithoutvalue ?
image

from canopeneditor.

trojanobelix avatar trojanobelix commented on July 22, 2024

Try bugfix branch c121291

from canopeneditor.

CANopenNode avatar CANopenNode commented on July 22, 2024

Sorry, I missed that issue.
CANopenNode V4 actually does not require data storage for a variable. Instead application may define own callbacks for reading or writing OD entry.
See also #73 (comment)

from canopeneditor.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.