AnsweredAssumed Answered

SS1 bean code is not able to be used

Question asked by kent ji on Jan 25, 2007
Latest reply on Jan 29, 2007 by kent ji
Hello, I am using a 9S12E64 MCU as SPI Slave and another MCU (non-Freescale) as Master. The Master treat 9S12E MCU as an EEPROM (ST95040). I used SS bean with CW4.6 to generate SPI code (SS1 Module). There was any data to be received and sent. Attached is my code.
Questions:
  1. SPICR1 was initialized as EC in main() when running step by step, SPICR1 = EC, SPISR = 20 (change to 00 late), and SPIDR = 00. when running fully SPICR1 = 04, SPISR = 20, and SPIDR = 00.
  2. Are enable Interrupt (SPICR1=140) and disable Interrupt (SPICR1=12) needed in the Main() code?
  3. Function SS1_SendChar(SS1_TComData Chr) be called at Main() but nothing happend with SPIDR.
  4. Function SS1_RecvChar(SS1_TComData *Chr) be called at Main() but nothing happend with SPIDR.

Thanks for hlep.

 
 
Message Edited by t.dowe on 2009-10-22 09:55 AM

Outcomes