Update direct_pi.py