Wojciech, is RiskFive still viable? The last news on your site is 2018, November. Not criticizing; just wondering. Thanks ... L. -- https://en.wikibooks.org/wiki/Medical_Machines Tel: +1 604 670 0140 Bcc: peter at easthope. ca
Peter: thank you for asking. RiskFive is low priority because it is at the sidelines of our funded work. Vedant is using one of these boards and I have four more piled on my desk. As of now Vedant has implemented Wiznet W5500 and he is now working on W5300. All this work was MicroBlaze and C because he is following Pong P. Chu firmware. My tentative plan is to let him complete this work, after which one of us will wrap RISC5 the same way as the MicroBlaze Controller System (MCS) from Xilinx. If RISC5 becomes a drop-in replacement for the MCS, then all the other firmware can stay in place. Implementing the W5300 reqired changing the address map from Pong P. Chu to wider address chunks per module, because PP.Chu provides for only 32 memory locations, while W5300 needs 32 kB. This is a minor change, which is greatly facilitated by the modular structure of P.P.Chu bus. Interestingly enough, NW/PR bus is basically the same as the P.P.Chu bus, but it is documented in a different way. It turns out that the "bus" does not really exist inside the FPGA. All that exists is its documentation. You can read the WishBone document where they clearly say that WishBone is a specification rather than a firmware component. Much the same is true about NW/PR, P.P.Chu, and other such buses. I tentatively decided to adopt FPro by P.P.Chu because it is both simple and extensively documented. After changing the memory map we will rename it to SPro to avoid confusion with his FPro specs. All this is firmware. My aim is development of a firmware framework with larger memory address range per chunk than FPro is providing, and then adopting P.P.Chu components to build a system on chip for our needs. Part of this work which of general interest can be open sourced, after writing and releasing sufficient documentation. I reviewed the current Oberon System software from the point of view of porting it to a future SoC. I found that the low level modules such as Kernel, Display, Files, or a boot loader, will all need to be factored into a low level driver layer with the HW addresses, and the upper layer without. This is perhaps stated in the NW book, but this book does not accurately describe the Oberon System reality. In reality there are numbers literally hardcoded inside the modules in more than one place. For example, at the end of the BootLoader, the locations 12 and 24 are loaded with values. Now imagine porting this software to another SoC. How do you make sure that these values are properly interfaced with hardware if it is not clear what is going on. It happens in many places in the low level drivers. My favorite lines of code in Modules.Mod are: mno := inst DIV 100000H MOD 10H; pno := inst DIV 1000H MOD 100H; disp := inst MOD 1000H; .... SYSTEM.PUT(adr, (offset MOD 1000000H) + 0F7000000H); Now imagine porting such undocumented code to range of different SoCs with different memory arrangements. It looks like a recipe for a disaster to me. It will be necessary to rewrite portions of low-level Oberon System code to factor out such pieces, before porting the system to other boards which are substantially different from the present boards. Documentation will be crucial. None of such literal values should be allowed in the portable code without extensive comments describing the mechanics. Such structural fixes would be needed before this software is portable to a different SoC. It would be helpful if this community formed a task force to start modernizing the FPGA Oberon System. The first modest task of the task force could be commenting and documenting the low level code, as well as moving all the hardcoded locations into the definition module SysDef.Mod corresponding to the firmware memory locations. (Consult the P.P.Chu book where he is doing exactly that.) Forming a task force could be contrary to the culture of this group. We seem to be very individualistic. And we do not seem to have a clear common goal. I can circulate a draft review of the low level Oberon System if there is interest. Thank you again for asking. And I want to profusely apologize to anyone who could read this e-mail as being unduly critical. Wojtek ________________________________________ From: Oberon [oberon-bounces@lists.inf.ethz.ch] on behalf of peter@easthope.ca [peter@easthope.ca] Sent: Wednesday, November 13, 2019 12:55 PM To: oberon@lists.inf.ethz.ch Subject: [Oberon] RiskFive; was Oberon on ULX3S explanation Wojciech, is RiskFive still viable? The last news on your site is 2018, November. Not criticizing; just wondering. Thanks ... L.
Wojtek I admit that the address fixing is not the easiest part of a compiler and module loader, but it is not undocumented. The first paragraph of chapter 12.7.9 in this document https://inf.ethz.ch/personal/wirth/ProjectOberon/PO.Applications.pdf explains what the compiler generates, why its doing it and what fields the module loader has to extract so he can modify the instruction while loading the module from disk to memory. BTW: The CPU instruction set of NW’s RISC-5 is documented here: https://inf.ethz.ch/personal/wirth/FPGA-relatedWork/RISC-Arch.pdf After reading it, you might understand that 0F7000000H is the assembler code for „BL always“ This Oberon code is totally agnostic to the used FPGA as long as the FPGA implements NW’s CPU called RISC-5. (to be found in RISC5.v) You can leave this Oberon code untouched. You „only“ have to make sure RISC5.v and more importantly RISC5Top.v is adapted to your FPGA and especially memory (address and timing) Jörg
Am 13.11.2019 um 20:33 schrieb Skulski, Wojciech <skulski@pas.rochester.edu>:
Peter:
thank you for asking. RiskFive is low priority because it is at the sidelines of our funded work. Vedant is using one of these boards and I have four more piled on my desk. As of now Vedant has implemented Wiznet W5500 and he is now working on W5300. All this work was MicroBlaze and C because he is following Pong P. Chu firmware. My tentative plan is to let him complete this work, after which one of us will wrap RISC5 the same way as the MicroBlaze Controller System (MCS) from Xilinx. If RISC5 becomes a drop-in replacement for the MCS, then all the other firmware can stay in place.
Implementing the W5300 reqired changing the address map from Pong P. Chu to wider address chunks per module, because PP.Chu provides for only 32 memory locations, while W5300 needs 32 kB. This is a minor change, which is greatly facilitated by the modular structure of P.P.Chu bus. Interestingly enough, NW/PR bus is basically the same as the P.P.Chu bus, but it is documented in a different way. It turns out that the "bus" does not really exist inside the FPGA. All that exists is its documentation. You can read the WishBone document where they clearly say that WishBone is a specification rather than a firmware component. Much the same is true about NW/PR, P.P.Chu, and other such buses. I tentatively decided to adopt FPro by P.P.Chu because it is both simple and extensively documented. After changing the memory map we will rename it to SPro to avoid confusion with his FPro specs.
All this is firmware. My aim is development of a firmware framework with larger memory address range per chunk than FPro is providing, and then adopting P.P.Chu components to build a system on chip for our needs. Part of this work which of general interest can be open sourced, after writing and releasing sufficient documentation.
I reviewed the current Oberon System software from the point of view of porting it to a future SoC. I found that the low level modules such as Kernel, Display, Files, or a boot loader, will all need to be factored into a low level driver layer with the HW addresses, and the upper layer without. This is perhaps stated in the NW book, but this book does not accurately describe the Oberon System reality. In reality there are numbers literally hardcoded inside the modules in more than one place. For example, at the end of the BootLoader, the locations 12 and 24 are loaded with values. Now imagine porting this software to another SoC. How do you make sure that these values are properly interfaced with hardware if it is not clear what is going on. It happens in many places in the low level drivers.
My favorite lines of code in Modules.Mod are:
mno := inst DIV 100000H MOD 10H; pno := inst DIV 1000H MOD 100H; disp := inst MOD 1000H; .... SYSTEM.PUT(adr, (offset MOD 1000000H) + 0F7000000H);
Now imagine porting such undocumented code to range of different SoCs with different memory arrangements. It looks like a recipe for a disaster to me. It will be necessary to rewrite portions of low-level Oberon System code to factor out such pieces, before porting the system to other boards which are substantially different from the present boards. Documentation will be crucial. None of such literal values should be allowed in the portable code without extensive comments describing the mechanics. Such structural fixes would be needed before this software is portable to a different SoC.
It would be helpful if this community formed a task force to start modernizing the FPGA Oberon System. The first modest task of the task force could be commenting and documenting the low level code, as well as moving all the hardcoded locations into the definition module SysDef.Mod corresponding to the firmware memory locations. (Consult the P.P.Chu book where he is doing exactly that.)
Forming a task force could be contrary to the culture of this group. We seem to be very individualistic. And we do not seem to have a clear common goal.
I can circulate a draft review of the low level Oberon System if there is interest.
Thank you again for asking. And I want to profusely apologize to anyone who could read this e-mail as being unduly critical.
Wojtek ________________________________________ From: Oberon [oberon-bounces@lists.inf.ethz.ch] on behalf of peter@easthope.ca [peter@easthope.ca] Sent: Wednesday, November 13, 2019 12:55 PM To: oberon@lists.inf.ethz.ch Subject: [Oberon] RiskFive; was Oberon on ULX3S explanation
Wojciech, is RiskFive still viable? The last news on your site is 2018, November. Not criticizing; just wondering.
Thanks ... L.
-- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon
Wojtek Porting the system to a new board is mainly a task of understanding and adapting the .v files. There are hardly any .Mod files you ever have to touch. The Oberon system can be compiled as is if the FPGA implements NW’s CPU and offers 1MB of memory, and the IOs and video framebuffer are mapped to the documented memory addresses. The first step in porting the system is: make the FPGA behave like the HW architecture as defined and documented by NW (His CPU, his 1MB memory layout with defined IO and framebuffer addresses.) AFTER you did that, you can take the second step and add new features to NW‘s machine like - adding more memory - adding color - adding Ethernet .... In this second step you might need to adapt 1 to 2 modules. Mainly BootLoad.Mod to adapt the memory layout (In Kernel.Mod the „stackSize“ is hardcoded. Unfortunately, Modules.Mod does not import stackSize from Kernel but hard codes it again😩) In case of color graphics Display.Mod has to be adapted. I might be wrong but that’s it. br Jörg
Am 13.11.2019 um 21:23 schrieb Joerg <joerg.straube@iaeth.ch>:
Wojtek
I admit that the address fixing is not the easiest part of a compiler and module loader, but it is not undocumented. The first paragraph of chapter 12.7.9 in this document https://inf.ethz.ch/personal/wirth/ProjectOberon/PO.Applications.pdf explains what the compiler generates, why its doing it and what fields the module loader has to extract so he can modify the instruction while loading the module from disk to memory.
BTW: The CPU instruction set of NW’s RISC-5 is documented here: https://inf.ethz.ch/personal/wirth/FPGA-relatedWork/RISC-Arch.pdf After reading it, you might understand that 0F7000000H is the assembler code for „BL always“
This Oberon code is totally agnostic to the used FPGA as long as the FPGA implements NW’s CPU called RISC-5. (to be found in RISC5.v) You can leave this Oberon code untouched. You „only“ have to make sure RISC5.v and more importantly RISC5Top.v is adapted to your FPGA and especially memory (address and timing)
Jörg
Am 13.11.2019 um 20:33 schrieb Skulski, Wojciech <skulski@pas.rochester.edu>:
Peter:
thank you for asking. RiskFive is low priority because it is at the sidelines of our funded work. Vedant is using one of these boards and I have four more piled on my desk. As of now Vedant has implemented Wiznet W5500 and he is now working on W5300. All this work was MicroBlaze and C because he is following Pong P. Chu firmware. My tentative plan is to let him complete this work, after which one of us will wrap RISC5 the same way as the MicroBlaze Controller System (MCS) from Xilinx. If RISC5 becomes a drop-in replacement for the MCS, then all the other firmware can stay in place.
Implementing the W5300 reqired changing the address map from Pong P. Chu to wider address chunks per module, because PP.Chu provides for only 32 memory locations, while W5300 needs 32 kB. This is a minor change, which is greatly facilitated by the modular structure of P.P.Chu bus. Interestingly enough, NW/PR bus is basically the same as the P.P.Chu bus, but it is documented in a different way. It turns out that the "bus" does not really exist inside the FPGA. All that exists is its documentation. You can read the WishBone document where they clearly say that WishBone is a specification rather than a firmware component. Much the same is true about NW/PR, P.P.Chu, and other such buses. I tentatively decided to adopt FPro by P.P.Chu because it is both simple and extensively documented. After changing the memory map we will rename it to SPro to avoid confusion with his FPro specs.
All this is firmware. My aim is development of a firmware framework with larger memory address range per chunk than FPro is providing, and then adopting P.P.Chu components to build a system on chip for our needs. Part of this work which of general interest can be open sourced, after writing and releasing sufficient documentation.
I reviewed the current Oberon System software from the point of view of porting it to a future SoC. I found that the low level modules such as Kernel, Display, Files, or a boot loader, will all need to be factored into a low level driver layer with the HW addresses, and the upper layer without. This is perhaps stated in the NW book, but this book does not accurately describe the Oberon System reality. In reality there are numbers literally hardcoded inside the modules in more than one place. For example, at the end of the BootLoader, the locations 12 and 24 are loaded with values. Now imagine porting this software to another SoC. How do you make sure that these values are properly interfaced with hardware if it is not clear what is going on. It happens in many places in the low level drivers.
My favorite lines of code in Modules.Mod are:
mno := inst DIV 100000H MOD 10H; pno := inst DIV 1000H MOD 100H; disp := inst MOD 1000H; .... SYSTEM.PUT(adr, (offset MOD 1000000H) + 0F7000000H);
Now imagine porting such undocumented code to range of different SoCs with different memory arrangements. It looks like a recipe for a disaster to me. It will be necessary to rewrite portions of low-level Oberon System code to factor out such pieces, before porting the system to other boards which are substantially different from the present boards. Documentation will be crucial. None of such literal values should be allowed in the portable code without extensive comments describing the mechanics. Such structural fixes would be needed before this software is portable to a different SoC.
It would be helpful if this community formed a task force to start modernizing the FPGA Oberon System. The first modest task of the task force could be commenting and documenting the low level code, as well as moving all the hardcoded locations into the definition module SysDef.Mod corresponding to the firmware memory locations. (Consult the P.P.Chu book where he is doing exactly that.)
Forming a task force could be contrary to the culture of this group. We seem to be very individualistic. And we do not seem to have a clear common goal.
I can circulate a draft review of the low level Oberon System if there is interest.
Thank you again for asking. And I want to profusely apologize to anyone who could read this e-mail as being unduly critical.
Wojtek ________________________________________ From: Oberon [oberon-bounces@lists.inf.ethz.ch] on behalf of peter@easthope.ca [peter@easthope.ca] Sent: Wednesday, November 13, 2019 12:55 PM To: oberon@lists.inf.ethz.ch Subject: [Oberon] RiskFive; was Oberon on ULX3S explanation
Wojciech, is RiskFive still viable? The last news on your site is 2018, November. Not criticizing; just wondering.
Thanks ... L.
-- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon -- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon
Wojtek As RiscFive is in the title, I just want to point out that RISC-V https://en.m.wikipedia.org/wiki/RISC-V ) is a completely different CPU than NW‘s RISC-5 ( https://inf.ethz.ch/personal/wirth/FPGA-relatedWork/RISC-Arch.pdf) To compile the Oberon system, the FPGA has to implement the RISC-5 CPU not the RISC-V br Jörg
Am 13.11.2019 um 22:04 schrieb Joerg <joerg.straube@iaeth.ch>:
Wojtek
Porting the system to a new board is mainly a task of understanding and adapting the .v files.
There are hardly any .Mod files you ever have to touch. The Oberon system can be compiled as is if the FPGA implements NW’s CPU and offers 1MB of memory, and the IOs and video framebuffer are mapped to the documented memory addresses.
The first step in porting the system is: make the FPGA behave like the HW architecture as defined and documented by NW (His CPU, his 1MB memory layout with defined IO and framebuffer addresses.)
AFTER you did that, you can take the second step and add new features to NW‘s machine like - adding more memory - adding color - adding Ethernet .... In this second step you might need to adapt 1 to 2 modules. Mainly BootLoad.Mod to adapt the memory layout (In Kernel.Mod the „stackSize“ is hardcoded. Unfortunately, Modules.Mod does not import stackSize from Kernel but hard codes it again😩) In case of color graphics Display.Mod has to be adapted. I might be wrong but that’s it.
br Jörg
Am 13.11.2019 um 21:23 schrieb Joerg <joerg.straube@iaeth.ch>:
Wojtek
I admit that the address fixing is not the easiest part of a compiler and module loader, but it is not undocumented. The first paragraph of chapter 12.7.9 in this document https://inf.ethz.ch/personal/wirth/ProjectOberon/PO.Applications.pdf explains what the compiler generates, why its doing it and what fields the module loader has to extract so he can modify the instruction while loading the module from disk to memory.
BTW: The CPU instruction set of NW’s RISC-5 is documented here: https://inf.ethz.ch/personal/wirth/FPGA-relatedWork/RISC-Arch.pdf After reading it, you might understand that 0F7000000H is the assembler code for „BL always“
This Oberon code is totally agnostic to the used FPGA as long as the FPGA implements NW’s CPU called RISC-5. (to be found in RISC5.v) You can leave this Oberon code untouched. You „only“ have to make sure RISC5.v and more importantly RISC5Top.v is adapted to your FPGA and especially memory (address and timing)
Jörg
Am 13.11.2019 um 20:33 schrieb Skulski, Wojciech <skulski@pas.rochester.edu>:
Peter:
thank you for asking. RiskFive is low priority because it is at the sidelines of our funded work. Vedant is using one of these boards and I have four more piled on my desk. As of now Vedant has implemented Wiznet W5500 and he is now working on W5300. All this work was MicroBlaze and C because he is following Pong P. Chu firmware. My tentative plan is to let him complete this work, after which one of us will wrap RISC5 the same way as the MicroBlaze Controller System (MCS) from Xilinx. If RISC5 becomes a drop-in replacement for the MCS, then all the other firmware can stay in place.
Implementing the W5300 reqired changing the address map from Pong P. Chu to wider address chunks per module, because PP.Chu provides for only 32 memory locations, while W5300 needs 32 kB. This is a minor change, which is greatly facilitated by the modular structure of P.P.Chu bus. Interestingly enough, NW/PR bus is basically the same as the P.P.Chu bus, but it is documented in a different way. It turns out that the "bus" does not really exist inside the FPGA. All that exists is its documentation. You can read the WishBone document where they clearly say that WishBone is a specification rather than a firmware component. Much the same is true about NW/PR, P.P.Chu, and other such buses. I tentatively decided to adopt FPro by P.P.Chu because it is both simple and extensively documented. After changing the memory map we will rename it to SPro to avoid confusion with his FPro specs.
All this is firmware. My aim is development of a firmware framework with larger memory address range per chunk than FPro is providing, and then adopting P.P.Chu components to build a system on chip for our needs. Part of this work which of general interest can be open sourced, after writing and releasing sufficient documentation.
I reviewed the current Oberon System software from the point of view of porting it to a future SoC. I found that the low level modules such as Kernel, Display, Files, or a boot loader, will all need to be factored into a low level driver layer with the HW addresses, and the upper layer without. This is perhaps stated in the NW book, but this book does not accurately describe the Oberon System reality. In reality there are numbers literally hardcoded inside the modules in more than one place. For example, at the end of the BootLoader, the locations 12 and 24 are loaded with values. Now imagine porting this software to another SoC. How do you make sure that these values are properly interfaced with hardware if it is not clear what is going on. It happens in many places in the low level drivers.
My favorite lines of code in Modules.Mod are:
mno := inst DIV 100000H MOD 10H; pno := inst DIV 1000H MOD 100H; disp := inst MOD 1000H; .... SYSTEM.PUT(adr, (offset MOD 1000000H) + 0F7000000H);
Now imagine porting such undocumented code to range of different SoCs with different memory arrangements. It looks like a recipe for a disaster to me. It will be necessary to rewrite portions of low-level Oberon System code to factor out such pieces, before porting the system to other boards which are substantially different from the present boards. Documentation will be crucial. None of such literal values should be allowed in the portable code without extensive comments describing the mechanics. Such structural fixes would be needed before this software is portable to a different SoC.
It would be helpful if this community formed a task force to start modernizing the FPGA Oberon System. The first modest task of the task force could be commenting and documenting the low level code, as well as moving all the hardcoded locations into the definition module SysDef.Mod corresponding to the firmware memory locations. (Consult the P.P.Chu book where he is doing exactly that.)
Forming a task force could be contrary to the culture of this group. We seem to be very individualistic. And we do not seem to have a clear common goal.
I can circulate a draft review of the low level Oberon System if there is interest.
Thank you again for asking. And I want to profusely apologize to anyone who could read this e-mail as being unduly critical.
Wojtek ________________________________________ From: Oberon [oberon-bounces@lists.inf.ethz.ch] on behalf of peter@easthope.ca [peter@easthope.ca] Sent: Wednesday, November 13, 2019 12:55 PM To: oberon@lists.inf.ethz.ch Subject: [Oberon] RiskFive; was Oberon on ULX3S explanation
Wojciech, is RiskFive still viable? The last news on your site is 2018, November. Not criticizing; just wondering.
Thanks ... L.
-- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon -- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon
Joerg: Yes, of course, we all know the difference between "5" and "-V". The name coincidence is quite unfortunate now that RISC-V is taking off. It is not up to us to rename the NW's design ;-( My RiskFive originally was a pun. But now I just like this name. Wojtek ________________________________________ From: Oberon [oberon-bounces@lists.inf.ethz.ch] on behalf of Joerg [joerg.straube@iaeth.ch] Sent: Wednesday, November 13, 2019 4:20 PM To: ETH Oberon and related systems Subject: Re: [Oberon] RiskFive; was Oberon on ULX3S explanation Wojtek As RiscFive is in the title, I just want to point out that RISC-V https://en.m.wikipedia.org/wiki/RISC-V is a completely different CPU than NW‘s RISC-5 ( https://inf.ethz.ch/personal/wirth/FPGA-relatedWork/RISC-Arch.pdf To compile the Oberon system, the FPGA has to implement the RISC-5 CPU not the RISC-V br Jörg Am 13.11.2019 um 22:04 schrieb Joerg <joerg.straube@iaeth.ch>: Wojtek Porting the system to a new board is mainly a task of understanding and adapting the .v files. There are hardly any .Mod files you ever have to touch. The Oberon system can be compiled as is if the FPGA implements NW’s CPU and offers 1MB of memory, and the IOs and video framebuffer are mapped to the documented memory addresses. The first step in porting the system is: make the FPGA behave like the HW architecture as defined and documented by NW (His CPU, his 1MB memory layout with defined IO and framebuffer addresses.) AFTER you did that, you can take the second step and add new features to NW‘s machine like - adding more memory - adding color - adding Ethernet .... In this second step you might need to adapt 1 to 2 modules. Mainly BootLoad.Mod to adapt the memory layout (In Kernel.Mod the „stackSize“ is hardcoded. Unfortunately, Modules.Mod does not import stackSize from Kernel but hard codes it again😩) In case of color graphics Display.Mod has to be adapted. I might be wrong but that’s it. br Jörg Am 13.11.2019 um 21:23 schrieb Joerg <joerg.straube@iaeth.ch>: Wojtek I admit that the address fixing is not the easiest part of a compiler and module loader, but it is not undocumented. The first paragraph of chapter 12.7.9 in this document https://inf.ethz.ch/personal/wirth/ProjectOberon/PO.Applications.pdf<https://urldefense.proofpoint.com/v2/url?u=https-3A__inf.ethz.ch_personal_wirth_ProjectOberon_PO.Applications.pdf&d=DwMFaQ&c=kbmfwr1Yojg42sGEpaQh5ofMHBeTl9EI2eaqQZhHbOU&r=uUiA_zLpwaGJIlq-_BM9w1wVOuyqPwHi3XzJRa-ybV0&m=yPydbfcjYBO_zaOHzU24TsG_7DH-CPGRc2IvLWFxTGE&s=KJXKQxCUcZrWTWw1Dupmbb5NEmsJitt6A6aiPL26atQ&e=> explains what the compiler generates, why its doing it and what fields the module loader has to extract so he can modify the instruction while loading the module from disk to memory. BTW: The CPU instruction set of NW’s RISC-5 is documented here: https://inf.ethz.ch/personal/wirth/FPGA-relatedWork/RISC-Arch.pdf<https://urldefense.proofpoint.com/v2/url?u=https-3A__inf.ethz.ch_personal_wirth_FPGA-2DrelatedWork_RISC-2DArch.pdf&d=DwMFaQ&c=kbmfwr1Yojg42sGEpaQh5ofMHBeTl9EI2eaqQZhHbOU&r=uUiA_zLpwaGJIlq-_BM9w1wVOuyqPwHi3XzJRa-ybV0&m=yPydbfcjYBO_zaOHzU24TsG_7DH-CPGRc2IvLWFxTGE&s=E9zvHPCV7EaQEN3vax1Hx2S2SpXsg5tqczLmve4Kry0&e=> After reading it, you might understand that 0F7000000H is the assembler code for „BL always“ This Oberon code is totally agnostic to the used FPGA as long as the FPGA implements NW’s CPU called RISC-5. (to be found in RISC5.v) You can leave this Oberon code untouched. You „only“ have to make sure RISC5.v and more importantly RISC5Top.v is adapted to your FPGA and especially memory (address and timing) Jörg Am 13.11.2019 um 20:33 schrieb Skulski, Wojciech <skulski@pas.rochester.edu>: Peter: thank you for asking. RiskFive is low priority because it is at the sidelines of our funded work. Vedant is using one of these boards and I have four more piled on my desk. As of now Vedant has implemented Wiznet W5500 and he is now working on W5300. All this work was MicroBlaze and C because he is following Pong P. Chu firmware. My tentative plan is to let him complete this work, after which one of us will wrap RISC5 the same way as the MicroBlaze Controller System (MCS) from Xilinx. If RISC5 becomes a drop-in replacement for the MCS, then all the other firmware can stay in place. Implementing the W5300 reqired changing the address map from Pong P. Chu to wider address chunks per module, because PP.Chu provides for only 32 memory locations, while W5300 needs 32 kB. This is a minor change, which is greatly facilitated by the modular structure of P.P.Chu bus. Interestingly enough, NW/PR bus is basically the same as the P.P.Chu bus, but it is documented in a different way. It turns out that the "bus" does not really exist inside the FPGA. All that exists is its documentation. You can read the WishBone document where they clearly say that WishBone is a specification rather than a firmware component. Much the same is true about NW/PR, P.P.Chu, and other such buses. I tentatively decided to adopt FPro by P.P.Chu because it is both simple and extensively documented. After changing the memory map we will rename it to SPro to avoid confusion with his FPro specs. All this is firmware. My aim is development of a firmware framework with larger memory address range per chunk than FPro is providing, and then adopting P.P.Chu components to build a system on chip for our needs. Part of this work which of general interest can be open sourced, after writing and releasing sufficient documentation. I reviewed the current Oberon System software from the point of view of porting it to a future SoC. I found that the low level modules such as Kernel, Display, Files, or a boot loader, will all need to be factored into a low level driver layer with the HW addresses, and the upper layer without. This is perhaps stated in the NW book, but this book does not accurately describe the Oberon System reality. In reality there are numbers literally hardcoded inside the modules in more than one place. For example, at the end of the BootLoader, the locations 12 and 24 are loaded with values. Now imagine porting this software to another SoC. How do you make sure that these values are properly interfaced with hardware if it is not clear what is going on. It happens in many places in the low level drivers. My favorite lines of code in Modules.Mod are: mno := inst DIV 100000H MOD 10H; pno := inst DIV 1000H MOD 100H; disp := inst MOD 1000H; .... SYSTEM.PUT(adr, (offset MOD 1000000H) + 0F7000000H); Now imagine porting such undocumented code to range of different SoCs with different memory arrangements. It looks like a recipe for a disaster to me. It will be necessary to rewrite portions of low-level Oberon System code to factor out such pieces, before porting the system to other boards which are substantially different from the present boards. Documentation will be crucial. None of such literal values should be allowed in the portable code without extensive comments describing the mechanics. Such structural fixes would be needed before this software is portable to a different SoC. It would be helpful if this community formed a task force to start modernizing the FPGA Oberon System. The first modest task of the task force could be commenting and documenting the low level code, as well as moving all the hardcoded locations into the definition module SysDef.Mod corresponding to the firmware memory locations. (Consult the P.P.Chu book where he is doing exactly that.) Forming a task force could be contrary to the culture of this group. We seem to be very individualistic. And we do not seem to have a clear common goal. I can circulate a draft review of the low level Oberon System if there is interest. Thank you again for asking. And I want to profusely apologize to anyone who could read this e-mail as being unduly critical. Wojtek ________________________________________ From: Oberon [oberon-bounces@lists.inf.ethz.ch] on behalf of peter@easthope.ca [peter@easthope.ca] Sent: Wednesday, November 13, 2019 12:55 PM To: oberon@lists.inf.ethz.ch Subject: [Oberon] RiskFive; was Oberon on ULX3S explanation Wojciech, is RiskFive still viable? The last news on your site is 2018, November. Not criticizing; just wondering. Thanks ... L. -- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon<https://urldefense.proofpoint.com/v2/url?u=https-3A__lists.inf.ethz.ch_mailman_listinfo_oberon&d=DwQFaQ&c=kbmfwr1Yojg42sGEpaQh5ofMHBeTl9EI2eaqQZhHbOU&r=uUiA_zLpwaGJIlq-_BM9w1wVOuyqPwHi3XzJRa-ybV0&m=yPydbfcjYBO_zaOHzU24TsG_7DH-CPGRc2IvLWFxTGE&s=xmvtvt1h7a1ra9Myzzmw-1vXshLo1AfvxTFCkByFQwc&e=> -- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon<https://urldefense.proofpoint.com/v2/url?u=https-3A__lists.inf.ethz.ch_mailman_listinfo_oberon&d=DwQFaQ&c=kbmfwr1Yojg42sGEpaQh5ofMHBeTl9EI2eaqQZhHbOU&r=uUiA_zLpwaGJIlq-_BM9w1wVOuyqPwHi3XzJRa-ybV0&m=yPydbfcjYBO_zaOHzU24TsG_7DH-CPGRc2IvLWFxTGE&s=xmvtvt1h7a1ra9Myzzmw-1vXshLo1AfvxTFCkByFQwc&e=>
Joerg wrote:
Porting the system to a new board is mainly a task of understanding and adapting the .v files.
Or devising an entirely new set of files, not necessarily in Verilog. My favorite is P.P.Chu because of the quality of his book. There is no need to shy away from using an entirely new SoC if it is essentially almost ready to take. Another need is adding new hardware to the board. New HW then needs to be interfaced, using an entirely new Verilog/VHDL files.
There are hardly any .Mod files you ever have to touch.
I strongly disagree. The goal of porting is to develop drivers for the new hardware. Current modules do not suffice, if the hardware has changed. Just a simple example: Imagine I want to use a QSPI interface to the SD card. The present interface is SPI. The code, which is currently in Kernel.Mod, is implementing SPI. It needs to be changed for the QSPI. Also look at the Kernel parameters, which limit the SD layout and limit its size. They are all hard coded in present modules. Another example: The FAT32 file system. Imagine I want to use the full card capacity, and make it readable under Windows. Then I need to switch to the FAT32. There are FAT32 implementations. You can get one from Cypress. Originally it was developed by Spansion. It is pretty substantial software. There are other, simpler implementations with some restrictions. Implementing FAT32 under Oberon System is a feasible task, though obviously it is lots of work. You may say "no, we should not be doing this". This is a different statement from saying "no need to touch the .Mod". If we do not touch these modules then we declare the Oberon System frozen and running on a frozen hardware. It becomes an interesting museum piece.
The Oberon system can be compiled as is if the FPGA implements NW’s CPU and offers 1MB of memory, and the IOs and video framebuffer are mapped to the documented memory addresses.
Note that this discussion started around this new board with much more RAM. And it has the HDMI output for graphics. So there is a need for evolution right away. If we want to freeze the system, then yes, we stay with 1 MB and declare it done. But we can also say that the present System was a step in the evolution. There is no strong argument it should be the last step. We can define the Classic Oberon System as the one from NW website. One meg RAM, mono display, and SD card limited to 64 MB. Nice. Let it stay this way. It served its goal. But it needs not be the final goal forever. I am interested in a Portable Oberon System where all these limitations are lifted. The very definition of the Portable Oberon System is that it can be ported. Now, the more I look at the Classic details, the more obvious it becomes that a significant effort is needed on documentation, factoring out the literal numbers, and restructuring the System such that the portable and adjustable parts are separated from each other.
The first step in porting the system is: make the FPGA behave like the HW architecture as defined and documented by NW (His CPU, his 1MB memory layout with defined IO and framebuffer addresses.)
Yes, of course. Vedant is already running Astrobe on RiskFive. He is not far from running the Classic on RiskFive. I would love to see him running the Classic Oberon System there.
AFTER you did that, you can take the second step and add new features to NW‘s machine like - adding more memory - adding color - adding Ethernet
Yes. ....
In this second step you might need to adapt 1 to 2 modules. Mainly BootLoad.Mod to adapt the memory layout (In Kernel.Mod the „stackSize“ is hardcoded.
This may be optimistic. As soon as we start adding truly new hardware like QSPI version of the SD card, there will be more changes. And how about having TWO SD cards rather than one? The whole Kernel will fall apart. Note that two cards is a very reasonable feature. I want to have a separate System Disk which stays in place, and a possibly a much larger Data Disk where we will write the data files and take the disk for processing with a Windows PC. The Data Disk must use the full capacity. It will really help if the Data Disk is formatted with FAT32. So if I look at fairly modest changes (a full size SD card with a universal FAT32, for example) then it is no longer a small set of changes. The System design needs to be reconsidered.
Unfortunately, Modules.Mod does not import stackSize from Kernel but hard codes it again😩)
We are in agreement. I noticed a few more such places. I am sure there are more.
In case of color graphics Display.Mod has to be adapted. I might be wrong but that’s it.
The current Display, even BW, can stay as is for quite a while. It is handy for software development. I think that the Display is one of the strongest assets of this System from the architecture standpoint. Changing its size or colors is not breaking the structure of the System. It means that Display is very well integrated. The other changes which I indicated (FAT32, or two cards) are both causing the domino effect. It means that the file system is very deeply entrenched in the System design. Changing these parts will have a profound effect on the System structure. Please feel free to question my assessment. Thank you, Wojtek PS: I remoed the original post which was then massaged by the ProofPoint.
participants (3)
-
Joerg -
peter@easthope.ca -
Skulski, Wojciech