CALPOLY MECHATRONICS
Documentation for all Mechatronics Labs
me405_lab3_front_end.py File Reference

This module runs on a pc and sends and recieves data to the nucleo. More...

Functions

def me405_lab3_front_end.sendChar ()
 Method to send an ascii character to the Nucleo over serial. More...
 
def me405_lab3_front_end.readLine ()
 A method to read from a line from the serial port. More...
 

Variables

 me405_lab3_front_end.ser = serial.Serial(port='COM3',baudrate=115200,timeout=1)
 
list me405_lab3_front_end.data = []
 
def me405_lab3_front_end.temp = readLine()
 

Detailed Description

This module runs on a pc and sends and recieves data to the nucleo.

This module first prompts the user to input an ASCII character to send to the nucleo, which is used to signal to the nucleo that it should start collecting data. Then, this module reads data from the nucleo via serial and prints it out.

Author
Eliot Briefer
Date
May 6, 2020

Function Documentation

◆ readLine()

def me405_lab3_front_end.readLine ( )

A method to read from a line from the serial port.

Returns
An ASCII string representation of the line read from serial.

◆ sendChar()

def me405_lab3_front_end.sendChar ( )

Method to send an ascii character to the Nucleo over serial.

When called, this method prompts the user to input a character, then waits for user input

Returns
the value sent over serial