How to start developing for Kl27Z

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to start developing for Kl27Z

1,349件の閲覧回数
dumr666
Contributor I

Hello,

I just recived my KL27Z board, and now I am totally lost. I tried blue led blink example from offical webpage, under tab Getting started and project won't compile because kPORT_MuxAsGpio is not defined. In other words, I was searching internet on how to acutally start, how load programs how to debug, how is everything executed, where to upload programs, what is difference, what is bootloader, how to toggle pins, which register is which. I have examples but they don't provide any help if they don't work from start or I can't actually chech if it working. Any help will be much appreciated. Also, I don't know which COM port to choose in Putty, I am using linux and Kinetis Design Studio

that is blink code that doesn't work

#include "fsl_device_registers.h"
#include "fsl_debug_console.h"
#include "board.h"
#include "pin_mux.h"
#include "clock_config.h"

int main(void) {

volatile uint32_t delay;

BOARD_InitPins();
BOARD_BootClockRUN();
BOARD_InitDebugConsole();

PRINTF("myProject project\n\r");

// Enable the clock to the PORT module that the LED is on.
CLOCK_EnableClock(kCLOCK_PortA);

// Set the PORT configuration - from DISABLED -> GPIO.
PORT_SetPinMux(BOARD_LED_BLUE_GPIO_PORT, BOARD_LED_BLUE_GPIO_PIN, kPORT_MuxAsGpio);

// Initialize the blue LED.
LED_BLUE_INIT(LOGIC_LED_OFF);

for (;;)
{
LED_BLUE_TOGGLE();

delay = 5000000;
while(delay--);

}
}

thank you

2 返答(返信)

1,162件の閲覧回数
dumr666
Contributor I

thank you very much, this has been very helpfull, I am programming industrial robots and normally everything is quite straight forward, now I am having a bit more time because winter is coming. Now off I go, chasing registers :smileyhappy:

0 件の賞賛
返信

1,162件の閲覧回数
mjbcswitzerland
Specialist V
0 件の賞賛
返信