Added rudimentary sensor code. Not working.