Thema: micro:bit
Thema: micro:bit
Anleitung: Erste Schritte
Anleitung: Erste Schritte
Anleitung
import ti_plotlib as plt
from ti_system import *
from microbit import *
from mb_sensr import *
plt.window(-1800,1800,-1200,1200)
x = 318/2
y = 30+212/2
r = 981*318/(plt.xmax-plt.xmin)
plt.color(240,240,240)
plt.cls()
plt.gr.fillCircle(x,y,r)
plt.grid(200,200,"solid")
plt.color(0,0,0)
plt.gr.drawArc(x-r,y-r,2*r,2*r,0,3600)
plt.axes("on")
plt.labels("x (mg) "," y (mg)",8,1)
plt.gr.drawString("981 mg",x+15,y-15)
plt.color(255,0,0)
while not escape():
accx = accelerometer.get_x()
accy = accelerometer.get_y()
plt.plot(accx,accy,"o")
plt.show_plot()
Seite 12
TI-84 Plus CE-T
TI-84 Plus CE-T
© 2021 Texas Instruments