EtchedPixels / FUZIX

FuzixOS: Because Small Is Beautiful
Other
2.13k stars 267 forks source link

rpipico platform not working #1062

Closed Challmymind closed 2 weeks ago

Challmymind commented 3 months ago

Newest pico build is not working. After flashing filesystem.uf2 then fuzix.uf2 there is no output on serial (ttyACM0), sadly i cannot test if UART is working. I have done the same with the tarballs from here with the success. Newest branch sets the LED on but as far as i can tell after it sits dormant. I will try to build version using previous commits before IOCTL changes (i dont know if it has broken things i just want to give it a try).

EtchedPixels commented 3 months ago

I suspect @veremenko-y 's usb serial changes might be a more likely candidate

Does a682f7e38ae477c525b80670e7ea2d1127b3cd84 run as a starting point - that's just before all the recent changing around.

Challmymind commented 3 months ago

You were right, a682f7e38ae477c525b80670e7ea2d1127b3cd84 builds correctly and everything works I might try to revert changes to the USB and keep those from IOCTL, maybe it will also work (as it should) without any additional fixes.

Challmymind commented 3 months ago

Update: shutdown is also invalid. 34ff65a1186027d45b63f88e443787799cff8695 is working until closed by shutdown command, after shutting it down it won't boot again.

veremenko-y commented 3 months ago

Ugh... I'll look at it today. What's your set up? Just bare pico and USB serial?

veremenko-y commented 3 months ago

Update: shutdown is also invalid. 34ff65a is working until closed by shutdown command, after shutting it down it won't boot again.

So I know what's happening with this one. Because you're using usb serial, it takes usually skips the starting messages. Even remount shutdown still corrupts file system for some reason. And after boot you get fsck prompt. If you type n or y, it'll continue booting.

Left is serial, right is USB. Screenshot from 2024-04-07 17-07-14

I had the same issue before my changes as well. If you add a sleep call after core1_init(); in main.c, you'll likely see full boot.

What I'm going to do is:

@EtchedPixels One question for you. Init refers to /dev/tty1 explicitly. What would be an appropriate way to configure it? Would something like this pass review? :)

// init.c:559
do {
#ifdef INIT_TTY
    fdtty1 = open(INIT_TTY, O_RDWR|O_NOCTTY);
#else
    fdtty1 = open("/dev/tty1", O_RDWR|O_NOCTTY);
#endif
} while (fdtty1 < 0);
EtchedPixels commented 3 months ago

tty1 is always the console

How devtty.c maps that minor is up to the platform

veremenko-y commented 3 months ago

I think I have a fix to reconfigure TTYs in any order. I need to test it properly in hardware, but expect PR in a few days.

veremenko-y commented 3 months ago

@Challmymind Are you able to test #1063 ?

fab1an2 commented 2 months ago

where is tutorial how run it? I have rpi2040 but how start? what program to flash etc?

i use linux

veremenko-y commented 2 months ago

where is tutorial how run it? I have rpi2040 but how start? what program to flash etc?

i use linux

This is unrelated to the current issue. Please create new one or post on discussion

veremenko-y commented 1 month ago

@Challmymind please try again!