Can SX be program in C?
I recently purchase an SX48 protoboard+blitz, can it be programmed in C?
Also, are there any good tutorials in programming with Basic? So far I've downloaded some PDFs from Parallax's website, but they focus heavily on assembly.
Thanks
Also, are there any good tutorials in programming with Basic? So far I've downloaded some PDFs from Parallax's website, but they focus heavily on assembly.
Thanks
Comments
Check this thread http://forums.parallax.com/showthread.php?p=582345·it's sort of been the unoffical status thread.
Post Edited (CPUMAN) : 6/9/2006 4:50:53 AM GMT
Bean.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Cheap 4-digit LED display with driver IC·www.hc4led.com
Low power SD Data Logger www.sddatalogger.com
"I reject your reality, and substitute my own." Mythbusters
·
Thanks
I can't speak for Parallax, but with a new version of SX/B coming out. Any print documentation that they would have produced would now be obsolete.
It has been a while since the last update, so it seems that the compiler is matureing. I've heard of a book or two "in the works", maybe this next release will spur them on.
Bean.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Cheap 4-digit LED display with driver IC·www.hc4led.com
Low power SD Data Logger www.sddatalogger.com
"I reject your reality, and substitute my own." Mythbusters
·
Ryan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Ryan Clarke
Parallax Tech Support
RClarke@Parallax.com
I see on the new intro pages "C" is shown as an option for the SX series, but I couldn't find the C compiler. Do I assume that marketing jumped the gun on the intro pages, or is release imminent?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
John R.
8 + 8 = 10
Yes, something like that. We recently updated our "Getting Started" page which included the forthcoming mention of the SX/C compiler from CCS. At the moment, Peter is working on yet another integration detail which CCS just assisted to resolve.
Ken Gracey
Parallax, Inc.
Are we all having fun yet???
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
John R.
8 + 8 = 10
Is there·any progress·in the realisation of the sx/c compiler? Can you give some information about·actual·actions/staps.
regards Rob.
It's still in an alpha test. The integration with the SX-Key IDE is mostly functional, but the users have pointed out several significant issues that CCS will need to fix before it can come near our customers. This could be a while and the schedule is up to CCS at this point.
I can admit you to the beta test forum for the SX/C compiler if you are interested in seeing the actual discussion.
Sincerely,
Ken Gracey
Parallax, Inc.
Thanks for your reply. Please add me to the discussion list.
regards,
Rob.
http://www.sourceboost.com/Products/C2C-plus/Overview.html
It has support for the sxblitz built in and works with all the sx chips.
Cost $70
I upgraded to the BoostC wich is an ANSI compiler for C and will be looking to see if I can get it to work with the SX chips.
I don't see why not since the SX is Pic chip compatible drop in replacement. Plus they have a great forum and plenty of example code. Also works with the PIC chips so you don't need two diffrent compilers.
Better than CCS, and HI-Tech in my opinion.
http://www.sourceboost.com/Products/C2C-pp/Overview.html
Hope this helps,
Alex.
EDIT: Sorry thosey, I didn't see your post. Didn't mean to repeat the same info.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Fear not that your project does not work, for it will,
Fear not if you see·a long dark path ahead, but follow it,
Fear not if what worked now refuses to,
For the only thing that's perfect is imperfection.
And this comes from someone who has been programming in C for over 25 years.
Why?
Because the SX's architecture is NOT condusive to C, and the ram is far too limited for the C compiler to do anything interesting.
To get the most out of SX's you have to learn their bizzare architecture - now all you SX defenders, before you jump on me, I just bought a pile of SX gear because even with the "interesting" architecture it MOST definitely has its uses due to its speed!
I mean for some projects... why would I use a Propeller ($12.95) when an SX28 ($2.79) will do the job???
A couple of the projects I am (slowly) working on use both an SX and a Propeller!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.mikronauts.com - a new blog about microcontrollers
Although most C compilers will generate obscenely inefficient code for the sake of simplicity and reusability, C2C -plus or C2C++ are two excellent compilers for the·SX chip (I prefer the latter). Of course, these compilers have their limitations because of the program memory·and·RAM constraints of the SX. For eaxample, a class (in C2C++) cannot hold more than 16 bytes, which is the size of a memory bank in the SX.
To unleash the real power of SX with C2C, it is helpful to use inline assembly code in time critical tasks, but one advantage prevails: you can take the compiled assembly code, and further optimize it.
The results would definitely be better than using SX/B, and·more efficient code can be generated faster.
Sincerely,
Alex.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Fear not that your project does not work, for it will,
Fear not if you see·a long dark path ahead, but follow it,
Fear not if what worked now refuses to,
For the only thing that's perfect is imperfection.
To unleash the real power of SX with SX/B, it is helpful to use inline assembly code in time critical tasks, but one advantage prevails: you can take the compiled assembly code, and further optimize it.
The results would definitely be better than using C2C, and more efficient code can be generated faster.
[noparse];)[/noparse]
Bean
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Cheap used 4-digit LED display with driver IC·www.hc4led.com
Low power SD Data Logger www.sddatalogger.com
SX-Video Display Modules www.sxvm.com
Stuff I'm selling on ebay http://search.ebay.com/_W0QQsassZhittconsultingQQhtZ-1
"USA Today has come out with a new survey - apparently, three out of every four people make up 75% of the population." - David Letterman
That being said I really don't like doing multi-byte math in assembly, and there's where the C would be nicer than SX/B and assembly...·· ...slow but nicer.
-Dan· (currently moving 4mbit/S data manchester encoded from on SX to another through·thin air...· ...the SX is a powerful little critter)
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"A saint-like quantity of patience is a help, if this is unavailable, a salty vocabulary works nearly as well." - A. S. Weaver
I'll check out those compilers, but frankly my interest in the SX is limited to using it as a VERY high speed I/O coprocessor for propellers (and possibly other architectures) - I would not even attempt to write anything significant for it, it is too resource constrained, and all the BANK / PAGE / MODE hacks make me cringe.
On the other hand, I LOVE the speed of it, even though I have to watch out for pipelining effects on read/modify/write instructions.
So far, other than a bit of experimenting with SX/B, everything I've written for the SX has been very tight assembly code, counting every cycle [noparse]:)[/noparse]
The prop on the other hand... I can't stop thinking of neat projects for it! VERY unique architecture.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.mikronauts.com - a new blog about microcontrollers
C2C has a 30-day trial period, so you can go start by downloading Source Boost (C2C, and C2C++ are included).
Sincerely,
Alex
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Fear not that your project does not work, for it will,
Fear not if you see·a long dark path ahead, but follow it,
Fear not if what worked now refuses to,
For the only thing that's perfect is imperfection.
Would anyone else be interested?
If I were to start a new thread with such a challenge, would someone with each of the languages do the code and present the findings?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
---
James Newton, Host of SXList.com
james at sxlist,com 1-619-652-0593 fax:1-208-279-8767
SX FAQ / Code / Tutorials / Documentation:
http://www.sxlist.com Pick faster!
I'd love to contribute SX/B code for that comparison if one is setup. Not so that I can say SX/B is better or worse than anything else (a tool is a tool), but so that newbies to SX/B can see an approach to a problem, and compare it to solutions offered by other tools.
James, sounds interesting. I'd like to contribute assembly and/or SX/B.
Bean.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Cheap used 4-digit LED display with driver IC·www.hc4led.com
Low power SD Data Logger www.sddatalogger.com
SX-Video Display Modules www.sxvm.com
Stuff I'm selling on ebay http://search.ebay.com/_W0QQsassZhittconsultingQQhtZ-1
"USA Today has come out with a new survey - apparently, three out of every four people make up 75% of the population." - David Letterman
Post Edited (Bean (Hitt Consulting)) : 2/9/2007 9:43:14 PM GMT
As assembly is all that I know, I'd love to have a go at that.
Cheers,
Peter (pjv)
Assembly and C sounds great. Most microcontrollers in this world are programmed in C.
Alex.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Fear not that your project does not work, for it will,
Fear not if you see·a long dark path ahead, but follow it,
Fear not if what worked now refuses to,
For the only thing that's perfect is imperfection.