This is an expert of my assignment. I am not very sure about what does this sentence mean and how to achieve this.
Accept a command line argument write to the file with: the time tab (\t in the print statement) and
5. [see Sections C to L] Work on the design for a program that will do the following:
a. Blink an LED with the following switch options (0 switch off – blink at 2 second intervals, 1 switch
on – blink at 1 second intervals).
b. Every time through the state of the LED changes, it should write to the file with: the time tab (\t in
the print statement), format such that the time from when the program started out to the nearest
millisecond), and switch state (on or off).
Write the code snippets required with the necessary imported libraries. Include a flow chart or
pseudocode for this. This will become program2.py.
6. [see Sections C to L] Alter the program from above to accept arguments for the following:
a. time for the program to run, default to 10 seconds
b. delay between blinks
c. debug value to display some diagnostic information
d. The switch should now either allow the led to blink (on) or not blink at all (off)
e. Accept a command line argument write to the file with: the time tab (\t in the print statement) and
switch state (on or off).
Write the code snippets required with the necessary imported libraries. Include a flow chart or
psuedocode for this. This will become program3.py
Statistics: Posted by ricky2777 — Mon Jan 20, 2025 1:32 am — Replies 0 — Views 12