AnsweredAssumed Answered

How to fix these errors in my code ?

Question asked by Ganesh Ramachandran on Apr 18, 2016
Latest reply on Apr 22, 2016 by Alice_Yang

I am using

Hardware: MKE02Z64VLD2

IDE: Kinetis Design Studio 2.0.

BL_SW: PTB1

When I "Build" the code, I got following errors.

1. Error in the Flash Declaration

Flash Error.jpg

           IT SAYS THAT THE IntFlashLdd1_ERASABLE_UNIT_SIZE IS UNDECLARED           

Flash Config.jpg

     IN ORDER TO FIX THE ERROR SHOULD I ENABLE OR DISABLE ANY FEATURES INSIDE THE FLASH COMPONENT ?    

(if the pic is not clear) As of now the Enabled features are,

  1. IntFlashLdd1:FLASH_LDD
  2. EraseSector
  3. SetByteFlash
  4. GetByteFlash
  5. SetWordFlash
  6. SetBlockFlash
  7. IFsh1_OnWriteEnd

1.How to fix this Error pertaining to Flash Declaration ??

 

2. Errors in Clocking and Enabling Pull Up

CLock and PUll up enable errors.jpg

                              SAME UNDECLARED ERRORS HERE TOO                               

SIM_SCGC5.... SYNTAX  does not support KINETIS E CONTROLLERS I guess. So I asked in this same forum and got this reply.

Clocking Port Pins in KE-02Z Controllers

2.a. From the answer, if clocking is done automatically after reset, then can I simply delete that code and start over with

/*Configure Pin as Input */

?????

2.b. The next problem is with enabling the Pull Up. I guess there should be different syntax for Kinetis E series Controller.

These are the Components inside my PDD --> Port, in my Processor Expert.

Port Config.jpg

So to fix those errors in 2 statements pertaining to Pull up, which 2 statements are to be selected ?

PORT_PDD_SetPinPullSelect(PORTB_BASE_PTR, 1, PORT_PDD_PULL_UP);
PORT_PDD_SetPinPullEnable(PORTB_BASE_PTR, 1, PORT_PDD_PULL_ENABLE);

What are the alternative statements fixing my problem ?

I request you to please answer my 1, 2.a, 2.b queries.

I repeat the queries alone..

1.How to fix this Error pertaining to Flash Declaration ??

 

2.a. From the answer, if clocking is done automatically after reset, then can I simply delete that code and start over with  /*Configure Pin as Input */  ?????

2.b. The next problem is with enabling the Pull Up. I guess there should be different syntax for Kinetis E series Controller. So to fix those errors in 2 statements pertaining to Pull up, which 2 statements are to be selected ?

Outcomes