Re: SPI problem
David VanHorn <[email protected]> Tue, 13 Jan 2004 16:52:43 -0500
| Newsgroups | gmane.comp.hardware.avr.general |
|---|---|
| Message-ID | <[email protected]> |
> >Does setting PORTB to 0x24 help? I see this in the datasheet: Not by itself. > PB2 -> SS* > PB3 -> MOSI > PB4 -> MISO > PB5 -> SCK > >Also, you might want to set PB2 high. Tried PORTB=0x26, also no go. >Might also consider clearing DDRB4 in DDRB since it's an input. DDRB is 0xEF, that's 11101111b which has that pin cleared (input) Right? >I assume you tried simple SPI output in a real device already and it works. Not recently, I don't have real hardware for this one yet. >I've had best results if I make sure that the SPI bits of DDRB >and PORTB are the same. Tried it, no go. I'm using the studio 4.08 sim, AFAIK it's the latest update.