[Article] NuttX on Star64 JH7110: OpenSBI (Supervisor Binary Interface)

2023-10-28 Thread Lee, Lup Yuen
Bare Metal Programming on a RISC-V SBC (Single-Board Computer) sounds
difficult. Thankfully we can get help from the OpenSBI Supervisor Binary
Interface! (A little like BIOS, but for RISC-V)

In this article, we boot NuttX on Star64 JH7110 RISC-V SBC (and
VisionFive2) to experiment with OpenSBI:

(1) Print to the Serial Console
(2) Set a System Timer
(3) Query the RISC-V CPUs
(4) Fetch the System Information
(5) And Shutdown / Reboot our SBC

Check out the article: https://lupyuen.codeberg.page/articles/sbi.html

Lup


Re: Code donation

2023-10-28 Thread Tim Hardisty

Hi,

Did anyone else make any progress with porting your settings code to 
NuttX Apps? It's taken a while but I am at long last looking to add a 
settings function to my new app and this still looks like it'll fit the 
bill nicely.


If not, I will set it up as an app, make sure it works, and submit it 
for review hopefully in the next few weeks. I won't add YAML as yet, 
just binary - my current think is to use a YAML parser between the user 
and this function rather than storing YAML directly, but not 100% 
decided yet.


On 05/12/2022 11:22, Fotis Panagiotopoulos wrote:

Hello!

Thank you for your interest in this!

As requested, I created a temporal repository and uploaded all the code
there.

https://github.com/fjpanag/code_for_nuttx

I have added a NOTICE file in each subdir, with some basic information.
Please contact me before starting any work, to provide you with help and
coordinate the effort.
Better yet, you may open a Github issue for the piece of software that you
would like to help porting.


Alan,
I would love to cooperate with you in this effort.
Pick your target!


Alin,
I would really like to see my MQTT broker become part of NuttX.

Alternatively, you can have a look at the XML or JSON parsers, which are of
general usefulness,
and the porting effort would be very very minimal.


Tim,
Thank you for your interest in the settings storage.
It is a very useful and versatile piece of software. In fact, I have used
it in all my projects over the last 5-6 years.

I also thought about YAML before, but never got to actually implementing
this.

I suggest you first add a YAML parser to NuttX (maybe similarly to JSON and
XML, if they get accepted),
and then use it in the settings storage. It would be best not to couple
these two softwares so someone
may use one without the other. But, nevertheless, it is your call...

If you provide me with a YAML parser, I believe that I can develop for you
a new settings storage that uses this parser.

Fotis

On Mon, Dec 5, 2022 at 12:12 AM Tim Hardisty
wrote:


I have interest in your settings storage, with the probability of adding
yaml output since I was going to do something similar for my current
project (once I get over the pain of getting NuttX fixed for the arch I'm
using).

As have been suggested, maybe push it to github and I/we can clone what's
of interest, see if it makes sense, then get it working right for NuttX
and
do a PR...in the fullness of time (i.e. I'm a slow worker!)

On 04/12/2022, 16:55, "Fotis Panagiotopoulos"
wrote:

 Hello everyone!

 Christmas arrived a bit earlier for NuttX as I would like to donate
some of
 my personal code to the community!

 A bit of context.
 Over the years that I am working on embedded systems, I have developed
lots
 of software that I use in my projects.
 Some of it is quite general-purpose, or useful for other applications,
and
 I have found my self reusing it
 quite often. In fact, there are some things that I use in practically
all
 firmwares that I have developed over
 the last years.

 I always wanted to open-source this software so other people can
benefit
 from it.
 But I never managed to do so. Open-sourcing needs some effort, the
software
 needs maintenance, documentation
 and support, and most importantly in most cases a "porting layer"
needs to
 be developed.
 Last but not least, every project needs a bit of "marketing" and
 "advertising" so others can learn about
 your work and use it.

 For the last couple of years I have been using NuttX a lot, and I have
 ported most of the aforementioned software
 to NuttX. I believe that NuttX and its community are perfect for me to
 publish my code, instead of creating
 a ton of small repos, of questionable usefulness and increasing my
workload
 considerably.

 It is very important that I can get immediate feedback from the
community,
 learn what people are actually
 interested in (instead of investing on software that no one needs),
and
 provide actual and *working*
 samples of the code (as NuttX already supports a ton of different
boards
 and arches).

 Using POSIX as the porting layer is also awesome.

 That being said, my free time is still exceptionally limited and I
cannot
 do this myself.
 I still need the help of the community, and most importantly I need to
see
 interest in a piece of
 software before putting any work on it.

 So, what I offer:
 * I offer various codes, fully featured, production ready and tested.
 * All code will be offered for free (of course) and under Apache
licensing.
 * I will provide support to those working on these codes, to my best
 ability.
 * I will contribute to testing everything integrated to NuttX, as
hardware
 availability allows me.
 * I will do some licensing check, to ensure code is 100% original and
mine,
 or state the licenses