Hello,
I’m trying to load the firmware on my SC20260 board but I get an error every time.
I’m using TinyCLR Config V2.0.0 and trying to load the firmware named “SITCore Firmware v2.0.0.ghi”.
I get the same error both selecting the “SC20260_SC20260” port or “COMx” after a reset with LDR.
In both cases, it connects (“Connected” appears in green color), I click “Update Firmware”, “connecting to loader mode…” appears; then the progress bar goes from “Loading Firmware 0%” to “Loading Firmware 100%” and then a red status appears with the message “There was an error during the upload”.
If I reconnect the device I see that device mode is “Firmware” and version is “2.0.0.8000”.
I tried both connecting the board through an USB 2.0 powered hub or an USB 3.0 docking unit with same results.
Thank you Gus, I installed the latest “TinyCLR config v2.1.0-preview4” and tried to upload the latest firmware “SITCore Firmware v2.1.0.4000.ghi” and I get the same error at the end of the firmware upload (whan it arrives at 100%). The reason is not specified.
After uploading the firmware (with both versions 2.0.0 or 2.1.0 preview 4), the TinyCLR Config app reports that the firmware is installed, even if I got the error message.
But with TinyCLR 2.0.0 I can deploy correcttly a simple app (the example of a blinking led on your “Getting started” page) and I can debug with VS 2019 with no errors (the led blinks).
If I use the 2.1.0 preview 4 the compiler throws a checksum error even if:
I installed the correct vsix extension (TinyCLR OS Project System v2.1.0-preview4.vsix)
I downloaded and referred the TinyCLR OS Libraries v2.1.0-preview4 in the nuget manager
The output says this:
In the TinyCLR Device Deployment output log:
Looking for a device on transport ‘USB’.
Found device port ‘USB’ with ID ‘1a9689a2-ce2c-409a-b2ec-7f4a08f9436d’ for transport ‘Usb’.
Starting device deployment.
Attempting to connect to device ‘USB:SC20260’: iteration 0.
Opening port ‘\?\usb#vid_1b9f&pid_5010#6&34cd6bee&3&1#{c13bcfe9-5e84-4187-9baa-45597ffcbb6f}’.
Attaching debugger engine.
Debugger engine attached.
Generating device specific assemblies.
TinyCLRTestApp v1.0.0.0 with size 608 bytes at ‘D:\Users\Vittorio\SCM20260\TinyCLRTestApp\TinyCLRTestApp\bin\Debug\pe\TinyCLRTestApp.pe’.
mscorlib v2.1.0.0 with size 71.832 bytes at ‘D:\Users\Vittorio\SCM20260\TinyCLRTestApp\TinyCLRTestApp\bin\Debug\pe\mscorlib.pe’.
GHIElectronics.TinyCLR.Devices.Gpio v2.1.0.0 with size 4.772 bytes at ‘D:\Users\Vittorio\SCM20260\TinyCLRTestApp\TinyCLRTestApp\bin\Debug\pe\GHIElectronics.TinyCLR.Devices.Gpio.pe’.
GHIElectronics.TinyCLR.Native v2.1.0.0 with size 5.692 bytes at ‘D:\Users\Vittorio\SCM20260\TinyCLRTestApp\TinyCLRTestApp\bin\Debug\pe\GHIElectronics.TinyCLR.Native.pe’.
Total deployment size is 82.904 bytes.
Incrementally deploying assemblies to the device:
Allocating assemblies:
Writing sector 1 (82.912 bytes).
Assemblies deployed. There are 571.432 bytes left in the deployment area.
Restarting interpreter.
Attaching to device.
Waiting for device to initialize.
In the debug log:
Found debugger!
Create TS.
Loading Deployment Assemblies.
Attaching deployed file.
Assembly: mscorlib (2.0.0.0)
Error: the reference mscorlib cannot be used with this version of the firmware.
Firmware checksum 0xC8BE8BE5 does not match the assembly checksum 0x88C3BB44.
Resolving.
The debugging target runtime is loading the application assemblies and starting execution.
Ready.
Cannot find any entrypoint!
Done.
Waiting for debug commands…
The program ‘[1] TinyCLR application: Managed’ has terminated with code 0 (0x0).
The dev board I am using is a custom board, the same that I use with the G400D SOM as it is pin-compatible. I have a dozen of production apps that I want to move to this new SitCore SOM migrating the application from NETMF to TinyCLR (hoping that all the functionalities the applications use are supported by this framework).
Yes, I did.
After erasing it (Erase All command), then I can connect the device via COMx port only, and when connected it says that the device mode is “Loader” and version “v2.1.3”.
After loading the firmware I get the same error “There was an error during the upload”.
If I connect again the device it says that device mode is “Firmware” and version is “2.1.0.4000”.
If I immediately choose “Erase application” I see this log in the debug window of TinyCLR Config:
???(?.=?
Found debugger!
Create TS.
Loading Deployment Assemblies.
Resolving.
Ready.
Cannot find any entrypoint!
Done.
Waiting for debug commands…
Probably this is normal as no any application has been deployed, but I don’t know if those trailing ???(?.=? characters are a normal behavior.
Thank you.
The device firmware I am trying now is 2.1.0.preview4.
In Visual Studio I installed the matching v2.1.0preview4 vsix extension and all the ghi nuget packages referred in the application are matching V2.1.0preview4 version.
I didn’t find any other place to select a different mscorlib version, any suggestion?
Yes, each used library is correct, version 2.1.0.preview4.
Now I can debug, suddenly it started working, probably the VS2019 environment was still updating in background after changing the nuget package version, as after a few minutes the debug started working correctly without making any other change.
Hello Gus,
I tried today the deployment of the firmware using a different brand new POWERED USB hub.
After the firmware upload arrives to 100%, I always get the error
Anyway, the system seems it is correctly loaded as I can connect the board to the VS2019 environment and debug correctly.
A reason for the error arised by TinyCLR Config would be useful.
The dev board I use is a custom board that It is correctly working for our G400D/NetMF4.3 projects.
A possible cause can be one or more pins that are connected on the board but I don’t know how to find them as the G400D and the SCM20260 should be pin-compatible.