How translate Arduino code to Proton.


Closed Thread
Results 1 to 3 of 3
  1. #1
    Join Date
    May 2013
    Posts
    12

    Default How translate Arduino code to Proton.

    Hello, All


    I have a problem with an engine acceleration PWM works with analog joystick of the PS3 and accelerating very fast.
    with this code I found quite solves the problem and is much smoother.
    The only thing I do not understand many parts, so that they can write in Proton.


    Arduino Code:
    Code:
    void loop() {
    
    
    potval=analogRead(potentiometer);
    potval=map(potval,0,1023,0,180);
    
    
    while(curval<potval){
      potval=analogRead(potentiometer);
      potval=map(potval,0,1023,0,180);
      curval=curval+1;
      ESC.write(curval);
      SoftwareServo::refresh();
      Serial.println(curval);
      delay(50);}
    THX.

  2. #2
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    3,796


    Did you find this post helpful? Yes | No

    Default Re: How translate Arduino code to Proton.

    This is Melabs Pic Basic forum. Maybe you have to ask this in the http://www.protonbasic.co.uk/forum.php forum.

    Ioannis

  3. #3
    Join Date
    May 2013
    Posts
    12


    Did you find this post helpful? Yes | No

    Default Re: How translate Arduino code to Proton.

    Hey,

    Ok, Thx.

Similar Threads

  1. Proton+ and PicBasicpro
    By Rob Martin in forum mel PIC BASIC Pro
    Replies: 34
    Last Post: - 9th November 2007, 08:58
  2. Translate code..
    By xobx in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 17th July 2007, 14:13
  3. proton problems
    By shantanu in forum Off Topic
    Replies: 1
    Last Post: - 10th February 2007, 13:39
  4. changing proton code to pic basic
    By bbarney in forum General
    Replies: 3
    Last Post: - 15th November 2005, 01:26
  5. Proton net
    By CBUK in forum General
    Replies: 1
    Last Post: - 11th May 2004, 14:55

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts