Python or Lua - Realtime Application

I started using Python in a real-time application (serial communication with gps modules right away), but recently learned about Lua . Which language is more suitable for the application?

My definition of real time in this context is the fastest time for receiving, processing and outputting data. (Feedback system)

+4
source share
2 answers

Both are beautiful languages. You do not need years to study. An easy way to make a decision is to see which modules already exist.

For example, you mentioned that your application is connected with GPS. See which libraries are already written to connect Python and Lua to your specific GPS equipment. Perhaps someone has already done most of the hard work for you. If not, then go down a step. If you are talking to your GPS via I2C, check out the I2C libraries in both languages. See which ones are more popular and better supported.

However, garbage collectors have historically encountered real-time compliance issues. Depending on yours, you may need to switch to a lower level. You must also make sure that any system you work on will support your programming environment. I worked with systems in which Python would be great, but it doesn't fit into the 5K code space.

+7
source

Take a look at eLua and see if it fits your needs.

+5
source

Source: https://habr.com/ru/post/1344671/


All Articles