I am a web developer. But I have taken on a legacy project (about embedded hardware) which is written in C# with .net micro framework. My boss wants me to upgrade this project to .net core 3.1.
After searching on the Internet, it seems very hard to do that because the project code use so many built-in functionalities of .net micro framework.
For example:
Microsoft.SPOT.Time.TimeService.SetTimeZoneOffset(currentTimeZone * 2);
this statement calls an extern method, which is:
/// <summary>
/// Sets time zone of the system. Effective immediately.
/// </summary>
/// <param name="offsetInMinutes"></param>
[MethodImplAttribute(MethodImplOptions.InternalCall)]
public static extern void SetTimeZoneOffset(int offsetInMinutes);
and this extern method will call a C++ method.
I am filled with doubt about the possibility of upgrading .net micro framework to .net core.
Could you please give any comment or direction to make it?
Edit: Thanks to @mtz, I followed the link and used ".NET Portability Analyzer" in Visual Studio 2019. The report says that DDLs used in the legacy project are compatible with .net core.
Does it mean I can directly use these DDLs from .net micro framework?

Have a look at this guide https://learn.microsoft.com/en-us/dotnet/core/porting/
.NET Framework isn't exactly .NET Micro Framework, but that will give you an idea of the challenges.
I'd probably start by analyzing the csproj's if I were you, and try to move them to the new csproj format.
As for the code you have quoted, it's interop code and is not specific to the .NET Micro Framework, you can likely re-use that when retargeting to .NET Core 3. More info here