Is there any demo projects for Kwikstik for SD card?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Is there any demo projects for Kwikstik for SD card?

891 Views
Amit_Kumar1
Senior Contributor II

Hi

I have made a code for SD card for KwikStik. Using FatFS and SDHC components of processor expert But it is not working. I have successfully tested similar code for SD card using SPI protocol with K20 uc it is working fine. I Just wanted any demo code for SD card to test if all the syntax I have written is correct. I am attaching my code. Kindly have a look and resolve the issue.

 

Thanks and Regards

Amit Kumar

Original Attachment has been moved to: k40sdhc1.zip

Tags (4)
0 Kudos
6 Replies

487 Views
Amit_Kumar1
Senior Contributor II

Hi

I had a look at the schematic  and I enabled the PTE6 by clearing the value, 3.3V is coming on TP59 (Vcc for SD card) but still the issue is not resolved. I am still unable to create any file in SD card. I probed TP60(SDHC0_DCLK) to CRO, there was no pulse.

pastedImage_0.png

0 Kudos

487 Views
mjbcswitzerland
Specialist V

Hi

If you would like to check your hardware you can download an SD card boot loader for the KWIKSTIK V5 here:

http://www.utasker.com/SW_Demos.html#K40

This will display the state on the SD card on your board on its LCD display so that you can detect whether it is not seeing it, it is not formatted, etc. The display images are detailed on page 23 of http://www.utasker.com/docs/uTasker/uTaskerSerialLoader.PDF

The SW can be loaded to the board using CW's flash utility. If the SD card is being detected you can put the file "software_1.4.003" onto it in the root directory and rename it to "software.bin" and then it will be loaded to the K40 and executed (this displays a clock in the LCD). If this works it will verify that the problem is not due to a local HW issue.

Regards

Mark

0 Kudos

487 Views
Amit_Kumar1
Senior Contributor II

Hi

Whenever I am trying to debug any program then following error is showing. i.e it is going in CPU interrupt. Any simple code is also not working. I am using Segger J link for programing. Please look into the matter 

pastedImage_2.png

Thanks and Regards

Amit Kumar

0 Kudos

487 Views
Amit_Kumar1
Senior Contributor II

I didn't know what was the issue but I created a new project in which I selected PK40X256 processor and Freescale compiler instead of GCC compiler, now pin toggle code is working and in debug mode the cpu is not going to interrupt but in the SD card nothing is still happening.

0 Kudos

487 Views
mjbcswitzerland
Specialist V

Hi

Please check which revision Kwikstik you have since revisions 3 and 4 have the SDHC incorrectly connected. I think that you need revision 5 for it to be correct.
http://cache.freescale.com/files/32bit/doc/errata/KWIKSTIKK40HWER.pdf?fpsp=1&WT_TYPE=Errata&WT_VENDO...

If you have an older one you can still use SPI mode.

Regards

Mark

487 Views
Amit_Kumar1
Senior Contributor II

Hi Mark

Thanks for replying I have checked the hardware It is version 5 and also went through the errata for rev 5 over there they have mentioned that SDHC has been corrected. But I don't know if there is still the issue.

Thanks and Regards

Amit Kumar

0 Kudos