RetroBSD
http://retrobsd.org/

STM32F7 discovery kit
http://retrobsd.org/viewtopic.php?f=3&t=37284
Page 1 of 1

Author:  dmmiller [ Fri Sep 18, 2015 6:17 pm ]
Post subject:  STM32F7 discovery kit

http://www.st.com/web/en/catalog/tools/ ... scovery-pr

Looks pretty nice, and it has the built-in LCD (4.3") too. It looks like it runs STM32F7Cube, which possibly includes a RTOS?

This looks like it would be great to run RetroBSD on, provided there is an stm32 port. I saw an stm32 port mentioned a while back, but not sure if anyone got around to actually porting it yet. I think RetroBSD would be very useful, as the LCD could be used with a console framebuffer to use it with "standard" command-line mode.

It would be nice to have stm32f7 up and running.

Author:  vak [ Sat Sep 19, 2015 9:25 am ]
Post subject:  Re: STM32F7 discovery kit

It would be great to port RetroBSD to Cortex-M architecture.
We just need somebody who could take the lead.

Here is a quote from my old post 2012-Apr-10 with some hints.
Quote:
RetroBSD was developed with a portability in mind. Most of the kernel is architecture-independent (sys/kernel, sys/include). There is a small number of places, where a saved stack frame is directly referenced (look for u.u_frame) - it needs to be guarded by #ifdefs.

PIC32-related part of the kernel is placed in sys/pic32 directory. I would recommend to create sys/stm32 directory for this port. Some drivers, like SD card, console, GPIO or ADC probably could be moved to arch-independent place, say sys/drivers. Unfortunately, we cannot reuse USB stack (Microchip's copyright is too restrictive).

You can use sys/pic32/baremetal/Makefile configuration as a starting point, for simplicity. The challenge is to build a kernel, which can start and print a message on console. Copy a basic set of arch-dependent files from sys/pic32 to sys/stm32, and modify them (cpu.h, io.h, limits.h, machparam.h, startup.S, clock.c, cons.c, devsw.c, exception.c, machdep.c, mem.c, signal.c, sysctl.c). Design a memory map and create a linker script. All we need from MPU is to protect a kernel data region from the user programs.

Next step is to design a user/kernel API: how to pass args to syscalls and get returned data. This will help to build a syscall library (src/libc/thumb2/sys). All other assembler files can be ported from NetBSD or other sources.

A year ago there was some related activity on getacoder.com, but seems like it ended in nothing.
http://www.getacoder.com/projects/retro ... 63817.html

Author:  dmmiller [ Sat Sep 19, 2015 2:04 pm ]
Post subject:  Re: STM32F7 discovery kit

Thanks for the reply. It's probably best to take a look at the NetBSD sources, like you suggested. And the other thing is the LCD, which would require its own driver. It's a shame that this port stagnated before it could get off the ground.

Some people have speculated that it's a matter of time until Microchip ditches mips and adopts the arm architecture eventuallly, but it seems unlikely, as they (Microchip) have a lot of development time and money invested in their own mips-based proprietary architecture.

http://www.microchip.com/forums/m601857.aspx

Author:  Pito [ Sat Sep 19, 2015 2:34 pm ]
Post subject:  Re: STM32F7 discovery kit

Why do you need an ARM from Microchip? There is plethora of ARM MCU producers, so you may choose..
The major point with retrobsd implementation was the ram size in the past. 5y back - as the retrobsd started - the only chip with 128kB ram available (from which you can execute a program) was the pic32mx695/795.
So porting retrobsd to ARM cannot be a problem today, provided you posses a know-how and time for such an exercise :)
I would rather plead for a retrobsd port to the pic32MZ, though.. :P
That could be a good starting point for any talented programmer - afterwards you may port to CM4 or CM7 easily.

Author:  vak [ Tue Sep 22, 2015 4:25 am ]
Post subject:  Re: STM32F7 discovery kit

Here is a good ARM target board for RetroBSD:

http://www.adafruit.com/products/2390

Image

Author:  Pito [ Tue Sep 22, 2015 7:02 am ]
Post subject:  Re: STM32F7 discovery kit

The only "issue" with stm32F4xx (I like much) is the ram is split into 128kB + 64kB.
Not sure we can execute from those 64kB ram (so called CCM). Also no DMA to the CCM. Good for various buffers, however.

There are newer 32Fxx parts btw, with 256kB+ ram (F7 is 256kB + 64kB + 16kB + 4kB of ram). None model with 512kB chunk of ram yet.

Author:  vak [ Mon Sep 28, 2015 7:21 pm ]
Post subject:  Re: STM32F7 discovery kit

Pito wrote:
The only "issue" with stm32F4xx (I like much) is the ram is split into 128kB + 64kB.
Not sure we can execute from those 64kB ram (so called CCM). Also no DMA to the CCM. Good for various buffers, however.

There are newer 32Fxx parts btw, with 256kB+ ram (F7 is 256kB + 64kB + 16kB + 4kB of ram). None model with 512kB chunk of ram yet.

That's a good question, which part of RAM is executable.
The other topic is how to protect the kernel space from user space.

Author:  dmmiller [ Tue Sep 29, 2015 12:11 pm ]
Post subject:  Re: STM32F7 discovery kit

The Pyboard looks really nice. Embedded python isn't so bad. It's better than compiling a project and sending it to the board every time you want to run something. But how would you get RetroBSD to the board? Like this (Device Firmware Update mod)?

https://github.com/micropython/micropyt ... are-Update

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/