Wisconsin
Offline
God Member
Karma: 4
Posts: 994
I LOVE THIS STUFF!!!!
|
 |
« Reply #15 on: January 31, 2012, 03:27:58 pm » |
so say I wanted to include tlc_fades.h from the TLC5940 Library from the arduino platform, I could just boom boom copy paste?
|
|
|
|
|
Logged
|
Accelerate to 88 miles per hour.
|
|
|
|
Gosport, UK
Offline
Faraday Member
Karma: 19
Posts: 3118
|
 |
« Reply #16 on: January 31, 2012, 03:45:43 pm » |
You could try, but I doubt it would work. The line ... #include <avr/interrupt.h>
certainly wouldn't work. I don't understand why you are asking Arduino users how to port a library to another architecture. You should be asking other MSP430 users if they have a library that does what you want.
|
|
|
|
|
Logged
|
|
|
|
|
Wisconsin
Offline
God Member
Karma: 4
Posts: 994
I LOVE THIS STUFF!!!!
|
 |
« Reply #17 on: January 31, 2012, 04:12:00 pm » |
Well the code is written for the arduino. Was thinking that maybe i could get something out of asking people here because they would understand how the library is written and why its written that so that i could decipher the arduino library and maybe be able to piece together what i need for the other platform b/c i don't know what the library for the arduino consists of right now.
|
|
|
|
|
Logged
|
Accelerate to 88 miles per hour.
|
|
|
|
Global Moderator
UK
Offline
Brattain Member
Karma: 137
Posts: 19006
I don't think you connected the grounds, Dave.
|
 |
« Reply #18 on: January 31, 2012, 04:15:05 pm » |
i don't know what the library for the arduino consists of right now. But you have the source
|
|
|
|
|
Logged
|
Pete, it's a fool looks for logic in the chambers of the human heart.
|
|
|
|
Wisconsin
Offline
God Member
Karma: 4
Posts: 994
I LOVE THIS STUFF!!!!
|
 |
« Reply #19 on: January 31, 2012, 04:17:53 pm » |
I have it but I don't understand it.
I don't get what all the #'s are for What does #endif mean?
Is there a webpage that explains it all?
|
|
|
|
|
Logged
|
Accelerate to 88 miles per hour.
|
|
|
|
Global Moderator
UK
Offline
Brattain Member
Karma: 137
Posts: 19006
I don't think you connected the grounds, Dave.
|
 |
« Reply #20 on: January 31, 2012, 04:21:07 pm » |
If you don't understand basic preprocessor constructs, there is very little chance of you translating or porting these libraries. Get hold of a copy of K&R.
|
|
|
|
|
Logged
|
Pete, it's a fool looks for logic in the chambers of the human heart.
|
|
|
|
0
Offline
God Member
Karma: 0
Posts: 596
Arduino rocks
|
 |
« Reply #21 on: January 31, 2012, 04:23:09 pm » |
Is there a webpage that explains it all? The title would be "C language in a web page". Not likely...
|
|
|
|
|
Logged
|
|
|
|
|
Global Moderator
Melbourne, Australia
Offline
Shannon Member
Karma: 218
Posts: 13896
Lua rocks!
|
 |
« Reply #22 on: January 31, 2012, 04:41:59 pm » |
Google "TLC5940 MSP430". There are about 4000 matches. Follow them. OOOOhhhkay so they have already done the conversion work it just doesn't seem to be in as nice a package as the library for the arduino. I'm not sure what your motivation here is, apart from boredom maybe. The MSP430 isn't a lot cheaper than the Atmega, for the simple reason that the Atmega itself only costs around $5 (and that is in single units of one of their more powerful processors). So the most you could save is $5. The Atmega can run with very low power consumption, less than a battery loses a day anyway due to self-discharge. And you admit that the Arduino has a "nice" package. What does #endif mean? You don't seem to be all that familiar with C programming. So why do you want to do this? Is this a school project? Has the teacher told you to do it?
|
|
|
|
|
Logged
|
|
|
|
|
Leighton Buzzard, UK
Offline
Edison Member
Karma: 11
Posts: 1049
|
 |
« Reply #23 on: January 31, 2012, 04:46:25 pm » |
is there the distinct whiff of troll around these parts?
been following the thread and it do seem so to me!
|
|
|
|
|
Logged
|
there are only 10 types of people them that understands binary and them that doesn't
|
|
|
|
Global Moderator
Melbourne, Australia
Offline
Shannon Member
Karma: 218
Posts: 13896
Lua rocks!
|
 |
« Reply #24 on: January 31, 2012, 05:03:05 pm » |
/agree
|
|
|
|
|
Logged
|
|
|
|
|
Wisconsin
Offline
God Member
Karma: 4
Posts: 994
I LOVE THIS STUFF!!!!
|
 |
« Reply #25 on: January 31, 2012, 07:51:50 pm » |
No i'm not trolling at all.
I'm a beginner to standalone microcontrollers and the launchpad was very friendly to beginners like me to microcontrollers. I am not familiar with C, you are right. My motivation is to make something sweet just like everybody else, but that shouldn't matter. I'm here cause i need help.
|
|
|
|
|
Logged
|
Accelerate to 88 miles per hour.
|
|
|
|
Global Moderator
Melbourne, Australia
Offline
Shannon Member
Karma: 218
Posts: 13896
Lua rocks!
|
 |
« Reply #26 on: January 31, 2012, 08:05:17 pm » |
OK, great. We are all trying to help here.
But what I don't get is, you have a MSP430 launchpad, and you want to interface it to TLC5940, right?
Well why ask on the Arduino forum? That's like asking on an Apple web site how to get Windows to work.
We don't know the answer, and the people on the MSP430 forum probably will.
As for "how do I convert the Arduino libraries?", well I wouldn't personally want to convert them all to another platform. You would need very in-depth knowledge of how the Atmega works (at the hardware level) to understand a lot of what the libraries are doing, and also in-depth knowledge of how the MSP430 works as well.
|
|
|
|
|
Logged
|
|
|
|
|
SF Bay Area (USA)
Offline
Faraday Member
Karma: 78
Posts: 5453
Strongly opinionated, but not official!
|
 |
« Reply #27 on: January 31, 2012, 08:07:50 pm » |
A couple of people (including myself) have done "some" work in porting the Arduino libraries to MSP430, back when there was so much excitement about the $5 LaunchPad that you could get (eventually.) It turns out to be pretty difficult to get very far, because you run into serious limitations very quickly (The original Launchpad has 1/16th the memory of an Uno and is only capable of one hardware PWM output.)
Still, I created a deeply philosophical and wildly entertaining set of blog posts on the subject that I'm sure you'll find fascinating: http://www.element14.com/community/people/WestfW/blog :-;
|
|
|
|
« Last Edit: January 31, 2012, 11:45:21 pm by westfw »
|
Logged
|
|
|
|
|
Wisconsin
Offline
God Member
Karma: 4
Posts: 994
I LOVE THIS STUFF!!!!
|
 |
« Reply #28 on: January 31, 2012, 10:00:03 pm » |
Well it isnt that complicated of a program, All i need is the microcontroller to send the data the to TLC5940 PWM Driver.
|
|
|
|
|
Logged
|
Accelerate to 88 miles per hour.
|
|
|
|
|
|
|