Timeline for ATMEGA328 SPI MCP2515 - SPI communication freezes at certain point
Current License: CC BY-SA 3.0
16 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Feb 27, 2023 at 11:03 | comment | added | KIIV | @hegel5000 Right, at least Atmega4809 has this mentioned in Errata document - even if you configure it, it won't disable it | |
Jan 23, 2023 at 14:21 | comment | added | hegel5000 |
@KIIV well, not general I/O. If you leave the SS pin as input, even with SPIO.CTRLB = SPI_SSD_bm , SPI can still hang! But it seems to work fine as output; no need to pull high. (Or I'm getting (un)lucky. Whether it hangs due to SS is somewhat random.)
|
|
Jan 20, 2023 at 22:57 | comment | added | KIIV | @hegel5000 However in the ATtiny1617 you can disable this functionality and use SS pin as IO: "If SSD in SPIn.CTRLB is ‘1’, the SPI does not use the SS pin, and it can be used as a regular I/O pin, or by other peripheral modules.". This is not possible in the older AVRs | |
Jan 20, 2023 at 15:53 | comment | added | hegel5000 | Turns out this applies for other Atmel products, including the ATiny1627, too. Very useful answer! | |
Jul 26, 2016 at 12:35 | history | edited | KIIV | CC BY-SA 3.0 |
added 111 characters in body
|
Jul 26, 2016 at 12:20 | comment | added | Peter Mortensen | So what is the conclusion? What should be done? Can you make it clear (by editing your answer)? | |
Jul 13, 2016 at 23:32 | vote | accept | KarlKarlsom | ||
Jul 13, 2016 at 23:31 | history | bounty awarded | KarlKarlsom | ||
Jul 13, 2016 at 14:33 | vote | accept | KarlKarlsom | ||
Jul 13, 2016 at 23:32 | |||||
Jul 13, 2016 at 14:33 | comment | added | KarlKarlsom | Just tested it and it works! Thank you very much for helping me out! Finding this cost me days :) | |
Jul 13, 2016 at 14:02 | comment | added | KIIV | Yes, you can switch these signals. But if you dont use D10, it must be set eiter as output (and used for another signal) or input pullup (and left unconnected). However i'd recommend to use PD2 (INT0) or PD3 (INT1). | |
Jul 13, 2016 at 13:39 | comment | added | KarlKarlsom | I think you are on the right track. Dont know, why I missed that in the datasheet... Let me quickly cut the track of PB2 and connect a botch wire to PB0 to test it. Btw. if I understand it correct, actually I would only need to change CAN_CS (which is an output) with CAN_INT (which is an input) in my final layout and everything should be ok, right? | |
Jul 13, 2016 at 9:08 | history | edited | KIIV | CC BY-SA 3.0 |
More detailed explanation based on comment
|
Jul 13, 2016 at 8:36 | comment | added | RSM | Could you possibly clarify this answer more, it is really vague and short. Also the connections of the OP's circuit is basically the same as the schematic from Sparkfuns shield | |
Jul 12, 2016 at 19:55 | review | First posts | |||
Jul 12, 2016 at 20:45 | |||||
Jul 12, 2016 at 19:52 | history | answered | KIIV | CC BY-SA 3.0 |