Giter VIP home page Giter VIP logo

Comments (5)

maruel avatar maruel commented on May 28, 2024

Sadly the SPI driver will never give you an exact match of the clock frequency requested, always something slower based on the current clock. I haven't found a way to fix this.

I recommend iterating over the specified frequency going up until you get in practice one that you like.

from periph.

lclslsls avatar lclslsls commented on May 28, 2024

Sadly the SPI driver will never give you an exact match of the clock frequency requested, always something slower based on the current clock. I haven't found a way to fix this.

I recommend iterating over the specified frequency going up until you get in practice one that you like.

the clock frequency is ok,
my quez is that when one frame is over the ce cost too much time to transfer the next frame
just like the picture show

from periph.

maruel avatar maruel commented on May 28, 2024

Ah I think I understand now, you mean that the delay between requests is too large? AFAIK all of this time is spent in the kernel. Tx() leads to exactly a single system call:

return s.f.Ioctl(spiIOCTx(len(m)), uintptr(unsafe.Pointer(&m[0])))

from periph.

lclslsls avatar lclslsls commented on May 28, 2024

Ah I think I understand now, you mean that the delay between requests is too large? AFAIK all of this time is spent in the kernel. Tx() leads to exactly a single system call:

return s.f.Ioctl(spiIOCTx(len(m)), uintptr(unsafe.Pointer(&m[0])))

you are right ,i write a c demo
it has same quiz
thank you very much
by the way is there some way to make ioct more faster??

from periph.

maruel avatar maruel commented on May 28, 2024

Not as far as I know. I suspect it's highly driver specific. One thing I never tried is to use NoCS, and manage it yourself. Maybe you'd save a bit on the timeouts.

from periph.

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.