propeller c clock speed
Rontopia
Posts: 139
I bought a propeller education kit some time ago. this was when spin was all there was. I had so many projects that years have passed and I never did master spin. I just bought a activity bot and am learning propeller c but I am unable to find how to set the propellers clock speed. if I remember right in spin you the default was 5mhz unless you specified a higher clock up to 80mhz.
there must be a way to do the same thing in c?
thanks
Comments
Tom
It never seemed strange to me to put clkfreq at location 0 in Spin (I learned Spin before C), but it just doesn't seem right to get the current clock frequency in C by dereferencing a NULL pointer.
The loader will be told to which type of board you want to upload the code and while uploading will put in the board specific details like which crystal mode and speed is used and which multiplier and where to find a SD card (if available) and whatever else the configuration file for that board tells him.
Search the folder of your propeller-gcc and then the subfolder with the loader's board descriptions (/opt/parallax/propeller-load on my systems, I use only C, not the IDE...).
Digging through https://github.com/parallaxinc/propgcc/tree/master/loader may help too...
And if I have written too much trash now, the propgcc authorities will correct me... ;-D
sorry it took me so long to reply. I'm swamped at work.
thanks for the info.
wait.. are you saying that the clk freq is automatically set to 80mhz? unless I use propeller.h and set the freq to some other value?
It would be nice if board configuration files could be created and edited within SimpleIDE itself. That would be a nice future enhancement.