When they moved to 8 bits, 8080/8085, Intel had an eye to backward compatibility. Those algorithms created for the four bitters had to be moveable to the 8 bitters. That called for a Half Carry bit and the DAA. Besides it made easy for regular programmers to do BCD arithmetic in assembler saving valuable code space as a bonus.
Speaking of DAA, it is still alive and well - here is a (8051) code snippet I found a while back on the web
This less common use is in Nibble to ASCII
( besides the more common BCD library conversion use, which is a fast & compact way to massage 32b numbers for human display.)
This code avoids any jumps, and comes in at 8 bytes.
Nibble_to_Asc_Hex: ; Nibble to "0".."9", "A".."F" (30H..39H and 41..46H)
anl A,#0Fh ;2 lower nibble
add A,#90H ;2
da A ;1
addc A,#40H ;2
da A ;1 8 bytes, 8 cycles, no jumps
Now many bytes for a RISC-V, or AMD64, to do the same thing ?
Seems, Parallax could have done themselves a favour by taking this lesson from Intel and ensuring that the Propeller ran BASIC Stamp code out of the box.
hehe, there is a serious angle here, in that the P1 is a ROM part, and Parallax could have released two ROMs....
Probably pretty easily, because IIRC, BASIC does make function calls, only jumps and all vars are global. The only thing is the tools would need to transparently include functions like PWM, serial, video, etc.
That said, I'm pretty sure there's at least one version of BASIC available on the prop.
There are a couple of BASIC implementations for the P1. As far as I know, none of them compiles to SPIN byte code.
Interesting is that there is even a byte code for GOTO in the SPIN interpreter. Just never used by the SPIN syntax.
I am personally quite language agnostic. But I am programming computer in various languages since the late 70' for a living. Whatever language the company uses, I use. Whatever naming style they use, I use. It's just the semantics to write it down. Does not really matter. The real programming is happening in my head. Most programmer I met at work do the same. I can not recall any professional programmer I met, just able to program in one language. Not even them COBOL guys. They mostly know FORTRAN and ALGOL also.
However I do like SPIN/PASM as combination and hope the P2 will get its own versions. C/C++ are a very common thing to have and Parallax is doing quite well there, pushing that option. The first computer I was allowed to put my hands on was a WANG 2000. So BASIC was the first thing I learned. Besides thinking in flow charts it did not help me much programming COBOL on mainframes later. SPIN would have done the same to me as BASIC did.
Getting me addicted to them computers!
I tried, Guys and Gals. I tried hard to get over that addiction. Working as truck driver, construction worker, janitor and other stuff. But I always went back to programming. It's a addiction.
Addiction is a medical, and subsequently a legal, term that only has a negative meaning - as in the authorities have the power to further limit your freedoms.
Obsession can be quite strongly perceived in a similarly negative sense, although there is no legal basis as far as I know. Passion would be the positive variant. There is no positive variant of addiction, it's a medical name.
Of course, many folks invert the meanings for fun. There is two problems with using addiction this way: They've used the wrong word for a starters, should be obsession instead, and addiction is such a serious subject it's not wise to joke about it. It's a bit like joking about bombs at an airport.
Similarly for "obsession". The negative connotation comes from the idea that that what you are obsessed with doing may not actually be good for you. See Obsessive Compulsive Disorder (OCD). Again "obsession" is often used in less serious contexts. Like Calvin Klein http://www.fragrancex.com/products/_cid_perfume-am-lid_o-am-pid_1002w__products.html
"Passion" might be better. Assuming msrobots is actually enjoying it, looking at his avatar we can't really be sure about that.
May be it's a "calling". A command from the creator himself to go forth and write code
This thread is not doomed yet. I'm still re-examining my P2 requirements.
It needs to come in a DIP 64 package. It needs to be 5v tolerant. It should be in a nice shade of purple. And it needs some internal firmware to detect any attempt to run Forth and reject it.
The DIP 64 is great and the 5v tolerance shows excellent social conscience (and that's a good thing these days!) but the purple package doesn't embrace diversity (and that's a BAD thing!).
In order to show support for diversity in the customer base, how about a translucent package (picture a frosted beer mug if you are on a country that drinks beer properly chilled (not to be intolerant of those that don't)).
Several WS2812's would be built into the package and connected to a spare pin. This would allow the customer to choose their package color and by doing so create an excellent customer experience!! Companies are all about the customer experience these days!
I'm here nor there about Forth. I can NOT finish a project in Forth as well as I can NOT finish a project in almost any other language! My overall productivity stays the same regardless of tools available.
Companies are all about the customer experience these days!
So I keep hearing. But I have noticed that my experience as customer for many services keeps getting worse and worse.
It was better when they did not try so hard.
OK, forget the purple package. I want a ceramic chip with gold plated pins like the good old days. That should satisfy all ethnic groups, including those purple aliens:
We're all about an "effortless customer experience" these days.
I'm old school and think people value things more if they have to work for them. I strive for an experience that the customer values...really, really values!!
I got a few of those gold packages way back in the 70's when my brother was a buyer for an electronics company. He got them as samples. I want to say memory chips? White ceramic and gold leads? Ahh, the memory is all foggy now.
.....
In order to show support for diversity in the customer base, how about a translucent package (picture a frosted beer mug if you are on a country that drinks beer properly chilled (not to be intolerant of those that don't)).
.....
As the OP, this is the first I have seen on topic for many posts.
Yes, a clear package would be nice - just like those windowed EPROMs of yesteryear
Obsession can be quite strongly perceived in a similarly negative sense, although there is no legal basis as far as I know. Passion would be the positive variant. There is no positive variant of addiction, it's a medical name.
Obsession can be perceived as negative, however it also quite dependent upon context.
Saying someone is obsessed with programming in a joking manner is quite different than saying the same with a grimace, or while twirling your forefinger in a circular manner on the side of your head.
Here are some alternatives-
an intense desire or enthusiasm for something.
"the English have a passion for gardens"
synonyms: fervor, ardor, enthusiasm, eagerness, zeal, zealousness, vigor, fire, fieriness, energy, fervency, animation, spirit, spiritedness, fanaticism ,
enthusiasm, love, mania, fascination, obsession, fanaticism, fixation, compulsion, appetite, addiction;
antonyms: apathy
a thing arousing enthusiasm.
"modern furniture is a particular passion of Bill's"
synonyms: obsession, preoccupation, craze, mania, hobbyhorse
"French literature is my passion"
As the OP, this is the first I have seen on topic for many posts.
Yes, a clear package would be nice - just like those windowed EPROMs of yesteryear
Might not be all that nice if parts of the chip turn out to be photosensitive as semiconductors are prone to be. While there is a simple cure for that it may take some time and head scratching to figure out why the code is misbehaving.
Comments
Speaking of DAA, it is still alive and well - here is a (8051) code snippet I found a while back on the web
This less common use is in Nibble to ASCII
( besides the more common BCD library conversion use, which is a fast & compact way to massage 32b numbers for human display.)
This code avoids any jumps, and comes in at 8 bytes.
Now many bytes for a RISC-V, or AMD64, to do the same thing ?
Couldn't tools simply compile BASIC to Spin byte code?
Probably pretty easily, because IIRC, BASIC does make function calls, only jumps and all vars are global. The only thing is the tools would need to transparently include functions like PWM, serial, video, etc.
That said, I'm pretty sure there's at least one version of BASIC available on the prop.
Interesting is that there is even a byte code for GOTO in the SPIN interpreter. Just never used by the SPIN syntax.
I am personally quite language agnostic. But I am programming computer in various languages since the late 70' for a living. Whatever language the company uses, I use. Whatever naming style they use, I use. It's just the semantics to write it down. Does not really matter. The real programming is happening in my head. Most programmer I met at work do the same. I can not recall any professional programmer I met, just able to program in one language. Not even them COBOL guys. They mostly know FORTRAN and ALGOL also.
However I do like SPIN/PASM as combination and hope the P2 will get its own versions. C/C++ are a very common thing to have and Parallax is doing quite well there, pushing that option. The first computer I was allowed to put my hands on was a WANG 2000. So BASIC was the first thing I learned. Besides thinking in flow charts it did not help me much programming COBOL on mainframes later. SPIN would have done the same to me as BASIC did.
Getting me addicted to them computers!
I tried, Guys and Gals. I tried hard to get over that addiction. Working as truck driver, construction worker, janitor and other stuff. But I always went back to programming. It's a addiction.
Enjoy!
Mike
English is my third language, so I am happy to learn the correct term.
Obsession. I looked it up and it really fits better. Thank you.
But what is that about 'correct negative term'?
What is negative about it?
Enjoy!
Mike
Obsession can be quite strongly perceived in a similarly negative sense, although there is no legal basis as far as I know. Passion would be the positive variant. There is no positive variant of addiction, it's a medical name.
Of course, many folks invert the meanings for fun. There is two problems with using addiction this way: They've used the wrong word for a starters, should be obsession instead, and addiction is such a serious subject it's not wise to joke about it. It's a bit like joking about bombs at an airport.
Whilst "addiction" may well be very negative it is often used less seriously. By Robert Palmer for example: https://www.youtube.com/watch?v=XcATvu5f9vE
Similarly for "obsession". The negative connotation comes from the idea that that what you are obsessed with doing may not actually be good for you. See Obsessive Compulsive Disorder (OCD). Again "obsession" is often used in less serious contexts. Like Calvin Klein http://www.fragrancex.com/products/_cid_perfume-am-lid_o-am-pid_1002w__products.html
"Passion" might be better. Assuming msrobots is actually enjoying it, looking at his avatar we can't really be sure about that.
May be it's a "calling". A command from the creator himself to go forth and write code
Edit: Not necessarily in Forth though.
It could be a passion since it probably isn't viewed as negative on both sides of the equation. )
It's nice to know that the inspiration to go code in forth is from the creator!! )
Of course a future history might misinterpret that commandment again as "Go forth and code in Go" https://golang.org/
Yeah, this thread is doomed!
Google may come to their senses and get their new language right by coming out with Go Forth. Of course, the web framework for that will be Conquer.
Who wouldn't feel comfortable about using a Google application that was developed in Go Forth and Conquer??
It needs to come in a DIP 64 package. It needs to be 5v tolerant. It should be in a nice shade of purple. And it needs some internal firmware to detect any attempt to run Forth and reject it.
Not asking too much am I?
In order to show support for diversity in the customer base, how about a translucent package (picture a frosted beer mug if you are on a country that drinks beer properly chilled (not to be intolerant of those that don't)).
Several WS2812's would be built into the package and connected to a spare pin. This would allow the customer to choose their package color and by doing so create an excellent customer experience!! Companies are all about the customer experience these days!
I'm here nor there about Forth. I can NOT finish a project in Forth as well as I can NOT finish a project in almost any other language! My overall productivity stays the same regardless of tools available.
It was better when they did not try so hard.
OK, forget the purple package. I want a ceramic chip with gold plated pins like the good old days. That should satisfy all ethnic groups, including those purple aliens:
I'm old school and think people value things more if they have to work for them. I strive for an experience that the customer values...really, really values!!
I got a few of those gold packages way back in the 70's when my brother was a buyer for an electronics company. He got them as samples. I want to say memory chips? White ceramic and gold leads? Ahh, the memory is all foggy now.
Back in the days of working in military electronics most chips looked like that.
Yes, a clear package would be nice - just like those windowed EPROMs of yesteryear
Next time would you please enclose "purple package" in Trigger Warning tags? Thx.
Obsession can be perceived as negative, however it also quite dependent upon context.
Saying someone is obsessed with programming in a joking manner is quite different than saying the same with a grimace, or while twirling your forefinger in a circular manner on the side of your head.
Here are some alternatives-
an intense desire or enthusiasm for something.
"the English have a passion for gardens"
synonyms: fervor, ardor, enthusiasm, eagerness, zeal, zealousness, vigor, fire, fieriness, energy, fervency, animation, spirit, spiritedness, fanaticism ,
enthusiasm, love, mania, fascination, obsession, fanaticism, fixation, compulsion, appetite, addiction;
antonyms: apathy
a thing arousing enthusiasm.
"modern furniture is a particular passion of Bill's"
synonyms: obsession, preoccupation, craze, mania, hobbyhorse
"French literature is my passion"
The corrector would see it as a passion.
The correctee, and probably everyone else in the vicinity would likely deem it an addiction.
Might not be all that nice if parts of the chip turn out to be photosensitive as semiconductors are prone to be. While there is a simple cure for that it may take some time and head scratching to figure out why the code is misbehaving.