Giter Site home page Giter Site logo

sdstate-cubesat's Introduction

sdstate-cubesat

New Raspberry Pi Set-Up

sudo apt-get update

Enable interfaces

sudo raspi-config

Enable Interface options VNC, I2C, SPI, Serial, etc.

(Optional) Install Remote Desktop

apt-get install xrdp

We also want to install some CircuitPython Adafruit libraries, since we're gonna use a lot of sensors from Adafruit, because they make their own drivers for them. Follow the instructions here: https://learn.adafruit.com/circuitpython-on-raspberrypi-linux/installing-circuitpython-on-raspberry-pi

Feather M0 Arduino IDE & Transmit/Receive Setup:

Download the Arduino IDE, go to preferences and add the URL below for Additional Boards Manager (click on the small icon on the side):

https://adafruit.github.io/arduino-board-index/package_adafruit_index.json

Click OK.

Now, go to the 'Tools' tab, mouse over 'Board:' and go to 'Boards Manager...' and install the following:

  • "Arduino SAMD Boards"

  • "Arduino SAMD Beta Boards"

  • "Adafruit SAMD Boards"

Restart the Arduino IDE.

Now connect the Adafruit Feather M0 with USB and go to the 'Tools' tab, go to 'Board:' and pick 'Adafruit Feather M0'.

And that's it!

GPS Set-Up (Using Adafruit Ultimate GPS Breakout Board)

GPS Raspberry Pi
Vin 3.3V
GND GND
RX UART TX
TX UART RX
  1. Set up minicom, so we can test out the UART ports.
sudo apt-get install minicom
  1. Edit the /boot/cmdline.txt file, so that it looks like this: (We are simply deleting references to ttyAMA0) Here is what looks like on the current Raspberry Pi (may differ):
dwc_otg.lpm_enable=0 console=tty1 root=/dev/mmcblk0p7 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait splash plymouth.ignore-serial-consoles

(single line)

  1. We can now test out what sort of data we are receiving from the UART serial port, but we first need to change the settings for the minicom:
sudo minicom -s

Go to serial port, change serial device to: /dev/ttyS0 Go to Bps/Par/Bits, change baudrate to: 9600

  1. We also want to install the great NMEA parser from this link: https://github.com/inmcm/micropyGPS Follow the install instructions and set it up. Then, you'll be able to use lib_GPS

MPL3115A2 Sensor Set-Up

Sensor Raspberry Pi
Vin 3.3V
GND GND
SCL i2c SCL
SDA i2c SDA

First we gotta set-up the Raspberry Pi:

sudo apt-get install python-smbus
sudo apt-get install i2c-tools

Set up modules:

sudo nano /etc/modules

i2c-bcm2708
i2c-dev

Remove blacklists:

sudo nano /etc/modprobe.d/raspi-blacklist.conf

#blacklist spi-bcm2708
#blacklist i2c-bcm2708

The MPL3115A2 requires a repeated start command in it's I2C communication - the Raspberry Pi doesn't do this out of the box, but we can use a kernel module.

sudo su -
echo -n 1 > /sys/module/i2c_bcm2708/parameters/combined
exit

We will also use Adafruit's CircuitPython MPL3115A2 library, and once the Adafruit CircuitPython dependencies are installed above, we can install the sensor driver with:

pip3 install adafruit-circuitpython-mpl3115a2

Additional Reading:

sdstate-cubesat's People

Contributors

rooftoofwoof avatar satyanto avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.