AnsweredAssumed Answered

How to use lpc54608 SDK

Question asked by Rob Jansen on Feb 24, 2017
Latest reply on Mar 1, 2017 by Rob Jansen

(moved here from LPCXpresso forum)

 

I created and downloaded an SDK for the lpc54608 using the MCUXpresso (see Welcome to MCUXpresso | MCUXpresso Config Tools ) and got it to work with LPCXpresso.

 

This means I can now create/download and debug code on my LPCXpresso54608 board and one of the first things I tried is a simple blinky using the systick but I had a little problem getting the GPIO port to work.

 

I used the fsl_gpio driver provided, the GPIO port was configured using:

 

#define USER_LED_1_PORT  3
#define USER_LED_1_PIN  14

 

    /* Define the init structure for the output LED pin*/
    gpio_pin_config_t led_config = {
        kGPIO_DigitalOutput, 0,

    };

    /* Init output LED GPIO. */

    GPIO_PinInit(GPIO, USER_LED_1_PORT, USER_LED_1_PIN, &led_config);
    GPIO_WritePinOutput(GPIO, USER_LED_1_PORT, USER_LED_1_PIN, 0);

and GPIO_WritePinOutput was used in the SysTick_Handler to toggle the GPIO pin.

 

Unfortunately this did not work. SYSCON->AHBCLKCTRL[0] |= (1<<17) needs to be added in order to enable the clock to GPIO3.

The lpc54608 user manual clearly mentions this in the "Basic configuration" chapter but I cound not find this in the SDK documentation. After browsing through the examples I noticed there is a non-documented CLOCK_EnableClock() function to do this. The example in the SDK documentation does not use this function but does contain a reference to a Board_InitHardware() function that is not documented.

 

So currently I need the SDK documentation, example programs and the user manual to get even basic functions to work.

I think that enabling/disabling clocks for a peripheral should be part of the driver. If not, any additional initialization that needs to be done before using a peripheral should be clearly documented.

 

How mature will the SDK be? Is it supposed to be usable for (commercial) projects, do we have any influence on the content for the different drivers? Is there, or will there be, a bug report system to log problems like this and get them solved in a new release?

 

Regards,

Rob

 

Outcomes