# BalenaFin uart pins

**URL:** <https://forums.balena.io/t/balenafin-uart-pins/203546>\
**Category:** balenaFin\
**Created:** [October 28, 2020, 4:49pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546 "2020-10-28T16:49:39Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![IngBianchi](https://avatars.discourse-cdn.com/v4/letter/i/f07891/32.png) [@IngBianchi](https://forums.balena.io/u/IngBianchi)\
**Post date:** [October 28, 2020, 4:49pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/1 "2020-10-28T16:49:39Z")

</div>

Hello, i am creating an uart interface between a board designed by me and balena fin. I am not so sure about the location of the uart port. On the documentation i have not found any information about uart pins. On the datasheet it is not mentioned. I read on a forum that uart pins could be GPIO14 and GPIO15 on the HAT connector. I am asking now, which one is TXD and which one is RXD ?? Is there an official document which describes the correct UART pinout? Thank you.

---

<div class="post-metadata">

**Author:** ![MTolba](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/mtolba/32/3894_2.png) [@MTolba](https://forums.balena.io/u/MTolba)\
**Post date:** [October 28, 2020, 5:03pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/5 "2020-10-28T17:03:05Z")

</div>

Hello Alessandro,

balenaFin HAT connector follows the same pinout standard of the Rasberry Pi 3 connector, You can check it [here](https://www.balena.io/blog/content/images/2019/03/pi-pinout-i2c-1.png)

- Pin 8 is GPIO14 --\> TXD
- Pin 10 is GPIO 15 --\> RXD

Happy to help you! Please let me know if you still have any questions!

---

<div class="post-metadata">

**Author:** ![IngBianchi](https://avatars.discourse-cdn.com/v4/letter/i/f07891/32.png) [@IngBianchi](https://forums.balena.io/u/IngBianchi)\
**Post date:** [October 28, 2020, 7:30pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/7 "2020-10-28T19:30:37Z")

</div>

Thank you for your quick answer. Is the voltage of UART , SPI , I2C, 3.3V or 5V ? Thanks

---

<div class="post-metadata">

**Author:** ![samothx](https://avatars.discourse-cdn.com/v4/letter/s/c89c15/32.png) [@samothx](https://forums.balena.io/u/samothx)\
**Post date:** [October 28, 2020, 10:46pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/8 "2020-10-28T22:46:07Z")

</div>

Hi Alessandro, all GPIO pins on the RPI3 and the fin operate on 3.3V.

---

<div class="post-metadata">

**Author:** ![IngBianchi](https://avatars.discourse-cdn.com/v4/letter/i/f07891/32.png) [@IngBianchi](https://forums.balena.io/u/IngBianchi)\
**Post date:** [October 29, 2020, 7:57am UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/10 "2020-10-29T07:57:39Z")

</div>

Thank you, SPI and I2C pin layout is exactly like the raspberry pi layout?  
Is there a dxf file or a gerber file of Balenafin board? I need it to calculate the board size occupancy on the motherboard i am going to design.

Regards

---

<div class="post-metadata">

**Author:** ![anujdeshpande](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/anujdeshpande/32/3155_2.png) [@anujdeshpande](https://forums.balena.io/u/anujdeshpande)\
**Post date:** [October 29, 2020, 8:15am UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/11 "2020-10-29T08:15:38Z")

</div>

Hi Alessandro

- Yes, the pin layout is the same as the RPi3 - so any HATs will be compatible.
- We have a HAT template repo - [https://github.com/balena-io-playground/balena-fin-examples-hw](https://github.com/balena-io-playground/balena-fin-examples-hw) - you can use this as a starting point to create your board.
- If you want to design anything mechanical, you will need the CAD files. You can find them here - [https://github.com/balena-io/balena-fin/blob/master/documentation/DOCUMENTATION.md#datasheet](https://github.com/balena-io/balena-fin/blob/master/documentation/DOCUMENTATION.md#datasheet)

Is that enough info to help you design your board? Let us know how it goes!

---

<div class="post-metadata">

**Author:** ![IngBianchi](https://avatars.discourse-cdn.com/v4/letter/i/f07891/32.png) [@IngBianchi](https://forums.balena.io/u/IngBianchi)\
**Post date:** [October 29, 2020, 9:43am UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/13 "2020-10-29T09:43:55Z")

</div>

Hello, yes the stuff you have is quite useful. For my project i need to make a change on balenafin hat connector. I should un-solder the actual strip 40 pin  
header and i should mount an- automotive suitable connector, because of the vibration and other kind of problems. Can you give me an advice of  
what connector could be better to substitute the factory one?

---

<div class="post-metadata">

**Author:** ![ntzovanis](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/ntzovanis/32/1150_2.png) [@ntzovanis](https://forums.balena.io/u/ntzovanis)\
**Post date:** [October 29, 2020, 7:38pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/21 "2020-10-29T19:38:32Z")

</div>

Hello @IngBianchi ,

I don’t know of any AEC-approved connector that is pin-compatible with the 40 pin header on the balenaFin. I’d like to hear a bit more about which type of vibrations and other issues you’ve seen/faced with the standard header.  
If you’re mostly concerned about vibrations, there are a few mounting holes on the balenaFin board that you could use to secure your custom HAT in place.

Cheers,  
Nico.

---

<div class="post-metadata">

**Author:** ![IngBianchi](https://avatars.discourse-cdn.com/v4/letter/i/f07891/32.png) [@IngBianchi](https://forums.balena.io/u/IngBianchi)\
**Post date:** [November 30, 2020, 4:46pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/24 "2020-11-30T16:46:32Z")

</div>

Hello,  
i need another information. I need to know the exact distance between the corner holes of balenafin,  
i did not find anything, and if you have a dxf it would be better.  
Thank you

---

<div class="post-metadata">

**Author:** ![MTolba](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/mtolba/32/3894_2.png) [@MTolba](https://forums.balena.io/u/MTolba)\
**Post date:** [November 30, 2020, 5:43pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/31 "2020-11-30T17:43:17Z")

</div>

A file has been uploaded using Jellyfish: [https://jel.ly.fish/0bca0394-a739-4aea-b7b1-47c5414741b6](https://jel.ly.fish/0bca0394-a739-4aea-b7b1-47c5414741b6)

---

<div class="post-metadata">

**Author:** ![MTolba](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/mtolba/32/3894_2.png) [@MTolba](https://forums.balena.io/u/MTolba)\
**Post date:** [November 30, 2020, 5:43pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/32 "2020-11-30T17:43:40Z")

</div>

Hi Alessandro,

Please find the attached dxf files and let us know if you need more help.

---

<div class="post-metadata">

**Author:** ![IngBianchi](https://avatars.discourse-cdn.com/v4/letter/i/f07891/32.png) [@IngBianchi](https://forums.balena.io/u/IngBianchi)\
**Post date:** [November 30, 2020, 6:04pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/34 "2020-11-30T18:04:59Z")

</div>

Hello thank you, i have not a jellyfish account, should i create one to download attached files?

---

<div class="post-metadata">

**Author:** ![MTolba](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/mtolba/32/3894_2.png) [@MTolba](https://forums.balena.io/u/MTolba)\
**Post date:** [November 30, 2020, 6:52pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/35 "2020-11-30T18:52:33Z")

</div>

Hello,  
We will add it to balena fin [GitHub repo](https://github.com/balena-io/balena-fin), I’ve opened an issue [here](https://github.com/balena-io/balena-fin/issues/62) you subscribe to it to know when we add the files to the repo.

---

<div class="post-metadata">

**Author:** ![IngBianchi](https://avatars.discourse-cdn.com/v4/letter/i/f07891/32.png) [@IngBianchi](https://forums.balena.io/u/IngBianchi)\
**Post date:** [December 14, 2020, 1:27pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/37 "2020-12-14T13:27:03Z")

</div>

Hello,  
my project consists of establishing an uart communication between pic32 and balenafin, do you have some software libraries or code sketch  
to have an optimal set up of balenafin uart peripheral? Thank you.

Regards

---

<div class="post-metadata">

**Author:** ![rcooke-warwick](https://avatars.discourse-cdn.com/v4/letter/r/ba9def/32.png) [@rcooke-warwick](https://forums.balena.io/u/rcooke-warwick)\
**Post date:** [December 14, 2020, 5:01pm UTC](https://forums.balena.io/t/balenafin-uart-pins/203546/38 "2020-12-14T17:01:59Z")

</div>

The default UART pins for the fins are 14/15, just as with the RPI3.

If you are using balenaOS, you can enable UART in the dashboard under the `device configuration` tab. The UART port will appear under ‘/dev/ttyAMA0’, and can be written to or read from. There are serial libraries for most languages that would allow you to do this at this point, for example n python something like this: [https://github.com/nhivp/Serial-Raspberry-Pi-3/blob/master/testSerial.py](https://github.com/nhivp/Serial-Raspberry-Pi-3/blob/master/testSerial.py)
