[Solved] Create an Ethernet project with Harmony that works

[Solved] Create an Ethernet project with Harmony that works

Postby Elinux » Mon Sep 03, 2018 9:45 am

Hello,

I have a PIC32 Ethernet Starter Kit with PIC32MX795F512L, and I would like to use Ethernet to be able to make a server client with a PC, for example: send a byte frame with TCP from the PC to the PIC32 ESK, and answer it by, yes j received your rocket.

To do this, I would like to use MPLAB Harmony, but every time I try I always get tons of errors (I use MPLAB X IDE v4.20 with MPLAB Harmony v2_06).

I have tried various tutorials, but none have worked for me (http://microchipdeveloper.com/wifi:wh, https://www.youtube.com/watch?v=EyclfQkgLnM ) Nothing worked for me, I always hang on mistakes, like this one for example (in first example):

Code: Select all
make -f nbproject/Makefile-default.mk SUBPROJECTS= .build-conf
make[1]: Entering directory 'C:/microchip/harmony/v2_06/apps/Ethernet_Project/firmware/Ethernet_Project.X'
make -f nbproject/Makefile-default.mk dist/default/production/Ethernet_Project.X.production.hex
make[2]: Entering directory 'C:/microchip/harmony/v2_06/apps/Ethernet_Project/firmware/Ethernet_Project.X'
../../../../framework/tcpip/src/dnss.c: In function 'TCPIP_DNSS_Initialize':
../../../../framework/tcpip/src/dnss.c:233:16: error: 'TCPIP_DNS_CLIENT_MAX_HOSTNAME_LEN' undeclared (first use in this function)
if(TCPIP_DNS_CLIENT_MAX_HOSTNAME_LEN != 0)
^
../../../../framework/tcpip/src/dnss.c:233:16: note: each undeclared identifier is reported only once for each function it appears in
../../../../framework/tcpip/src/dnss.c: In function 'TCPIP_OAHASH_DNSS_KeyCopy':
../../../../framework/tcpip/src/dnss.c:1417:37: error: 'TCPIP_DNS_CLIENT_MAX_HOSTNAME_LEN' undeclared (first use in this function)
memset(pDnssHE->pHostName,0,TCPIP_DNS_CLIENT_MAX_HOSTNAME_LEN);
^
make[2]: *** [build/default/production/_ext/1408260596/dnss.o] Error 1
make[1]: *** [.build-conf] Error 2
make: *** [.build-impl] Error 2
"C:\Program Files\Microchip\xc32\v2.10\bin\xc32-gcc.exe" -g -x c -c -mprocessor=32MX795F512L -ffunction-sections -O1 -D__XC -I../src -I../src/system_config/default -I../src/default -I../../../../framework -I../src/system_config/default/framework -I../../../../framework/driver/wifi/winc1500/include -I../../../../framework/driver/wifi/winc1500/wireless_driver/include -I../../../../framework/driver/wifi/winc1500/wireless_driver_extension -I../../../../framework/driver/wifi/winc1500/wireless_driver_extension/bsp/include -I../../../../framework/driver/wifi/winc1500/wireless_driver_extension/bus_wrapper/include -I../../../../framework/driver/wifi/winc1500/wireless_driver_extension/common/include -I../../../../framework/driver/wifi/winc1500/wireless_driver_extension/driver/include -I../../../../framework/driver/wifi/winc1500/wireless_driver_extension/driver/source -I../../../../framework/driver/wifi/winc1500/wireless_driver_extension/spi_flash/include -I../src/system_config/default/bsp -I../../../../third_party/rtos/FreeRTOS/Source/include -I../../../../third_party/rtos/FreeRTOS/Source/portable/MPLAB/PIC32MX -MMD -MF build/default/production/_ext/1408260596/dnss.o.d -o build/default/production/_ext/1408260596/dnss.o ../../../../framework/tcpip/src/dnss.c -DXPRJ_default=default -no-legacy-libc
nbproject/Makefile-default.mk:1053: recipe for target 'build/default/production/_ext/1408260596/dnss.o' failed
make[2]: Leaving directory 'C:/microchip/harmony/v2_06/apps/Ethernet_Project/firmware/Ethernet_Project.X'
nbproject/Makefile-default.mk:90: recipe for target '.build-conf' failed
make[1]: Leaving directory 'C:/microchip/harmony/v2_06/apps/Ethernet_Project/firmware/Ethernet_Project.X'
nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed

BUILD FAILED (exit value 2, total time: 10s)


:?: Someone would have examples of projects that could be useful to me, or could I run on my mistakes?

Thank you
Last edited by Elinux on Wed Oct 03, 2018 9:12 am, edited 1 time in total.
Elinux
 
Posts: 15
Joined: Mon Sep 03, 2018 9:39 am
Location: France

Re: Create an Ethernet project with MPLAB Harmony that works

Postby AussieSusan » Tue Sep 04, 2018 3:50 am

I've not used Harmony but I have created projects that use the MLA IP stack.
Looking at the errors, I would guess that you have not included a needed header file, or the file is not in the header search path.
Are all of the header and library files installed and in the right place?
Susan
AussieSusan
Verified identity
 
Posts: 93
Joined: Mon Jun 16, 2014 4:45 am
PIC experience: Experienced Hobbyist

Re: Create an Ethernet project with MPLAB Harmony that works

Postby Elinux » Tue Sep 04, 2018 10:40 am

Hello,

I just tried the demos proposed by Harmony, present in tcpip_tcp_client and tcpip_tcp_server, I compiled the two and its march! but I loaded the client project to my PIC32 Ethernet Starter Kit and in fact, I do not know if it works, I executed both projects, server/client, being in the wireshark to view something but I do not see anything, then I tried on the cmd Windows to make arp -a to see the IP addresses present (I do not know that of my PIC32 ESK), to check if my hardware is present I left the RJ45 cable connected to my network (the same as my pc), then I removed the cable and I still have the same number of IP addresses, so I deduce that my card is not visible on my network !!

It is clear I am a newcomer in the world of PIC :oops: ! so help me by being as accurate as possible!

Thank you
Elinux
 
Posts: 15
Joined: Mon Sep 03, 2018 9:39 am
Location: France

Re: Create an Ethernet project with MPLAB Harmony that works

Postby AussieSusan » Wed Sep 05, 2018 3:33 am

Step back to the start and move forward from there.
You need to be able to compile some code - any code - cleanly. I suggest that you write a small app that (say) flashes a LED once a second. Get that to compile without errors and warnings first.
You will also need to set up the CONFIG settings and the oscillator to get the LED to flash at the right frequency. All of this is part of getting the very basic parts of an application to work.
The next step is to program the MCU, again without getting any error messages from the programmer.
When you compile a program, you can do a 'release' build or a 'debug' build.A 'release' build will start your code going immediately after a reset whereas a 'debug' build will interact with the debugger and let you step through the code, examine variables and the like.
At this point you will know how to properly compile your code, properly program the MCU and also how to debug he code which is useful to make sure that the code is running as expected.
When you apply the steps to your real application, you will be able to determine if the code is actually running and where any problems might be - no guessing involved.
PIC MCUs do tend to have a fairly steep initial learning curve but once you are over that, you can do just about anything.
Susan
AussieSusan
Verified identity
 
Posts: 93
Joined: Mon Jun 16, 2014 4:45 am
PIC experience: Experienced Hobbyist

Re: Create an Ethernet project with MPLAB Harmony that works

Postby Elinux » Thu Sep 06, 2018 2:36 pm

Hello, thank you for your answer,

I have already run programs to light up leds, and it works very well,
Now I just run the demo (berkeley_tcp_server.X) and make it build very well, then I created a client code on a Raspberry PI to try to get something from my PIC, but this one does not unfortunately receive nothing, here is the python code for the client (I'm sure my client code written with python works very well):

Code: Select all
import socket
import sys

def c():
    while 1:
        try:
           
            hote = '192.168.100.115'
            port = 9760
            Connection_PIC=socket.socket(socket.AF_INET, socket.SOCK_STREAM)
           Connection_PIC.connect((hote,port))
            print("Connection whith PIC in port {}\n".format(port))
            #------------------------------------------------------------------------------------
            msg_recu=Connection_PIC.recv(1024).decode('UTF-8')
            print(msg_recu)

        except:
            print('Connection ...')
c()


After running I do not get anything on this port, so I pinged the Windows cmd (ping 192.168.100.115) and sometimes the packets are all sent and received and sometimes some are lost!

Here is the code of the demo that can send something:

Code: Select all
/*******************************************************************************
  MPLAB Harmony Application Source File
 
  Company:
    Microchip Technology Inc.
 
  File Name:
    app.c

  Summary:
    This file contains the source code for the MPLAB Harmony application.

  Description:
    This file contains the source code for the MPLAB Harmony application.  It
    implements the logic of the application's state machine and it may call
    API routines of other MPLAB Harmony modules in the system, such as drivers,
    system services, and middleware.  However, it does not call any of the
    system interfaces (such as the "Initialize" and "Tasks" functions) of any of
    the modules in the system or make any assumptions about when those functions
    are called.  That is the responsibility of the configuration-specific system
    files.
 *******************************************************************************/

// DOM-IGNORE-BEGIN
/*******************************************************************************
Copyright (c) 2013-2014 released Microchip Technology Inc.  All rights reserved.

Microchip licenses to you the right to use, modify, copy and distribute
Software only when embedded on a Microchip microcontroller or digital signal
controller that is integrated into your product or third party product
(pursuant to the sublicense terms in the accompanying license agreement).

You should refer to the license agreement accompanying this Software for
additional information regarding your rights and obligations.

SOFTWARE AND DOCUMENTATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
 *******************************************************************************/
// DOM-IGNORE-END


// *****************************************************************************
// *****************************************************************************
// Section: Included Files
// *****************************************************************************
// *****************************************************************************

#include "app.h"

#include "tcpip/tcpip.h"

#include <errno.h>
#include <sys/errno.h>

#define SERVER_PORT 9760
// *****************************************************************************
// *****************************************************************************
// Section: Global Data Definitions
// *****************************************************************************
// *****************************************************************************

// *****************************************************************************
/* Application Data

  Summary:
    Holds application data

  Description:
    This structure holds the application's data.

  Remarks:
    This structure should be initialized by the APP_Initialize function.
   
    Application strings and buffers are be defined outside this structure.
 */

APP_DATA appData;


// *****************************************************************************
// *****************************************************************************
// Section: Application Callback Functions
// *****************************************************************************
// *****************************************************************************

/* TODO:  Add any necessary callback functions.
 */


// *****************************************************************************
// *****************************************************************************
// Section: Application Local Functions
// *****************************************************************************
// *****************************************************************************

/* TODO:  Add any necessary local functions.
 */


// *****************************************************************************
// *****************************************************************************
// Section: Application Initialization and State Machine Functions
// *****************************************************************************
// *****************************************************************************

/*******************************************************************************
  Function:
    void APP_Initialize ( void )

  Remarks:
    See prototype in app.h.
 */

void APP_Initialize(void) {
    /* Place the App state machine in its initial state. */
    appData.state = APP_TCPIP_WAIT_INIT;

    /* TODO: Initialize your application's state machine and other
     * parameters.
     */
}

/******************************************************************************
  Function:
    void APP_Tasks ( void )

  Remarks:
    See prototype in app.h.
 */

void APP_Tasks(void) {
    SYS_STATUS tcpipStat;
    const char *netName, *netBiosName;
    int i, nNets;
    TCPIP_NET_HANDLE netH;


    SYS_CMD_READY_TO_READ();
    switch (appData.state) {
        case APP_TCPIP_WAIT_INIT:
            tcpipStat = TCPIP_STACK_Status(sysObj.tcpip);
            if (tcpipStat < 0) { // some error occurred
                SYS_CONSOLE_MESSAGE(" APP: TCP/IP stack initialization failed!\r\n");
                appData.state = APP_TCPIP_ERROR;
            } else if (tcpipStat == SYS_STATUS_READY) {
                // now that the stack is ready we can check the
                // available interfaces
                nNets = TCPIP_STACK_NumberOfNetworksGet();

                for (i = 0; i < nNets; i++) {

                    netH = TCPIP_STACK_IndexToNet(i);
                    netName = TCPIP_STACK_NetNameGet(netH);
                    netBiosName = TCPIP_STACK_NetBIOSName(netH);

#if defined(TCPIP_STACK_USE_NBNS)
                    SYS_CONSOLE_PRINT("    Interface %s on host %s - NBNS enabled\r\n", netName, netBiosName);
#else
                    SYS_CONSOLE_PRINT("    Interface %s on host %s - NBNS disabled\r\n", netName, netBiosName);
#endif  // defined(TCPIP_STACK_USE_NBNS)

                }

                appData.state = APP_TCPIP_WAIT_FOR_IP;
            }

            break;

        case APP_TCPIP_WAIT_FOR_IP:
            nNets = TCPIP_STACK_NumberOfNetworksGet();
            for (i = 0; i < nNets; i++) {
                netH = TCPIP_STACK_IndexToNet(i);
                if (!TCPIP_STACK_NetIsReady(netH)) {
                    return; // interface not ready yet!
                }
                IPV4_ADDR           ipAddr;
                ipAddr.Val = TCPIP_STACK_NetAddress(netH);
                SYS_CONSOLE_MESSAGE(TCPIP_STACK_NetNameGet(netH));
                SYS_CONSOLE_MESSAGE(" IP Address: ");
                SYS_CONSOLE_PRINT("%d.%d.%d.%d \r\n", ipAddr.v[0], ipAddr.v[1], ipAddr.v[2], ipAddr.v[3]);
            }
            // all interfaces ready. Could start transactions!!!
            appData.state = APP_BSD_INIT;
            //... etc.
            break;
        case APP_BSD_INIT:
        {
            // Initialize all client socket handles so that we don't process
            // them in the BSD_OPERATION state
            for (i = 0; i < MAX_CLIENT; i++)
                appData.ClientSock[i] = INVALID_SOCKET;

            appData.state = APP_BSD_CREATE_SOCKET;

        }
            break;

        case APP_BSD_CREATE_SOCKET:
        {
            // Create a socket for this server to listen and accept connections on
            SOCKET tcpSkt = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP);
            if (tcpSkt == INVALID_SOCKET)
                return;
            appData.bsdServerSocket = (SOCKET) tcpSkt;

            appData.state = APP_BSD_BIND;
        }
            break;

        case APP_BSD_BIND:
        {
            // Bind socket to a local port
            struct sockaddr_in addr;
            int addrlen = sizeof (struct sockaddr_in);
            addr.sin_port = SERVER_PORT;
            addr.sin_addr.S_un.S_addr = IP_ADDR_ANY;
            if (bind(appData.bsdServerSocket, (struct sockaddr*) &addr, addrlen) == SOCKET_ERROR)
                return;

            appData.state = APP_BSD_LISTEN;
            // No break needed
        }
            break;

        case APP_BSD_LISTEN:
        {
            if (listen(appData.bsdServerSocket, MAX_CLIENT) == 0) {
                appData.state = APP_BSD_OPERATION;
                SYS_CONSOLE_PRINT("Waiting for Client Connection on port: %d\r\n", SERVER_PORT);
            }
        }
            break;
        case APP_BSD_OPERATION:
        {
            int length;
            struct sockaddr_in addRemote;
            int addrlen = sizeof (struct sockaddr_in);
            char rr['A'];

            for (i = 0; i < MAX_CLIENT; i++) {
                // Accept any pending connection requests, assuming we have a place to store the socket descriptor
                if (appData.ClientSock[i] == INVALID_SOCKET)
                    appData.ClientSock[i] = accept(appData.bsdServerSocket, (struct sockaddr*) &addRemote, &addrlen);

                // If this socket is not connected then no need to process anything
                if (appData.ClientSock[i] == INVALID_SOCKET)
                    continue;

                // For all connected sockets, receive and send back the data
                length = recv(appData.ClientSock[i], rr, sizeof (rr), 0);

                if (length > 0) {
                    rr[length] = '\0';
                    send(appData.ClientSock[i], rr, strlen(rr), 0);
                } else if (length == 0 || errno != EWOULDBLOCK) {
                    closesocket(appData.ClientSock[i]);
                    appData.ClientSock[i] = INVALID_SOCKET;
                }
                // else just wait for some more data
            }
        }
            break;
        default:
            break;
    }
}
/*******************************************************************************
 End of File
 */


:idea: Where there is the send! he sends the variable rr

:?: Why do not I see anything in Wireshark and why on the console of the execution of my client code of my Raspberry I do not visualize anything too?
Elinux
 
Posts: 15
Joined: Mon Sep 03, 2018 9:39 am
Location: France

Re: Create an Ethernet project with MPLAB Harmony that works

Postby AussieSusan » Fri Sep 07, 2018 3:27 am

You will need to use the debugger to see which code segments work and which are causing the problems.
For example, is the APP_Tasks function working through the various state changes correctly?
It is good that you have something that you know is working that will try to create a connection (or ping) so use that to see where the server code is not working.
Als0 use a scope to make sure that the signal from the Ethernet connector is getting passed to the MCU correctly.
Susan
AussieSusan
Verified identity
 
Posts: 93
Joined: Mon Jun 16, 2014 4:45 am
PIC experience: Experienced Hobbyist

Re: Create an Ethernet project with MPLAB Harmony that works

Postby Elinux » Fri Sep 07, 2018 9:42 am

The demo works very well:

Code: Select all
make -f nbproject/Makefile-pic32mx_eth_sk2.mk SUBPROJECTS= .build-conf
make[1]: Entering directory 'C:/microchip/harmony/v2_06/apps/tcpip/berkeley_tcp_server/firmware/berkeley_tcp_server.X'
make  -f nbproject/Makefile-pic32mx_eth_sk2.mk dist/pic32mx_eth_sk2/debug/berkeley_tcp_server.X.debug.elf
make[2]: Entering directory 'C:/microchip/harmony/v2_06/apps/tcpip/berkeley_tcp_server/firmware/berkeley_tcp_server.X'
"C:\Program Files\Microchip\xc32\v2.10\bin\xc32-gcc.exe" -g -D__DEBUG -DSKDEPIC32PlatformTool=1 -fframe-base-loclist -x c -c -mprocessor=32MX795F512L -ffunction-sections -O1 -I/system_config/pic32mx_eth_sk2 -I/crypto/src -I/crypto -I/driver/tmr -I/driver -I/system/clk -I/system/clk/src -I/system/common -I/system/devcon -I/system/int -I/system/ports -I/system/random -I/system/reset -I/system/tmr -I/system -I/tcpip -I/tcpip/src -I/driver/ethmac -I/driver/ethmac/src -I/driver/ethmac/src/dynamic -I/driver/ethphy -I/driver/ethphy/src -I/driver/ethphy/src/dynamic -I/tcpip/src/common -I/tcpip/src/system/drivers -I/system_config/pic32mx_eth_sk2/framework -I2 -I/pic32mx_eth_sk2 -I/system_config/pic32mx_eth_sk2/bsp -I/system_config/pic32mx_eth_sk2 -I/pic32mx_eth_sk2 -I/system_config/pic32mx_eth_sk2/framework -I/system_config/pic32mx_eth_sk2/bsp -I../src -I../src/system_config/pic32mx_eth_sk2 -I../src/pic32mx_eth_sk2 -I../../../../../framework -I../src/system_config/pic32mx_eth_sk2/framework -I../src/system_config/pic32mx_eth_sk2/bsp -Werror -Wall -MMD -MF build/pic32mx_eth_sk2/debug/_ext/1360937237/app.o.d -o build/pic32mx_eth_sk2/debug/_ext/1360937237/app.o ../src/app.c -DXPRJ_pic32mx_eth_sk2=pic32mx_eth_sk2 -no-legacy-libc
"C:\Program Files\Microchip\xc32\v2.10\bin\xc32-gcc.exe"  -g -mdebugger -DSKDEPIC32PlatformTool=1 -mprocessor=32MX795F512L  -o dist/pic32mx_eth_sk2/debug/berkeley_tcp_server.X.debug.elf build/pic32mx_eth_sk2/debug/_ext/29024758/misc.o build/pic32mx_eth_sk2/debug/_ext/1712127810/bsp.o build/pic32mx_eth_sk2/debug/_ext/1117026064/net_pres_enc_glue.o build/pic32mx_eth_sk2/debug/_ext/270127451/sys_clk_pic32mx.o build/pic32mx_eth_sk2/debug/_ext/1749535796/sys_devcon.o build/pic32mx_eth_sk2/debug/_ext/1749535796/sys_devcon_pic32mx.o build/pic32mx_eth_sk2/debug/_ext/907942421/sys_ports_static.o build/pic32mx_eth_sk2/debug/_ext/1798756562/sys_reset.o build/pic32mx_eth_sk2/debug/_ext/374686574/system_init.o build/pic32mx_eth_sk2/debug/_ext/374686574/system_interrupt.o build/pic32mx_eth_sk2/debug/_ext/374686574/system_exceptions.o build/pic32mx_eth_sk2/debug/_ext/374686574/system_tasks.o build/pic32mx_eth_sk2/debug/_ext/1360937237/app.o build/pic32mx_eth_sk2/debug/_ext/1360937237/main.o build/pic32mx_eth_sk2/debug/_ext/2046866571/adler32.o build/pic32mx_eth_sk2/debug/_ext/2046866571/compress.o build/pic32mx_eth_sk2/debug/_ext/2046866571/crc32.o build/pic32mx_eth_sk2/debug/_ext/2046866571/deflate.o build/pic32mx_eth_sk2/debug/_ext/2046866571/infback.o build/pic32mx_eth_sk2/debug/_ext/2046866571/inffast.o build/pic32mx_eth_sk2/debug/_ext/2046866571/inflate.o build/pic32mx_eth_sk2/debug/_ext/2046866571/inftrees.o build/pic32mx_eth_sk2/debug/_ext/2046866571/trees.o build/pic32mx_eth_sk2/debug/_ext/2046866571/uncompr.o build/pic32mx_eth_sk2/debug/_ext/2046866571/zutil.o build/pic32mx_eth_sk2/debug/_ext/29024758/ecc.o build/pic32mx_eth_sk2/debug/_ext/29024758/arc4.o build/pic32mx_eth_sk2/debug/_ext/29024758/pwdbased.o build/pic32mx_eth_sk2/debug/_ext/29024758/tfm.o build/pic32mx_eth_sk2/debug/_ext/29024758/asn.o build/pic32mx_eth_sk2/debug/_ext/29024758/des3.o build/pic32mx_eth_sk2/debug/_ext/29024758/rsa.o build/pic32mx_eth_sk2/debug/_ext/29024758/aes.o build/pic32mx_eth_sk2/debug/_ext/29024758/md5.o build/pic32mx_eth_sk2/debug/_ext/29024758/sha.o build/pic32mx_eth_sk2/debug/_ext/29024758/sha256.o build/pic32mx_eth_sk2/debug/_ext/29024758/sha512.o build/pic32mx_eth_sk2/debug/_ext/29024758/hmac.o build/pic32mx_eth_sk2/debug/_ext/29024758/hash.o build/pic32mx_eth_sk2/debug/_ext/29024758/compress.o build/pic32mx_eth_sk2/debug/_ext/29024758/random.o build/pic32mx_eth_sk2/debug/_ext/29024758/crypto.o build/pic32mx_eth_sk2/debug/_ext/29024758/coding.o build/pic32mx_eth_sk2/debug/_ext/29024758/error.o build/pic32mx_eth_sk2/debug/_ext/29024758/integer.o build/pic32mx_eth_sk2/debug/_ext/29024758/logging.o build/pic32mx_eth_sk2/debug/_ext/29024758/memory.o build/pic32mx_eth_sk2/debug/_ext/29024758/wc_port.o build/pic32mx_eth_sk2/debug/_ext/29024758/wolfmath.o build/pic32mx_eth_sk2/debug/_ext/1697634946/drv_ethmac.o build/pic32mx_eth_sk2/debug/_ext/1697634946/drv_ethmac_lib.o build/pic32mx_eth_sk2/debug/_ext/521481140/drv_ethphy.o build/pic32mx_eth_sk2/debug/_ext/521481140/drv_extphy_smsc8740.o build/pic32mx_eth_sk2/debug/_ext/1470245908/drv_miim.o build/pic32mx_eth_sk2/debug/_ext/941160041/drv_tmr.o build/pic32mx_eth_sk2/debug/_ext/831465284/drv_usbfs.o build/pic32mx_eth_sk2/debug/_ext/831465284/drv_usbfs_device.o build/pic32mx_eth_sk2/debug/_ext/871719959/net_pres.o build/pic32mx_eth_sk2/debug/_ext/1891376032/sys_command.o build/pic32mx_eth_sk2/debug/_ext/1434663852/sys_console.o build/pic32mx_eth_sk2/debug/_ext/1434663852/sys_console_usb_cdc.o build/pic32mx_eth_sk2/debug/_ext/2137108136/sys_debug.o build/pic32mx_eth_sk2/debug/_ext/1042686532/sys_int_pic32.o build/pic32mx_eth_sk2/debug/_ext/470001640/sys_random.o build/pic32mx_eth_sk2/debug/_ext/2110151058/sys_tmr.o build/pic32mx_eth_sk2/debug/_ext/1886247299/helpers.o build/pic32mx_eth_sk2/debug/_ext/1164207549/ipv4.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcp.o build/pic32mx_eth_sk2/debug/_ext/1164207549/udp.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_heap_alloc.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_heap_internal.o build/pic32mx_eth_sk2/debug/_ext/1164207549/arp.o build/pic32mx_eth_sk2/debug/_ext/1164207549/berkeley_api.o build/pic32mx_eth_sk2/debug/_ext/1164207549/dhcp.o build/pic32mx_eth_sk2/debug/_ext/1164207549/dns.o build/pic32mx_eth_sk2/debug/_ext/1164207549/nbns.o build/pic32mx_eth_sk2/debug/_ext/1164207549/zero_conf_helper.o build/pic32mx_eth_sk2/debug/_ext/1164207549/zero_conf_link_local.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_announce.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_commands.o build/pic32mx_eth_sk2/debug/_ext/1164207549/hash_fnv.o build/pic32mx_eth_sk2/debug/_ext/1164207549/oahash.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_helpers.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_helper_c32.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_manager.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_notify.o build/pic32mx_eth_sk2/debug/_ext/1164207549/tcpip_packet.o build/pic32mx_eth_sk2/debug/_ext/2136608937/usb_device.o build/pic32mx_eth_sk2/debug/_ext/2136608937/usb_device_cdc.o build/pic32mx_eth_sk2/debug/_ext/2136608937/usb_device_cdc_acm.o    ..\..\..\..\..\bin\framework\peripheral\PIC32MX795F512L_peripherals.a      -DXPRJ_pic32mx_eth_sk2=pic32mx_eth_sk2  -no-legacy-libc        -Wl,--defsym=__MPLAB_BUILD=1,--defsym=__MPLAB_DEBUG=1,--defsym=__DEBUG=1,-D=__DEBUG_D,--defsym=SKDEPIC32PlatformTool=1,--defsym=_min_heap_size=44960,--gc-sections,--no-code-in-dinit,--no-dinit-in-serial-mem,-Map="dist/pic32mx_eth_sk2/debug/berkeley_tcp_server.X.debug.map",--memorysummary,dist/pic32mx_eth_sk2/debug/memoryfile.xml
make[2]: Leaving directory 'C:/microchip/harmony/v2_06/apps/tcpip/berkeley_tcp_server/firmware/berkeley_tcp_server.X'
make[1]: Leaving directory 'C:/microchip/harmony/v2_06/apps/tcpip/berkeley_tcp_server/firmware/berkeley_tcp_server.X'

BUILD SUCCESSFUL (total time: 37s)
Loading symbols from C:/microchip/harmony/v2_06/apps/tcpip/berkeley_tcp_server/firmware/berkeley_tcp_server.X/dist/pic32mx_eth_sk2/debug/berkeley_tcp_server.X.debug.elf...
Loading code from C:/microchip/harmony/v2_06/apps/tcpip/berkeley_tcp_server/firmware/berkeley_tcp_server.X/dist/pic32mx_eth_sk2/debug/berkeley_tcp_server.X.debug.elf...
Loading completed


:!: Me the problem is that with the Wireshark I do not visualize anything! there is nothing sent or received!

As for the debugger, it shows me nothing
Debugger Console:
Code: Select all
Launching
Programming target
User program running
Elinux
 
Posts: 15
Joined: Mon Sep 03, 2018 9:39 am
Location: France

Re: Create an Ethernet project with MPLAB Harmony that works

Postby Roche » Fri Sep 07, 2018 2:02 pm

Have you got wireshark on the same network segment as the device(s) you are trying to monitor - you must use either a hub or a mirrored port for connection...
Roche
 
Posts: 30
Joined: Fri Jul 11, 2014 12:35 pm
PIC experience: Professional 5+ years with MCHP products

Re: Create an Ethernet project with MPLAB Harmony that works

Postby Elinux » Fri Sep 07, 2018 2:07 pm

Hello,

Yes I am on the same local network as my Raspberry Pi, my PC and my PIC32 Ethernet Starter Kit, and I connect to the same port
Elinux
 
Posts: 15
Joined: Mon Sep 03, 2018 9:39 am
Location: France

Re: Create an Ethernet project with MPLAB Harmony that works

Postby Roche » Fri Sep 07, 2018 2:12 pm

how do you connect the three?
Roche
 
Posts: 30
Joined: Fri Jul 11, 2014 12:35 pm
PIC experience: Professional 5+ years with MCHP products

Next

Return to PIC32 topics

Who is online

Users browsing this forum: No registered users and 3 guests