@Asmyldof probably the same ones that always wondered what would happen if they try to flush 100kg of mercury down a toilet, and then decided to try and see
I'm still a bit new to this domain, just wondering if the rise time of a probe and the oscilloscope itself have to be substracted to the measure in order to recover the real measured rise time?
Let's suppose a case:
My signal have a real rise time of 0.7ns.
The probe is announced to have a rise...
@Asmyldof Got me. I need to receive some commands on SPI (as slave), and then fiddle around with some peripherals (SPI, I2C, on-chip ADC, mainly), and provide data back thru SPI.
@Asmyldof For example, if the master wants to know what's the voltage on a certain external ADC, I might have to do 3-4 transactions on a local SPI bus to get that value.
I'm not sure how you'd do this pure interrupt driven. For example, I might be waiting for an interrupt to tell me a local SPI transaction has finished, when a new byte arrives on the slave SPI interface. (or you might be shuffling data around from the local SPI when the new data arrives) It seems like it would be pretty hairy to coordinate those things, you'd need multiple interrupt levels, ...
If you want to guarantee a request-response speed it's smart to keep the highest IRQ priority (lowest number) free for systick, which can often be set to any number of CPU cycles, to check for execution problems
1. Home Folder abuse (I don't do quota) is punished by permanent removal of useraccount 2. Attempts at circumventing barriers result in the same 3. If you feel you could write somewhere you shouldn't, please let me know
@Asmyldof, setting up a SERCOM for SPI in ASF, the config structure has 4 parameters, pinmux_pad0, pinmux_pad1, etc. The type is uint32_t. Any idea what is supposed to go into those fields? (I'm guessing it should be something like GPIO<n> but I don't see anything in the docs to confirm it)
@Asmyldof I found demo code that uses EXT1_SPI_SERCOM_PINMUX_PAD3 but I haven't poked through the 3 levels of #define indirection to find out what it means.
What I'm confused by is, for example, the pads I want to use can be connected to eithe SERCOM0 or SERCOM4, but I don't see where I say which one I want to use.
ASF, as I keep saying, is far from complete and does need maintenance, so it's not impossible some options are not available
But, be happy this is the state you get to work with. At 5000eur cost you could also get to play with ARM/KEIL and a CMSIS that implements only happy-flow even in the lowest levels
@Asmyldof After I get 10 different web pages open with documentation on a function, and on its arguments, and on the struct types of each argument, and the functions to configure the structs for the arguments, ... my brain starts to hurt a little bit.
Well, I set up a cute little project with a reasonably clean structure to develop the examples in
But no actual code yet :/
To note: this is an example set-up
For a complicated project I would set up using full specifications and use layered abstraction for maintenance and team-work purposes, like I set up at EFFECT
@ThePhoton Than he didn't love layers and abstraction, he just loved to hear himself talk
A good layered abstraction model is easy to comprehend by working downwards, where the lower layer, or at worst lower two require knowledge of chip and hadware
When you do it right, you're making a sort of purpose built operating system, where the most maintenance and change after you're done proving full determinism is in the upper layers just calling "GetValue(Temperature)"
@ThePhoton ASF is nor has ever been a good example of well built layered software
@Asmyldof Sure, I've been doing that kind of thing for 20 years. The problem is the abstractions that are easy for me to understand are not necessarily the same ones that are easy for the next guy.