My Project
task2.uiTask Class Reference

Public Member Functions

def __init__ (self)
 collects encoder driver counter data and stores into an array
 
def run (self)
 runs the finite state machine of collecting Data on Nucleo
 
def transitionTo (self, newState)
 transitions from current state to next More...
 

Public Attributes

 state
 Set state equal to 0.
 
 myuart
 Set UART communication.
 
 time
 Time array that hold data for 30 secs to plot.
 
 value
 Data array.
 
 idx
 iteration of list
 
 key
 collect encoder updated value for each index of time self.valueNum = self.encoder2.get_position() print("valueNum: ", self.valueNum)
 
 start
 start recording time
 
 mode
 set mode to figure which encoder to collect data for More...
 
 now
 time updated when state is collecting data
 
 duration
 duration of when G is clicked and current time in microsec
 

Static Public Attributes

int S0_WAITING = 0
 Initiliaze Program with State 0, waiting for G to be pushed.
 
int S1_COLLECT_DATA = 1
 State 1 starts collecting and storing data.
 
int S2_SEND_DATA = 2
 State 2 sends data to PC.
 

Member Function Documentation

◆ transitionTo()

def task2.uiTask.transitionTo (   self,
  newState 
)

transitions from current state to next

Parameters
newStateThe next desire state
Returns
the new state to transition to

Member Data Documentation

◆ mode

task2.uiTask.mode

set mode to figure which encoder to collect data for

collect encoder updated value for each index of time self.valueNum = self.encoder1.get_position() print("valueNum: ", self.valueNum)


The documentation for this class was generated from the following file: