repo for the lego scratch block coding and related materials
-
please use the http as the img1 shows to copy the repo address
-
since the Mindstorm Innovator software platform can only be run in windows, so please use "git for windows" to do any git operation, here is the downnload address: https://gitforwindows.org/
-
in the git-bash window, you can use "git clone https://github.com/m-xin/lego-stealth-python.git" , to pull the whole repo to your local machine
-
please do not directly modify the "master" branch. you need to create your own local branch based on the master to do any modifications
-
if you believe your scratch code block is able to be used as the final version, you can merge to the master. definition of the final version:
- you code block schema would not change anymore,
- the control parameters are generally comfirmed in your robot platform.
-
here are some commands as your reference
$ git clone https://github.com/m-xin/lego-stealth-python.git
$ git checkout -b <kid's name>/mission_number_mission_name ex: $ git checkout -b williamx/mission1_cinema_mission13_soundtrack
when you Temporarily have done your work, please use the following commands to save your work and push to the remote repo
# added all changes $ git add . # commit your changes $ git commit -m "write a brief msg to indicate your changes, no more than ten words." ex: $ git commit -m "finished mission1 para tuning." # upload your work to the remote repo (cloud) $ git push origin <your branch name> ex: $ git push origin williamx/mission1_cinema_mission13_soundtrack
# check your branch name, and status, such as update, untracked/unsaved modifications etc. $ git status # check the local branches and its upstreams $ git branch -vv # check all available branch (local and remote) $ git branch -a # check the commit record $ git log
we will use the master branch to deploy the combined code block.
-
please create a folder with the name of your kid's firstname and last name initial.
-
in the end, we will combine all kid's work to a filename of 'combined', in the folder mane of "combined".
-
Here are some useful video links to teach kids to encapsulate their work to a function, how to make a PID control, how to use Gyro for straight line movement, and cornering. # gyro turn: https://www.youtube.com/watch?v=nXLXmUY4JnQ # how to use "my block" (i.e. functions/modules in c++ or python): https://www.youtube.com/watch?v=PwSW8L5stmM # PID control: https://www.youtube.com/watch?v=HGwXER0hRMg
-
Please feel free to add items here, Thanks!