Announcement

Collapse
No announcement yet.

OnBot Java and source control

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • OnBot Java and source control

    We have used Android Studio for 3 years now and so I understand the value proposition that OnBot Java offers. As I read the documentation, it is unclear to me how you manage the source code. Sure you write code that runs directly on the phone, but how do you get it back from the phone, let alone put it in git? Can anyone recommend best practices or a workflow that has worked for them?

    Thank you.

  • #2
    Robert Woodley After previously Using Android Studio for two seasons, we tried OnBot Java last season, and the only benefit we realized was wireless compiling, as we had never gotten wireless ADB to work. After surviving the season, with multiple code/version control related issues, we spent the off-season moving back to Android Studio, with Sourcetree/Git version control, as the lack of Version Control in OBJ was/is just too much risk vs. reward.

    As we don't consider ourselves expert coders, maybe there are other benefits we never made use of, but again, for us, the risk of losing all our code far outweighed the benefits.

    Good luck this season!
    Michael P Clark
    Founding Mentor, FTC 9958
    http://www.redfishrobotics.com
    "We're Hooked on FIRST"

    Comment


    • #3
      To transfer files from Onbot to PC, right click on the Opmode, select download, select folder.

      Don't have a workflow or best practice, just trying to get my team to use Onbot when fine tuning.

      Comment


      • #4
        Best solution is to combine Android Studio and OnBot. Do actual development in the nicer Android Studio IDE. This gives you access to version control as well as professional IDE features. Then instead of deploying an entire new robot controller to the robot phone you just upload the OpMode java files that have changed. OnBot then compiles just the OpModes and links them to the running robot controller for a much faster turnaround. You can literally tweak OpModes and the next time you press play on the robot the new code runs without even restarting. An FTC team even created a nice command line utility for this that can be integrated into Android Studio for uploading and downloading source.

        https://github.com/TheLostLambda/ftc_http/releases

        Comment


        • #5
          Yes ftc_http utility works great. Thanks to The LostLambda team. We used it last season and will use this season also.you can create external tool using this utility in AS to transfer file so you do not have to type commands.

          Comment


          • #6
            Helpful Hint: If you right click to download with no files specified, you will download a .zip of all of your code. Additionally, you can also select multiple files to download and they will also download as a .zip file.

            Comment


            • #7
              Last year, we stay in Android Studio to developed our code and all the functionality needed.... at some point, just before comp we switched to OnBot to fine tune our Auton... then stay in there until now... This year, we will most likely do the same thing except figure out how to integrate GitHub with it....

              Comment

              Working...
              X