🎄Merry Christmas🎄Coolest Christmas Gift Received Ever!
🌟All products' price reduced by 15% off
🎁Hot-Selling Items: Buy 10 Get 1 Free

ecode Star Annulus

Through our last ecode Five-pointed Star project introduction, you must have some understandings on the ecode pen extension, today let’s do a more complicated drawing via the pen extension named Star Annulus, see the picture below:

ecode Star Annulus

Is it amazing? You can achieve it by making amendments on the basis of the code the five-pointed star.

Principle:

Please can think it by yourself and here is a tip by slowing the Gif and you may find the principle.

ecode Star Annulus

This figure is actually a combination of two movements, one is to draw a five-pointed star, the other is to turn a circle, first draw a five-pointed star, then turn it by an angle, then draw a five-pointed star, then turn it by another angle, and so on, one after the circle is turned, it becomes this beautiful figure. We have already learned how to draw a five-pointed star in the last project. Let’s turn an angle first, here we choose 15 degrees, and then execute it again, how many times do we need to turn it in total? One turn is 360 degrees, and one turn is 15 degrees, then 360/15=24, which means that you need to turn 24 times, and you just finish one turn, and then draw a five-pointed star for each turn until you finish one turn. Code:

ecode Star Annulus

1.Add another loop to the original that was executed 5 times, and execute it for 24 times

2.Add a sentence below the original loop that was executed 5 times, turn right 15 degrees, or turn left 15 degrees, and you’ve completed it!

Complete code:

ecode Star Annulus

If you have any ideas or opinions, please feel free to contact us via [email protected].

Leave a Reply

Frame 422188
Meet ELECFREAKS at BETT 2025!
Frame 422521
Our New Distributor——BERRYBASE
images
In March, ELECFREAKS supported 5 schools to carry out school science and technology festival activities
Frame 422188
Meet ELECFREAKS at BETT 2025!
Frame 422521
Our New Distributor——BERRYBASE
images
How to make a counter with micro:bit?
Monthly Archive