Skip to content

JuanBindez/ohmslawAPI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ohmslaw API

import requests

SOURCE = 12
COMPONENT_VOLTS = 5.0

url = f'127.0.0.1:5000/api/v1/f_resistor?source={SOURCE}&component_voltage={COMPONENT_VOLTS}'
response = requests.get(url)

if response.status_code == 200:
    data = response.json()
    print(data)
else:
    print(f'Error: {response.status_code}')

Releases

No releases published

Packages

No packages published