Moving from 8051 to AVR

The first link was new to me but the others I have come across and as you say are less C51 specific. There seems to be lots of Pascal interest. I assume you are aware of the Lazarus and free pascal projects.

formatting link

Ian

Reply to
Ian Bell
Loading thread data ...

It means that if they try to optimize the program, then they do it so it runs more efficient on a high end machine with some registers instead of a machine with an 8 bit accumulator and no stack.

--
Best Regards,
Ulf Samuelsson
ulf@atmel.com
GSM:  +46 (706) 22 44 57
Tel:     +46  (8) 441 54 22
Fax:     +46 (8) 441 54 29
Mail: Box 2033  174 02 Sundbyberg
Visit: Kavallerivägen 24
          174 58 Sundbyberg'
Sweden
Reply to
Ulf Samuelsson

Nope, 500k object code. Remember, the AVR has 8 MByte address space.

--
Best Regards,
Ulf Samuelsson
ulf@atmel.com
GSM:  +46 (706) 22 44 57
Tel:     +46  (8) 441 54 22
Fax:     +46 (8) 441 54 29
Mail: Box 2033  174 02 Sundbyberg
Visit: Kavallerivägen 24
          174 58 Sundbyberg'
Sweden
Reply to
Ulf Samuelsson

Unless "Concurrent Euclid" FINALLY takes off ;-)

--
Best Regards,
Ulf Samuelsson
ulf@atmel.com
GSM:  +46 (706) 22 44 57
Tel:     +46  (8) 441 54 22
Fax:     +46 (8) 441 54 29
Mail: Box 2033  174 02 Sundbyberg
Visit: Kavallerivägen 24
          174 58 Sundbyberg'
Sweden
Reply to
Ulf Samuelsson

formatting link

No, but they do not choose controllers, the engineers do. Plenty of use of both std AVRs and AT91s in Ericsson and more is coming...

--
Best Regards,
Ulf Samuelsson
ulf@atmel.com
GSM:  +46 (706) 22 44 57
Tel:     +46  (8) 441 54 22
Fax:     +46 (8) 441 54 29
Mail: Box 2033  174 02 Sundbyberg
Visit: Kavallerivägen 24
          174 58 Sundbyberg'
Sweden
Reply to
Ulf Samuelsson

Yes they are, they deliver ASIC chipsets to mobile phone manufacturers like Sony-Ericsson

--
Best Regards,
Ulf Samuelsson
Reply to
Ulf Samuelsson

If the compiler can figure out what is happening, then the compiler can do transformations which generates code which can be very different from the *obvious* translation of the source code. The more complex the CPU, the more complex this task becomes.

An architecture which is C-Friendly will simplify writing the compiler so that in the ideal case, the compiler will not care which code was written and will always generate the optimal solution to the problem.

If such a compiler is available, then you save a lot of time by not having to worry too much about the nitty gritty details of the architecture. Once you can stop worrying about this, then you save a LOT of time.

--
Best Regards,
Ulf Samuelsson
Reply to
Ulf Samuelsson

The internal registers allow you to use 5 bit address. How many bytes does it take (best case) to move a 16 bit number on an 8051. AVR will do it in two bytes. AVR does pretty good on code generation for real applications.

But enough for many small applications.

And you can add two registers using a single instruction without using an accumulator...

Everything is moving to lower geometries. Today ASSPs , tomorrow std products.

Well; I can happily say, I dont care if people choose ARM or AVR ;-)

--
Best Regards,
Ulf Samuelsson
Reply to
Ulf Samuelsson

Yep, done on the 16 bit CR16 and 32 bit CR32 from National , but the CompactRISC architecture seems to generate more code than the AVR ...

--
Best Regards,
Ulf Samuelsson
ulf@a-t-m-e-l.com
This message is intended to be my own personal view and it
may or may not be shared by my employer Atmel Nordic AB
Reply to
Ulf Samuelsson

I bow respectfully..

Which one is that?

Meindert

Reply to
Meindert Sprang

Thanks for the detail, here. That's not quite what I was thinking about, when I remarked they weren't in the business of selling CPUs. What you've added, though, doesn't really correct my comment. They are in the business, from what you say, in selling a highly integrated set of functions. That's not the same thing. It would be not so unlike claiming that selling a South Bridge ASIC for the Intel family was competing with a PC compatible UART from some other manufacturer, simply because this particular South Bridge ASIC happens to include a PC compatible UART function in it. Certainly, few would consider the vendor of the ASIC as competing in the business of selling UARTs.

It doesn't change my central thought, either. Was there a complete misunderstanding of expectations by these two companies? If so, what does that say of top management at both that a meeting of the minds was so fundamentally flawed? If not, if Ericsson understand some of what they may have been doing, why wouldn't Ericsson have chosen one of so many other less expensive and better options available to them?

I take it that there aren't public details to be found, here. If you know of any, I'd enjoy reading them.

Jon

Reply to
Jonathan Kirwan

Except National Semiconductor which had the patent on some of the key functionality of that specific UART.

Can't discuss internal Atmel business here, but there are some open sources of info.

As far as I understand, (and I repeat, I was not employed by Atmel at the time) They evaluated the market, ended up with the ARM and the AVR on the short list and selected the best technical solution for their needs, which was the AVR. This was so long time ago that I think any NDAs have expired

There was 5 major decision criteria and the AVR fullfilled all, with the best power consumption. I think all "less expensive and better options" you mention would fall on certain requirements for support (compiler and OS).

I was proposing the CompactRISC CR16 to them at the time, but National architecture group adamantly refused to support more than 2 MB addressing space and it had slightly higher power consumption than the AVR. It also uses more code. The 5 requirements from Ericsson was known by National for about two years. I managed to make NSC do a verilog synthesizable CR16 core (and convinced National to make ARM to do the ARM7TDMI-S in the process), fixed the right compiler, failed to convince NSC to port the right O/S. In the end, the lack of addressing space killed all prospects. The CR32 (which has not been released in any product) would have been able to solve the problem, but at a higher power consumption Once the "official" project was started National was prepared to do everything Ericsson required. Only problem was that Ericsson wanted to have everything ready two months after the start of the "official" project. (NSC managed to say *no* to Nokia TWICE when Nokia wanted National to do the baseband controller for the Nokia GSM phone)

The "court" has obviously decided that the license terms was violated otherwise no penalty would be awarded.

42 M$ might sound expensive, but an ARM core is not for free either. I think Sony-Ericsson which is but one of the buyers of the Ericsson ASICs sold 30 - 40 M phones last year. My guess is that licensing the ARM would have cost them similar amounts.
--
Best Regards,
Ulf Samuelsson
ulf@a-t-m-e-l.com
This message is intended to be my own personal view and it
may or may not be shared by my employer Atmel Nordic AB
Reply to
Ulf Samuelsson

All the ones with a 22-bit PC. Note 1) Having 8 MB address space is different from having 8 MB memory. Note 2) This is 8 MB PROGRAM memory space. AVR is a Harvard architecture. Note 3) Yes, 2**22 is only 4 M, but AVR instructions are addressed on 16-bit words.

Regards, -=Dave

--
Change is inevitable, progress is not.
Reply to
Dave Hansen

I know all this. But if you have 500k of code, you not only need the address space but also the memory space. And when I look at atmel.com, I don't see any AVR 's listed with that amount of memory. Hence my question.

Meindert

Reply to
Meindert Sprang

So in other words they are useless as embedded programmers in 8 bit systems. I rest my case.

Ian

Reply to
Ian Bell

Only if you insist that they have to use the accumulator style 8 bit CPUs instead of register oriented CPU s like the AVR which still generates good code using that style.

--
Best Regards,
Ulf Samuelsson
ulf@a-t-m-e-l.com
This message is intended to be my own personal view and it
may or may not be shared by my employer Atmel Nordic AB
Reply to
Ulf Samuelsson

We were talking about the 8051 and the AVR both of which have registers and an accumulator so your point is invalid.

Ian

Reply to
Ian Bell

On the AVR? Must be some new use of the term "accumulator" of which I was previously unaware.

Regards, -=Dave

--
Change is inevitable, progress is not.
Reply to
Dave Hansen

The fact that the 8051 has registers does not make it register oriented in my opinion. It is still accumulator oriented, since you have to use the accumulator in all operations. Adding two registers on 8051 = 3 instructions MOV A,R0 ADD A,R1 MOV R1,A while on the AVR it is ADD R1,R0

If A happens to contain either R0 or R1 , then this is reduces to ADD A,R0/R1 MOV R1,A

Having multiple ways of solving the problem make writing the compiler more complex. General purpose registers is the name of the game...

The AVR does not have any accumulator. All the upper 16 registers are equivalent, the lower 16 have restrictions. (The upper 6 have dual use as address registers of course) This means that is more complex to calculate the best possible instruction sequence.

--
Best Regards,
Ulf Samuelsson
ulf@a-t-m-e-l.com
This message is intended to be my own personal view and it
may or may not be shared by my employer Atmel Nordic AB
Reply to
Ulf Samuelsson

A large chunk of Atmel's AVR business is ASIC / Application Specific / large customers - this is clearly not a 'merchant device' and will have likely predated their ARM offerings...

-jg

Reply to
Jim Granville

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.