***** ASSERT ***** during program execution

Hello. I am getting an ***** ASSERT ***** on the screen of my EMX Development System

I found an old post:

Was running the latest tweaked version of my app described in this thread:
http://www.tinyclr.com/forum/21/4703/
and it appeared that the code executed successfully, but then I noticed that the following appeared on my LCD:
***** ASSERT *****
Any clues on what that means?
Thankfully, when I re-run the app, the message goes away, so doesn’t look like I borked anything permanently

Reply from GUS:
This should not happen and if it did we need the simplest possible program you can provide that repro this so we can look into it.

Is this still a ‘should not be happening issue’? If so, I can post the relevant code.

Thanks,
Rick

I did some further checking and my program runs, but I get the ***** ASSERT ***** first

If I turn on power to the board, I get:

  1. EMX…version… debug…
  2. Screen Clears
  3. ***** ASSERT ***** for several seconds. Then it disappears for a fraction of a second… then it comes back ***** ASSERT *****. This can happen several times (usually about 10-15 seconds worth of this
  4. Then my program runs (it writes to the screen, so I know it is running).

We need the code and firmware version please.

Where should I send the code. I ‘smallified’ the code to simplify the issue as much as possible. All it does is write “Board Test” to the screen. It works fine after about 10 seconds of 4 ***** ASSERT *****.

This seemed to start occurring after I went to firmward version 4.2.7.0

Thanks.

You can paste it here (please use code tags)

Here it is.


using System;
using System.Threading;
using Microsoft.SPOT;
using GHI.Premium.Hardware;
using GHI.Premium.IO;
using GHI.Premium.System;
using Microsoft.SPOT.Hardware;
using System.IO;
using Microsoft.SPOT.Net.NetworkInformation;
using System.Net.Sockets;
//using GHI.Premium.Hardware.EMX;
using Microsoft.SPOT.Presentation;
using Microsoft.SPOT.Presentation.Media;
using System.Net;

namespace EMXbase
{
    public class Program
    {        
        public static String strOutputText = "";
        public static int iLineCount = 0;

        public static void Main()
        {
            BigText("Board Test");
            while (true)
            {
                Thread.Sleep(50);
            }
        }


        public static void BigText(String strMessage)
        {
            if (strOutputText.Length > 0)
            {
                strOutputText += "\n";
            }
            iLineCount++;
            if (iLineCount > 5)
            {
                strOutputText = "";
                iLineCount = 0;
            }
            strOutputText += strMessage;


            Bitmap LCD = new Bitmap(SystemMetrics.ScreenWidth, SystemMetrics.ScreenHeight);

            LCD.Clear();  // clears the memory and not the display
            //for (int i=10; i<200; i += 4)
            //{
            //    LCD.DrawLine(Colors.Green, 1, 10, i, i, 200); //draw in memory
            //}

            //Debug.Print("Test");

            Font MyFont = Resources.GetFont(Resources.FontResources.small);
            //LCD.DrawText(strMessage, MyFont, Colors.Cyan, 20, 20);
            LCD.DrawTextInRect(strOutputText, 0, 0, SystemMetrics.ScreenWidth, SystemMetrics.ScreenHeight, 0, Colors.Cyan, MyFont);
            LCD.Flush(); // transfer the bitmap memory to the actual display
        }   
    }
}

Sorry. You beat me to it. I noticed that and fixed it quickly… not fast enough though. :wink:

Interestingly, the problem goes away if I go back to 4.1.8. But I’d really like to start using 4.2.

I think you reference too many assemblies or some of them are of the wrong version. I have tried your example and don’t have any Asserts.

LOL. I wouldn’t be surprised since that is the issue in my other thread. I’ll try it again this weekend and see how it goes.

Thank you.

You are welcome!