Particle IO Photon

Pinout

../_images/photon-pinout.png

Detailed pinout

Right side pins

../_images/photon-pinout1.png

Left side pins

../_images/photon-pinout2.png

User I/O

../_images/photon-pinout3.png

Prerequisities

Install the dfu-utility.

git clone git://git.code.sf.net/p/dfu-util/dfu-util
cd dfu-util
sudo apt-get build-dep dfu-util
./autogen.sh
./configure
make
sudo make install
cd ..

# Give users access to the device.
sudo cp simba/environment/udev/49-photon.rules /etc/udec/rules.d

Flashing

The Photon must enter DFU mode before software can be uploaded to it. It’s recommended to use the manual method to verify that software can be successfully uploaded to the board, and then start using the automatic method to reduce the manual work for each software upload.

Manual

To enter DFU Mode:

  1. Hold down the RESET and SETUP buttons.
  2. Release only the RESET button, while holding down the SETUP button.
  3. Wait for the LED to start flashing yellow (it will flash magenta first).
  4. Release the SETUP button.

NOTE: Do not connect DTR and/or RTS using manual upload. They must only be connected using the automatic method.

Upload the software with make BOARD=photon upload.

Default system features

The default configuration includes those major features. They are all initialized by sys_start() at the startup of the application.

Library Reference

Read more about board specific functionality in the Particle IO Photon module documentation in the Library Reference.

Memory usage

Below is the memory usage of two applications:

  • The minimal-configuration application is configured to only include the bare minimum of functionality for the low level kernel to run. That is, the thread scheduler and system tick.
  • The default-configuration application is built with the default configuration, including a lot more functionality. See the list of Default system features above for a summary.
Application Flash RAM
minimal-configuration 4204 1672
default-configuration 77416 5898

Default configuration

Default Standard Library configuration.

Name Value
CONFIG_ADC 0
CONFIG_ANALOG_INPUT_PIN 0
CONFIG_ANALOG_OUTPUT_PIN 0
CONFIG_ASSERT 1
CONFIG_ASSERT_FORCE_FATAL 1
CONFIG_CAN 0
CONFIG_CHIPID 0
CONFIG_CRC_TABLE_LOOKUP 1
CONFIG_DAC 0
CONFIG_DEBUG 1
CONFIG_DS18B20 0
CONFIG_DS3231 0
CONFIG_EMACS_COLUMNS_MAX 80
CONFIG_EMACS_HEAP_SIZE 32768
CONFIG_EMACS_ROWS_MAX 24
CONFIG_ESP_WIFI 0
CONFIG_EXTI 0
CONFIG_FAT16 1
CONFIG_FATAL_ASSERT 1
CONFIG_FILESYSTEM_GENERIC 1
CONFIG_FLASH 1
CONFIG_FLOAT 1
CONFIG_FS_CMD_DS18B20_LIST 1
CONFIG_FS_CMD_ESP_WIFI_STATUS 0
CONFIG_FS_CMD_FS_APPEND 1
CONFIG_FS_CMD_FS_COUNTERS_LIST 1
CONFIG_FS_CMD_FS_COUNTERS_RESET 1
CONFIG_FS_CMD_FS_FILESYSTEMS_LIST 1
CONFIG_FS_CMD_FS_FORMAT 1
CONFIG_FS_CMD_FS_LIST 1
CONFIG_FS_CMD_FS_PARAMETERS_LIST 1
CONFIG_FS_CMD_FS_READ 1
CONFIG_FS_CMD_FS_REMOVE 1
CONFIG_FS_CMD_FS_WRITE 1
CONFIG_FS_CMD_I2C_READ 1
CONFIG_FS_CMD_I2C_WRITE 1
CONFIG_FS_CMD_LOG_LIST 1
CONFIG_FS_CMD_LOG_PRINT 1
CONFIG_FS_CMD_LOG_SET_LOG_MASK 1
CONFIG_FS_CMD_NETWORK_INTERFACE_LIST 1
CONFIG_FS_CMD_PING_PING 1
CONFIG_FS_CMD_PIN_READ 1
CONFIG_FS_CMD_PIN_SET_MODE 1
CONFIG_FS_CMD_PIN_WRITE 1
CONFIG_FS_CMD_SERVICE_LIST 1
CONFIG_FS_CMD_SERVICE_START 1
CONFIG_FS_CMD_SERVICE_STOP 1
CONFIG_FS_CMD_SETTINGS_LIST 1
CONFIG_FS_CMD_SETTINGS_READ 1
CONFIG_FS_CMD_SETTINGS_RESET 1
CONFIG_FS_CMD_SETTINGS_WRITE 1
CONFIG_FS_CMD_SYS_BACKTRACE 1
CONFIG_FS_CMD_SYS_CONFIG 1
CONFIG_FS_CMD_SYS_INFO 1
CONFIG_FS_CMD_SYS_PANIC 1
CONFIG_FS_CMD_SYS_REBOOT 1
CONFIG_FS_CMD_SYS_UPTIME 1
CONFIG_FS_CMD_THRD_LIST 1
CONFIG_FS_CMD_THRD_SET_LOG_MASK 1
CONFIG_FS_CMD_UPGRADE_APPLICATION_ENTER 1
CONFIG_FS_CMD_UPGRADE_APPLICATION_ERASE 1
CONFIG_FS_CMD_UPGRADE_APPLICATION_IS_VALID 1
CONFIG_FS_CMD_UPGRADE_BOOTLOADER_ENTER 1
CONFIG_FS_CMD_USB_DEVICE_LIST 1
CONFIG_FS_CMD_USB_HOST_LIST 1
CONFIG_FS_PATH_MAX 64
CONFIG_HTTP_SERVER_REQUEST_BUFFER_SIZE 128
CONFIG_HTTP_SERVER_SSL 0
CONFIG_I2C 1
CONFIG_I2C_SOFT 1
CONFIG_LED_7SEG_HT16K33 0
CONFIG_LINUX_SOCKET_DEVICE 0
CONFIG_MCP2515 0
CONFIG_MODULE_INIT_ADC 0
CONFIG_MODULE_INIT_ANALOG_INPUT_PIN 0
CONFIG_MODULE_INIT_ANALOG_OUTPUT_PIN 0
CONFIG_MODULE_INIT_BUS 1
CONFIG_MODULE_INIT_CAN 0
CONFIG_MODULE_INIT_CHAN 1
CONFIG_MODULE_INIT_CHIPID 0
CONFIG_MODULE_INIT_DAC 0
CONFIG_MODULE_INIT_DS18B20 0
CONFIG_MODULE_INIT_DS3231 0
CONFIG_MODULE_INIT_ESP_WIFI 0
CONFIG_MODULE_INIT_EXTI 0
CONFIG_MODULE_INIT_FLASH 1
CONFIG_MODULE_INIT_FS 1
CONFIG_MODULE_INIT_I2C 1
CONFIG_MODULE_INIT_I2C_SOFT 1
CONFIG_MODULE_INIT_INET 0
CONFIG_MODULE_INIT_LOG 1
CONFIG_MODULE_INIT_MCP2515 0
CONFIG_MODULE_INIT_NETWORK_INTERFACE 0
CONFIG_MODULE_INIT_NRF24L01 0
CONFIG_MODULE_INIT_OWI 0
CONFIG_MODULE_INIT_PIN 1
CONFIG_MODULE_INIT_PING 0
CONFIG_MODULE_INIT_PWM 0
CONFIG_MODULE_INIT_PWM_SOFT 0
CONFIG_MODULE_INIT_RANDOM 0
CONFIG_MODULE_INIT_RWLOCK 1
CONFIG_MODULE_INIT_SD 0
CONFIG_MODULE_INIT_SEM 1
CONFIG_MODULE_INIT_SETTINGS 1
CONFIG_MODULE_INIT_SOCKET 0
CONFIG_MODULE_INIT_SPI 0
CONFIG_MODULE_INIT_SSL 0
CONFIG_MODULE_INIT_STD 1
CONFIG_MODULE_INIT_THRD 1
CONFIG_MODULE_INIT_TIMER 1
CONFIG_MODULE_INIT_UART 1
CONFIG_MODULE_INIT_UART_SOFT 0
CONFIG_MODULE_INIT_UPGRADE 0
CONFIG_MODULE_INIT_USB 0
CONFIG_MODULE_INIT_USB_DEVICE 0
CONFIG_MODULE_INIT_USB_HOST 0
CONFIG_MODULE_INIT_WATCHDOG 0
CONFIG_MONITOR_THREAD 1
CONFIG_MONITOR_THREAD_PERIOD_US 2000000
CONFIG_NRF24L01 0
CONFIG_OWI 0
CONFIG_PANIC_ASSERT 1
CONFIG_PIN 1
CONFIG_PREEMPTIVE_SCHEDULER 0
CONFIG_PROFILE_STACK 1
CONFIG_PWM 0
CONFIG_PWM_SOFT 0
CONFIG_RANDOM 0
CONFIG_SD 0
CONFIG_SETTINGS_AREA_SIZE 256
CONFIG_SETTINGS_BLOB 1
CONFIG_SHELL_COMMAND_MAX 64
CONFIG_SHELL_HISTORY_SIZE 768
CONFIG_SHELL_MINIMAL 0
CONFIG_SHELL_PROMPT “$ “
CONFIG_SHT3XD 0
CONFIG_SOAM_EMBEDDED_DATABASE 0
CONFIG_SOCKET_RAW 1
CONFIG_SOFTWARE_I2C 1
CONFIG_SPC5_BOOT_ENTRY_RCHW 1
CONFIG_SPC5_RAM_CLEAR_ALL 1
CONFIG_SPI 0
CONFIG_SPIFFS 0
CONFIG_START_CONSOLE CONFIG_START_CONSOLE_UART
CONFIG_START_CONSOLE_DEVICE_INDEX 0
CONFIG_START_CONSOLE_UART_BAUDRATE 38400
CONFIG_START_CONSOLE_UART_RX_BUFFER_SIZE 32
CONFIG_START_CONSOLE_USB_CDC_CONTROL_INTERFACE 0
CONFIG_START_CONSOLE_USB_CDC_ENDPOINT_IN 2
CONFIG_START_CONSOLE_USB_CDC_ENDPOINT_OUT 3
CONFIG_START_CONSOLE_USB_CDC_WAIT_FOR_CONNETION 1
CONFIG_START_FILESYSTEM 0
CONFIG_START_FILESYSTEM_ADDRESS 0
CONFIG_START_FILESYSTEM_SIZE 65536
CONFIG_START_NETWORK 0
CONFIG_START_NETWORK_INTERFACE_WIFI_CONNECT_TIMEOUT 30
CONFIG_START_NETWORK_INTERFACE_WIFI_PASSWORD MyWiFiPassword
CONFIG_START_NETWORK_INTERFACE_WIFI_SSID MyWiFiSSID
CONFIG_START_SHELL 1
CONFIG_START_SHELL_PRIO 30
CONFIG_START_SHELL_STACK_SIZE 768
CONFIG_START_SOAM 0
CONFIG_START_SOAM_PRIO 30
CONFIG_START_SOAM_STACK_SIZE 840
CONFIG_STD_OUTPUT_BUFFER_MAX 16
CONFIG_SYSTEM_INTERRUPTS 1
CONFIG_SYSTEM_INTERRUPT_STACK_SIZE 0
CONFIG_SYSTEM_TICK_FREQUENCY 100
CONFIG_SYSTEM_TICK_SOFTWARE 0
CONFIG_SYS_CONFIG_STRING 1
CONFIG_SYS_PANIC_KICK_WATCHDOG 0
CONFIG_SYS_SIMBA_MAIN_STACK_MAX 4096
CONFIG_THRD_CPU_USAGE 1
CONFIG_THRD_ENV 1
CONFIG_THRD_IDLE_STACK_SIZE 384
CONFIG_THRD_MONITOR_STACK_SIZE 512
CONFIG_THRD_SCHEDULED 1
CONFIG_THRD_STACK_HEAP 0
CONFIG_THRD_STACK_HEAP_SIZE 0
CONFIG_THRD_TERMINATE 1
CONFIG_TIME_UNIX_TIME_TO_DATE 1
CONFIG_UART 1
CONFIG_UART_SOFT 0
CONFIG_USB 0
CONFIG_USB_DEVICE 0
CONFIG_USB_DEVICE_PID 0x8037
CONFIG_USB_DEVICE_VID 0x2341
CONFIG_USB_HOST 0
CONFIG_WATCHDOG 0