EmbeddedRelated.com
Forums

8051

Started by zibidi February 1, 2006
cbarn24050@aol.com wrote:

> >> >> >> >>I would have thought the PIC18 would have even worse than the 8051. >> >> >> The problem for a pre-emptive OS is stack. No 8051 variant has a stack >> greater then 256 bytes (and in practice it is rather less). Some OS get >> round this by using XRAM to save non running processes' stacks but this >> is slow. >> >> Most (all?) PICs have a fixed, inaccessible and rather small stack which >> makes it harder to write an RTOS IMHO. >> >> Ian > > The other problem is the lack of data pointers on the 8051. The pic18 > have 3 I think so you can easily make your own data stack and plenty on > onboard ram to accomodate it.
The 8051 has three as well. Two 8bit and one 16 bit pointer. Why anyone would want to do something as cumbersome as their own datastack on a small 8 bit micro is beyond me. Ian
Hans-Bernhard Broeker wrote:

> Ian Bell <ruffrecords@yahoo.com> wrote: > >> The problem for a pre-emptive OS is stack. No 8051 variant has a stack >> greater then 256 bytes (and in practice it is rather less). > > BZZZZ! --- and thanks for playing ;-) Check out the DS80C390: 1 kB of > dedicated stack space. And it's even in on-chip XDATA memory so it > doesn't even eat up valuable IDATA. >
Now that is an interesting variant; they have actually increased the stack pointer to 10 bits so it can address 1K of memory. Pity is has CAN bus baggage. Now if someone brought out a range of variants all with a 1K stack that would be interesting. The compiler writers would have fun with it too. Ian