Number of UART ports on the Photon

I want to talk to another processor and also use a 4D-display touch display. I need 2 UART ports to do this, but it seems like the photon only has 1 UART port? is this true?
do I have to do bit banging for the 2nd serial com?

There is Serial2, but not easily accessible.
You’d need to detach the blue and green subLEDs of the RGB LED and solder to the two solder pads on the bottom of the Photon.
But if you are talking to another processor, could you use I2C or SPI?

@coldquanta, the second UART on the Photon is available on pads under the Photon and if you remove the two of the RGB resistors.

As for bit-banging, you will notice that there is no software serial library for the Particle platform. That is mainly because of the interrupt overhead incurred by software serial and the need to disable all interrupts to get correct bit timing. This does not play nice with FreeRTOS and the system firmware.

1 Like

hmmmm, this really narrows down my options then!!
If I let go of the RGB LED i loose access to the board status. It is very unusual then, because this means that I can use the 2nd UART port just fine when I go to P1 and layout my board but have to give up the RGB LED during prototyping!!

@coldquanta, that is the unfortunate reality of keeping the same footprint as the original Core. You may want to consider the Sparkfun P1 Redboard for your prototyping.

1 Like

Although it is listed as retired a I2c to UART may be the way to go - I am sure there are other breakouts that will do this!

Hello,

I am also planning to connect a Sara module to Photon, for which I’ll need Uart2,

as peekay123 said, sparkfun P1 redboard looks a little bit more easier for rework.

Not neccessarily, since you can “move” the status feedback to three other PWM outputs (or other pins if you translate the RGB to digital values) via an onChange() handler.

1 Like

thank you guys, these are all great recommendations. I will look into them

Just out of curiosity, the reference says that there are two serial channels, but it lists Serial, Serial1 and Serial2, which looks like 3 to me. Is that a typo? And do these channels (2 or 3, depending on the answer to my previous question :grin:) each have their own UART, or do they share?

Thanks for any info!

There are two physical UART channels Serial1 and Serial2 (with their own UART) which work via RX/TX communication on the respective GPIOs and there is one virtual serial interface Serial that communicates via the USB CDC protocol (virtual COM port).

1 Like

Thanks, ScruffR – that clarifies things.

1 Like