Initialization for nut4nt+

About GNSS boards with NTLab's nt1065 chip, SE4150 and ad9361
amungo coder
Posts: 22
Joined: Tue Sep 06, 2016 5:37 am

Initialization for nut4nt+

Postby amungo coder » Fri Sep 15, 2017 3:07 am

Hello!

Some help for nut4nt+ cypress fw

  1. There are some defines.

    Code: Select all

    #define NT1065EN  (17)  /* GPIO17, CTL[0] */
    #define VCTCXOEN  (19)  /* GPIO19, CTL[2] */
    #define ANTLNAEN  (50)  /* GPIO50 */
    #define ANTFEEDEN (18)  /* GPIO18, CTL[1] */

    #define SPI_CLK   (17)  /* SPI CLOCK signal, GPIO17, CTL[0] */
    #define SPI_MOSI  (18)  /* SPI data OUT line,   GPIO18, CTL[1] */
    #define SPI_MISO  (24)  /* SPI data IN line, GPIO24, CTL[7] */
    #define SPI_SS0   (20)  /* SPI Slave select for AD9269, GPIO20, CTL[3] */
    #define SE4150EN  (22)  /* receiver enable CTRL[5], GPIO22 */
    #define AD9361RST (24)  /* SPI data IN line, GPIO24, CTL[7] */
    #define SPI_SS1   ( 0)  /* SPI Slave select for other device */


  2. Init GPIO module.

    Code: Select all

    CyU3PGpioClock_t gpioClock;

    gpioClock.fastClkDiv = 2;
    gpioClock.slowClkDiv = 0;
    gpioClock.simpleDiv  = CY_U3P_GPIO_SIMPLE_DIV_BY_2;
    gpioClock.clkSrc     = CY_U3P_SYS_CLK;
    gpioClock.halfDiv    = 0;

    CyU3PGpioInit( &gpioClock, NULL );

  3. Override some IOs as a GPIO.

    Code: Select all

    CyU3PDeviceGpioOverride( SE4150EN,  CyTrue );
    CyU3PDeviceGpioOverride( AD9361RST, CyTrue );
    CyU3PDeviceGpioOverride( NT1065EN,  CyTrue );
    CyU3PDeviceGpioOverride( VCTCXOEN,  CyTrue );
    CyU3PDeviceGpioOverride( ANTFEEDEN, CyTrue );
    CyU3PDeviceGpioOverride( ANTLNAEN,  CyTrue );

  4. Configure a simple GPIOs.

    Code: Select all

    CyU3PGpioSimpleConfig_t gpioConfig;

    gpioConfig.outValue    = CyTrue;
    gpioConfig.driveLowEn  = CyTrue;
    gpioConfig.driveHighEn = CyTrue;
    gpioConfig.inputEn     = CyFalse;
    gpioConfig.intrMode    = CY_U3P_GPIO_NO_INTR;

    CyU3PGpioSetSimpleConfig( SE4150EN,  &gpioConfig );
    CyU3PGpioSetSimpleConfig( NT1065EN,  &gpioConfig );
    CyU3PGpioSetSimpleConfig( VCTCXOEN,  &gpioConfig );
    CyU3PGpioSetSimpleConfig( ANTFEEDEN, &gpioConfig );
    CyU3PGpioSetSimpleConfig( ANTLNAEN,  &gpioConfig );
    CyU3PGpioSetSimpleConfig( AD9361RST, &gpioConfig );

  5. Update the states of a GPIO outputs.

    Code: Select all

    CyU3PGpioSetValue( SE4150EN,  CyTrue  );
    CyU3PGpioSetValue( AD9361RST, CyFalse );

    CyU3PThreadSleep( 1 ); // Hm..

    CyU3PGpioSetValue( AD9361RST, CyTrue );
    CyU3PGpioSetValue( ANTLNAEN,  CyTrue );
    CyU3PGpioSetValue( NT1065EN,  CyTrue );
    CyU3PGpioSetValue( VCTCXOEN,  CyTrue );
    CyU3PGpioSetValue( ANTFEEDEN, CyTrue );
Best regards,

Viktor
Amungo Navigation

amungo coder
Posts: 22
Joined: Tue Sep 06, 2016 5:37 am

Re: Initialization for nut4nt+

Postby amungo coder » Fri Sep 15, 2017 3:14 am

Not sure that all of GPIO are really usefull :roll:
But these four are!

Code: Select all

#define NT1065EN  (17)  /* GPIO17, CTL[0] */
#define VCTCXOEN  (19)  /* GPIO19, CTL[2] */
#define ANTLNAEN  (50)  /* GPIO50 */
#define ANTFEEDEN (18)  /* GPIO18, CTL[1] */
Best regards,

Viktor
Amungo Navigation


Return to “Boards: nut4nt, nut4se, nut2ad”

Who is online

Users browsing this forum: No registered users and 1 guest