a raspberry pi hexy - python conference ph 2016

Post on 22-Jan-2017

327 Views

Category:

Education

3 Downloads

Preview:

Click to see full reader

TRANSCRIPT

A Raspberry Pi Hexy

Prepared for PyCon PH Feb 27, 2016, University of the Philippines Cebu

Slides by Mithi Sevilla

Original Code: github.com/ArcBotics/PoMoCo

My Code (WIP): github.com/mithi/hexy

Don’t just do something. Stand there.The Art of Linux Programming

PEP8? PEP20? DRY? Minimal Duplication? Intention-Revealing, Meaningful Names? What else?

Class Hexapod(): #six Leg objects, one Neck objectClass Leg(): def hip(angle): def knee(angle): def ankle(angle): def replant_foot(h, k, a): ....

Class Neck(): def pose(angle): def off():

Class Hexapod(): #six Leg objects, one Neck objectClass Leg(): #three Joint objects: hip, ankle, knee def move(h, k, a): ...

Class Joint(): def pose(angle) def off()

http://mithi.xyz

two minute video.

Thank you for listening.

top related