-
Notifications
You must be signed in to change notification settings - Fork 280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FUZIX for Mizar32: Thoughts and hacks so far #1040
Comments
There are two tricks I use depending on the port
|
You should get to starting the shell before setjmp/longjmp burns you. The Bourne Shell uses it at startup and then for various kind of error and end of job handling |
Dear Alan, Many thanks for your message. I revisited RISC-V and ESP8266 parts of The build system is able to generate libmuc3a0512.a and further visits
Files like bd.c and chmem.c are getting compiled. But some of them are
I end up with this output:
I also tried removing the files that complain from SRC within the What am I getting wrong? Could you please give me a hint? Second: While I'm trying to get familiar with the FUZIX code-base, is |
I fully understand Alan. Sure. I'll keep this in mind. |
avr32-ld: BFD (AVR_32_bit_GNU_Toolchain_3.4.2_435) 2.23.1 assertion fail Your linker is broken. Unfortunately this seems to be a bit common with GNU linkers, especially forks of them. Nobody actually tests anything but the standard build options. That may need some detective work to see if it's a known problem and if there is a workaround, or a way to change the link file to dodge it. Is your tree accessible anywhere as it's probably going to be easier to debug this with the tree merged here and a copy of the right tool chain. |
Thank you Alan. I suspected the toolchain too but I wasn't very sure.
Sure. It is on the avr32 branch here [1]. [2] is the avr32-gcc I used Please note: I still haven't imported the clock, USART and device References: |
Dear Alan, Greetings!
Firstly, many thanks for FUZIX! I had a lot of fun reading the
codebase. @sergio-sorrenti and I were talking about exploring FUZIX
for the Mizar32 [1] platform a few weeks ago. I thought I will give it
a shot.
The first problem I had with AT32UC3 controllers (also in the context
of FUZIX) was the lack of debug capability on GNU/Linux. I invoked GNU
Make on the rpi-pico platform to figure out the core kernel files that
were being compiled. I imported all of them into a test Microchip
Studio project for Mizar32-A (AT32UC3A0512) on Windows.
I was able to get kprintf to work very quickly. After that, I
struggled with the SD card interface on Mizar32 for a bit. I
implemented __hard_irqrestore, __hard_ei, __hard_di and everything
else the compiler asked for on Windows.
I didn't have the root file system yet. But I fired up the debug
session with rpi-pico's root file system anyway. At least it came to a
point where it complained about the endianness. This part was too
exciting: just proof that the bare metal for the SD card and kprintf
(USART) works.
I knew that init wasn't going to fire. I assumed that context
switching OR interrupts weren't important for my debug sessions at
that moment. I took it as it came. AVR32 is a big endian machine.
s_mounted on the debug session held 50737. Perfect.
I knew it was time to checkout the root file system for AVR32. I went
back to GNU/Linux, cloned FUZIX and took much inspiration from 68K,
the ARM M0 and M4 ports.
I then spent time hacking Makefiles and writing files for dependencies
within Library/libs and Library/tools; For root. I implemented a very
quick and (for sure) buggy setjmp. I am sure my longjmp will fail with
what I've written so far. I thought I can fix them later.
I am stuck at `-pie' not being recognized by avr32-gcc.
I use this version of avr32-gcc (the default that comes with Microchip
Studio) OR the one I've been using for years to compile eLua [2] OR
since recently, RT-Thread [3] for Mizar32 on GNU/Linux:
The biggest problem is that we can't have an updated toolchain for
AVR32.
I understand the problem with -pie. Is there a way to further hacks on
FUZIX for AVR32 with this toolchain? Have I missed anything OR have I
thought of something incorrectly?
Your suggestions will be very helpful. Many thanks once again for
FUZIX!
Highest regards and respect,
References:
[1]: https://en.wikibooks.org/wiki/Mizar32
[2]: https://github.com/elua/elua/tree/master/src/platform/avr32
[3]: https://github.com/RT-Thread/rt-thread/tree/master/bsp/avr32/at32uc3a0256
The text was updated successfully, but these errors were encountered: