Code Monkey home page Code Monkey logo

Comments (14)

interactive-matter avatar interactive-matter commented on August 28, 2024

correction: the compiler DOES not like it:

Creating app_ledtile.xe
.././../../sc_ethernet/module_ethernet/src/server/getmac.xc: Error: Type of symbol ethernet_getmac_otp_indexed has mismatch with previous definition:
.././../../sc_ethernet/module_ethernet/src/server/getmac.xc: Error: found: void ethernet_getmac_otp_indexed( port, out port, port, unsigned char[], unsigned int )
.././src/ethernet/localServer/retrieveMAC/get_mac_addr.xc: Error: previous: void ethernet_getmac_otp_indexed( port, out port, port, signed int[], unsigned int )

from sc_ethernet.

DavidNorman avatar DavidNorman commented on August 28, 2024

The address is compared inside the code using a word aligned compare, so it passes data back word aligned. that is the reason for the int[] rather than the char[]. I think that the char[] in the XC file is a mistake.

from sc_ethernet.

interactive-matter avatar interactive-matter commented on August 28, 2024

will fork, repair & pull request ;)
see comment abt. compiler error

from sc_ethernet.

DavidNorman avatar DavidNorman commented on August 28, 2024

thanks.

from sc_ethernet.

ajwlucas avatar ajwlucas commented on August 28, 2024

Whoops. See Dave's reply - it sounds like the correct type is array of ints.

from sc_ethernet.

DavidNorman avatar DavidNorman commented on August 28, 2024

its possible that the API does a byte copy from the word aligned entry to the char aligned one.

this OTP get mac thing was originally going to support layer-3 type routers where there are multiple MAC addresses for a single board. since we have abandoned that for the time being, there is only a need for a single MAC address for any board including ones with multiple ports. hence this indexed and count getmac stuff isn't really that important.

from sc_ethernet.

interactive-matter avatar interactive-matter commented on August 28, 2024

whoopsala, over my head ;)

perhaps you have seen the changes in my pull request - they seem to solve the issues from the compiler point of view (which is neccessarily the first step to fix it from a functional point of view). I will test it presumably next week (still in the middle of sc_ethernet migration for ap_led_tile).

Are there any automated test which could be used to verify the fix?

from sc_ethernet.

DavidNorman avatar DavidNorman commented on August 28, 2024

I'm not sure that there is, to test the multiple MAC address part. But the getting a single MAC address just gets entry zero, so if any code at all successfully returns a MAC address without causing an alignment exception, then you can be happy that all is ok.

from sc_ethernet.

interactive-matter avatar interactive-matter commented on August 28, 2024

Will close this issue after successfully testing it next week (lil' bit too short on time)

from sc_ethernet.

ajwlucas avatar ajwlucas commented on August 28, 2024

Hi Marcus,

I've had to revert to before your commit. It causes our AVB reference design to error on compile and I haven't time to implement the necessary fixes in all the AVB apps at the moment. Can you implement a fix in your LED repo in the meantime?

from sc_ethernet.

interactive-matter avatar interactive-matter commented on August 28, 2024

Hi Andy,

No problem. I will keep it in my fork. And try to keep my fork as updated as possible. I will reopen the issue so that we have a reminder. Is that OK?
Then we can see later how can get it into the upstream. I think it should be there.

Marcus

This mail may contain unwanted typos

Am 14.10.2011 um 19:20 schrieb Andy Lucas [email protected]:

Hi Marcus,

I've had to revert to before your commit. It causes our AVB reference design to error on compile and I haven't time to implement the necessary fixes in all the AVB apps at the moment. Can you implement a fix in your LED repo in the meantime?

Reply to this email directly or view it on GitHub:
#10 (comment)

from sc_ethernet.

ajwlucas avatar ajwlucas commented on August 28, 2024

Yes, great. Will revisit this in the near future.

from sc_ethernet.

interactive-matter avatar interactive-matter commented on August 28, 2024

is there any progress in applying the changes to the AVB framework?
Still want to get rid of my sc_ethernet fork ;)

from sc_ethernet.

ajwlucas avatar ajwlucas commented on August 28, 2024

Closing. Now using sc_otp for reading MAC addresses.

from sc_ethernet.

Related Issues (18)

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.