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.

TMS320F28379D: GPIO pin setting in Ethercat reference design code

Part Number: TMS320F28379D
Other Parts Discussed in Thread: CONTROLSUITE

Hi

TI reference design for ET1100+TMS320F2837x ethercat solution as below.

http://www.ti.com/tool/TIDM-DELFINO-ETHERCAT?keyMatch=ETHERCAT&tisearch=Search--Everything

current demo code uses EMIF2 to work with ET1100,

the pin connection map is as blow, GPIO136 interrupt is configured in code, but theGPIO93,GPIO94,GPIO89,GPIO90 has no initialization code in the demo

code, i want to know why we don't need to do set these pins when these MCU pins has connection with ET1100.

//function for EMIF2 GPIO pin setup
void setup_emif2_pinmux_async_16bit(Uint16 cpu_sel)
{
Uint16 i;

for (i=96; i<=121;i++)
{
GPIO_SetupPinMux(i,cpu_sel,3);
}

for (i=53; i<=68;i++)
{
GPIO_SetupPinMux(i,cpu_sel,3);
}

//setup async mode for Data pins
for (i=53; i<=68;i++)
{
GPIO_SetupPinOptions(i,0,0x31);
}
}

  

  • Hardy,

    GPIO136 (IRQ), GPIO89, GPIO90 are needed/used when stack is running on the C28. Please refer the SW collateral with TMDSECATCNCD379D EtherCAT kit in controlSuite (C:\ti\controlSUITE\development_kits\TMDSECATCND379D_V1.0) and you will see the HAL initializing these IOs or providing functions to initialize this IOs.

    Also as mentioned in SPRUIF9 in the controlSuite docs in same folder as above GPIO93 an GPIO94 are for future address expansion, the example as it is doesn't use this. But user can set the GPIO94 or GPIO94 High/LOW depending on the address address bits 14 and 15 of the address that is being accessed because these pins doesn't have native EMIF address bits function in the pin mux. Again this is a restriction because the TI Design uses EMIF2.

    The above is mentioned in the TI Design document section 1.4.1 as well, www.ti.com/.../tidubq6a.pdf.


    Hope this helps.

    Best Regards
    Santosh Athuru
  • Hi

    The code is modified from TI's reference code, TI's reference code uses EMIF2, i want to use EMIF1 following hardware design.

    the code and pin assignment is as below link.

    /cfs-file/__key/communityserver-discussions-components-files/171/sw_5F00_v1.rar

    main pin assignments are as below

    EEPROM LOAD  GPIO33

    CS2                       GPIO34

    INT                         GPIO35

    SYNC0                  GPIO86

    SYNC1                  GPIO87

    A[14]                       GPIO88

    A[15]                       GPIO89

    but the we can run this code to configure the ET1100, pls help check if any problem for the setting.

    Thanks.

  • Hardy,
    I will not be able to verify the entire pin mapping for user. We have provided the HAL API Test SW that will work seamless if the HW mapping is correct and there are resources in form of pin mux table in data sheet for user to come up with the pin mapping for application.

    You wouldn't need A14 and A15 with ET1100 , the provided reference SW has EMIF1 initialization functions as well, please update it for the GPIO mappings you have on HW.

    Please let me know if there is any other specific question.

    Best Regards
    Santosh Athuru
  • Hi

      Thanks for your reply.

       I will double check with GPIO setting, and pls help confirm if the EMIF1 interface code to access ET110 can be verified ok in your side.  

  • Hardy,

    Probably the TI Design SW can help you first. Are you using ControlCard or Launchpad or custom board with MCU?

    once you scroll all the way down on the page www.ti.com/.../TIDM-DELFINO-ETHERCAT to Software title, you should be able to download a zip file (www.ti.com/.../tidcc35) that has a CCS project that implements PDI HAL layer to interface F2837xD MCU with ET1100 using EMIF or SPI.

    You can import the CCS project in sw\pdi_hal_test_app folder and build and run/explore. One of the build options here is LaunchPAD + EMIF1. Check that configuration and functions, once you align the SW with the HW for the GPIOs used in HW you should have communication with ET1100 using EMIF1 on F2837x.


    Alternatively, You can stick to the Collateral provided with TMDSECATCNCD379D Kit. The PDI HAL API Test APP and other CCS projects provided can be modified to enable the EMIF1 usage. You will have to choose one of the *_CCARD_EMIF_* build configurations for the project and go enable USE_EMIF1 F2837xD_device.h (line 67) that is included in the project. This will pull in the EMIF1 init functions and you still have to verify the GPIOs that this function initializes is same as you have in HW.

    We have verified in factory that EMIF1 can be used to interface to ET1100 and we do have atleast one more forum user that we know did what you are trying to do and was able to get EMIF1 working with ET1100.

    Hope this helps.

    Best REgards
    Santosh Athuru