• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Low Power RF & Wireless Connectivity » SimpleLink™ Wi-Fi® » Porting the CC3000 Host Driver to MSP430f5438a
Share
Low Power RF & Wireless Connectivity
  • Forums
  • Announcements
  • Files
  • E2E Wiki
Options
  • Subscribe via RSS

Porting the CC3000 Host Driver to MSP430f5438a

Porting the CC3000 Host Driver to MSP430f5438a

This question is answered
Nathan Abercrombie
Posted by Nathan Abercrombie
on Apr 17 2012 18:05 PM
Prodigy220 points

As the title suggests, I am trying to port the libraries over.  I already have the libraries working on the 5739, but I need more memory for my application, and the 5438 has much more.  When trying to port over the SPI code, I noticed that it uses P2IE and P2IFG.  I was going to use the SPI port on port 9 of 5438, but when I changed P2IE to P9IE, the compiler told me that those do not exist.  Sure enough, only P1IE and P2IE are defined in <msp430f5438a.h>.  And unfortunately, there is no SPI port on port 1 or 2 of the 5438.  

What should I do?  Should I just move the interrupt pin to port 2, and leave the rest of the SPI on port 9?  

Are there any better porting guides than this one?

http://processors.wiki.ti.com/index.php/CC3000_Host_Driver_Porting_Guide

Thank you

Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • GustavoL
    Posted by GustavoL
    on Apr 17 2012 20:03 PM
    Intellectual590 points

    Nathan,

    I am not sure which pin you're referring to, but IRQ pin must be placed in an interrupt capable port of the MSP430 which is usually only PORT 1 and 2.
    It doesn't matter which GPIO it is, just that it triggers it correctly. Therefore, you can carry the settings over from the Port 2 settings used for IRQ.

    There is no need to have the SPI physically on the same port as the IRQ and WLAN_EN.

    Regards,
    Gustavo

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Miguel
    Posted by Miguel
    on Apr 17 2012 22:54 PM
    Verified Answer
    Verified by Nathan Abercrombie
    Genius11495 points

    Nathan,

    Have you had a chance to look into the Basic WiFi App for the MSP430F5438?

    http://processors.wiki.ti.com/index.php/CC3000_Wi-Fi_MSP-EXP430F5438#Supported_Applications   

    Regards,

    Miguel

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Nathan Abercrombie
    Posted by Nathan Abercrombie
    on Apr 18 2012 13:07 PM
    Prodigy220 points

    Miguel,

    Thank you! This will hopefully save me a lot of time.

    Nathan

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hsiung Chia-Wei
    Posted by Hsiung Chia-Wei
    on Oct 01 2012 05:17 AM
    Prodigy210 points

    Excuse me.

    Do you find solution to solve MSP430F5438 to link CC3000.
    I use http://processors.wiki.ti.com/index.php/ CC3000 _Wi Fi_ MSP # -EXP430F5438。

    but it can not work

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • //--Kelvin--\\
    Posted by //--Kelvin--\\
    on Oct 01 2012 09:26 AM
    Intellectual1305 points

    Hello Hsiung Chai-Wei,

    The following link should work for you: http://processors.wiki.ti.com/index.php/CC3000_Wi-Fi_MSP-EXP430F5438#Supported_Applications

    If that doesn't work, you can download the Basic Wi-Fi app for the 5438 directly from here: http://www.ti.com/lit/sw/swrc241/swrc241.zip

    Regards,

    Kelvin

    Please click the Verify Answer button on this post if it answers your question.  Thank You.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hsiung Chia-Wei
    Posted by Hsiung Chia-Wei
    on Oct 01 2012 21:07 PM
    Prodigy210 points

    Dear Kelvin,

    I have been use http://www.ti.com/lit/sw/swrc241/swrc241.zip for a long time.

    I use IAR "NEXT STATAEMENT and breakpoint" ,  but it shut down at  wlan_start(0).  P1.7 WLANENABLE is already high.

    My MSP430F5438 is not MSP-EXPF5438, but I already set pin P1.3 for IRQ
                                                                                                                    P1.7 for WLANENABLE

                                                                                                                    P5.6 for UART_PIN_TXD   
                                                                                                                    P5.7 for UART_PIN_RXD

                                                                                                                    P9.4 for RF_SPI_SIMO    

                                                                                                                    P9.5 for RF_SPI_SOMI

                                                                                                                    P9.0 for RF_SPI_CLK

                                                                                                                    P9.3 for RF_SPI_CS 

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hsiung Chia-Wei
    Posted by Hsiung Chia-Wei
    on Oct 02 2012 02:08 AM
    Prodigy210 points

    It is SHUT DOWN at  SimpleLink_Init_Start in wlan_start(0) .

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hsiung Chia-Wei
    Posted by Hsiung Chia-Wei
    on Oct 02 2012 05:09 AM
    Prodigy210 points

    Dear Kelvin,

    The same problem for me.  http://e2e.ti.com/support/low_power_rf/f/851/t/201415.aspx

    wlan_start(0) function call is blocking on 

    SimpleLinkWaitEvent(HCI_CMND_SIMPLE_LINK_START, 0);

    (within SimpleLink_Init_Start)

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • //--Kelvin--\\
    Posted by //--Kelvin--\\
    on Oct 02 2012 10:15 AM
    Intellectual1305 points

    Hello Hsiung Chai-Wei,

    So are you testing this on a custom board?  If so, it may be easier for you to evaluate this solution with the experimenter board, which can be found here: https://estore.ti.com/MSP-EXP430F5438-MSP430F5438-Experimenter-Board-P1508.aspx  It sounds like something is going on with your SPI line.  Have you looked at the SOMI line to see if the CC3000 responds with anything on this line?

    Regards,

    Kelvin

    Please click the Verify Answer button on this post if it answers your question.  Thank You.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Pedro5084
    Posted by Pedro5084
    on Oct 02 2012 10:16 AM
    Intellectual2390 points

    Hi, 

    Did you see if the wlan interrupt was triggered. And how about the state of the SPI?

    Pedro 

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hsiung Chia-Wei
    Posted by Hsiung Chia-Wei
    on Oct 02 2012 22:37 PM
    Prodigy210 points

    DEAR Pedro5084,

    Wlan interrupt was triggered means WLAN IRQ high???

    And then,I should test SPI PIN.

    I will test it.

    THANKS


    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hsiung Chia-Wei
    Posted by Hsiung Chia-Wei
    on Oct 02 2012 22:41 PM
    Prodigy210 points

    Dear Kelvin,

    I use customer borad.

    I will test SPI PIN.


    how should SPI pin status be?(HIGH or LOW)
    MISO    

    MOSI

    CLK
    STE

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • //--Kelvin--\\
    Posted by //--Kelvin--\\
    on Oct 04 2012 14:22 PM
    Intellectual1305 points

    Hello Hsiung Chai-Wei,

    After a command is issued, the CC3000 should assert the IRQ line.  The master will then issue a read command, then the CC3000 will send the response data.  You should observe the CC3000 responce back on this MISO line.  The sequence of events is detailed further in the CC3000 Host Porting Guide here: http://processors.wiki.ti.com/index.php/CC3000_Host_Programming_Guide

     

    Regards,

    Kelvin

    Please click the Verify Answer button on this post if it answers your question.  Thank You.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hsiung Chia-Wei
    Posted by Hsiung Chia-Wei
    on Oct 13 2012 00:54 AM
    Prodigy210 points

    Dear Kelvin,

    I check SPI.

    void halRfSpiInit(void)
    {
        /* Setup CS to be used as GPIO */
        RF_PORT_SEL &= ~RF_SPI_CS;         
        RF_PORT_OUT |= RF_SPI_CS;
            RF_PORT_DIR |= RF_SPI_CS;
        
        // Set up pins used by peripheral unit
        RF_PORT_SEL |= RF_SPI_SIMO + RF_SPI_SOMI + RF_SPI_CLK;
        RF_PORT_DIR |= RF_SPI_CLK + RF_SPI_SIMO;
        RF_PORT_DIR &= ~RF_SPI_SOMI;
        
        RF_PORT_REN |= RF_SPI_SOMI;                                   // Pull-Ups on RF Interface SOMI
        RF_PORT_OUT |= RF_SPI_SOMI;                                   
        RF_PORT_SEL |= RF_SPI_SIMO + RF_SPI_SOMI + RF_SPI_CLK;

        // Initialize USCI_B1 for SPI Master operation
        UCB0CTL1 = UCSWRST;                                   // Put state machine in reset
        UCB0CTL0 |= /*UCCKPH +*/ UCMSB + UCMST  + UCMODE_0 + UCSYNC ; // 3-pin, 8-bit SPI master
        // Clock polarity select - The inactive state is high
        // MSB first
        UCB0CTL1 |= /*UCSWRST +*/ UCSSEL_2;                         // Use SMCLK, keep RESET
        
        UCB0BR0 = 0x10;                                          // Initial SPI clock must be <400kHz
        UCB0BR1 = 0;                                           // f_UCxCLK = 16MHz/16 = 1MHz
        // Release for operation
       UCB0IE &= ~(UCTXIE + UCRXIE);
           
        UCB0CTL1 &= ~UCSWRST;
        UCB0IFG &= ~UCRXIFG;
    }

    I didn't find where is wrong.

    This code is download from TI.

    Does UCCKPH   UCCKPL   is problem?

    Edward

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hsiung Chia-Wei
    Posted by Hsiung Chia-Wei
    on Oct 13 2012 02:44 AM
    Prodigy210 points

    Dear Kelvin,

    SIMO and CLK are always low.

    When WLAN_ENABLE

    IRQ goes to low first.

    When hci_command_send(HCI_CMND_SIMPLE_LINK_START, ptr, sizeof(SimpleLink_Init_Start_t));

    SOMI ,Cs,PWREN,VCC goes to low.

    Then it shut dowm at SimpleLinkWaitEvent(HCI_CMND_SIMPLE_LINK_START, 0);

    Edward

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use