Re: [Sdcc-user] Function addressing

2009-01-18 Thread Jesus Calvino-Fraga
The resulting code using the C version generates this assembly instructions: mov _fp,#0xF0 mov (_fp + 1),#0xFF . . . mov dpl,_fp mov dph,(_fp + 1) lcall __sdcc_call_dptr That is 15 bytes of code memory and two bytes of RAM. On the other hand, the assembly call (within C) lcal

Re: [Sdcc-user] [OT] Equipment for amateur robotics

2009-01-18 Thread Matthew Smith
For Aussies: Web site is pretty crappy but they do a good paper catalogue. Range is a bit limited but prices are MUCH cheaper than the likes of RS - even in 1-off quantities. Flat $8 AUD freight for web orders. No minimum order quantities. Have a range of motor

Re: [Sdcc-user] Function addressing

2009-01-18 Thread Maarten Brock
Or in C void (*fp)(void) = 0xfff0; fp(); > Try: > > _asm lcall 0xfff0 _endasm; > > > At 10:59 AM 18/01/2009, Gudjon I. Gudjonsson wrote: > > >Hi > > Sorry once again if the question is silly but I am trying to call the > >PGM_MTP at address 0xFFF0 > >function in the in application bootlo

Re: [Sdcc-user] [OT] Equipment for amateur robotics

2009-01-18 Thread Richard Gray
If you would prefer an EU supplier, then I can think of a couple of places in the UK... http://www.maplin.co.uk and... http://uk.rs-online.com/ On Sunday 18 January 2009 14:41:18 Ori Idan wrote: > I would like as a hobby to build a small Robot. > I am a programmer with little experience in mec

Re: [Sdcc-user] How to generete .map/.mem files with PIC port?

2009-01-18 Thread Raphael Neider
Hi, > But now I have a multifile PIC project and I cannot see the.map nor > .mem files anywhere. And I can't find a relevant command line option > to turn them on either. For the PIC ports (pic14 and pic16), the linker (gplink) is responsible for creating the .map files. You can call for them by

Re: [Sdcc-user] [OT] Equipment for amateur robotics

2009-01-18 Thread Jesus Calvino-Fraga
Take a look at www.robotshop.ca At 06:41 AM 18/01/2009, you wrote: >I would like as a hobby to build a small Robot. >I am a programmer with little experience in mechanics. >Does someone on this list knows where I can buy servomotrs etc.? > >-- >Ori Idan > >---

Re: [Sdcc-user] Function addressing

2009-01-18 Thread Jesus Calvino-Fraga
Try: _asm lcall 0xfff0 _endasm; At 10:59 AM 18/01/2009, Gudjon I. Gudjonsson wrote: >Hi > Sorry once again if the question is silly but I am trying to call the >PGM_MTP at address 0xFFF0 >function in the in application bootloader for the NXP 8051 microcontrollers. >The problem is that I don

Re: [Sdcc-user] How to generete .map/.mem files with PIC port?

2009-01-18 Thread bobrob
- Kustaa Nyholm wrote: > Hi, > > according to SDCC manual .mem and .map are automatically genereated, > and indeed I recall them being generated when I was working with HC08. > > But now I have a multifile PIC project and I cannot see the.map nor > .mem > files anywhere. And I can't find a

[Sdcc-user] How to generete .map/.mem files with PIC port?

2009-01-18 Thread Kustaa Nyholm
Hi, according to SDCC manual .mem and .map are automatically genereated, and indeed I recall them being generated when I was working with HC08. But now I have a multifile PIC project and I cannot see the.map nor .mem files anywhere. And I can't find a relevant command line option to turn them on

[Sdcc-user] Function addressing

2009-01-18 Thread Gudjon I. Gudjonsson
Hi Sorry once again if the question is silly but I am trying to call the PGM_MTP at address 0xFFF0 function in the in application bootloader for the NXP 8051 microcontrollers. The problem is that I don't know how to put an absolute address on a function. I know how to absolute address variab

[Sdcc-user] [OT] Equipment for amateur robotics

2009-01-18 Thread Ori Idan
I would like as a hobby to build a small Robot. I am a programmer with little experience in mechanics. Does someone on this list knows where I can buy servomotrs etc.? -- Ori Idan -- This SF.net email is sponsored by: Sou

Re: [Sdcc-user] unsigned long support for PIC18F4550 ?

2009-01-18 Thread Kustaa Nyholm
Hi, actually, just 10 minutes ago, (partially) solved the issue. To get some more debug info, I tried to find out how come my printf/uart had become unfonctional. After stripping down the code, function by function towards what I knew was the last working configuration, I found out that I was usi

Re: [Sdcc-user] unsigned long support for PIC18F4550 ?

2009-01-18 Thread Richard Gray
I am guessing a bit, but try:- STEPPER.brakeDistance = (unsigned long) ((STEPPER.maxSpeed+STEPPER.minSpeed)*(STEPPER.maxSpeed-STEPPER.minSpeed))/(2*STEPPER.acceleration); Of course, you could declare all the relevant variables unsigned longs and not bother with the cast. FWIW, I have had troubl

Re: [Sdcc-user] New TinyOS 8051 platform results in non zero exit code

2009-01-18 Thread Martin Leopold
Hi Maarten. On Sat, 2009-01-17 at 01:02 +0100, Maarten Brock wrote: > But it looks like Martin uses it on an unsigned char and > not on a bit variable. I doubt it will create a problem > here. Probably not even suboptimal code. Thanks for the reassurance, but there must be some way of expressin

[Sdcc-user] unsigned long support for PIC18F4550 ?

2009-01-18 Thread Kustaa Nyholm
Hi, a bit early to ask this but it may take a few hours before I can actually see what values I'm getting (my usart/serial port is not functioning at the moment) so I might as well ask here. Is there something to I need to do to enable support for 32 bit arithm ops? It appears that the following