#pip3 install ardupy-aipLastly, it is time to download and install Visual Studio Code and the Seeed ArduPy IDE extension. Visual Studio Code can be downloaded here for Windows, Mac, and Linux. Once installed, search the Extensions Market for Seeed ArduPy IDE. Once selected in the search results, click Install, and the plugin will be added to Visual Studio. Now you are set up to take advantage of all the features of the ArduPy toolset.
#aip boardThis will list any ArduPy compatible boards currently hooked up to your computer. If you ever forget this command or to learn how to use the AIP, issue the help command:
#aip helpThe help command is the go-to command to learn everything that is possible via the ArduPy command-line tool. Some of the additional commands available through the AIP include:
Save the boot.py file. Next, from the command-line interface, issue the following command:import time import board from digitalio import DigitalInOut, Direction led = DigitalInOut(board.D13) led.direction = Direction.OUTPUT while True: led.value = True print("LED ON") time.sleep(1) led.value = False print("LED OFF") time.sleep(1)
# aip shell -n -c "put //boot.py"
(To enlarge .....Click it)
Michael Parks, P.E. |
Michael Parks, P.E. is the co-founder of Green Shoe Garage, a custom electronics design studio and embedded security research firm located in Western Maryland. He produces the Gears of Resistance Podcast to help raise public awareness of technical and scientific matters. Michael is also a licensed Professional Engineer in the state of Maryland and holds a Master’s degree in systems engineering from Johns Hopkins University. |