The following changes have been made to Python for it to run on an embedded system:
No files or sockets can be opened from inside Python scripts.
No system calls can be made from inside Python scripts nor is the posix package available.
The maximum recursion depth is fixed to twenty.
The total amount of dynamic memory available for Python itself and Python scripts (excluding the Python cache) is capped at 8 Mb for 32-bit SR OS and 16 Mb for 64-bit SR OS on a CPM.
The size of the Python script source file should be less than 60 kb.