openbouffalo / buildroot_bouffalo

Linux Image for the BL808 CPU by Bouffalo Lab
124 stars 33 forks source link

Serial Console #61

Open KTechDev4213 opened 1 year ago

KTechDev4213 commented 1 year ago

What settings should be used for the linux serial console?

Fishwaldo commented 1 year ago

2000000 Baud, 8N1

KTechDev4213 commented 1 year ago

What flow control? Because putty is not showing anything.

eeucalyptus commented 1 year ago

No flow control. Maybe you selected the wrong com-port?

KTechDev4213 commented 1 year ago

I opened both at the same time with putty

eeucalyptus commented 1 year ago

Here is a list of things that you could try to solve it:

KTechDev4213 commented 1 year ago

DevCube said it successfully flashed it. Is it still possible that it was not flashed properly?

Fishwaldo commented 1 year ago

Please make sure you are using version 1.8.3 of Devcube. Older versions have a issue.

KTechDev4213 commented 1 year ago

Where can I find version v1.8.3? I have only found v1.8.4 on their website?

KTechDev4213 commented 1 year ago

I used version v1.8.3 and I still was not able to get a serial console.

jbrunk1966 commented 1 year ago

Used v1.8.4 and the latest FW from https://github.com/openbouffalo/buildroot_bouffalo/releases/tag/v1.0.1 but i also didn't get a working serial console (neither 2000000 Bd or 115200 8N1 etc is working) for Linux on GPIO 16/17 (Pin 31/32), just get carbage on GPIO 14/15 (Pin 1/2) used for the programming 🤷

Fishwaldo commented 1 year ago

1.8.4 is broken with the current buildroot. You have to use 1.8.3.

Get Outlook for iOShttps://aka.ms/o0ukef


From: jbrunk1966 @.> Sent: Wednesday, May 24, 2023 3:24:56 PM To: openbouffalo/buildroot_bouffalo @.> Cc: Justin Hammond @.>; Comment @.> Subject: Re: [openbouffalo/buildroot_bouffalo] Serial Console (Issue #61)

Used v1.8.4 and the latest FW from https://github.com/openbouffalo/buildroot_bouffalo/releases/tag/v1.0.1 but i also didn't get a working serial console (neither 2000000 Bd or 115200 8N1 etc is working) for Linux on GPIO 16/17 (Pin 31/32), just get carbage on GPIO 14/15 (Pin 1/2) used for the programming 🤷

— Reply to this email directly, view it on GitHubhttps://github.com/openbouffalo/buildroot_bouffalo/issues/61#issuecomment-1560587461, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AAGNURDBT3JHXECJ5TYYLRDXHWZURANCNFSM6AAAAAAX5LCMUE. You are receiving this because you commented.Message ID: @.***>

jbrunk1966 commented 1 year ago

1.8.4 is broken with the current buildroot. You have to use 1.8.3.

only 1.8.4 is available from https://dev.bouffalolab.com/download :(

Fishwaldo commented 1 year ago

https://github.com/openbouffalo/buildroot_bouffalo/issues/60#issuecomment-1549218266

jbrunk1966 commented 1 year ago

@Fishwaldo thnx a lot, with 1.8.3 i was able to get "something" from GPIO 16/17 (Pin 31/32), but it's still just carbage. Seems my USB-to-Serial Converter based on CP210x isnt capable to operate above 115200 Bb... According to the data sheet a FT232 based could do up to 3M Bd, but Amazon just listed converters with FT232BL/RL which are only able up to 1M Bd ... any suggestions for a working converter capable for 2M baud? thnx

jbrunk1966 commented 1 year ago

Bought a CH340G based USB-to-Serial Converter at Amazon for 5 bucks this is able to operate at 2.000.000 Bd :woohoo:

lxgr-linux commented 1 year ago

Bought a CH340G based USB-to-Serial Converter at Amazon for 5 bucks this is able to operate at 2.000.000 Bd :woohoo:

Which one? Because mine also does not support 2.000.000 Bd. I managed to patch the firmware to run at 115200 Bd, but having a faster serial port might be more convenient.

jbrunk1966 commented 1 year ago

Bought a CH340G based USB-to-Serial Converter at Amazon for 5 bucks this is able to operate at 2.000.000 Bd :woohoo:

Which one? Because mine also does not support 2.000.000 Bd. I managed to patch the firmware to run at 115200 Bd, but having a faster serial port might be more convenient.

bought this one: UART-TTL USB Adapter mit CH340G... https://www.amazon.de/dp/B0B7RHPMT7

lxgr-linux commented 1 year ago

Bought a CH340G based USB-to-Serial Converter at Amazon for 5 bucks this is able to operate at 2.000.000 Bd :woohoo:

Which one? Because mine also does not support 2.000.000 Bd. I managed to patch the firmware to run at 115200 Bd, but having a faster serial port might be more convenient.

bought this one: UART-TTL USB Adapter mit CH340G... https://www.amazon.de/dp/B0B7RHPMT7

Thanks a lot, bought it.

SLASH-JEET commented 1 year ago

I used version v1.8.3 and I still was not able to get a serial console.

were you able to get it working because I am unable to get anything on the serial port 14/15 seems to work but 16/17 isn't working using CH340G based adapter

jbrunk1966 commented 1 year ago

I used version v1.8.3 and I still was not able to get a serial console.

were you able to get it working because I am unable to get anything on the serial port 14/15 seems to work but 16/17 isn't working using CH340G based adapter

flashed it with v1.8.3 via GPIO14/15 (Pin 1/2) in boot mode, afterwards got the serial console for linux via GPIO16/17 (Pin 31/32) ...

SLASH-JEET commented 1 year ago

flashed it with v1.8.3 via GPIO14/15 (Pin 1/2) in boot mode, afterwards got the serial console for linux via GPIO16/17 (Pin 31/32) ...

That is exactly what I did still I am not getting anything on 16/17 and when I check 14/15 I get following log " [I][] [I][] _
[I][] / \ | \ / |/ | | |
[I][] | | | |
| |_) | | || |_ | |
[I][] | | | | ' \ / \ ' | < / | | | | | / ` | |/ _ \ [I][] | |
| | |_) | / | | | |) | () | || | | | || (| | | (_) | [I][] _/| ./ \|| ||_/ \/ _,|| || _,|_|__/ [I][] | |
[I][] |
|
[I][] [I][] Powered by BouffaloLab [I][] Build:11:52:22,Mar 6 2023 [I][] Copyright (c) 2023 OpenBouffalo team [I][] Copyright (c) 2022 Bouffalolab team [I][] =========== flash cfg ============== [I][] jedec id 0xEF4018 [I][] mid 0xEF [I][] iomode 0x04 [I][] clk delay 0x01 [I][] clk invert 0x01 [I][] read reg cmd0 0x05 [I][] read reg cmd1 0x35 [I][] write reg cmd0 0x01 [I][] write reg cmd1 0x31 [I][] qe write len 0x01 [I][] cread support 0x00 [I][] cread code 0xFF [I][] burst wrap cmd 0x77 [I][] sector size: 0x04 [I][] ===================================== [I][] dynamic memory init success,heap size = 156 Kbyte [I][MAIN] Starting Mailbox Handlers [I][MBOX] Forwarding Interupt SDH (33) to D0 (0x58008bbc) [I][MBOX] Forwarding Interupt GPIO (60) to D0 (0x58008d0e) [I][MAIN] Running... [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== "

and nothing on 16/17

jbrunk1966 commented 1 year ago

flashed it with v1.8.3 via GPIO14/15 (Pin 1/2) in boot mode, afterwards got the serial console for linux via GPIO16/17 (Pin 31/32) ...

That is exactly what I did still I am not getting anything on 16/17 and when I check 14/15 I get following log " [I][] [I][] _ [I][] / \ | \ / |/ | | | [I][] | | | | | |_) | | || |_ | | [I][] | | | | ' \ / \ ' | < / | | | | | / ` | |/ _ \ [I][] | || | |_) | / | | | |) | () | || | | | || (| | | (_) | [I][] _/| ./ **|| ||__/ _**/ ,|| |_| _,||/ [I][] | | [I][] |_| [I][] [I][] Powered by BouffaloLab [I][] Build:11:52:22,Mar 6 2023 [I][] Copyright (c) 2023 OpenBouffalo team [I][] Copyright (c) 2022 Bouffalolab team [I][] =========== flash cfg ============== [I][] jedec id 0xEF4018 [I][] mid 0xEF [I][] iomode 0x04 [I][] clk delay 0x01 [I][] clk invert 0x01 [I][] read reg cmd0 0x05 [I][] read reg cmd1 0x35 [I][] write reg cmd0 0x01 [I][] write reg cmd1 0x31 [I][] qe write len 0x01 [I][] cread support 0x00 [I][] cread code 0xFF [I][] burst wrap cmd 0x77 [I][] sector size: 0x04 [I][] ===================================== [I][] dynamic memory init success,heap size = 156 Kbyte [I][MAIN] Starting Mailbox Handlers [I][MBOX] Forwarding Interupt SDH (33) to D0 (0x58008bbc) [I][MBOX] Forwarding Interupt GPIO (60) to D0 (0x58008d0e) [I][MAIN] Running... [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== "

and nothing on 16/17

seems this is the output of Core M0; maybe something went wrong during flashing? i by myself flashed it with 115200 Bd only

SLASH-JEET commented 1 year ago

flashed it with v1.8.3 via GPIO14/15 (Pin 1/2) in boot mode, afterwards got the serial console for linux via GPIO16/17 (Pin 31/32) ...

That is exactly what I did still I am not getting anything on 16/17 and when I check 14/15 I get following log " [I][] [I][] _ [I][] / \ | \ / |/ | | | [I][] | | | | | |_) | | || |_ | | [I][] | | | | ' \ / \ ' | < / | | | | | / ` | |/ _ \ [I][] | || | |_) | / | | | |) | () | || | | | || (| | | (_) | [I][] _/| ./ **|| ||__/ _**/ ,|| |_| _,||/ [I][] | | [I][] |_| [I][] [I][] Powered by BouffaloLab [I][] Build:11:52:22,Mar 6 2023 [I][] Copyright (c) 2023 OpenBouffalo team [I][] Copyright (c) 2022 Bouffalolab team [I][] =========== flash cfg ============== [I][] jedec id 0xEF4018 [I][] mid 0xEF [I][] iomode 0x04 [I][] clk delay 0x01 [I][] clk invert 0x01 [I][] read reg cmd0 0x05 [I][] read reg cmd1 0x35 [I][] write reg cmd0 0x01 [I][] write reg cmd1 0x31 [I][] qe write len 0x01 [I][] cread support 0x00 [I][] cread code 0xFF [I][] burst wrap cmd 0x77 [I][] sector size: 0x04 [I][] ===================================== [I][] dynamic memory init success,heap size = 156 Kbyte [I][MAIN] Starting Mailbox Handlers [I][MBOX] Forwarding Interupt SDH (33) to D0 (0x58008bbc) [I][MBOX] Forwarding Interupt GPIO (60) to D0 (0x58008d0e) [I][MAIN] Running... [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== [I][MBOX] Mailbox IRQ Stats: [I][MBOX] Peripheral SDH (33): 0 [I][MBOX] Peripheral GPIO (60): 0 [I][MBOX] Unhandled Interupts: 0 Unhandled Signals 0 [I][MBOX] ==================================== " and nothing on 16/17

seems this is the output of Core M0; maybe something went wrong during flashing? i by myself flashed it with 115200 Bd only

in that case Ill try to flash it with 115200

SLASH-JEET commented 1 year ago

getting this while flashing MCU [16:11:23.947] - ========= eflash loader config ========= [16:11:23.955] - group0 img len error, get 61664 except 1075840 [16:11:23.974] - Version: eflash_loader_v2.4.5 [16:11:23.975] - Program Start [16:11:23.975] - ========= eflash loader cmd arguments =========

but it gets flashed successfully

jbrunk1966 commented 1 year ago

getting this while flashing MCU [16:11:23.947] - ========= eflash loader config ========= [16:11:23.955] - group0 img len error, get 61664 except 1075840 [16:11:23.974] - Version: eflash_loader_v2.4.5 [16:11:23.975] - Program Start [16:11:23.975] - ========= eflash loader cmd arguments =========

but it gets flashed successfully

that looks not right, re-download the images from https://github.com/openbouffalo/buildroot_bouffalo/releases/tag/v1.0.1 and try it again. i didn't got that error during flashing. maybe you've mistaken m0_lowload_bl808_m0.bin with d0_lowload_bl808_d0.bin or vice versa?

SLASH-JEET commented 1 year ago

getting this while flashing MCU [16:11:23.947] - ========= eflash loader config ========= [16:11:23.955] - group0 img len error, get 61664 except 1075840 [16:11:23.974] - Version: eflash_loader_v2.4.5 [16:11:23.975] - Program Start [16:11:23.975] - ========= eflash loader cmd arguments ========= but it gets flashed successfully

that looks not right, re-download the images from https://github.com/openbouffalo/buildroot_bouffalo/releases/tag/v1.0.1 and try it again. i didn't got that error during flashing. maybe you've mistaken m0_lowload_bl808_m0.bin with d0_lowload_bl808_d0.bin or vice versa?

Nope still getting the same error, re-downloaded and checked if ive mistaken or not, it still gives me same error

KTechDev4213 commented 1 year ago

getting this while flashing MCU [16:11:23.947] - ========= eflash loader config ========= [16:11:23.955] - group0 img len error, get 61664 except 1075840 [16:11:23.974] - Version: eflash_loader_v2.4.5 [16:11:23.975] - Program Start [16:11:23.975] - ========= eflash loader cmd arguments =========

but it gets flashed successfully

I got the same error.

SLASH-JEET commented 1 year ago

getting this while flashing MCU [16:11:23.947] - ========= eflash loader config ========= [16:11:23.955] - group0 img len error, get 61664 except 1075840 [16:11:23.974] - Version: eflash_loader_v2.4.5 [16:11:23.975] - Program Start [16:11:23.975] - ========= eflash loader cmd arguments ========= but it gets flashed successfully

I got the same error.

did you manage to get it working?

lxgr-linux commented 1 year ago

Bought a CH340G based USB-to-Serial Converter at Amazon for 5 bucks this is able to operate at 2.000.000 Bd :woohoo:

Which one? Because mine also does not support 2.000.000 Bd. I managed to patch the firmware to run at 115200 Bd, but having a faster serial port might be more convenient.

bought this one: UART-TTL USB Adapter mit CH340G... https://www.amazon.de/dp/B0B7RHPMT7

Thanks a lot, bought it.

Arrived and works perfectly.

catsuperberg commented 1 year ago

Have the same problem on sipeed M1s. Tried listening on all the UART pins from separate usb to uart board. Tried flashing versions from here https://github.com/openbouffalo/buildroot_bouffalo/actions/runs/4754065203, check everything 3 times. Nothing seems to help, just constantly repeating [MBOX] messges about Unhandled Interrupts on E907 uart.

EDIT: solved Turned out i was writing IOT firmware at the wrong address. I didn't change it to 0x800000 from 0xD2000 of sipeed example.

imchos commented 11 months ago

@Fishwaldo thnx a lot, with 1.8.3 i was able to get "something" from GPIO 16/17 (Pin 31/32), but it's still just carbage. Seems my USB-to-Serial Converter based on CP210x isnt capable to operate above 115200 Bb... According to the data sheet a FT232 based could do up to 3M Bd, but Amazon just listed converters with FT232BL/RL which are only able up to 1M Bd ... any suggestions for a working converter capable for 2M baud? thnx

To use the CP210x, use the CP21xxCustomizationUtility to change the baud rate to 2000000.

illantalex commented 1 month ago

I had the same problem on my Sipeed M1s (only the M0 core was showing something, while D0 was just completely silent), I managed to solve it by using the old version of DevCube:

here