dsPIC33EP512MU810 datasheet note states, "The SMP bit must be set only after setting the MSTEN bit. The SMP bit remains cleared if MSTEN =0" http://ww1.microchip.com/downloads/en/D ... 70616g.pdf (p.341)
PIC16BIT_CAL_SPI.c assigns the value of SMP prior to setting MSTEN. Hence, it appears that Input data is always sampled at the middle of data output time, even if "END" is selected in the SPI component properties.
Possible PIC16 SPI issue
Moderator: Benj
- LeighM
- Matrix Staff
- Posts: 2178
- Joined: Tue Jan 17, 2012 10:07 am
- Has thanked: 481 times
- Been thanked: 699 times
- Contact:
Re: Possible PIC16 SPI issue
Thanks for the spot.
I've updated the CAL file (and attached)
I've updated the CAL file (and attached)
- Attachments
-
- PIC16BIT_CAL_SPI.c
- (15.43 KiB) Downloaded 223 times