<div dir="ltr">Alex,<div><br></div><div>If you want Python threading to work with multiple processors it won't work because of the GIL (Global Interpreter Log) in Python. It is generally better to use processes than threading.</div><div><br></div><div>With that said both threading and processes are not very difficult in Python and if running on a Linux OS the speed will be about the same.</div><div><br></div><div>The python docs for both  are:</div><div><a href="https://docs.python.org/3.6/library/threading.html">https://docs.python.org/3.6/library/threading.html</a><br></div><div><a href="https://docs.python.org/3.6/library/multiprocessing.html">https://docs.python.org/3.6/library/multiprocessing.html</a><br></div><div><br></div><div>Both of these methods follow a similar paradigm.</div><div><br></div><div>The docs above have examples. In general, if you have Python question consult the docs they are very well written and complete.</div><div><br></div><div>At the top of the screen, you can flip to Python 2.7.x.</div><div><br></div><div>~Carl</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Nov 14, 2017 at 2:38 PM, Alex Davis via TriEmbed <span dir="ltr"><<a href="mailto:triembed@triembed.org" target="_blank">triembed@triembed.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word;line-break:after-white-space">Sorry this is somewhat off-topic for embedded:<div><br></div><div>Anyone have experience with threading in python? I’ve written a combo clock and RSS feed scroller for a character-based VFD display. Via polling, it manages to keep the time ticking on the upper line while scrolling RSS stuff on the lower line, iterating through an array of headlines. This is fine until it needs to update the RSS feed, in which case it’s outside of my polling loop and I have to put up a “please wait” message.</div><div><br></div><div>I’m curious if you’ve come across a good threading guide for beginners.</div><div><br></div><div>Thanks,</div><div>Alex<br><div>
<div style="color:rgb(0,0,0);font-family:Monaco;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><br class="m_-6173951343189732087Apple-interchange-newline">|\ |  (¯  \/ |¯\  |V| |\ ¯|¯ |¯) | \/ | | | |¯\ (¯   /¯  /\ |V|</div><div style="color:rgb(0,0,0);font-family:Monaco;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">|-||_ (_  /\ |_/ @| | |-| |  | \ | /\ |^| | |_/ (_ . \_  \/ | |</div><br style="color:rgb(0,0,0);font-family:Monaco;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><br style="color:rgb(0,0,0);font-family:Monaco;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><br style="color:rgb(0,0,0);font-family:Monaco;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><br style="color:rgb(0,0,0);font-family:Monaco;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><br style="color:rgb(0,0,0);font-family:Monaco;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><br style="color:rgb(0,0,0);font-family:Monaco;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
</div>
<br></div></div><br>______________________________<wbr>_________________<br>
Triangle, NC Embedded Computing mailing list<br>
<a href="mailto:TriEmbed@triembed.org">TriEmbed@triembed.org</a><br>
<a href="http://mail.triembed.org/mailman/listinfo/triembed_triembed.org" rel="noreferrer" target="_blank">http://mail.triembed.org/<wbr>mailman/listinfo/triembed_<wbr>triembed.org</a><br>
TriEmbed web site: <a href="http://TriEmbed.org" rel="noreferrer" target="_blank">http://TriEmbed.org</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">-------------------------------------------------------------------------------<br>Carl J. Nobile (Software Engineer)<br><a href="mailto:carl.nobile@gmail.com" target="_blank">carl.nobile@gmail.com</a><br>-------------------------------------------------------------------------------</div>
</div>