This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

SPI interface b/w ST10F269 and MCP2515

hi,
has anyone interfaced MCP2515 with ST10F269. i am facing issues with establishing the connection b/w the two. the CAN routines are fine (i suppose), but the SPI interface between the two seems to be the issue. Can anyone please post his/her code if any. This would be of very much great help...
Thanks a lot in advance.

Rgds

Parents
  • let me tell you that this product is to be installed in an aircraft which plays with 3 CAN interface also a hell lot of ARINC messages.this 3 CAN (via MCP2515) just forms only the 3% of the whole system.
    Well, without this information I cannot draw a right conclusion for sure.
    In fact I had a 8-channel CAN Distributor project which include a LM3S5xxx (one CAN included) and 8 MCP2515.
    So I sincerely hope in future, when you ask someone to help, you should be frank and provide sufficient information, because nobody else could be familar to your real need than YOUSELF.

    Now let's back to the topic, I've read the ST10F269's user manual and learn the memory organization of it.
    According to your code snippet:

    void WriteSingleSSCByte(WORD address,BYTE data)
    ...
    pPage = (unsigned char*)0x0F007C;
    pExCANMem = (unsigned char*)0x0F0000;
    ...
    do
    ; while(P3_7 ==0)
    ; *pPage = page;
    do
    ; while(P3_7 ==0); *(pExCANMem+lowaddress)=data;
    


    The accessed addresses are 0F'00xx, which means they all lie in Segment 15 of external addressing space.
    So it's not using the on-chip SSC but some external memory-mapped interface.
    Also I have checked 82C900's datasheet and it stated:

    Paging Mode Register:  xx7Ch
    

    In conclusion, the code snippet you provided can ALMOST prove that the former design used EBI to access 82C900, not SSC.
    So I think both hardware and software would be modified to replace 82C900 with MCP2515.

    Of course all these are just my deduction. I think you should talk with your manager to determine how to proceed this project. You should require more information from your team.

Reply
  • let me tell you that this product is to be installed in an aircraft which plays with 3 CAN interface also a hell lot of ARINC messages.this 3 CAN (via MCP2515) just forms only the 3% of the whole system.
    Well, without this information I cannot draw a right conclusion for sure.
    In fact I had a 8-channel CAN Distributor project which include a LM3S5xxx (one CAN included) and 8 MCP2515.
    So I sincerely hope in future, when you ask someone to help, you should be frank and provide sufficient information, because nobody else could be familar to your real need than YOUSELF.

    Now let's back to the topic, I've read the ST10F269's user manual and learn the memory organization of it.
    According to your code snippet:

    void WriteSingleSSCByte(WORD address,BYTE data)
    ...
    pPage = (unsigned char*)0x0F007C;
    pExCANMem = (unsigned char*)0x0F0000;
    ...
    do
    ; while(P3_7 ==0)
    ; *pPage = page;
    do
    ; while(P3_7 ==0); *(pExCANMem+lowaddress)=data;
    


    The accessed addresses are 0F'00xx, which means they all lie in Segment 15 of external addressing space.
    So it's not using the on-chip SSC but some external memory-mapped interface.
    Also I have checked 82C900's datasheet and it stated:

    Paging Mode Register:  xx7Ch
    

    In conclusion, the code snippet you provided can ALMOST prove that the former design used EBI to access 82C900, not SSC.
    So I think both hardware and software would be modified to replace 82C900 with MCP2515.

    Of course all these are just my deduction. I think you should talk with your manager to determine how to proceed this project. You should require more information from your team.

Children
No data