Do I really need all the setup in the script.py file

59 views
Skip to first unread message

Tom Dickerson

unread,
May 15, 2019, 5:53:48 PM5/15/19
to WebIOPi
If I am using the Javascript API, do I need to setup all input and output in the script.py file or can I just use the HTML with Javascript to setup everything.  I am a beginner and just trying to get my head around how the javascript and python work together.

hal8000b

unread,
May 22, 2019, 6:17:29 PM5/22/19
to WebIOPi
Yes, you always need to include a script.py file.

The script.py controls the RPi GPIO ports,, I2C and rest of your connected hardware.
The HTML  displays your webpage content, (use CSS to style), javascript will interface
the HTML to call python scripts and functions in script.py

There are some tutorials, framework basis  (which I think Eric meant "Framework Basic")
link below:
Reply all
Reply to author
Forward
0 new messages