Funny you say that....I was just considering putting OpenWRT on an SD card for one of my Raspis.
Why would I do that?
Well, OpenWRT is a small Linux system designed to run on the ARM and MIPS processors in WIFI routers. Like those from Linksys, D-Link and many others. Those machines are very limited on FLASH and RAM space so you really do need a small Linux system. OpenWRT is based on uclibc and busybox for example. Thing is I never use a GUI on my Pis, I never have a screen attached. The other big recent thing is that I just got OpenSoin and the propeller-loader from propgcc cross-compiled for OpenWRT. They work just fine. I can now use a WIFI router as a Propeller development box! Then OpenWRT has a very nice WEB interface for the normal configuration of a WIFI router. With a bit of work that could also serve up the propeller web IDE we have working now. That has a nice syntax highlighting Spin editor that runs in your browser.
All in all it's tempting to try it on a PI.
Is any of this relevant for mklrobo and his project proposals? No idea but OpenWRT has a package manger that I think is probably a lot simpler to deal with than say Debian's. So it would make a nice ready made Linux base. People are far more likely to dedicate a Pi to a mklrobo style project, Linux "brain" + Propeller network, than a PC.
I'm not sure if linuxcnc is at all a comparable situation. I imagine that those setting up CNC machines would dedicate a PC to the CNC machine not uses it as a primary work station. There may well be other reasons for wanting a special distro for CNC. Does it use a funky real-time kernel or real-time layer under the kernel for example?
I cannot imagine people wanting to boot some weird OS just to do some Propeller work and have to be switching back and forth all the time. That is just not going to happen in the same way I did not dual boot to Windows to run the Prop Tool back in the day.
If I recall correctly LinuxCNC does have a real-time kernel. It isn't just about the kernel though, it is a preconfigured system including software for controlling CNC devices that can be booted without installing on the machine.
What I was suggesting to the OP was the concept of having a bootable image with items like PropGCC, SimpleIDE, etc. already setup. This lets someone new to the Prop dive right in without needing to spend a bunch of time trying to get software installed.
A VirtualBox image would be another approach to having a ready to run system.
Heater, I think it has relevance. The router project you mention is a good example of the "appliance" model that saw some traction a while back. Myth TV is another one I used some time back. Making a DVR is a discrete task one would see benefit from a custom environment.
It's a good jump start type activity, where one has a piece of hardware to dedicate to getting going. Learn a lot, then jump to a full OS, or not. Just depends.
Where it conflicts is running one computer for more than one task. A lot of us develop for many things, and have that setup on our OS of choice. The cost of moving away from that is high.
But some people might want to jump in and go. And for them, a nice package could make sense.
Me again! Sorry that I have not responded. At Bush Gardens...
I appreciate everyone's input, and ANY idea on the subject is relavent. I can always
use information, in one form or fashion, to focus on a problem that may occur.
I woudl like to put all ya'll's name on the credits of contributors on my OS package,
if you so desire. It is a big goal, but it will be woth it.
1) If I understand correctly, most of what you want will be available or buildable using Propforth 6. PF6 is the multitasking pool version, all cogs are treated as "execution opportunites". We can have less than 104 tasks running with little impact on realtime event handling, of course only 8 tasks max could have determininistic 12.5 ns event handling. PF6 will be integrated with linux 10.10 (so it doesn't change in the test environment). It will also work with other linux versions, but we are starting with 10.10 to reduce varialbes in the test environment.
2) If you use FORTH, about half of folks here just won't get it. Very few aggressively hate forth and are very noisy, however, these folks are sufficient to muddy the waters. The other half of folks here may or may not be interested in another tool (until there is a really nifty demo that they want to play with). Of the 500 or so propforth users, all will try to help, but have other projects, so be prepared to most slowly and thoughtfully. PropForth went from a hacked together experiement to one of the best tested and stable tools I have use in about 6 years. Slow and steady wins the race.
3) the history of forth on the prop has an amusing history but it changes depending upon who you ask. If you ask me I will tell you, and the story gets better with each telling.But it may have less relation to actual events as more time passes.
4) MIL-Spec is a cool idea, but might not be a good choice in this case, as you are not the DoD. But we get the idea. I'm sure you can come up more suitable name as your requirements get better defined and the project takes shape.
Also - we will be building out test environment with DLINK DIR505 router ($25 on ebay) as linux box, as the lowest cost linux platform with WiFi. Any linux will work as near as I can tell, and WiFi is optional. But PF6 development specifically includes WiFi, so DIR505 seemed a reasonable choice.
EDT: DIR505 can be switched to any of stock firmware, openWRT, and a custom package for the DIR505. At the moment we are make an explicit paint-by-numbers checklist so everyone can have the exact same (successful) result setting up the rig, every time.
2) If you use FORTH, about half of folks here just won't get it. Very few aggressively hate forth and are very noisy, however, these folks are sufficient to muddy the waters. The other half of folks here may or may not be interested in another tool (until there is a really nifty demo that they want to play with). Of the 500 or so propforth users, all will try to help, but have other projects, so be prepared to most slowly and thoughtfully. PropForth went from a hacked together experiement to one of the best tested and stable tools I have use in about 6 years. Slow and steady wins the race.
"500 propforth users"? The activity on the forum doesn't indicate that. It seems at most there are 5 or 6 active users.
"about half of folks here just won't get it"? I think that number is more like 99%.
"Very few aggressively hate forth"? I think the majority hate Forth. I personally don't hate Forth, but I don't think it is the best choice for a language in most cases. The only time Forth is really useful is when there are no other development tools available for a processor. Of course, the Prop has many development tools available for it, so Forth doesn't really provide any advantages for the Prop.
"500 propforth users"? The activity on the forum doesn't indicate that. It seems at most there are 5 or 6 active users..
The 500 or so downloads indicate this as a possible upper limit, and Sal, caskaz, and me might be the lower limit. But that takes too long to type everytime, and its almost fun to see your predictable response.
"about half of folks here just won't get it"? I think that number is more like 99%.
touche. At least among the folks that make that extra effort to really go out of their way to express their negativity. Some folk need a hobby.
"Very few aggressively hate forth"? I think the majority hate Forth. I personally don't hate Forth, but I don't think it is the best choice for a language in most cases. The only time Forth is really useful is when there are no other development tools available for a processor. Of course, the Prop has many development tools available for it, so Forth doesn't really provide any advantages for the Prop.
Maybe hate is the wrong word, but based on the effort you expend to express your negative opinion, I hope you understand my confusion. Maybe this is like that sports thing where folks cheer their favorite team but also must have a special hate for another team? I don't do spectator sports, possibly for this reason.
So back to the original poster's idea, just be aware that you will continue to draw this type of enthusiasm from folks that do not appreciate the concept, and should not even be interested enough to response in the first place. It appears negative participation is also a hobby of sorts.
This is the penalty for not following the herd. But other folks "not getting it" is no reason not to go forward with something that might be interesting.
In reading the forum, I was under the impression that everyone liked Forth, or at least one of its children,
like Tachyon Forth. There are at least 100 pages of people who have contributed to that Forth. Why is
this? I thought Forth was a higher lever language that enabled easier manipulation of the propeller,
without having to delve into assembler, taking much more time. ?!?
In reading the forum, I was under the impression that everyone liked Forth, or at least one of its children,
like Tachyon Forth. There are at least 100 pages of people who have contributed to that Forth. Why is
this? I thought Forth was a higher lever language that enabled easier manipulation of the propeller,
without having to delve into assembler, taking much more time. ?!?
I think there is a lot of volume in a couple of the Forth threads because the creators and/or there advocates are fairly passionate about Forth. When someone wants to dive into Forth and has questions they get good feedback and support. I really respect those guys because they are willing to advocate for what they believe in.
That said, I've tried to "get" Forth and it just isn't there for me, I find C/C++, SPIN, and PASM much more understandable.
My opinion is you would be best served basing your project on PropGCC for the following reasons:
- C/C++ are very common in the MCU space.
- Push by educators for Parallax to support C/C++ in education materials.
- Easier point of entry for Arduino users than Spin.
As the vocal self-proclaimed greatest resident Forth code hater here ....
I think Forth may have value, but not necessarily as Forth lovers would want it.
It could be useful as an intermediate language barely understood by humans.
Compilers end up generating RPN style constructs anyway so why not?
Forth is easy for Forth lovers to create for different MCUs.
An intermediate language interface should be easy to make.
Only simple set of "words" would be needed.
There are a few Forth enthusiasts who seem to think it's the answer to everything. Most use a mix of languages depending on their needs and experience.
I think there is a lot of volume in a couple of the Forth threads because the creators and/or there advocates are fairly passionate about Forth. When someone wants to dive into Forth and has questions they get good feedback and support. I really respect those guys because they are willing to advocate for what they believe in.
That said, I've tried to "get" Forth and it just isn't there for me, I find C/C++, SPIN, and PASM much more understandable.
My opinion is you would be best served basing your project on PropGCC for the following reasons:
- C/C++ are very common in the MCU space.
- Push by educators for Parallax to support C/C++ in education materials.
- Easier point of entry for Arduino users than Spin.
C.W.
I appreciate your insight. Would ya'll mind if I posted a voting thread in general discussion, to see if anybody uses Forth?
If nobody uses it, there is no reason for me to waste my time with Forth. I am leaning toward using PropGcc with appropriate libraries
to accomodate the most users. Maybe someone has an idea to focus Forth on a dedicated problem, rather than as
a generic fix-all. This would seem more appropriate. I know Huminoid has a encyclopedia of forths, and so, I will look into
that, to try to divine some kind of use for Forth, if any. Thanks.
The .problem with Forth as an intermediate language is that it uses a stack-based VM. Tachyon has done a good job in mapping a portion of the stacks into registers, but stack access, or even virtual stack access using registers still requires shuffling values to the top of the stack to use them. Even C does a bit of register shuffling, but this is minimized when using the optimized compile modes.
I've spent many months writing in Forth and writing Forth interpreters, and I think I have a good understanding of its strengths and weaknesses. The nice thing about Forth is that it can support a stand-alone development environment. The disadvantage to Forth is that it doesn't support a lot of the high level features that are in other languages, such as pre-compiled libraries, data structures and object-oriented coding.
So in my humble opinion, Forth should be used when no other development tools are available. However, it is not needed when there are other languages, such as Spin or C. This is something the Forth evangelists don't seem to recognize. The Forth evangelist don't seem to realize, or won't admit that Spin or C will work just as well, or better than Forth for most applications.
I dabble in Forth and having admitted that, your Propeller Linux Distribution should not be Forth based. Anyone wanting to use any of the Forths on the Propeller can certainly do so with your distribution as long as it has the tools below.
It should have the SimpleIDE/PropGCC and PropellerIDE/OpenSpin toolchains on it completely installed and functional.
It should have a minicom and a few editors on it (vim, pico, nano)
It should come on a double ended USB stick as a bootable live image with write access to the USB memory and sandboxed from the PC (sorry, schools will like this).
If you plug the USB into a PC and boot from it, you boot into your image, plug a USB capable development board into the other side and you go develop. (think of it as a USB thumb drive with a one port hub on the other end)
If you plug the USB into a running system and don't boot, it has a file partition which the host system can mount and write to - this allows transferring files from internal storage to USB storage to make life easier with multiple systems.
You can just move your entire development environment from system to system as needed, rebooting into the live image as you need to. You never touch the "host" computer, it just provides keyboard/monitor/CPU/Memory to your storage footprint.
In reading the forum, I was under the impression that everyone liked Forth...
Oh dear...
I thought Forth was a higher lever language that enabled .... without having to delve into assembler
Oh dear...
Forth is actually amazing.
Forth is perhaps the smallest and simplest way to enable the writing programs for a computer that are, in principal at least, portable from one machine architecture to another. A program in Forth like "2 3 +" can be moved from machine to machine and still work. So that is a step up from writing your code in assembler which is architecture specific.
Not only that it provides an interactive "command line" session with the user. Which allows for code entry and editing. The language run time provides it's own development system. Quite unlike languages that normally get compiled to fixed binary executables like C or Spin. There are of course many other languages that provide this Read Eval Print Loop (REPL) capability, Lisp, Scheme, Python, JavaScript etc. They are generally much much bigger than a Forth implementation.
All that in a code size that fits into a Propeller and no doubt machines with much less memory. (Anyone know what the smallest space a usable Forth has ever run in is?)
All in all quite impressive.
If you really need a stand alone Propeller, or whatever, system that needs no external computer or software to program it or if you really need interactive sessions with your machine then Forth is a way to go.
However...
Would I program in Forth? No. I'd rather have an interactive hex editor on the target machine (See Propeller II). Or perhaps a lobotomy.
Why?
I do actually happen to have a PC. I have no need for a stand alone development environment on a Propeller. I have no need for that interactive session capability. Editing code in a nice big syntax highlighted editor window on my huge monitor is much nicer. When writing programs of the size that fits in a Propeller the speed of compilation and download of Spin or C is fast enough that it may as well be an interactive session. When I'm done I want a text file containing my source code on my PC somewhere. Not out there in the Propeller. In fact I don't even want it on my PC I want it in github https://github.com/ where others can get it and mess with it if they want to.
Forth is not a high level language. Despite what it's supporters say and despite it being a tiny step up from assembler. Heck they were even crazy enough to claim that Forth was a 4th generation language back in day!
Forth is the only, so called, HLL that actually makes programming a solution to a problem harder than writing PASM or other assembly language.
Forth lacks pretty much any high level language features. That's why it fits in such small spaces. Heck, you still have to worry about the location in memory of your data. I mean really, even assembly languages do that for you.
As a clever piece of design Forth is fascinating. As a way to program your Propeller with nothing more sophisticated than an ASR-33 teletype Forth is a God send, if your really have to do that.
As a way of writing programs more complex than "2 3 +", it's pointless when there are so many better alternatives.
Braino is right. We do like to bash on Forth. I believe it's a valuable community service:)
If I see a farmer ploughing his fields with a plough dragged behind a moped. Should I not point out to him that a tractor might get things more easily? If the farmer won't listen I should certainly mention to any young farmers seeking his advice that perhaps there are better alternatives before they waste their lives in senseless toil.
I will delay putting in Mil-Spec Forth, and put my concentration on the system, with the nice tools.
I am thinking about submitting a question to the general discussion, to get input from the general forum.
If, in reviewing people's projects, I see a "shortcut" in the code, then I may pursue Forth. Right now,
I will stick with the OS, and follow thru with that.
In reference to programming languages; In reference to programming choices, Functions, and Performance Status; I will divide up the programming into 2 base classes;
1> Development and moderate performance
Spin, Pasm, etc
2> Specialized, Industrial, and Pro-Performance
Tachyon forth, etc.
a selection of languages will be avaliable, but will
but put in different categories. This will avoid
confusion and attempt to provide stability to
the choice that the programmer uses. Different classes
demand different "loads" on the programmer, with different
libraries, venaculars, etc. Comments?
Can you define what you mean by the terms Development, Specialized and Industrial? I'm assuming moderate performance and Pro-Performance describe execution speed, but maybe those need to be defined also. It seems that PASM is not correctly categorized, and there is no mention of C. I would categorize PASM and LMM C as Development and high performance. CMM C would be Development and moderate performance.
There is no need to alter the development software. Unless, of course they are developing a
new language or related item. This software needs to be working correctly.(as it all does)
Specialized high performance software may need to be altered. This is because these software
packages may depend on the OS for dedicated operations, specialized libraries, etc.
The categorization should eliminate emotional contamination; while strengthening support, stability, and
intended function. Some languages may evolve into high performance, while others may devolve. Some
measuring critera needs to be used to maintain stability. Some development software may be able to
achieve high performance; but the average mean of programmers may not have used that language
for such purpose. Targeting high performance consistantly, for dedicated purposes, may demand
more rigid order and dedicated libraries to attain this goal.
Can you define what you mean by the terms Development, Specialized and Industrial? I'm assuming moderate performance and Pro-Performance describe execution speed, but maybe those need to be defined also. It seems that PASM is not correctly categorized, and there is no mention of C. I would categorize PASM and LMM C as Development and high performance. CMM C would be Development and moderate performance.
Maybe there should be more descriptors, befitting the language. I would like to use real world application models to support the catorigization.
I appreciate your input, David. I have been reading some of your work. have alot to learn.
There is no need to alter the development software. Unless, of course they are developing a
new language or related item. This software needs to be working correctly.(as it all does)
Specialized high performance software may need to be altered. This is because these software
packages may depend on the OS for dedicated operations, specialized libraries, etc.
Now I'm even more confused. I have no idea what that means. Your definitions don't seem to match up with Spin, PASM and Tachyon.
Now I'm even more confused. I have no idea what that means. Your definitions don't seem to match up with Spin, PASM and Tachyon.
I would like your input. From my humble perspective, it looks like some languages are used more in commercial ventures than others.I was walking through languages this
weekend, trying to put languages into context. But, I guess it depends on the programmers you ask.?
Now I'm even more confused. I have no idea what that means. Your definitions don't seem to match up with Spin, PASM and Tachyon.
You are a talented programmer. You have the capability to take ANY language, and make it high performance; which is a credit to your skill. But what about people like me?
I still don't understand what you're getting at. Classifying languages isn't going to make a novice programmer an expert.
You are the one developing your MS Forth and Linux OS platform. It will be whatever you make it to be. However, if you want anybody else to use it you will need to clearly describe what it is, and how to use it. Even then, people may decide not to use it if they have a better alternative, such as the current approach of developing code on their own existing platforms.
I still don't understand what you're getting at. Classifying languages isn't going to make a novice programmer an expert.
You are the one developing your MS Forth and Linux OS platform. It will be whatever you make it to be. However, if you want anybody else to use it you will need to clearly describe what it is, and how to use it. Even then, people may decide not to use it if they have a better alternative, such as the current approach of developing code on their own existing platforms.
examine the following Wikipedia descriptors, comparing Javascript to Forth; JavaScript (JS) is a dynamic computer programming language.[5] It is most commonly used as part of web browsers, whose implementations allow client-side scripts to interact with the user, control the browser, communicate asynchronously, and alter the document content that is displayed.[5] It is also being used in server-side network programming (with Node.js), game development and the creation of desktop and mobile applications.
Forth - Forth is an imperativestack-based computer programming language and programming environment. Language features include structured programming, reflection (the ability to modify the program structure during program execution), concatenative programming (functions are composed withjuxtaposition) and extensibility (the programmer can create new commands). Although not an acronym, the language's name is sometimes spelled with all capital letters as FORTH, following the customary usage during its earlier years. The Javascriipt description seems to me, pretty clear as to function and application. I can not make out what in the world the Forth description means, applies to, or ??!?. I am familiar with the internal of the CPU, stacks, etc,; butjuxtaposition? Where does this apply to? One can look this up, but intuitive descriptors would be nice.
In this case, this is what I am trying to avoid. The right tool, with the right libraries, for the intended purpose. If someone tries to use Javascript for an assembler,(?) then what is that?
You can possibly use any language for any purpose, but why? I am trying to establish some-kind of order, in which a clear purpose from application can be readily understood.
I must "endeavor to persevere" in my quest.
If someone tries to use Javascript for an assembler,(?) then what is that?
Then we end up with Emscripten.
Emscripten can "compile" C and C++ sources into JavaScript. As a sort of assembler language output. Indeed the style of code it generates is called asm.js.
That generated Javascript, mostly unreadable by humans, can then be run in the browser or under node.js at speeds approaching that of C/C++ compiled to native machine instructions!
And that's how we get the Open Source Spin compiler, written in C++, running in the browser to form a web based IDE for Spin. Search for openspin.js.
After reading hard here I still have no idea what you are trying to do.
Emscripten can "compile" C and C++ sources into JavaScript. As a sort of assembler language output. Indeed the style of code it generates is called asm.js.
That generated Javascript, mostly unreadable by humans, can then be run in the browser or under node.js at speeds approaching that of C/C++ compiled to native machine instructions!
And that's how we get the Open Source Spin compiler, written in C++, running in the browser to form a web based IDE for Spin. Search for openspin.js.
After reading hard here I still have no idea what you are trying to do.
I will post a "challenge" in the discussion soon, to try to illustrate what I am looking for. It will
be a fun "thought" problem. I hope alot of people will post their solutions. Thanks.
Comments
Or Pi type device.
For those, it's just something on an SD card.
Just tossing that into the mix. Personally, I would much prefer packages as mentioned above.
Funny you say that....I was just considering putting OpenWRT on an SD card for one of my Raspis.
Why would I do that?
Well, OpenWRT is a small Linux system designed to run on the ARM and MIPS processors in WIFI routers. Like those from Linksys, D-Link and many others. Those machines are very limited on FLASH and RAM space so you really do need a small Linux system. OpenWRT is based on uclibc and busybox for example. Thing is I never use a GUI on my Pis, I never have a screen attached. The other big recent thing is that I just got OpenSoin and the propeller-loader from propgcc cross-compiled for OpenWRT. They work just fine. I can now use a WIFI router as a Propeller development box! Then OpenWRT has a very nice WEB interface for the normal configuration of a WIFI router. With a bit of work that could also serve up the propeller web IDE we have working now. That has a nice syntax highlighting Spin editor that runs in your browser.
All in all it's tempting to try it on a PI.
Is any of this relevant for mklrobo and his project proposals? No idea but OpenWRT has a package manger that I think is probably a lot simpler to deal with than say Debian's. So it would make a nice ready made Linux base. People are far more likely to dedicate a Pi to a mklrobo style project, Linux "brain" + Propeller network, than a PC.
https://openwrt.org/
If I recall correctly LinuxCNC does have a real-time kernel. It isn't just about the kernel though, it is a preconfigured system including software for controlling CNC devices that can be booted without installing on the machine.
What I was suggesting to the OP was the concept of having a bootable image with items like PropGCC, SimpleIDE, etc. already setup. This lets someone new to the Prop dive right in without needing to spend a bunch of time trying to get software installed.
A VirtualBox image would be another approach to having a ready to run system.
C.W.
It's a good jump start type activity, where one has a piece of hardware to dedicate to getting going. Learn a lot, then jump to a full OS, or not. Just depends.
Where it conflicts is running one computer for more than one task. A lot of us develop for many things, and have that setup on our OS of choice. The cost of moving away from that is high.
But some people might want to jump in and go. And for them, a nice package could make sense.
I appreciate everyone's input, and ANY idea on the subject is relavent. I can always
use information, in one form or fashion, to focus on a problem that may occur.
I woudl like to put all ya'll's name on the credits of contributors on my OS package,
if you so desire. It is a big goal, but it will be woth it.
1) If I understand correctly, most of what you want will be available or buildable using Propforth 6. PF6 is the multitasking pool version, all cogs are treated as "execution opportunites". We can have less than 104 tasks running with little impact on realtime event handling, of course only 8 tasks max could have determininistic 12.5 ns event handling. PF6 will be integrated with linux 10.10 (so it doesn't change in the test environment). It will also work with other linux versions, but we are starting with 10.10 to reduce varialbes in the test environment.
2) If you use FORTH, about half of folks here just won't get it. Very few aggressively hate forth and are very noisy, however, these folks are sufficient to muddy the waters. The other half of folks here may or may not be interested in another tool (until there is a really nifty demo that they want to play with). Of the 500 or so propforth users, all will try to help, but have other projects, so be prepared to most slowly and thoughtfully. PropForth went from a hacked together experiement to one of the best tested and stable tools I have use in about 6 years. Slow and steady wins the race.
3) the history of forth on the prop has an amusing history but it changes depending upon who you ask. If you ask me I will tell you, and the story gets better with each telling.But it may have less relation to actual events as more time passes.
4) MIL-Spec is a cool idea, but might not be a good choice in this case, as you are not the DoD. But we get the idea. I'm sure you can come up more suitable name as your requirements get better defined and the project takes shape.
You can PM me if you want to talk off - line.
EDT: DIR505 can be switched to any of stock firmware, openWRT, and a custom package for the DIR505. At the moment we are make an explicit paint-by-numbers checklist so everyone can have the exact same (successful) result setting up the rig, every time.
"about half of folks here just won't get it"? I think that number is more like 99%.
"Very few aggressively hate forth"? I think the majority hate Forth. I personally don't hate Forth, but I don't think it is the best choice for a language in most cases. The only time Forth is really useful is when there are no other development tools available for a processor. Of course, the Prop has many development tools available for it, so Forth doesn't really provide any advantages for the Prop.
The 500 or so downloads indicate this as a possible upper limit, and Sal, caskaz, and me might be the lower limit. But that takes too long to type everytime, and its almost fun to see your predictable response.
touche. At least among the folks that make that extra effort to really go out of their way to express their negativity. Some folk need a hobby.
Maybe hate is the wrong word, but based on the effort you expend to express your negative opinion, I hope you understand my confusion. Maybe this is like that sports thing where folks cheer their favorite team but also must have a special hate for another team? I don't do spectator sports, possibly for this reason.
So back to the original poster's idea, just be aware that you will continue to draw this type of enthusiasm from folks that do not appreciate the concept, and should not even be interested enough to response in the first place. It appears negative participation is also a hobby of sorts.
This is the penalty for not following the herd. But other folks "not getting it" is no reason not to go forward with something that might be interesting.
In reading the forum, I was under the impression that everyone liked Forth, or at least one of its children,
like Tachyon Forth. There are at least 100 pages of people who have contributed to that Forth. Why is
this? I thought Forth was a higher lever language that enabled easier manipulation of the propeller,
without having to delve into assembler, taking much more time. ?!?
I think there is a lot of volume in a couple of the Forth threads because the creators and/or there advocates are fairly passionate about Forth. When someone wants to dive into Forth and has questions they get good feedback and support. I really respect those guys because they are willing to advocate for what they believe in.
That said, I've tried to "get" Forth and it just isn't there for me, I find C/C++, SPIN, and PASM much more understandable.
My opinion is you would be best served basing your project on PropGCC for the following reasons:
- C/C++ are very common in the MCU space.
- Push by educators for Parallax to support C/C++ in education materials.
- Easier point of entry for Arduino users than Spin.
C.W.
As the vocal self-proclaimed greatest resident Forth code hater here ....
I think Forth may have value, but not necessarily as Forth lovers would want it.
It could be useful as an intermediate language barely understood by humans.
Compilers end up generating RPN style constructs anyway so why not?
Forth is easy for Forth lovers to create for different MCUs.
An intermediate language interface should be easy to make.
Only simple set of "words" would be needed.
Meanwhile %99.98 of the world has moved on.
My $0.02
I appreciate your insight. Would ya'll mind if I posted a voting thread in general discussion, to see if anybody uses Forth?
If nobody uses it, there is no reason for me to waste my time with Forth. I am leaning toward using PropGcc with appropriate libraries
to accomodate the most users. Maybe someone has an idea to focus Forth on a dedicated problem, rather than as
a generic fix-all. This would seem more appropriate. I know Huminoid has a encyclopedia of forths, and so, I will look into
that, to try to divine some kind of use for Forth, if any. Thanks.
I've spent many months writing in Forth and writing Forth interpreters, and I think I have a good understanding of its strengths and weaknesses. The nice thing about Forth is that it can support a stand-alone development environment. The disadvantage to Forth is that it doesn't support a lot of the high level features that are in other languages, such as pre-compiled libraries, data structures and object-oriented coding.
So in my humble opinion, Forth should be used when no other development tools are available. However, it is not needed when there are other languages, such as Spin or C. This is something the Forth evangelists don't seem to recognize. The Forth evangelist don't seem to realize, or won't admit that Spin or C will work just as well, or better than Forth for most applications.
It should have the SimpleIDE/PropGCC and PropellerIDE/OpenSpin toolchains on it completely installed and functional.
It should have a minicom and a few editors on it (vim, pico, nano)
It should come on a double ended USB stick as a bootable live image with write access to the USB memory and sandboxed from the PC (sorry, schools will like this).
If you plug the USB into a PC and boot from it, you boot into your image, plug a USB capable development board into the other side and you go develop. (think of it as a USB thumb drive with a one port hub on the other end)
If you plug the USB into a running system and don't boot, it has a file partition which the host system can mount and write to - this allows transferring files from internal storage to USB storage to make life easier with multiple systems.
You can just move your entire development environment from system to system as needed, rebooting into the live image as you need to. You never touch the "host" computer, it just provides keyboard/monitor/CPU/Memory to your storage footprint.
Forth is actually amazing.
Forth is perhaps the smallest and simplest way to enable the writing programs for a computer that are, in principal at least, portable from one machine architecture to another. A program in Forth like "2 3 +" can be moved from machine to machine and still work. So that is a step up from writing your code in assembler which is architecture specific.
Not only that it provides an interactive "command line" session with the user. Which allows for code entry and editing. The language run time provides it's own development system. Quite unlike languages that normally get compiled to fixed binary executables like C or Spin. There are of course many other languages that provide this Read Eval Print Loop (REPL) capability, Lisp, Scheme, Python, JavaScript etc. They are generally much much bigger than a Forth implementation.
All that in a code size that fits into a Propeller and no doubt machines with much less memory. (Anyone know what the smallest space a usable Forth has ever run in is?)
All in all quite impressive.
If you really need a stand alone Propeller, or whatever, system that needs no external computer or software to program it or if you really need interactive sessions with your machine then Forth is a way to go.
However...
Would I program in Forth? No. I'd rather have an interactive hex editor on the target machine (See Propeller II). Or perhaps a lobotomy.
Why?
I do actually happen to have a PC. I have no need for a stand alone development environment on a Propeller. I have no need for that interactive session capability. Editing code in a nice big syntax highlighted editor window on my huge monitor is much nicer. When writing programs of the size that fits in a Propeller the speed of compilation and download of Spin or C is fast enough that it may as well be an interactive session. When I'm done I want a text file containing my source code on my PC somewhere. Not out there in the Propeller. In fact I don't even want it on my PC I want it in github https://github.com/ where others can get it and mess with it if they want to.
Forth is not a high level language. Despite what it's supporters say and despite it being a tiny step up from assembler. Heck they were even crazy enough to claim that Forth was a 4th generation language back in day!
Forth is the only, so called, HLL that actually makes programming a solution to a problem harder than writing PASM or other assembly language.
Forth lacks pretty much any high level language features. That's why it fits in such small spaces. Heck, you still have to worry about the location in memory of your data. I mean really, even assembly languages do that for you.
As a clever piece of design Forth is fascinating. As a way to program your Propeller with nothing more sophisticated than an ASR-33 teletype Forth is a God send, if your really have to do that.
As a way of writing programs more complex than "2 3 +", it's pointless when there are so many better alternatives.
Braino is right. We do like to bash on Forth. I believe it's a valuable community service:)
If I see a farmer ploughing his fields with a plough dragged behind a moped. Should I not point out to him that a tractor might get things more easily? If the farmer won't listen I should certainly mention to any young farmers seeking his advice that perhaps there are better alternatives before they waste their lives in senseless toil.
In relation to the Forth agenda;
I will delay putting in Mil-Spec Forth, and put my concentration on the system, with the nice tools.
I am thinking about submitting a question to the general discussion, to get input from the general forum.
If, in reviewing people's projects, I see a "shortcut" in the code, then I may pursue Forth. Right now,
I will stick with the OS, and follow thru with that.
Thanks again.
spin simulator, by Dave;
http://forums.parallax.com/showthrea...Spin-Simulator
Whiteoxe found LTSpice to run circuit simulators.
If someone has written propeller simulators, and the like, Please advise.
In reference to programming choices, Functions, and Performance Status;
I will divide up the programming into 2 base classes;
1> Development and moderate performance
Spin, Pasm, etc
2> Specialized, Industrial, and Pro-Performance
Tachyon forth, etc.
a selection of languages will be avaliable, but will
but put in different categories. This will avoid
confusion and attempt to provide stability to
the choice that the programmer uses. Different classes
demand different "loads" on the programmer, with different
libraries, venaculars, etc. Comments?
There is no need to alter the development software. Unless, of course they are developing a
new language or related item. This software needs to be working correctly.(as it all does)
Specialized high performance software may need to be altered. This is because these software
packages may depend on the OS for dedicated operations, specialized libraries, etc.
The categorization should eliminate emotional contamination; while strengthening support, stability, and
intended function. Some languages may evolve into high performance, while others may devolve. Some
measuring critera needs to be used to maintain stability. Some development software may be able to
achieve high performance; but the average mean of programmers may not have used that language
for such purpose. Targeting high performance consistantly, for dedicated purposes, may demand
more rigid order and dedicated libraries to attain this goal.
I appreciate your input, David. I have been reading some of your work. have alot to learn.
weekend, trying to put languages into context. But, I guess it depends on the programmers you ask.?
You are the one developing your MS Forth and Linux OS platform. It will be whatever you make it to be. However, if you want anybody else to use it you will need to clearly describe what it is, and how to use it. Even then, people may decide not to use it if they have a better alternative, such as the current approach of developing code on their own existing platforms.
JavaScript (JS) is a dynamic computer programming language.[5] It is most commonly used as part of web browsers, whose implementations allow client-side scripts to interact with the user, control the browser, communicate asynchronously, and alter the document content that is displayed.[5] It is also being used in server-side network programming (with Node.js), game development and the creation of desktop and mobile applications.
Forth - Forth is an imperative stack-based computer programming language and programming environment. Language features include structured programming, reflection (the ability to modify the program structure during program execution), concatenative programming (functions are composed with juxtaposition) and extensibility (the programmer can create new commands). Although not an acronym, the language's name is sometimes spelled with all capital letters as FORTH, following the customary usage during its earlier years. The Javascriipt description seems to me, pretty clear as to function and application. I can not make out what in the world the Forth description means, applies to, or ??!?. I am familiar with the internal of the CPU, stacks, etc,; butjuxtaposition? Where does this apply to? One can look this up, but intuitive descriptors would be nice.
In this case, this is what I am trying to avoid. The right tool, with the right libraries, for the intended purpose. If someone tries to use Javascript for an assembler,(?) then what is that?
You can possibly use any language for any purpose, but why? I am trying to establish some-kind of order, in which a clear purpose from application can be readily understood.
I must "endeavor to persevere" in my quest.
Emscripten can "compile" C and C++ sources into JavaScript. As a sort of assembler language output. Indeed the style of code it generates is called asm.js.
That generated Javascript, mostly unreadable by humans, can then be run in the browser or under node.js at speeds approaching that of C/C++ compiled to native machine instructions!
And that's how we get the Open Source Spin compiler, written in C++, running in the browser to form a web based IDE for Spin. Search for openspin.js.
After reading hard here I still have no idea what you are trying to do.
I will post a "challenge" in the discussion soon, to try to illustrate what I am looking for. It will
be a fun "thought" problem. I hope alot of people will post their solutions. Thanks.