Is SPI Flash required


#1

@eric, do you know if the SPI flash is required to be used with the Bluz module when paring with a Photon?

Is the SPI flash chip just extra storage in addition to the Bluz module or is it required for hosting firmware etc.

Thanks!


Bluz Coin: New Form Factor for Wearables
#2

The SPI Flash is used to store system information, such as flags and the device ID, as well as the keys to connect to the cloud and factory reset firmware. It is also used when downloading OTA updates to store them temporarily. So yes, it is pretty much required, though with some low level firmware re-writes you could technically get away without it.

You can also check out our docs, we have started writing up some items around building products with bluz: http://docs.bluz.io/tutorials/custom_hw/


#3

@eric, Thanks, I’m just starting looking in how to implement the Bluz module in my own PCB that already has the particle P1 integrated. My main intention is to be able to switch operating modes to use either Wifi or bluetooth. In this case, whats your recommendation to use the flash?

Also I see that the RX and TX pins are used to connect between the P1 and Bluz. Are these connections needed?

My P1 already has all available pins used.

Thanks


#4

I assume you are looking at the gateway?

The gateway is used to talk Bluetooth on one side and WiFi on the other, so the use case sounds different than yours. We use SPI to pass data back and forth, and use a 5-wire version with an extra pin for flow control. This is used to pass the data back and forth from connected bluz boards to the cloud.

If all you want is a way to switch between the P1 and bluz, you could potentially do with a lot less. Not sure how much communication you need between the two, but your pin mapping should be based on that. This could be as simple as one GPIO pin that just turns the P1 on/off, or could be a more involved interface like we use for the gateway. Depends on what you want to do.

If you intend the bluz module on board to act as bluz (get OTA updates, cloud control, etc.) then you should include the SPI flash.


#5

I was looking at the gateway, but yeah does sound to be slightly different application.

Are the TX and RX (UART) used for the communication too?

I guess that here’s how I envision it working.

The P1 is the main unit to perform the processing of data etc (due to more available pins for use). The user can then choose to connect using a WiFi network or a Bluetooth network. If connected via Bluetooth the Bluz will receive/transmit all data (including firmware updates) and update variable on the P1.

On a side note,is it possible to update the P1 firmware through Bluz?


#6

We used the TX/RX pins on the P1 in case we wanted UART for some reason. We ended up using SPI and so the TX/RX pins are just used as GPIO for flow control.

As for bluz updating the P1, it is possible, but not with default firmware. The P1 can be updated OTA through WiFi or over DFU through USB. Since bluz can’t support either of those options, it wouldn’t work out of the box. However, depending on how much you wanted to tinker with the P1 firmware, it is possible.