This document has links to videos to give tutorials on how to getting started *from scratch* with the freedom board. In these tutorials we build projects with bare metal code to see how things work! It includes the basics on how to get clocks running, lights blinking and interrupts firing *from scratch*. For more code/peripheral examples that use a "bare metal" approach, check out the page on the FRDM-TFC board.
ERRATA!!!
While working with a large number of Freedom boards in a course, it was observed that the InitClockRoutines would *sometimes* not work. *Some* of the crystals on the freedom boards do NOT like "HIGH_GAIN" mode. The new code is uploaded to this page but you could also change the code yourself:
This is Great !! Many, many Thanks to eli_hughes for creating a tutorial page for this platform.
I think it is a great Idea , as many new comers to arm will have a jump start in development, + it is a value ad-don as your code is not generated automatically, so you really have to dig to learn . :smileyhappy:
.
-->>Can you please add some videos on life cycle of the code from compilation to execution , and
-->>It will be a huge help if you can add a video on how to create a bare bone project using gcc tool-chain with eclipse, as Code Warrior uses Open-Source GCC. :smileyhappy:
I got this the other day and couldn't get it work with processor expert. This cleared out a lot of things for me :smileyhappy:. It's exactly what I was searching for.
Wating for the virtual COM port tutorial :smileygrin:
Thanks so much for all the time it must have taken to put this material together!
One question about clock distribution -
In theory, I understand why your change to pll_init()'s vdiv from 24 to 4 would slow down the LED blink rate. However, I wasn't able to get the example to work. I added a breakpoint to that line and found that it was returning 0x42, which according to the README is the following error:
0x42 - VDIV outside allowed range
I looked into mcg.c and noticed that its error checking is actually quite strict, ensuring that vdiv_val is between 24 and 50. In the end, I couldn't really get any values other than 48MHz to work, with all the checks it does. What am I doing wrong that you're doing right?
I am in the process of re-doing these videos to be CMSIS compatible. I'll take a look when A get a moment. For now you will just have to use at 48MHz. Not sure what I did different in that video.
Thanks a lot for those tutorial. they are very useful since I started to play with the "Kinetis Design Studio" with "KSDK_1.3.0", and I develop a prototype with the "MKL34Z64VLL4" Kinetis MCU. it is a 100pin MCU and I populated with around 12 LEDS on some GPIO, I use a similar structure as the tutorial "Using the Freescale Header Files and Blinking the LED", and it is very similar, the only difference is that my code looks a little bigger, and instead of playing with two LEDS I am playing with 12 LEDs. Well my program compiles without errors or warnings, but once my program goes once pass on the main loop, it got stock for some reason while debugging, and when I paused it, I noticed that the program get stocked on the following lines:
DefaultISR:
ldr r0, =DefaultISR
bx r0
Those lines belong to the "startup_MKL34Z4.s" file, and I don't have any clue how to fix it, could you help me please?.
that is the default interrupt handler that gets populated in the IRQ table. Did you enable an interrupt for something? Please post your project if you can.
Sorry for this delayed reply, I found the issue to what i was asking you before. The issue what that I was enabling the same PORT where the NMI pin is, so this pin was left floating and some cross-talking voltage was generating some kind of interruption, once I assign a GPIO function to the NMI pin the problem went away. But Thanks a lot for your help