0

I'm using Yocto-dunfell for getting custom my Raspberrypi3 image. Here I want to enable serial-console via uart1. for that I have given change in my files-

local.conf:

ENABLE_UART = "1"   
ENABLE_KGBD = "1"

and changes in my config.txt file:

dtoverlay=pi3-disable-wifi"
dtoverlay=pi3-disable-bt"               
dtoverlay=uart1,txd1_pin=32,rxd1_pin=33"                               
enable_uart=1                
core_freq=250                
force_turbo=1 

and cmdline.txt:

dwc_otg.lpm_enable=0 console=serial1,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait kgdboc=serial0,115200

After these changes also I'm not getting serial data in my minicom. Please assist me if any further changes are required.

Thanks & Regards.

Prashant
  • 21
  • 2
  • 1
    it is far from clear what OS you have or are trying to do. One thing is clear dtoverlay=uart1,txd1_pin=32,rxd1_pin=33 is unlikely to help because the pins are inaccessible on a Pi3 - the ONLY usable pins are 14,15. – Milliways Feb 16 '21 at 10:15
  • for same pi3, I'm generating image via openwrt kernel 4.9.65, and there I'm able to get the console with the same uart1 pins 32 and 33 to txd1 and txd1 respenctively. – Prashant Mar 12 '21 at 05:18

2 Answers2

2

To use the default serial console available on pin 8 and 10 (GPIO 14 and 15) you have to use a USB to TTL serial adapter. How to connect it and how do configure the RasPi to get the serial console working you can look at What is the correct way to connect serial console on RPi4 Model B?.

Ingo
  • 42,107
  • 20
  • 85
  • 197
  • Her in yocto image I've observed like in /dev I'm not getting ttyS0 even if I'm giving enable_uart=1, where as same in rasbian OS earlier /dev./ttyS0 was not there, but after addding enable_uart=1 in config.txt file and after rebooting it generated the /devttyS0 termina But after doing same with yocto image it's not generating the /dev/ttyS0 terminal. I've tried same with two different rpi kernel 5.4 and 4.14 by compiling two different poky's (dunfell and sumo).

    Please assist me with this as it's becoming bottle neck for my project.

    – Prashant Mar 12 '21 at 05:31
2

Issue resolved, this issue was persisting because uart1.dtbo was not getting added in /boot/overlays/ path by default, so for making this to happen just added KERNEL_DEVICETREE_append = "overlays/uart1.dtbo" to my local.conf file. Before building it, changed uart1 pin from 14 15 to 32 33 in build/tmp/work-shared/raspberrypi3/kernel-source/arch/arm/boot/dts/overlays/uart1-overlay.dts
after this compiled the raspberrypi kernel by bitbake linux-raspberrypi -c compile -f;bitbake linux-raspberrypi
done after this compiled the whole source code by bitabke my-image, now flashed .sdimg image using dd command and now console via uart1 on pin 32 and 33 is working fine.

Prashant
  • 21
  • 2