Utilizing Low Cost Linux Micro Computer & Utilizing Low-Cost Linux ...

3 downloads 172289 Views 1MB Size Report
Dec 12, 2013 - Android Phone Solutions on Cube-Satellites .... UART and I2C cameras in local markets are slow in storage process. 25. Image Capture. 10. 15.
Utilizing Low‐Cost Linux Micro‐Computer &  Utilizing Low Cost Linux Micro Computer & Android Phone Solutions on Cube‐Satellites Ahmed Farid1, Ahmed Samy2, Ahmed Shalaby2, Ahmed Tarek2,  Mahmoud Ayyad2, Muhammad Assem2, Samy Amin2 1 B.Sc. Graduation project, Computer Engineering Department, October 

University for Modern Sciences & Arts 2 B.Sc. Graduation project, Aerospace Engineering Department, Cairo University

O tli Outline • • • •

Problem Definition Proposed Approach Approach Description Linux Micro‐Computers

• • • •

Android Smartphones Interface Models Proposed Improvements Conclusion

Problem Definition Problem Definition • IImplementation of satellite computing functionalities as a  l t ti f t llit ti f ti liti proof of concept, given the following circumstances: – Minimal time span (1 Year + No prior space know‐how). – Lesser funding for overall project. (Student‐funded) – Lack of/Import restrictions on certain components.

• The following capabilities are required for the onboard  computer: – – – – –

12/12/2013

Autonomous operation.  Operating a payload camera  P idi Providing necessary interfaces. (i.e. I2C, SPI, A/D… etc.)  i f (i I2C SPI A/D ) Real‐time system monitoring.  Bidirectional communications handling. Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

2/14

Proposed Approach Proposed Approach Recommended Strategies: Recommended Strategies: • Budget cannot afford space‐qualified systems. Budget cannot afford space‐qualified systems • More focus on local markets and affordable options. • Design Complexity = Possible issues = More troubleshooting time.

Suitable approaches: • Linux Micro‐Computers • Android Smartphones

12/12/2013

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

3/14

Approach Description Approach Description Linux Micro‐Computers

Android Smartphone

Picture

Specifications

‐ Low cost (25‐200$) cost (25 200$)

‐ Relatively low‐cost (300‐500$) Relatively low cost (300 500$)

‐700‐1000 MHz, 512 Mb RAM

‐Dual 1 GHz processor

‐ SD Card, USB, Ethernet, Audio SD Card USB Ethernet Audio

‐ 512‐2 Gb 512 2 Gb RAM

‐ Hardware I/O (µART, SPI, I2C, GPIO)

‐ Integrated camera, sensors, and SD card

‐ Power: 1‐2.3 W Power: 1‐2 3 W

‐ Power: Power: Device and usage dependant  Device and usage dependant (Ex: Galaxy S3 is 0.45 W on normal use.) ‐ Weight: Device dependant

‐ Weight: 37‐45 gm Disadvantages

12/12/2013

‐ Missing hardware IO in some OBCs  (Analog, PWM as in the Raspberry Pi)

‐ No built‐in hardware I/O

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

4/14

Linux Micro‐Computers:

Sensor Readings Acquisition & Actuator Control R Requirements i

I l Implementation i

• Interface with sensors (I2C, SPI, A/D) • Control actuators (PWM) ( )

• An external MCU is used, acting as a  compatibility layer (Ex: PIC16f877).  p y y ( ) Connections are over I2C or µART channels.

Complications

• Simple voltage level shifters were  i l implemented (5‐3.3 v). t d (5 3 3 )

• Some interfaces may not be available Some interfaces may not be available on  on accessible OBCs (PWM, A/D) • Difference in voltage logic levels I2C

I2C Sensor

Linux Micro‐computer

I2C Sensor

MCU

Analog In

Analog Sensor

PWM

Analog Actuator

I2C configuration I2C configuration

12/12/2013

I2C

SDA SCL

Digital UART SPI Digital, UART, SPI,  Audio… etc.

UART

Linux Micro‐computer

MCU I2C Sensor

I2C Sensor

Analog In

Analog A l Sensor

PWM

A l Analog Actuator

Other  Hardware

Digital, UART, SPI,  A di Audio… etc.

Transistor‐based Logic Level Shifter Logic‐Level Shifter

Other  Hardware

Serial configuration Serial configuration Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

5/14

Linux Micro‐Computers:

Operating Payload Camera R Requirements i

I l Implementation i

• Camera interface for image capturing • Image storage g g

• Usage of USB cameras. (Typically webcams)

Complications

• Since Linux is used, interface can be done  using programming libraries or ready‐made  packages (fswebcam).

• UART and I2C cameras in local markets are  slow in storage process.

• Capture takes 2 seconds for 320x240 images.

25 20

Image Capture g p Duration

15

µART

10

Webcam

5 Linksprite µART Camera 12/12/2013

Playstation Eye Webcam

0 38.4K Baud

PIL

PyGame

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

Fswebcam 6/14

Linux Micro‐Computers:

Communications R Requirements i

I l Implementation i

• Send/Receive Data with a ground‐station • Interpret commands from a ground‐station p g

• I2C, SPI, or UART are utilized in the presence  of low‐level communications hardware.

Complications • Due to import restrictions, no low‐level long  range VHF/UHF transceivers are sold. • Only hand‐held radio transceivers (VHF/UHF)  are available, with audio interface only.

• Robot36 was used to convert images to 36‐ second sound. Modifying sampling rate helps  reduce transmission time. d t i i ti • AFSK was used to convert binaries to sound  at 1200 bps transmission speed. p p • DTMF was used to create downlink frame  headers‐trailers, and as uplink commands

Data encoding workflow d kfl Downlink Transmission Example

Beacon 12/12/2013

Type: Binaries Type: Binaries

Binaries

Type: Image Type: Image

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

Images

END 7/14

Linux Micro‐Computers:

Computation & Operations Management R Requirements i

I l Implementation i

• Management of subroutines and modes. • Use of an attitude determination algorithm. g

• Modules are compiled as standalone, but  called by a single controller program. y g p g

Complications • Prototypes yp and libraries not in C are time  consuming in code porting. • Integrating several modules in a single C  program is considerably  complex.

• The controller program has two main parts:  Listener and state computation. • Attitude determination written in Matlab script is run using Octave.

G P S

S u b r o u t in e  1

1

S e n so rs M a in G S  C o m m an d s O p e r a t io n s Seq u en ce   

12/12/2013

2

S u b r o u t in e  2

3

Autonomous subroutine initiation  based on state. based on state Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

S u b r o u t in e  3   

8/14

Android Smartphones: Sensor Readings Acquisition, Actuator Control, & Image Capture R Requirements i

I l Implementation i

• Interface with sensors . • Control actuator • Image capture and storage.

• Sensors and camera come built‐in. Only Java  codingg is required. q • OTG connection to external MCU (Ex:  IOIO, Arduino, Attiny85) for actuators.

Complications • Phone has no low‐level hardware interface. Return Readings

Readings Listening

Register Sensor/Manager Object Sensor/Manager Object Accelerometer Gyroscope

Readings

Sensor  Manager

GPS Magnetometer

Sensor interface code workflow 12/12/2013

Android app controlling DC fan and motor with MCU Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

9/14

Android Smartphones:

Computations & Operations Management R Requirements i

I l Implementation i

• Management of subroutines and modes.

• Virtual Linux OS is run in parallel to the native  Android OS. (Initiated through CHROOT) ( g )

Complications • Prototypes and libraries not in Java/C are time  consuming in code porting.

SSH (Commands)

Sensors

MCU

Audio

Camera

Robot36

AFSK

Attitude  Determination

Sound  Manipulator

SD Card (Storage)

Android Java Modules

12/12/2013

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

Linux Modules

10/14

Android Smartphones:

Communications & Attitude Determination R Requirements i

I l Implementation i

• Manage communications with the ground. • Use of an attitude determination algorithm. g

• Using virtual Linux technique: Codes, libraries  and software packages implemented on Linux  p g p micro‐computers are easily ported to Android  (With minor modifications).

Complications • Porting modules to Android is time costly.

• Robot36, AFSK, and Octave R b t36 AFSK d O t are utilized. tili d

Radio Transceiver (3) Audio

Comm Payload

SSTV

C fi Confirm Modulation

Android App

(2) SSH (1) SSH

Modulation Command

Images

System  Logs

Actuators

Octave (On Linux) Binaries

(4) MCU

(1) Readings

Android App

Comm Audio

Android communications workflow 12/12/2013

Control

AFSK

SD Card

Images

Sensors

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

Control Parameters (3) SSH (2) SSH

Octave (On Linux)

Readings

Android ADC workflow 11/14

Interface Models Interface Models

12/12/2013

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

12/14

Conclusion Rapid  Prototyping

Linux  Possibilities • • •

Capacity building within small time and limited  resources. Faster adoption of space systems development in  developing countries. Attracting smaller generations to learn of space Attracting smaller generations to learn of space  engineering.

Overcoming  Technical‐non Technical non Difficulties

12/12/2013

Low‐cost  Development

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

13/14

Thank you for your time Thank you for your time. Acknowledgements g •

Our mentors: A. Sherif, A. Desoki, and M.  Khalil for their highly valued assessments  and supporting us with their knowledge and  expertise in the field expertise in the field.



My project colleagues for their cooperative  work to reach project milestones.



Our families and friends for their continued  moral support.

The overall project is presented during the poster  session as  #32.

12/12/2013

Utilizing Low‐Cost Linux Micro‐Computer &  Android Phone Solutions on Cube‐Satellites

14/14