>gee, didn't mean to come across as upset - far from
>it! I got a chuckle out of it. I've written a ton of
>PIC assembler and am getting tired of getting the
>btfsx sense wrong or being in the wrong bank. That's
>why I use the simulator on little snippets of code -
>too make sure I got it right. PICs are amazing but
>the instruction set basically sucks. A C compiler
>really does make it a lot easier for the average
>programmer.
>
>btw, my first code was Basic on an RCA Spectra 70 in
>1971 but I really dont count that as programming.
>
>--- Ake Hedman <
RemoveMEakhespam_OUT
KILLspameurosource.se> wrote:
>
>
>
>>Phil,
>>
>>You are right. I wrote my first code early 1980 so
>>you beat me with four
>>years. ;-)
>>
>>I also still write a lot of assembler still but not
>>for any religious
>>reasons. I just try to use the tool I think is best
>>for the job at
>>hand. For me it would be stupid to write all the
>>code for a 18F258 in
>>assembler. I can understand if one or maybe two K
>>of it was in
>>assembler because of some special needs. But as
>>always this is up to the
>>person doing the job. I can't see that one way or
>>the other should be
>>wrong even if I'm convinced that 32K C is easier to
>>maintain and debug
>>then 32K assembler.
>>
>>Sorry if I upset you in any way. It was not my
>>intent!
>>
>>/Ake
>>
>>phil B wrote:
>>
>>
>>
>>>I probably saw the light before you were
>>>
>>>
>>programming!
>>
>>
>>>I got hooked on C in 1976 on a PDP-11/45 running
>>>
>>>
>>Unix
>>
>>
>>>V6. (it had 256K of RAM and supported 16
>>>
>>>
>>concurrent
>>
>>
>>>users. those were the days. sigh...).
>>>
>>>But there is no substitute for understanding the
>>>machine architecture. I still write lots of code
>>>
>>>
>>in
>>
>>
>>>ASM.
>>>
>>>Sorry for helping the thread to veer OT...
>>>
>>>Phil
>>>
>>>--- Ake Hedman <
RemoveMEakheTakeThisOuT
spameurosource.se> wrote:
>>>
>>>
>>>
>>>
>>>>You have seen the light... ;-)
>>>>
>>>>Cheers
>>>>/Ake
>>>>
>>>>phil B wrote:
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>>While I prefer to understand the chip to a depth
>>>>>
>>>>>
>>>>>
>>>>>
>>>>that
>>>>
>>>>
>>>>
>>>>
>>>>>only asm allows, it is completely valid that some
>>>>>
>>>>>
>>>>>
>>>>>
>>>>one
>>>>
>>>>
>>>>
>>>>
>>>>>whould prefer to code in C. The benefits of C
>>>>>
>>>>>
>>are
>>
>>
>>>>>very real.
>>>>>
>>>>>As part of evaluating cc5x, I rewrote my driveway
>>>>>sensor logger code in C (ds1302-SPI, relay,
>>>>>
>>>>>
>>serial
>>
>>
>>>>>I/O). It took all of about 3 hours vs the 2 days
>>>>>
>>>>>
>>>>>
>>>>>
>>>>to
>>>>
>>>>
>>>>
>>>>
>>>>>do the asm version (and I borrowed a lot of asm
>>>>>
>>>>>
>>>>>
>>>>>
>>>>code
>>>>>from previous projects). Granted, some time was
>>>>saved
>>>>
>>>>
>>>>
>>>>
>>>>>because I was writing the program the second time
>>>>>
>>>>>
>>>>>
>>>>>
>>>>but
>>>>
>>>>
>>>>
>>>>
>>>>>not having to worry about details like the screwy
>>>>>conditional instructions of the PIC is a big
>>>>>
>>>>>
>>>>>
>>>>>
>>>>benefit.
>>>>
>>>>
>>>>
>>>>
>>>>>Phil
>>>>>
>>>>>--- Jan-Erik Soderholm
>>>>>
>>>>>
>>>>>
>>>>>
>>>><
EraseMEjan-erik.soderholmspam
spamBeGonetelia.com>
>>>>
>>>>
>>>>
>>>>
>>>>>wrote:
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>>Hasan A. Khan wrote :
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>>Executing: "C:\Program
>>>>>>>
>>>>>>>
>>Files\bknd\CC5X\CC5X.EXE"
>>
>>
>>>>>>>SAMPLE1.C -CC -fINHX8M -p16F628 -I"C:\Program
>>>>>>>Files\bknd\CC5X" -a -L -Q -V -FM +reloc.inc
>>>>>>>Error : Unable to open file 'reloc.inc'
>>>>>>>
>>>>>>>why can't the compiler find it?
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>Does it exist at all ?
>>>>>>
>>>>>>Jan-Erik.
>>>>>>
>>>>>>PS:
>>>>>>You also wrote :
>>>>>>" One thing I learned was that I didn't have to
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>use
>>>>
>>>>
>>>>
>>>>
>>>>>>assembler..."
>>>>>>
>>>>>>No, but why not ?
>>>>>>You are using a 16F628. Not that much memory.
>>>>>>
>>>>>>
>>And
>>
>>
>>>>>>you'll
>>>>>>probaby learn the chip faster with assembler
>>>>>>
>>>>>>
>>then
>>
>>
>>>>>>with C.
>>>>>>Have you written anything in (PIC) assembler ?
>>>>>>
>>>>>>
>>>>>>
>>>>>>--