Hackpack v3: Difference between revisions

From Wildsong
Jump to navigationJump to search
Brian Wilson (talk | contribs)
mNo edit summary
Brian Wilson (talk | contribs)
m Brian Wilson moved page Hackpack v3 + GPS to Hackpack v3 without leaving a redirect: no gps here!
 
(No difference)

Latest revision as of 02:16, 21 June 2020

Hackpack V3 was part of the badge for Signal 2017.

It consists of a custom PC board with a socketed Particle Electron, a lithium ion battery, and 16 Neopixel LEDs.

The Electron has GSM but not WiFi or BT. The Photon has WiFi but still no BT. The project I am working on today (Sept2018) requires BT. I am looking at Cypress WiCED right now.

You can program it entirely via the Particle web site, or you can download Particle's fork of Atom, and use it to edit code. Atom is a Github product.

The compiler is on the web.

2017-05-30 I tried following the example in the Packt book "Learning IoT with Particle Photon and Electron". See Twitter app. I quit reading when I realized there was next to nothing on the Electron in this book despite the title.

2017-05-28 I am trying out Atom right now. I installed it on my Mac. Works pretty well.

Hello World

See the code and some variants at https://github.com/twilio/hackpack-v3

Firmware notes

The Electron is running FreeRTOS. http://www.freertos.org/ Hmmmm, interesting; FreeRTOS should run on the Teensy USB Development Board as well. What about the Anaren Bluetooth Smart Development Kit?

Hardware notes

I/O

There is a button marked "mode" that is just a generic button on an input port.

There is an RGB "System" LED and a "User" LED. The system LED is used to show status, here is the guide. You can drive the user LED on port D7 for anything you want to use it for.

There appear to be CAN bus ports, so in theory you could plug into OBDII.

There is a JTAG port.

All the Electron pins including GPIO are accessible via a couple headers on the back of the Twilio card.

They had a dock at Signal that used letters in "Twilio",

twi = TX
 l  = 
 i  = B2
 o  = 


Cellular

The chip on the Hackpack Electron is the U-Blox SARA-G350. That means this is the 2G version.

Power management

I want to be able to detect when external power is connected and disconnected. External power will be an automobile, so I want to know when the car starts and is shut down.

BQ24195 power management unit and battery charger (pdf data sheet) Refer to section 8.5 to find out about i2c communications with this device. You can poll it or accept interrupts from it; when you get an interrupt, read the fault register to clear it.

Q. Is the interrupt line connected on the Electron board?

MAX17043 fuel gauge (pdf data sheet) This chip has some registers you can read to find out the state of the battery. You can put it to sleep to save power by dropping SDA and SCL for at least 2.5 seconds.

Neopixel

There are 16 on this board. I also still have the 8x8 matrix from Hackpack v1 (Signal 2015).

I am not working with the LEDs yet, this is a little information I collected for future needs.

"NeoPixel" is an Adafruit brand for an LED with a controller. Each LED is individually addressable on a serial bus. You can buy individual LEDs or you can get various strips and sheets.

There are more tutorials on these than you can shake a stick at on the Adafruit site. Here is a pdf guide