Loading ...
Sorry, an error occurred while loading the content.

Re: [jallist] How to insert this assm. into jal ?

Expand Messages
  • Vasile Surducan
    Lasse, if you learn now to insert asm into jal the answer to your problem is at piclist, in delay
    Message 1 of 5 , Sep 30, 2001
    • 0 Attachment
      Lasse, if you learn now to insert asm into jal the answer to your problem
      is at piclist, in delay
      generator:http://www.piclist.com/techref/piclist/codegen/delay
      Use the result in your jal code as distinctive procedure for both your
      delays.
      Vasile



      On Mon, 1 Oct 2001, Lasse Madsen wrote:

      > Hi wouter thanks for the code !
      > I wasnt aware of the local function but now i am.
      >
      > Im still fuzzing around with those delays
      >
      > If jal can generate these 2 delays as precise as assembler im still hooked
      > on jal :) but i cant get it work no matter what i do, jal malfunction or
      > code problem i dont know maybe you or others can straighten this out.
      >
      > <CODE>
      > procedure color_1 is
      > delay_100uS ( 8 )
      > delay_10uS ( 5 )
      > delay_1us ( 6 )
      > end procedure
      >
      > procedure color_8 is
      > delay_1mS ( 2 )
      > delay_100uS ( 1 )
      > delay_10us ( 4 )
      > delay_1us ( 4 )
      > end procedure
      >
      > </CODE>
      >
      > As you can see the goal is to produce precisely 856uS and 2144uS assembler
      > can do this but can jal ?
      > The above dont work and what ever else ive tried in jal also failed. Am i
      > really forced to learn better assembly language or does jal have the curage
      > to fight back. ( i believe that i has the nerve :)
      >
      > Best regards
      > Lasse Madsen
      >
      >
      >
      >
      >
      > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
      >
      >
    • Lasse Madsen
      Hi Vasile & Co. Awesome link you gave me ! I ve been sitting around and calculating the delays ( it worked but it took alot of time and alot of compiles in
      Message 2 of 5 , Oct 1, 2001
      • 0 Attachment
        Hi Vasile & Co.

        Awesome link you gave me !

        I've been sitting around and calculating the delays ( it worked but it took
        alot of time and alot of compiles in mplap to get it right )

        Thanks !

        Wouter helped me with putting assembler into jal - obviously (now) í was
        missing a statement.
        But when i insert my (mplap verified delay) into jal and it compiles the
        delay comes out totally wrong. To confirm this i opened the asm file which
        jal created and debug'ed it with mplaps stopwatch and that came out wrong -
        off by over 100uS in one of the delays ...

        So assembler within Jal doesnt solve my problems unless im missing
        something.

        Thanks for the support

        Regards
        Lasse
      • wouter van ooijen & floortje hanneman
        ... curage ... As a guideline I think you should not try to be more accurate than - 1 instruction in assembler (either standalone or inside Jal) - 10-100
        Message 3 of 5 , Oct 1, 2001
        • 0 Attachment
          > As you can see the goal is to produce precisely 856uS and 2144uS assembler
          > can do this but can jal ?
          > The above dont work and what ever else ive tried in jal also failed. Am i
          > really forced to learn better assembly language or does jal have the
          curage
          > to fight back. ( i believe that i has the nerve :)

          As a guideline I think you should not try to be more accurate than
          - 1 instruction in assembler (either standalone or inside Jal)
          - 10-100 instructions in pure Jal

          A PIC takes 4 cycles per instruction, an SX 1.

          Note that when you ant to manipulate I/O really precisely timed you must
          include the actual I/O instructions in the assembler part, because the time
          Jal takes to execute the I/O can vary from target to target.

          Wouter van Ooijen

          Van Ooijen Technische Informatica: http://www.voti.nl
          Jal compiler for PIC uC's: http://www.xs4all.nl/~wf/wouter/pic/jal
        Your message has been successfully submitted and would be delivered to recipients shortly.