From owner-freebsd-arm@freebsd.org Thu Feb 7 08:10:33 2019 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B8C3514CEC50 for ; Thu, 7 Feb 2019 08:10:33 +0000 (UTC) (envelope-from dmarquess@gmail.com) Received: from mail-ed1-x532.google.com (mail-ed1-x532.google.com [IPv6:2a00:1450:4864:20::532]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 02BCD753C3 for ; Thu, 7 Feb 2019 08:10:33 +0000 (UTC) (envelope-from dmarquess@gmail.com) Received: by mail-ed1-x532.google.com with SMTP id h50so8232415ede.5 for ; Thu, 07 Feb 2019 00:10:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=PC5bLeDbAPLyHaJdqzyLQbuImgQsZAWXX/xU5PgD//M=; b=kVnR6gVMUStQ88GD/5ljIWYfxmUdWEKmpgRzlbIi25ONJZ+X5IENHgC86PkM7QPzjW cbJFg8wz10XVVShZR8ajJscVMtxbq9K/a+86ZurH1+3nkbsbSz1gGn7MQwMJhqm50mHE XY82CGIpnsVwRGb6R2nf0cgq0cSrTpDBiBfAcpdKTrxP23VnxCkF5vK7y5Lr98yD8kO4 gmTuG8ZayN6XzIwS2A7+Ma+eMq1tbKGig1LrI6F+wcMioh9RNE+ds1Q9zH+eULSA1etH 8lF2Io0M8qy4t6ogdp5sD/7WGH9Fe8BEbIZubdBuojkhRPPumOWVsk19xlURAwGsyNdB iJWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=PC5bLeDbAPLyHaJdqzyLQbuImgQsZAWXX/xU5PgD//M=; b=IY8sKTkaNV1TvZhO7Kp581HjprWVZbL8wJNxn2gBPwRH99OFPtkV/j2r8aYNDEq0ne Q3B5CFV0ulH8cOuvhmYXNU1Fh5P27aznQS8mMYlzYLzm/29h3Ved5XZhM1m0+TM4m1/q chK3U7pjSi1DkShMaCh7fg4Phcwi0Be1vSfTOZDFNrIG8M6UIlQqQ2GhKq/7JiCN1255 /qFHMHZ3JZCiuneT4nUqrcUXZeKg/Yu9UDHIHNzouYaR4IYV7z7G60EmvnbGS15r87vz HwFvyZEp57klNsEBJXStsNBf/SvTJ8KIYAw3TyszylvnX55BELSq/lI2vxm1edmvSmTR N9eQ== X-Gm-Message-State: AHQUAubhnQlTGBoCKacrYKNsBmOsuW8OG+Dh5WA8odeDCXs6fToYqSyp YOyhRCt+swVGSO3tycvrZCKQ1pJY+m/g8W/QHI+Rkmm2 X-Google-Smtp-Source: AHgI3IbVJCuChsVBdfLK+00K7BGe2hE+VJQN3TNsO7EW0OKBqG8FfFqiM61YnUKpCL23qJT5dX9wZPkYQfwMx4A++gQ= X-Received: by 2002:a50:f5af:: with SMTP id u44mr11877704edm.172.1549527030660; Thu, 07 Feb 2019 00:10:30 -0800 (PST) MIME-Version: 1.0 References: <75aa4f8f-1c93-0cc0-b3ed-0208c40098be@bunyatech.com.au> In-Reply-To: <75aa4f8f-1c93-0cc0-b3ed-0208c40098be@bunyatech.com.au> From: Dustin Marquess Date: Thu, 7 Feb 2019 02:10:19 -0600 Message-ID: Subject: Re: Serial Port on RPi3 To: Brian Scott Cc: freebsd-arm Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: 02BCD753C3 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.94 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; NEURAL_HAM_SHORT(-0.94)[-0.945,0]; REPLY(-4.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0] X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 07 Feb 2019 08:10:34 -0000 You're absolutely right about the PL011 speed change issue. I had the same exact issue (for the exact same reason too, GPS!) and gonzo told me to use init_uart_baud in my config.txt: https://lists.freebsd.org/pipermail/freebsd-arm/2017-January/015474.html I managed to get the older U-Boots to not spew on the UART at all. The newer ones seem to desperately want one and panic/die/etc if they can't find one. I spent hours on it and finally just gave up :(. -Dustin On Thu, Feb 7, 2019 at 12:17 AM Brian Scott wrote: > > Hi, > > Has anyone had any success using the serial port on a Raspberry Pi 3 at > anything other than 115200? > > I'm trying to connect a GPS module to it (as most people do...) but am > having a lot of trouble. > > To give myself some diagnostics I have connected another machine up > using an adafruit cable and a terminal program. > > My first problem was u-boot. I have largely managed to get it out of the > way by setting the stdin, stdout and stderr environment variables to > usbkbd, vidconsole, and vidconsole (i.e. removing the serial option) but > it still insists on sending: > > MMC: mmc@7e300000: 1 > Loading Environment from FAT... OK > In: serial > Out: vidconsole > Err: vidconsole > > at 115200 baud before getting out of the way. No big deal because it > doesn't look like gps commands and it is being sent at much higher > speeds than I would expect the gps to understand anyway. > > The message on boot for the UART is: > > uart0: mem 0x7e201000-0x7e201fff irq 24 on > simplebus0 > > If I send data to the uart (echo Hi >/dev/cuau0) it works but at 115200 > baud, not respecting the stty speed of 9600. Similarly, using cu (cu -l > cuau0 -s 9600), I can send data but at 115200, not the expected 9600 baud. > > I have done some experiments with enable_uart= in the config.txt as well > as overlays from the linux world (uart0.dtbo and uart1.dtbo). While I > can get FreeBSD to detect the Mini-UART with some combinations of > settings, either on it's own or with the PL011, I haven't been able to > get anything out of the mini-uart and only a single character out of the > PL011 (at 115200 baud despite other settings). > > My conclusions so far: > > * There is no working driver behind the detection of the mini-uart. > * There is no way to change the speed of the PL011 to anything other > than 115200 (maybe because u-boot sets it that way at startup - > haven't fiddled with those knobs yet). > > Am I missing something important somewhere? > > Cheers, > > Brian > > P.S. I'm running 12-RELEASE with no software changes. > > > _______________________________________________ > freebsd-arm@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-arm > To unsubscribe, send any mail to "freebsd-arm-unsubscribe@freebsd.org"