This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

enet_uip example is broken

Other Parts Discussed in Thread: CONTROLSUITE, CCSTUDIO

I have been trying to get the enet_uip example to work on the F28M35x, but it seems broken in so many ways.

First, I imported the project (without copying). The immediate problem is that multiple includes are not found, and I had to add a bunch of path variables. Each time I added a path variable, another include problem showed up. For reference, these are the extra path variables I had to add:

"${INSTALLROOT_F28M35X_V201}/MWare/third_party/uip-1.0"
"${INSTALLROOT_F28M35X_V201}/MWare/third_party/uip-1.0/uip"
"${INSTALLROOT_F28M35X_V201}/MWare/third_party/uip-1.0/apps"
"${INSTALLROOT_F28M35X_V201}/MWare/third_party/uip-1.0/apps/webserver"
"${INSTALLROOT_F28M35X_V201}/MWare/third_party/uip-1.0/unix"

Even after all this, I get the following errors:

declaration is incompatible with "u8_t uip_buf[422]" (declared at line 425 of "C:/ti/controlSUITE/device_support/f28m35x/v201/MWare/third_party/uip-1.0/uip/uip.h")    enet_uip.c    /enet_uip_m3    line 99    C/C++ Problem

pointer to incomplete class type is not allowed    dhcpc.c    /enet_uip_m3/third_party/uip-1.0/apps/dhcpc    line 364    C/C++ Problem

Has anyone gotten this to work? Any idea how to fix these problems?

  • Hi Michael!

    Oddly...I have imported project from ti\controlSUITE\device_support\f28m35x\v160\F28M35x_examples_Master\enet_uip\ (because of for v201 other version of compiler is used and my CCS IDE hasn't one).

    I have gotten one warning but compiling was successful (.out file have been created ). I use CCSv5.2.

    Regards,

    Igor

  • Hi Guys,

    I checked it with CCS v5.5 and its building successfully too. Few warnings as the compiler versions are different.

    declaration is incompatible with "u8_t uip_buf[422]" (declared at line 425 of "C:/ti/controlSUITE/device_support/f28m35x/v201/MWare/third_party/uip-1.0/uip/uip.h")    enet_uip.c    /enet_uip_m3    line 99    C/C++ Problem

    pointer to incomplete class type is not allowed    dhcpc.c    /enet_uip_m3/third_party/uip-1.0/apps/dhcpc    line 364    C/C++ Problem

    No errors. Michael please check your include paths.

    Regards,

    Gautam

  • Hi Gautam,

    I get the same messages, except they are errors, not warnings. There is no way to compile for me with those problems still present.

    I took the v201 version of the files, the previous post mentioned that he got v160 to work. I will try that, but why is the newer version more broken than the older one?

    Mike

  • I tried the v160 version too, and I get the exact same two errors even after adding a dozen includes to fix all the include problems.

    How are you getting this to compile at all? Those warnings you get are clearly errors on my machine. I am starting from basically fresh installs of all TI software here, and it just doesn't work.

  • Hi Michael!

    If you are sure that you do importing correctly then it is difficult to understand where is problem still. But try to check please compiler version: Properties>General. There are two versions at window General:

    1) "current version" (with this version project was created)

    2) version, which proposes your CCS.

    If these versions are different then paste version 2) in box "current version".

    Also try to do import with filled check box "copy project into workspace"

    Regards,

    Igor 

  • Igor Gorbachev said:

    If you are sure that you do importing correctly then it is difficult to understand where is problem still. But try to check please compiler version: Properties>General. There are two versions at window General:

    1) "current version" (with this version project was created)

    2) version, which proposes your CCS.

    I don't see "current version" or "version". Unless you are talking about "compiler version" and "effective compiler version"? If so, they are the same.

    Also try to do import with filled check box "copy project into workspace"

    That's funny that you say that, if you google enet_uip, all the other threads about problems with this example say to NOT copy into the workspace. Right now, I did not copy it. I have tried copying it before, and ran into the same problems.

  • Hi!

    Michael Hu. said:

    That's funny that you say that, if you google enet_uip, all the other threads about problems with this example say to NOT copy into the workspace. Right now, I did not copy it. I have tried copying it before, and ran into the same problems.

    No matter who and what said, I have imported this project with "copy" option and you saw my successful result above. Sometimes, when result is absent, it need to try all ideas and even most funny.

    Goog luck,

    Igor

  • But I also previously tried that and it didn't work. This has been tested on two different development computers. My second one is working off a clean install of CCS. I have no problem running a number of other examples.

  • Eventually could be try to reinstall controlSUITE, if there are problems with this example exactly.  BTW did you use online web installer or installation from hard disk?

    Igor 

  • I am also using a completely new install of controlSUITE. I used the disk installer, I believe. The installer is 850MB on my disk, so i assume that is the full thing.

  • I just tried Copying the files into the Workspace, on version v160 of the example. I still get the two errors mentioned above. I copied them below again.

    Maybe this is because of the version of CCS. I am using 5.5

    Description    Resource    Path    Location    Type
    declaration is incompatible with "u8_t uip_buf[422]" (declared at line 425 of "C:/ti/controlSUITE/device_support/f28m35x/v160/MWare/third_party/uip-1.0/uip/uip.h")    enet_uip.c    /enet_uip_m3    line 97    C/C++ Problem
    Description    Resource    Path    Location    Type
    pointer to incomplete class type is not allowed    dhcpc.c    /enet_uip_m3/third_party/uip-1.0/apps/dhcpc    line 364    C/C++ Problem


  • Well. I have carefully read about the error messages that you get. Nevertheless, it would be very interesting to look at the screenshot with your project and error messages window. At least we with Gautam have uploaded our screenshots. Now it's your turn :-)

    Igor

  • Ok, Here are screenshots of CCS showing the errors and my Properties window

  • Let us check your Include options

    Igor

  • I had to include everything under the sun to fix initial errors upon importing the project:

  • Oddly...And if you will adjust the include options like on my screenshot then it will be heap of error messages?

  • If I only have your Include paths, I get a ton of errors, as shown below. This is just the initial screenshot. if I fix those, more will pop up, until I have included everything in my previous screenshot.

  • Wow! I found very strange thing. When I import this project to CCS then in "General"  there is target device by default StellarisLM3S9B96!!!??? And compiling is successful. But if to change target device on M35 then problems will be apear. I commiserate you. What target device by default do you have once after import?

    Igor

  • Wow, maybe that is the problem. I got a warning when I first tried to build it that the target device was wrong or something, so I changed it to the Concerto, specifically F28M35H52C1.

  • Hi Michael.

    Perhaps I should have done this before. I have looked at threads of this topic and I have gotten following results:

    http://e2e.ti.com/support/microcontrollers/c2000/f/171/t/139403.aspx  somebody offers to not do import with "copy into workspace" option. I have checked it and it does not affect. For M36 there are the similar problem and somebody proposes to change some source files. Also here somebody proposes several "magic" steps (a creation of new workspace and copying broken project into one etc.) and this helps as no strangely.

    http://e2e.ti.com/support/microcontrollers/c2000/f/171/p/271876/962939.aspx#962939 somebody writes that bug is exists into enet_uip.c and another version is offered.

    3 http://e2e.ti.com/support/microcontrollers/c2000/f/171/t/212559.aspx here I found my case - LM3S9B96 is set by default after import. The problems were reduced but firmware does not work so as it must be.

    Perhaps you have already passed all above. But in general all it looks irresponsibly with respect to the customers. Instead of the normal debugged version of the example project in controlSUITE,  it is offered a variety ways to patch up holes in the run-down coat. May be I return to this issue at near time.

    Regards,

    Igor

  • Hi Michael!

    For M35 the compilation succeeded at last! But for "eabi(ELF)" output format. For "legacy COFF" output format (as on your screenshot) it is impossible (heap of error messages). The "Include options" are the same that before.

    Regards,

    Igor

  • Hi Igor,

    I tried setting the output format to "eabi" and the Runtime Support Library to "automatic", but I still get the same include bugs at first, and the same additional bugs if I add all the extra include options. Did you change anything else to get it to work?

    Description    Resource    Path    Location    Type
    pointer to incomplete class type is not allowed    dhcpc.c    /enet_uip_m3/third_party/uip-1.0/apps/dhcpc    line 364    C/C++ Problem
    declaration is incompatible with "u8_t uip_buf[422]" (declared at line 425 of "C:/ti/controlSUITE/device_support/f28m35x/v160/MWare/third_party/uip-1.0/uip/uip.h")    enet_uip.c    /enet_uip_m3    line 97    C/C++ Problem

  • Hi Michael!

    My actions were following:

    1 Importing project with "Copy into workspace" option (BTW no matter at least for me).

    2 In "General":

    - changing target Device on F28M35H52C1;

    - changing Compiler version on "effective";

    - changing Output format on "eabi (ELF)";

    - changing Runtime support library on "automatic".

    That's all I have tuned after importing. After that a compilation was successful. 

    What else?...

    1Check please: Properties>Build>ARM Compiler>Advanced Options>Language Options>Enable Support for GCC (check box must be filled).

    2 At my above second post I have mentioned about some bug in file enet_uip.c (Reference 2). Try this variant

    3225.6648.enet_uip.c
    //###########################################################################
    // FILE:   enet_uip.c
    // TITLE:  Ethernet GPIO control using uIP TCP/IP stack
    //###########################################################################
    // $TI Release: F28M35x Support Library v201 $
    // $Release Date: Fri Jun  7 10:51:13 CDT 2013 $
    //###########################################################################
    
    #include "inc/hw_ints.h"
    #include "inc/hw_nvic.h"
    #include "inc/hw_gpio.h"
    #include "inc/hw_udma.h"
    #include "inc/hw_types.h"
    #include "inc/hw_memmap.h"
    #include "inc/hw_sysctl.h"
    #include "inc/hw_ethernet.h"
    
    #include "board_drivers/set_pinout_f28m35x.h"
    
    #include "driverlib/udma.h"
    #include "driverlib/gpio.h"
    #include "driverlib/debug.h"
    #include "driverlib/sysctl.h"
    #include "driverlib/systick.h"
    #include "driverlib/ethernet.h"
    #include "driverlib/interrupt.h"
    
    #include "utils/ustdlib.h"
    #include "utils/uartstdio.h"
    
    #include "uip/uip.h"
    #include "uip/uip_arp.h"
    #include "httpd.h"
    #include "dhcpc/dhcpc.h"
    
    //*****************************************************************************
    //! \addtogroup master_example_list
    //! <h1>Ethernet GPIO control using uIP stack (enet_uip)</h1>
    //!
    //! This example application demonstrates controlling a GPIO pin using ethernet
    //! communication. It makes use of the uIP TCP/IP stack.
    //! A basic web site is served over the Ethernet port. The web site displays
    //! a few lines of text, a Toggle LED button, an input to select an LED (6 or 7)
    //! and a get status button. The user specifies which LED needs to be toggled
    //! and presses the Toggle button. The user gets the status of the LED(ON or 
    //! OFF), by pressing the Get status button.
    //! This code uses a static IP address. Depending on the client machine,the user
    //! may need to manually set a fixed static IP address.
    //! Follow the following steps to assign a static IP address to the client
    //! machine
    //!  - disable any wireless connection that may be active.
    //!  - start-> control Panel->right click on "Network connection"->open.
    //!  - Identify the connection to use "Local Area connection" or "Wired
    //!    Network Connection" or some other name depending on the client machine.
    //!  - Right click on the connection -> click on properties. In the "Local Area
    //!    Connection" or "Wired Network connection" properties window under
    //!    "general" tab in the "This connection uses the following items:" list 
    //!    scroll down and click on "Internet Protocol (TCP/IP)" item(! don't 
    //!    uncheck it). click on properties. In the "Internet Protocol(TCP/IP) 
    //!    properties" window select "Use the following IP address" and enter the 
    //!    following:
    //!         IP address:   "169.254.42.86"
    //!         Subnet mask:  "255.255.0.0"
    //!  - click "ok" twice to close the open dialog boxes.
    //!  - Remember to revert back the above settings to their default values once
    //!    the use of this server is complete.
    //!  - The IP address for the server is "169.254.254.169"
    //!
    //! 
    //! \b Note
    //! - Connect the MAC with the PHY using the provided jumpers.
    //!	  Connect the first 15 pins of Row C to Row B using the jumpers.
    //!
    //! - All EMAC examples use a generic TI�s MAC address A8-63-F2-00-00-80. 
    //!   User defined MAC address can be programmed in a fixed non-volatile memory 
    //!   location. Refer to device data sheet and reference guides for details.
    //!
    //! \b Caution
    //! - If you have two concerto CCARDS communicating with each other, they 
    //!   need to have different EMAC addresses.
    //!
    //! For additional details on uIP, refer to the uIP web page at:
    //! http://www.sics.se/~adam/old-uip/
    //
    //*****************************************************************************
    
    //*****************************************************************************
    // Defines for setting up the system clock.
    //*****************************************************************************
    #define SYSTICKHZ               CLOCK_CONF_SECOND
    #define SYSTICKMS               (1000 / SYSTICKHZ)
    #define SYSTICKUS               (1000000 / SYSTICKHZ)
    #define SYSTICKNS               (1000000000 / SYSTICKHZ)
    
    //*****************************************************************************
    // Macro for accessing the Ethernet header information in the buffer.
    //*****************************************************************************
    u8_t ucUIPBuffer[UIP_BUFSIZE + 2];
    u8_t *uip_buf;
    
    #define BUF                     ((struct uip_eth_hdr *)uip_buf)
    
    //*****************************************************************************
    // A set of flags.  The flag bits are defined as follows:
    //     0 -> An indicator that a SysTick interrupt has occurred.
    //     1 -> An RX Packet has been received.
    //     2 -> A TX packet DMA transfer is pending.
    //     3 -> A RX packet DMA transfer is pending.
    //*****************************************************************************
    #define FLAG_SYSTICK            0
    #define FLAG_RXPKT              1
    #define FLAG_TXPKT              2
    #define FLAG_RXPKTPEND          3
    static volatile unsigned long g_ulFlags;
    
    //*****************************************************************************
    // A system tick counter, incremented every SYSTICKMS.
    //*****************************************************************************
    volatile unsigned long g_ulTickCounter = 0;
    
    //*****************************************************************************
    // The control table used by the uDMA controller.  This table must be aligned
    // to a 1024 byte boundary.  In this application uDMA is only used for USB,
    // so only the first 8 channels are needed.
    //*****************************************************************************
    #pragma DATA_ALIGN(g_sDMAControlTable, 1024)
    tDMAControlTable g_sDMAControlTable[8];
    
    //*****************************************************************************
    // Default TCP/IP Settings for this application.
    // Default to Link Local address ... (169.254.1.0 to 169.254.254.255).  Note:
    // This application does not implement the Zeroconf protocol.  No ARP query is
    // issued to determine if this static IP address is already in use.
    // TODO:  Uncomment the following #define statement to enable STATIC IP
    // instead of DHCP.
    //*****************************************************************************
    #define USE_STATIC_IP
    
    #ifndef DEFAULT_IPADDR0
    #define DEFAULT_IPADDR0         169
    #endif
    
    #ifndef DEFAULT_IPADDR1
    #define DEFAULT_IPADDR1         254
    #endif
    
    #ifndef DEFAULT_IPADDR2
    #define DEFAULT_IPADDR2         254
    #endif
    
    #ifndef DEFAULT_IPADDR3
    #define DEFAULT_IPADDR3         169
    #endif
    
    #ifndef DEFAULT_NETMASK0
    #define DEFAULT_NETMASK0        255
    #endif
    
    #ifndef DEFAULT_NETMASK1
    #define DEFAULT_NETMASK1        255
    #endif
    
    #ifndef DEFAULT_NETMASK2
    #define DEFAULT_NETMASK2        0
    #endif
    
    #ifndef DEFAULT_NETMASK3
    #define DEFAULT_NETMASK3        0
    #endif
    
    //*****************************************************************************
    // UIP Timers (in MS)
    //*****************************************************************************
    #define UIP_PERIODIC_TIMER_MS   500
    #define UIP_ARP_TIMER_MS        10000
    
    //*****************************************************************************
    // Defines for commands
    //*****************************************************************************
    #define TOGGLE_LED_6     0xA1
    #define TOGGLE_LED_7     0xA2
    #define GET_LED6_STATUS  0xA3
    #define GET_LED7_STATUS  0xA4
    #define INVALID_CMD      0xA5
    #define INVALID_INPUT    0xA6
    #define NO_CMD           0xA6
    
    //*****************************************************************************
    // functions added in httpd.c
    //*****************************************************************************
    extern void httpd_clear_command(void);
    extern void httpd_clear_command(void);
    extern int httpd_get_command(int *command_word);
    extern void httpd_insert_response(int data_length,char *data);
    
    //*****************************************************************************
    // Responses displayed to the user
    //*****************************************************************************
    const char led6_on[] = " LED6_ON";
    const char led6_off[] = "LED6_OFF";
    const char led7_on[] = " LED7_ON";
    const char led7_off[] = "LED7_OFF";
    
    //*****************************************************************************
    // The error routine that is called if the driver library encounters an error.
    //*****************************************************************************
    #ifdef DEBUG
    void
    __error__(char *pcFilename, unsigned long ulLine)
    {
    }
    
    #endif
    
    //*****************************************************************************
    // The interrupt handler for the SysTick interrupt.
    //*****************************************************************************
    void
    SysTickIntHandler(void)
    {
        // Increment the system tick count.
        g_ulTickCounter++;
    
        // Indicate that a SysTick interrupt has occurred.
        HWREGBITW(&g_ulFlags, FLAG_SYSTICK) = 1;
    }
    
    //*****************************************************************************
    // Display the current IP address on the screen and transmit it via the UART.
    //*****************************************************************************
    void
    ShowIPAddress(const uip_ipaddr_t sIPAddr)
    {
        char pcBuffer[24];
    
        usprintf(pcBuffer, "IP: %d.%d.%d.%d", sIPAddr[0] & 0xff,
                 sIPAddr[0] >> 8, sIPAddr[1] & 0xff, sIPAddr[1] >> 8);
    }
    
    //*****************************************************************************
    //! When using the timer module in UIP, this function is required to return
    //! the number of ticks.  Note that the file "clock-arch.h" must be provided
    //! by the application, and define CLOCK_CONF_SECONDS as the number of ticks
    //! per second, and must also define the typedef "clock_time_t".
    //*****************************************************************************
    clock_time_t
    clock_time(void)
    {
        return((clock_time_t)g_ulTickCounter);
    }
    
    //*****************************************************************************
    // The interrupt handler for the Ethernet interrupt.
    //*****************************************************************************
    void
    EthernetIntHandler(void)
    {
        unsigned long ulTemp;
    
        // Read and Clear the interrupt.
        ulTemp = EthernetIntStatus(ETH_BASE, false);
        EthernetIntClear(ETH_BASE, ulTemp);
    
        // Check to see if an RX Interrupt has occurred.
        if(ulTemp & ETH_INT_RX)
        {
            // Indicate that a packet has been received.
            HWREGBITW(&g_ulFlags, FLAG_RXPKT) = 1;
    
            // Disable Ethernet RX Interrupt.
            EthernetIntDisable(ETH_BASE, ETH_INT_RX);
        }
    
        // Check to see if waiting on a DMA to complete.
        if(HWREGBITW(&g_ulFlags, FLAG_RXPKTPEND) == 1)
        {
            // Verify the channel transfer is done
            if(uDMAChannelModeGet(UDMA_CHANNEL_ETH0RX) == UDMA_MODE_STOP)
            {
                // Indicate that a data has been read in.
                HWREGBITW(&g_ulFlags, FLAG_RXPKTPEND) = 0;
            }
        }
    
        // Check to see if the Ethernet TX uDMA channel was pending.
        if(HWREGBITW(&g_ulFlags, FLAG_TXPKT) == 1)
        {
            // Verify the channel transfer is done
            if(uDMAChannelModeGet(UDMA_CHANNEL_ETH0TX) == UDMA_MODE_STOP)
            {
                // Trigger the transmission of the data.
                HWREG(ETH_BASE + MAC_O_TR) = MAC_TR_NEWTX;
    
                // Indicate that a packet has been sent.
                HWREGBITW(&g_ulFlags, FLAG_TXPKT) = 0;
            }
        }
    }
    
    //*****************************************************************************
    // Callback for when DHCP client has been configured.
    //*****************************************************************************
    void
    dhcpc_configured(const struct dhcpc_state *s)
    {
        uip_sethostaddr(&s->ipaddr);
        uip_setnetmask(&s->netmask);
        uip_setdraddr(&s->default_router);
        ShowIPAddress(s->ipaddr);
    }
    
    //*****************************************************************************
    // Read a packet using DMA instead of directly reading the FIFO if the
    // alignment will allow it.
    //*****************************************************************************
    long
    EthernetPacketGetDMA(unsigned long ulBase, unsigned char *pucBuf, long lBufLen)
    {
        unsigned long ulTemp;
        unsigned char pucData[4];
        unsigned char *pucBuffer;
        long lTempLen, lFrameLen;
        long lRemainder;
        int iIdx;
    
        // Check the arguments.
        ASSERT(ulBase == ETH_BASE);
        ASSERT(pucBuf != 0);
        ASSERT(lBufLen > 0);
    
        // If the buffer is not aligned on an odd half-word then it cannot use DMA.
        // This is because the two packet length bytes are written in front of the
        // packet, and the packet data must have two bytes that can be pulled off
        // to become a word and leave the remainder of the buffer word aligned.
        if(((unsigned long)pucBuf & 3) != 2)
        {
            // If there is not proper alignment the packet must be sent without
            // using DMA.
            return(EthernetPacketGetNonBlocking(ulBase, pucBuf, lBufLen));
        }
    
        // Read WORD 0 from the FIFO, set the receive Frame Length and store the
        // first two bytes of the destination address in the receive buffer.
        ulTemp = HWREG(ulBase + MAC_O_DATA);
        lFrameLen = (long)(ulTemp & 0xffff);
        pucBuf[0] = (unsigned char)((ulTemp >> 16) & 0xff);
        pucBuf[1] = (unsigned char)((ulTemp >> 24) & 0xff);
    
        // The maximum DMA size is the frame size - the two bytes already read and
        // truncated to the nearest word size.
        lTempLen = (lFrameLen - 2) & 0xfffffffc;
        lRemainder = (lFrameLen - 2) & 3;
    
        // Don't allow writing beyond the end of the buffer.
        if(lBufLen < lTempLen)
        {
            lRemainder = lTempLen - lBufLen;
            lTempLen =  lBufLen;
        }
        else if(lBufLen >= (lFrameLen - 2 + 3))
        {
            // If there is room, just DMA the last word as well so that the
            // special copy after DMA is not required.
            lRemainder = 0;
            lTempLen = lFrameLen - 2 + 3;
        }
    
        // Mark the receive as pending.
        HWREGBITW(&g_ulFlags, FLAG_RXPKTPEND) = 1;
    
        // Set up the DMA to transfer the Ethernet header when a
        // packet is received
        uDMAChannelTransferSet(UDMA_CHANNEL_ETH0RX, UDMA_MODE_AUTO,
                               (void *)(ETH_BASE + MAC_O_DATA),
                               &pucBuf[2], lTempLen>>2);
        uDMAChannelEnable(UDMA_CHANNEL_ETH0RX);
    
        // Issue a software request to start the channel running.
        uDMAChannelRequest(UDMA_CHANNEL_ETH0RX);
    
        // Wait for the previous transmission to be complete.
        while(HWREGBITW(&g_ulFlags, FLAG_RXPKTPEND) == 1)
        {
        }
    
        // See if there are extra bytes to read into the buffer.
        if(lRemainder)
        {
            // If the remainder is more than 3 bytes then the buffer was never big
            // enough and data must be tossed.
            if(lRemainder > 3)
            {
                // Read any remaining WORDS (that did not fit into the buffer).
                while(lRemainder > 0)
                {
                    ulTemp = HWREG(ulBase + MAC_O_DATA);
                    lRemainder -= 4;
                }
            }
    
            // Read the last word from the FIFO.
            *((unsigned long *)&pucData[0]) = HWREG(ulBase + MAC_O_DATA);
    
            // The current buffer position is lTempLen plus the two bytes read
            // from the first word.
            pucBuffer = &pucBuf[lTempLen + 2];
    
            // Read off each individual byte and save it.
            for(iIdx = 0; iIdx < lRemainder; iIdx++)
            {
                pucBuffer[iIdx] = pucData[iIdx];
            }
        }
    
        // If frame was larger than the buffer, return the "negative" frame length.
        lFrameLen -= 6;
        if(lFrameLen > lBufLen)
        {
            return(-lFrameLen);
        }
    
        // Return the Frame Length
        return(lFrameLen);
    }
    
    //*****************************************************************************
    // Transmit a packet using DMA instead of directly writing the FIFO if the
    // alignment will allow it.
    //*****************************************************************************
    static long
    EthernetPacketPutDMA(unsigned long ulBase, unsigned char *pucBuf,
                         long lBufLen)
    {
        unsigned long ulTemp;
    
        // If the buffer is not aligned on an odd half-word then it cannot use DMA.
        // This is because the two packet length bytes are written in front of the
        // packet, and the packet data must have two bytes that can be pulled off
        // to become a word and leave the remainder of the buffer word aligned.
        if(((unsigned long)pucBuf & 3) != 2)
        {
            // If there is not proper aligment the packet must be sent without
            // using DMA.
            return(EthernetPacketPut(ulBase, pucBuf, lBufLen));
        }
    
        // Indicate that a packet is being sent.
        HWREGBITW(&g_ulFlags, FLAG_TXPKT) = 1;
    
        // Build and write WORD 0 (see format above) to the transmit FIFO.
        ulTemp = (unsigned long)(lBufLen - 14);
        ulTemp |= (*pucBuf++) << 16;
        ulTemp |= (*pucBuf++) << 24;
        HWREG(ulBase + MAC_O_DATA) = ulTemp;
    
        // Force an extra word to be transferred if the end of the buffer is not
        // aligned on a word boundary.  The math is actually lBufLen - 2 + 3 to
        // insure that the proper number of bytes are written.
        lBufLen += 1;
    
        // Configure the TX DMA channel to transfer the packet buffer.
        uDMAChannelTransferSet(UDMA_CHANNEL_ETH0TX, UDMA_MODE_AUTO,
                               pucBuf, (void *)(ETH_BASE + MAC_O_DATA),
                               lBufLen>>2);
    
        // Enable the Ethernet Transmit DMA channel.
        uDMAChannelEnable(UDMA_CHANNEL_ETH0TX);
    
        // Issue a software request to start the channel running.
        uDMAChannelRequest(UDMA_CHANNEL_ETH0TX);
    
        // Wait for the previous transmission to be complete.
        while((HWREGBITW(&g_ulFlags, FLAG_TXPKT) == 1) &&
              EthernetSpaceAvail(ETH_BASE))
        {
        }
    
        // Take back off the byte that we addeded above.
        return(lBufLen - 1);
    
    }
    
    //*****************************************************************************
    // Set up the pins that are used for Ethernet
    //*****************************************************************************
    void EthernetPinsSetup(void)
    {
        // MII_TXD3
        GPIODirModeSet(GPIO_PORTC_BASE, GPIO_PIN_4, GPIO_DIR_MODE_HW);
        GPIOPadConfigSet(GPIO_PORTC_BASE, GPIO_PIN_4, GPIO_PIN_TYPE_STD);
        HWREG(GPIO_PORTC_BASE + GPIO_O_PCTL) &= 0xFFF0FFFF;
        HWREG(GPIO_PORTC_BASE + GPIO_O_PCTL) |= 0x00030000;
    
        // MII_MDIO
        GPIODirModeSet(GPIO_PORTE_BASE, GPIO_PIN_6, GPIO_DIR_MODE_HW);
        GPIOPadConfigSet(GPIO_PORTE_BASE, GPIO_PIN_6, GPIO_PIN_TYPE_STD);
        HWREG(GPIO_PORTE_BASE + GPIO_O_APSEL)|= 0x00000040;
        HWREG(GPIO_PORTE_BASE + GPIO_O_PCTL) &= 0xF0FFFFFF;
        HWREG(GPIO_PORTE_BASE + GPIO_O_PCTL) |= 0x0C000000;
    
        // MII_RXD3
        GPIODirModeSet(GPIO_PORTF_BASE, GPIO_PIN_5, GPIO_DIR_MODE_HW);
        GPIOPadConfigSet(GPIO_PORTF_BASE, GPIO_PIN_5, GPIO_PIN_TYPE_STD);
        HWREG(GPIO_PORTF_BASE + GPIO_O_PCTL) &= 0xFF0FFFFF;
        HWREG(GPIO_PORTF_BASE + GPIO_O_PCTL) |= 0x00300000;
    
        // MII_TXER , MII_RXDV , MII_RXD1 , MII_RXD2
        GPIODirModeSet(GPIO_PORTG_BASE, GPIO_PIN_7|GPIO_PIN_3|GPIO_PIN_1|GPIO_PIN_0,
                       GPIO_DIR_MODE_HW);
        GPIOPadConfigSet(GPIO_PORTG_BASE, GPIO_PIN_7|GPIO_PIN_3|GPIO_PIN_1|
                         GPIO_PIN_0,
                         GPIO_PIN_TYPE_STD);
        HWREG(GPIO_PORTG_BASE + GPIO_O_APSEL)|= 0x0000000B;
        HWREG(GPIO_PORTG_BASE + GPIO_O_PCTL) &= 0x0FFF0F00;
        HWREG(GPIO_PORTG_BASE + GPIO_O_PCTL) |= 0x3000C0CC;
    
        // MII_TXCK , MII_TXEN , MII_TXD0 , MII_TXD1 , MII_TXD2 , MII_RXD0
        GPIODirModeSet(
            GPIO_PORTH_BASE, GPIO_PIN_7|GPIO_PIN_6|GPIO_PIN_5|GPIO_PIN_4|
            GPIO_PIN_3|
            GPIO_PIN_1, GPIO_DIR_MODE_HW);
        GPIOPadConfigSet(
            GPIO_PORTH_BASE, GPIO_PIN_7|GPIO_PIN_6|GPIO_PIN_5|GPIO_PIN_4|
            GPIO_PIN_3|
            GPIO_PIN_1, GPIO_PIN_TYPE_STD);
        HWREG(GPIO_PORTH_BASE + GPIO_O_APSEL)|= 0x000000C2;
        HWREG(GPIO_PORTH_BASE + GPIO_O_PCTL) &= 0x00000F0F;
        HWREG(GPIO_PORTH_BASE + GPIO_O_PCTL) |= 0xCC9990C0;
    
        // MII_PHYRSTn , MII_PHYINTRn , MII_CRS , MII_COL , MII_MDC , MII_RXCK ,
        // MII_RXER
        GPIODirModeSet(
            GPIO_PORTJ_BASE, GPIO_PIN_7|GPIO_PIN_6|GPIO_PIN_5|GPIO_PIN_4|
            GPIO_PIN_3|
            GPIO_PIN_2|GPIO_PIN_0, GPIO_DIR_MODE_HW);
        GPIOPadConfigSet(
            GPIO_PORTJ_BASE, GPIO_PIN_7|GPIO_PIN_6|GPIO_PIN_5|GPIO_PIN_4|
            GPIO_PIN_3|
            GPIO_PIN_2|GPIO_PIN_0, GPIO_PIN_TYPE_STD);
        HWREG(GPIO_PORTJ_BASE + GPIO_O_APSEL)|= 0x000000FC;
        HWREG(GPIO_PORTJ_BASE + GPIO_O_PCTL) &= 0x000000F0;
        HWREG(GPIO_PORTJ_BASE + GPIO_O_PCTL) |= 0xCCCCCC03;
    }
    
    //*****************************************************************************
    // respond to commands sent by the user (client)
    //
    //*****************************************************************************
    void EthernetProcessCMD(int command)
    {
    
        static unsigned char toggle_LED6 = 0;
        static unsigned char toggle_LED7 = 0;
    
        switch(command)
        {
        case TOGGLE_LED_7:
            toggle_LED7 = ~toggle_LED7;
            GPIOPinWrite(GPIO_PORTC_BASE, GPIO_PIN_6, toggle_LED7);
            break;
    
        case TOGGLE_LED_6:
            toggle_LED6 = ~toggle_LED6;
            GPIOPinWrite(GPIO_PORTC_BASE, GPIO_PIN_7, toggle_LED6);
            break;
    
        case GET_LED6_STATUS:
            if(GPIOPinRead(GPIO_PORTC_BASE,GPIO_PIN_7)& 0x80)
                httpd_insert_response(sizeof(led6_off)-1,(char *)led6_off);
            else
                httpd_insert_response(sizeof(led6_on)-1,(char *)led6_on);
            break;
    
        case GET_LED7_STATUS:
            if(GPIOPinRead(GPIO_PORTC_BASE,GPIO_PIN_6) & 0x40)
                httpd_insert_response(sizeof(led7_off)-1,(char *)led7_off);
            else
                httpd_insert_response(sizeof(led7_on)-1,(char *)led7_on);
            break;
    
        default:
    
            break;
        }
    }
    
    //*****************************************************************************
    // This example demonstrates the use of the Ethernet Controller with the uIP
    // TCP/IP stack.
    //*****************************************************************************
    int
    main(void)
    {
        uip_ipaddr_t ipaddr;
        static struct uip_eth_addr sTempAddr;
        long lPeriodicTimer, lARPTimer;
        unsigned long ulUser0, ulUser1;
        unsigned long ulTemp;
        int command_word;
    
        // Disable Protection
        HWREG(SYSCTL_MWRALLOW) =  0xA5A5A5A5;
    
    
        // Sets up PLL, M3 running at 100MHz and C28 running at 100MHz
        SysCtlClockConfigSet(SYSCTL_USE_PLL | (SYSCTL_SPLLIMULT_M & 0xA) |
                             SYSCTL_SYSDIV_1 | SYSCTL_M3SSDIV_1 |
                             SYSCTL_XCLKDIV_4);
    
        // Remove This
        // PinoutSet();
    
        // Enable clock supply for the following peripherals
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOA);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOB);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOC);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOD);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOE);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOF);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOG);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOH);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOJ);
    
    
        // Enable clock supply for the following peripherals
        SysCtlPeripheralEnable(SYSCTL_PERIPH_UDMA);
        SysCtlPeripheralEnable(SYSCTL_PERIPH_ETH);
    
        // Disable clock supply for the watchdog modules
        SysCtlPeripheralDisable(SYSCTL_PERIPH_WDOG1);
        SysCtlPeripheralDisable(SYSCTL_PERIPH_WDOG0);
    
        // Set up the 20 pins required for Ethernet communication
        EthernetPinsSetup();
    
        // Set up LED7 pin
        GPIOPinTypeGPIOOutput(LED_0_BASE, LED_0_PIN);
        GPIOPinWrite(LED_0_BASE, LED_0_PIN, 0);
    
        // Set up LED6 pin
        GPIOPinTypeGPIOOutput(LED_1_BASE, LED_1_PIN);
        GPIOPinWrite(LED_1_BASE, LED_1_PIN, 0);
    
        // Adjust the pointer to be aligned on an odd half word address so that
        // DMA can be used.
        uip_buf = (u8_t *)(((unsigned long)ucUIPBuffer + 3) & 0xfffffffe);
    
        // Enable the uDMA controller and set up the control table base.
        SysCtlPeripheralEnable(SYSCTL_PERIPH_UDMA);
        uDMAEnable();
        uDMAControlBaseSet(g_sDMAControlTable);
    
        // Configure the DMA TX channel
        uDMAChannelAttributeDisable(UDMA_CHANNEL_ETH0TX, UDMA_ATTR_ALL);
        uDMAChannelControlSet(UDMA_CHANNEL_ETH0TX,
                              UDMA_SIZE_32 | UDMA_SRC_INC_32 |
                              UDMA_DST_INC_NONE | UDMA_ARB_8);
    
        // Set user/company specific MAC octets
        // (for this code we are using A8-63-F2-00-00-80)
        // 0x00 MACOCT3 MACOCT2 MACOCT1
        ulUser0 = 0x00F263A8;
    
        // 0x00 MACOCT6 MACOCT5 MACOCT4
        ulUser1 = 0x00800000;
    
        // User needs to program user specific MAC address into Flash
        // and read it on power up
        if((ulUser0 == 0xffffffff) || (ulUser1 == 0xffffffff))
        {
            // We should never get here.  This is an error if the MAC address has
            // not been programmed into the device.  Exit the program.
            while(1)
            {
            }
        }
    
        // Enable and Reset the Ethernet Controller.
        SysCtlPeripheralEnable(SYSCTL_PERIPH_ETH);
        SysCtlPeripheralReset(SYSCTL_PERIPH_ETH);
    
        // Configure SysTick for a periodic interrupt.
        SysTickPeriodSet(SysCtlClockGet(SYSTEM_CLOCK_SPEED) / SYSTICKHZ);
        SysTickEnable();
        IntRegister(FAULT_SYSTICK, SysTickIntHandler);
        SysTickIntEnable();
    
        // Configure the DMA channel for Ethernet receive.
        uDMAChannelAttributeDisable(UDMA_CHANNEL_ETH0RX, UDMA_ATTR_ALL);
        uDMAChannelControlSet(UDMA_CHANNEL_ETH0RX,
                              UDMA_SIZE_32 | UDMA_SRC_INC_NONE |
                              UDMA_DST_INC_32 | UDMA_ARB_8);
    
        // Initialize the Ethernet Controller and disable all Ethernet Controller
        // interrupt sources.
        EthernetIntDisable(ETH_BASE, (ETH_INT_PHY | ETH_INT_MDIO |
                                      ETH_INT_RXER | ETH_INT_RXOF |
                                      ETH_INT_TX | ETH_INT_TXER | ETH_INT_RX));
        ulTemp = EthernetIntStatus(ETH_BASE, false);
        EthernetIntClear(ETH_BASE, ulTemp);
    
        // Initialize the Ethernet Controller for operation.
        EthernetInitExpClk(ETH_BASE, SysCtlClockGet(SYSTEM_CLOCK_SPEED));
    
        // Configure the Ethernet Controller for normal operation.
        // - Full Duplex
        // - TX CRC Auto Generation
        // - TX Padding Enabled
        EthernetConfigSet(ETH_BASE, (ETH_CFG_TX_DPLXEN | ETH_CFG_TX_CRCEN |
                                     ETH_CFG_TX_PADEN));
    
        // Wait for the link to become active.
        while((EthernetPHYRead(ETH_BASE, PHY_MR1) & 0x0004) == 0)
        {
        }
    
        // Enable the Ethernet Controller.
        EthernetEnable(ETH_BASE);
        
        
    
        // Enable and register the Ethernet interrupt.
        IntRegister(INT_ETH, EthernetIntHandler);
        IntEnable(INT_ETH);
    
    
        // Enable the Ethernet RX Packet interrupt source.
        EthernetIntEnable(ETH_BASE, ETH_INT_RX);
    
        // Enable all processor interrupts.
        IntMasterEnable();
    
        // Initialize the uIP TCP/IP stack.
        uip_init();
    #ifdef USE_STATIC_IP
        uip_ipaddr(ipaddr, DEFAULT_IPADDR0, DEFAULT_IPADDR1, DEFAULT_IPADDR2,
                   DEFAULT_IPADDR3);
        uip_sethostaddr(ipaddr);
        ShowIPAddress(ipaddr);
        uip_ipaddr(ipaddr, DEFAULT_NETMASK0, DEFAULT_NETMASK1, DEFAULT_NETMASK2,
                   DEFAULT_NETMASK3);
        uip_setnetmask(ipaddr);
    #else
        uip_ipaddr(ipaddr, 0, 0, 0, 0);
        uip_sethostaddr(ipaddr);
        uip_ipaddr(ipaddr, 0, 0, 0, 0);
        uip_setnetmask(ipaddr);
    #endif
    
        // Convert the 24/24 split MAC address from ram into a 32/16 split MAC
        // address needed to program the hardware registers, then program the MAC
        // address into the Ethernet Controller registers.
        sTempAddr.addr[0] = ((ulUser0 >>  0) & 0xff);
        sTempAddr.addr[1] = ((ulUser0 >>  8) & 0xff);
        sTempAddr.addr[2] = ((ulUser0 >> 16) & 0xff);
        sTempAddr.addr[3] = ((ulUser1 >>  0) & 0xff);
        sTempAddr.addr[4] = ((ulUser1 >>  8) & 0xff);
        sTempAddr.addr[5] = ((ulUser1 >> 16) & 0xff);
    
        // Program the hardware with it's MAC address (for filtering).
        EthernetMACAddrSet(ETH_BASE, (unsigned char *)&sTempAddr);
        uip_setethaddr(sTempAddr);
    
        // Initialize the TCP/IP Application (e.g. web server).
        httpd_init();
    
    #ifndef USE_STATIC_IP
    
        // Initialize the DHCP Client Application.
        dhcpc_init(&sTempAddr.addr[0], 6);
        dhcpc_request();
    #endif
    
        // Main Application Loop.
        lPeriodicTimer = 0;
        lARPTimer = 0;
        httpd_clear_command();
        while(true)
        {
    
            // Wait for an event to occur.  This can be either a System Tick event,
            // or an RX Packet event.
            while(!g_ulFlags)
            {
            }
    
            // If SysTick, Clear the SysTick interrupt flag and increment the
            // timers.
            if(HWREGBITW(&g_ulFlags, FLAG_SYSTICK) == 1)
            {
                HWREGBITW(&g_ulFlags, FLAG_SYSTICK) = 0;
                lPeriodicTimer += SYSTICKMS;
                lARPTimer += SYSTICKMS;
            }
    
            // Check for an RX Packet and read it.
            if(HWREGBITW(&g_ulFlags, FLAG_RXPKT))
            {
                // Get the packet and set uip_len for uIP stack usage.
                uip_len = (unsigned short)EthernetPacketGetDMA(ETH_BASE, uip_buf,
                                                               sizeof(ucUIPBuffer));
    
                // Clear the RX Packet event and re-enable RX Packet interrupts.
                if(HWREGBITW(&g_ulFlags, FLAG_RXPKT) == 1)
                {
                    HWREGBITW(&g_ulFlags, FLAG_RXPKT) = 0;
                    EthernetIntEnable(ETH_BASE, ETH_INT_RX);
                }
    
                // Process incoming IP packets here.
                if(BUF->type == htons(UIP_ETHTYPE_IP))
                {
    
                    uip_arp_ipin();
                    uip_input(); //uip_process (calls uip_appcall())
    
                    if(httpd_get_command(&command_word))
                    {
                        httpd_clear_command();
                        EthernetProcessCMD(command_word);
                    }
    
                    // If the above function invocation resulted in data that
                    // should be sent out on the network, the global variable
                    // uip_len is set to a value > 0.
                    if(uip_len > 0)
                    {
                        uip_arp_out();
                        EthernetPacketPutDMA(ETH_BASE, uip_buf, uip_len);
                        uip_len = 0;
                    }
                }
    
                // Process incoming ARP packets here.
                else if(BUF->type == htons(UIP_ETHTYPE_ARP))
                {
                    uip_arp_arpin();
    
                    // If the above function invocation resulted in data that
                    // should be sent out on the network, the global variable
                    // uip_len is set to a value > 0.
                    if(uip_len > 0)
                    {
                        EthernetPacketPutDMA(ETH_BASE, uip_buf, uip_len);
                        uip_len = 0;
                    }
                }
            }
    
            // Process TCP/IP Periodic Timer here.
            if(lPeriodicTimer > UIP_PERIODIC_TIMER_MS)
            {
                lPeriodicTimer = 0;
                for(ulTemp = 0; ulTemp < UIP_CONNS; ulTemp++)
                {
                    uip_periodic(ulTemp);
    
                    // If the above function invocation resulted in data that
                    // should be sent out on the network, the global variable
                    // uip_len is set to a value > 0.
                    if(uip_len > 0)
                    {
                        uip_arp_out();
                        EthernetPacketPutDMA(ETH_BASE, uip_buf, uip_len);
                        uip_len = 0;
                    }
                }
    
    #if UIP_UDP
                for(ulTemp = 0; ulTemp < UIP_UDP_CONNS; ulTemp++)
                {
                    uip_udp_periodic(ulTemp);
    
                    // If the above function invocation resulted in data that
                    // should be sent out on the network, the global variable
                    // uip_len is set to a value > 0.
                    if(uip_len > 0)
                    {
                        uip_arp_out();
                        EthernetPacketPutDMA(ETH_BASE, uip_buf, uip_len);
                        uip_len = 0;
                    }
                }
    #endif
            }
    
            // Process ARP Timer here.
            if(lARPTimer > UIP_ARP_TIMER_MS)
            {
                lARPTimer = 0;
                uip_arp_timer();
            }
        }
    }
    
    
    
    
    .

    3 I haven't for my vesion of CCSv5.2 the option "Manage the project's target-configuration automatically" in "General" options window. Maybe to try to disable that option.

    It's all at now...

    Regards,

    Igor

  • I'm sorry Igor, I've done everything you wrote above exactly, and it still does not work. I've tried it with both v160 and v201.

    When I change the target Device the first time, I do get the following error message:

    Maybe this has something to do with it? If I look at project.log, I see the following:

    !ERROR: java.lang.NullPointerException
        at com.ti.ccstudio.project.core.internal.initializer.CCSConfigurationInitializer.doCopyBuildOptions(CCSConfigurationInitializer.java:453)
        at com.ti.common.project.core.internal.initializer.AConfigurationInitializer.copyBuildOptions(AConfigurationInitializer.java:123)
        at com.ti.common.project.core.internal.initializer.AConfigurationInitializer.internalCopyBuildOptions(AConfigurationInitializer.java:352)
        at com.ti.common.project.core.internal.initializer.AConfigurationInitializer.internalInitializeBuildOptions(AConfigurationInitializer.java:311)
        at com.ti.common.project.core.internal.initializer.AConfigurationInitializer.initializeFromExisting(AConfigurationInitializer.java:99)
        at com.ti.common.project.ui.internal.properties.ConfigurationPropertiesPage.saveConfiguration(ConfigurationPropertiesPage.java:339)
        at com.ti.common.project.ui.internal.properties.ConfigurationPropertiesPage.forEach(ConfigurationPropertiesPage.java:285)
        at org.eclipse.cdt.ui.newui.AbstractPage$5.sendOK(AbstractPage.java:644)
        at org.eclipse.cdt.ui.newui.AbstractPage$5.run(AbstractPage.java:675)
        at org.eclipse.ui.actions.WorkspaceModifyDelegatingOperation.execute(WorkspaceModifyDelegatingOperation.java:69)
        at org.eclipse.ui.actions.WorkspaceModifyOperation$1.run(WorkspaceModifyOperation.java:106)
        at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2344)
        at org.eclipse.ui.actions.WorkspaceModifyOperation.run(WorkspaceModifyOperation.java:118)
        at org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.java:464)
        at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:372)
        at org.eclipse.jface.dialogs.ProgressMonitorDialog.run(ProgressMonitorDialog.java:507)
        at org.eclipse.ui.internal.progress.ProgressManager$RunnableWithStatus.run(ProgressManager.java:1346)
        at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
        at org.eclipse.ui.internal.progress.ProgressManager$7.run(ProgressManager.java:1184)
        at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:180)
        at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:150)
        at org.eclipse.swt.widgets.Display.syncExec(Display.java:4687)
        at org.eclipse.ui.internal.progress.ProgressManager.runInUI(ProgressManager.java:1182)
        at org.eclipse.cdt.ui.newui.AbstractPage.performSave(AbstractPage.java:691)
        at org.eclipse.cdt.ui.newui.AbstractPage.performOk(AbstractPage.java:569)
        at com.ti.common.project.ui.internal.properties.BasePropertiesPage.performOk(BasePropertiesPage.java:128)
        at org.eclipse.jface.preference.PreferenceDialog$13.run(PreferenceDialog.java:965)
        at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
        at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:49)
        at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:175)
        at org.eclipse.jface.preference.PreferenceDialog.okPressed(PreferenceDialog.java:945)
        at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.okPressed(FilteredPreferenceDialog.java:449)
        at org.eclipse.jface.preference.PreferenceDialog.buttonPressed(PreferenceDialog.java:233)
        at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:624)
        at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:248)
        at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
        at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
        at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4169)
        at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3758)
        at org.eclipse.jface.window.Window.runEventLoop(Window.java:825)
        at org.eclipse.jface.window.Window.open(Window.java:801)
        at org.eclipse.ui.dialogs.PropertyDialogAction.run(PropertyDialogAction.java:158)
        at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
        at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:584)
        at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:501)
        at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:411)
        at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
        at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
        at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4169)
        at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3758)
        at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2701)
        at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2665)
        at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2499)
        at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:679)
        at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
        at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:668)
        at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
        at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:124)
        at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
        at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
        at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
        at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
        at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
        at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
        at org.eclipse.equinox.launcher.Main.run(Main.java:1438)


  • Hi Michael!

    You can try importing my workable project V160 to your workspace 4214.enet_uip_m3.rar. Just please pay attention that my controlSUITE directory is E:\ti...(not C:\, perhaps it will need to correct "Include options" and to set your "effective compiler version" also before compilation). Let us try to do that.

    Regards,

    Igor

  • Thanks Igor, but is your file missing some source code? I have enet_uip.c, httpd.c, startup_ccs.c, and driverlib.lib all showing as missing.

  • This is what I was worried about. This is a problem of incorrect paths to the project resources. I'll think of how it can be overcome. Anyway it would be very interesting to check my project on your PC.

    Regards,

    Igor

  • Hi Michael!

    An attempt #2 8130.enet_uip.zip

    Importing the project on another machine http://processors.wiki.ti.com/index.php/Project_Sharing#Importing_the_project_on_another_machine

    These instructions cover how to import the project from the archive. What happens is that it will import the project into your workspace. For linked/referenced resources it will copy those files from the archive in place then at the same path where they were located on the original computer.

    1. Project -> Import Existing CCS/CCE Eclipse Project
    2. Change the radio button selection at the top to "Select archive file"
    3. Browse to and select your archive file
    4. It will list all of the projects found in the archive. The are all selected by default. Select the ones you want and click "Finish"
    5. The project is now in your workspace

    Regards,

    Igor

  • I think it's almost there? I changed the Build Variable ORIGINAL_PROJECT_ROOT to start with C: instead of E:, it only gives the error:

    Description    Resource    Path    Location    Type
    cannot open source file "dhpc.h"    dhcpc.c    /enet_uip_m3/third_party/uip-1.0/apps/dhcpc    line 38    C/C++ Problem

    This error remains even if I change the options for the compiler version, manage configuration automatically, etc as you have previously written.

  • Try to add into  "Include options" full path for this damn file:

    C:\ti\controlSUITE\device_support\f28m35x\v160\MWare\third_party\uip-1.0\apps\dhcpc\dhcpc.h

    Regards,

    Igor

  • Success! Finally got it to compile. Now time to test...

  • Hi Michael!

    Congrats! The long siege ended in the capture of the impregnable fortress finally :-)

    Good luck,

    Igor

  • Hi

    I needed to change the "set_pinout_f28m35x.h" and the "set_pinout_f28m35x.c" files (they are contain some errors in the GPIO config) by the cited in the link:

    http://e2e.ti.com/support/microcontrollers/c2000/f/171/t/301751.aspx

    Now it works: