Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Renan

Pages: [1]
1
NXPTM M522XX, KINETIS and i.MX RT / Re: FLASH blocks
« on: September 18, 2009, 02:52:09 PM »
HI Mark,

I have to write data in flash and these data can not be changed when I make an upload.
I'm writing at the end of the boot loader (0x7FC) and I would like to know I have some problem in writing this region of the flash??
After I write in flash I can lock this block to prevent it from being modified?

Regards,

Renan.

2
NXPTM M522XX, KINETIS and i.MX RT / Re: fnWrite
« on: February 11, 2009, 12:34:44 PM »
Hi Mark,

I solved my problems with their tips and my system is working very well.

Regards,

Renan



3
NXPTM M522XX, KINETIS and i.MX RT / Re: fnWrite
« on: February 05, 2009, 07:30:34 PM »
I was actually returns a zero pointer, but now I can send thousands of packages in sequence without problems, thank's Mark.

In my system, I'm implementing a "Watchdog for ICMP" where it has the function to send pings (SendPing ()) for some set of IP addresses. When I send more than 3 packets of ping (SendPing ()) in sequence, I looked at that some are not sent or are overwritten by the next, how could I check whether or not I can send the next ping?


Regards..

Renan

4
NXPTM M522XX, KINETIS and i.MX RT / Re: fnWrite
« on: February 05, 2009, 04:50:28 PM »
Hi Mark,

   
My routine is simple, follows below:

Code: [Select]
if (inicia!=1){
uTaskerGlobalMonoTimer( OWN_TASK, (DELAY_LIMIT)(2   * SEC), E_MYEVENT); 
inicia =1;
}

    while ( fnRead( PortIDInternal, ucInputMessage, HEADER_LENGTH )) {   // check input queue
        switch ( ucInputMessage[MSG_SOURCE_TASK] ) {            // switch depending on message source
        case TIMER_EVENT:
       
    if (ucInputMessage[MSG_TIMER_EVENT] == E_MYEVENT)
{
enviaARP();
a=0;
for (a = 0; a <= 10; a++)
                                {
if (Ethernet_handle!=0)
{enviaPKG();}
}
uTaskerGlobalStopTimer( OWN_TASK, E_MYEVENT );
uTaskerGlobalMonoTimer( OWN_TASK, (DELAY_LIMIT)(2 * SEC), E_MYEVENT );
}

I created an event that occurs in 2 to 2 seconds and if found sends a data packet. Below the function that sends the packet:

Code: [Select]
void enviaPKG(void)
{
static unsigned int  lengh1 = 60;
static unsigned char * ptr    = 0;
       unsigned int usPortNr = 1000;
       unsigned char meuIP[4]  = { 192,168,0,121};
unsigned char teste[] =
{
0x08, //ETH.TYPE
0x00,
0x00,
0x01,
0x08,
0x00,
0x06,
0x04,
0x00,
0x01,
0x01,
0x08,
0x06,
0x00,
0x01,
0x08,
0x00,
0x06,
0x04,
0x00,
0x01,
0x08,
0x00,
0x06,
0x04,
0x00,
0x01,
};

// Aloca memoria para pacote
ptr = uMalloc(lengh1);
/* Monta o pacote */
// Dst = MAC do CG
uMemcpy(ptr, &meuIP, MAC_LENGTH);
// Src = MAC da gerencia
uMemcpy(ptr+6, network.ucOurMAC, MAC_LENGTH);
// ethernet type
uMemcpy(ptr+12, &teste, sizeof(teste));
// dados
uMemcpy(ptr+22, network.ucOurMAC, MAC_LENGTH);
uMemcpy(ptr+28, network.ucOurIP, IPV4_LENGTH);
// Zera os demais bytes do pacote
uMemset (ptr+34, 5, 60-34);

fnWrite(Ethernet_handle, ptr, lengh1);
fnWrite(Ethernet_handle, 0, 0);

}

I Follow the steps in another post but did not understand the problem. My "view memory" is in Attached, Can you help?




5
NXPTM M522XX, KINETIS and i.MX RT / Re: fnWrite
« on: February 04, 2009, 06:52:08 PM »
Yes, when I'm sending the package the value of Ethernet_handle is 8. In the Wireshark i can see the first 10 packets and the next 8 packets, in this moment the system stop to work in the function __interrupt__ static void undef_int (void).

Regards...

Renan

6
NXPTM M522XX, KINETIS and i.MX RT / Re: fnWrite
« on: February 04, 2009, 02:33:00 PM »
Hi Mark,

I used the function fnwrite to send a burst of ethernet packets. I am testing sending 10 packets of 200 bytes in a range of 2 seconds. The coldfire just hangs when I receive the 2nd round.

fnWrite(Ethernet_handle, pointer , lenght);
fnWrite(Ethernet_handle, 0 , 0);

I am using the function correctly? how can I increase the buffer of output?

Thanks...

Renan.

7
NXPTM M522XX, KINETIS and i.MX RT / fnWrite
« on: February 02, 2009, 07:46:54 PM »
Hi Mark,
I'm having problems when you send packets followed by fnwrite() function. I am sending 10 packages of 2 in 2 seconds and the system crash and getting stuck in the function:

__interrupt__ static void undef_int (void){
while (1) {}
}

It is normal that happen?

Best Regards.

Renan.

8
Hi Mark,
   
I'm having problems to upload a file larger than 63k. I'm using microcontroller M52233 (utasker SP8) what size max I can upload? 64k?

Another thing, how do I enable a password for the FTP?


Thank's in advance

9
NXPTM M522XX, KINETIS and i.MX RT / Re: fnSaveNewPars
« on: October 16, 2008, 08:29:18 PM »
Hi Mark,

Exactly, USE_MAINTENANCE The routine has been disabled and was the cause of my mistakes. :-[
Thank you for your attention, I'm migrating from an older version to the SP8 and I hope not generate more errors. :D

Best Regards;

Renan

10
NXPTM M522XX, KINETIS and i.MX RT / Re: fnSaveNewPars
« on: October 16, 2008, 06:22:51 PM »
Hi Mark,

Yes, I´m  include "config.h".

This error in the "myfile.c" also happens if I try to use the fnSaveNewPars() function in the file "arp.c" (for example), which is included the "config.h". ???

Best Regards...

Renan.

11
NXPTM M522XX, KINETIS and i.MX RT / fnSaveNewPars
« on: October 16, 2008, 01:32:27 PM »
Hi,

I'm calling the function "fnSaveNewPars(SAVE_NEW_PARAMETERS)" in my file Myfile.c and it is giving compilation error.
In this file, I am only including Myfile.h and  config.h and CW shows:

Link Error : Undefined : "fnSaveNewPars" Referenced from "myfunction" in "MyFile.c".
Link Failed.

I´m It seems to be something simple but I am not getting solved.  ???
I'm using the SP8.

Thanks in advance.

Renan.


12
NXPTM M522XX, KINETIS and i.MX RT / Re: Watchdog enable
« on: January 21, 2008, 12:32:15 PM »
Hi Mark,

I used the original version and could reproduce the same result. Then I returned some earlier versions and also worked, I have changed something that impair the functioning of the watch dog, but now is functioning properly.

Thanks,
Renan.

13
NXPTM M522XX, KINETIS and i.MX RT / Re: Watchdog enable
« on: January 03, 2008, 01:34:59 PM »
Hi MArk,

1.I checked my code and it enables the Watchdog always through
CWCR = CONFIGURE_WATCHDOG;

Watchdog activation defines is ...

Code: [Select]
#define ACTIVE_WATCHDOG_2_SEC   (CWE | WATCHDOG_2_SEC | CWTA | CWTAVA | CWTIF);
fnSetIntHandler(SW_WD_VECTOR, (unsigned char *)sw_wdog_timeout);
IC_ICR_0_8 = (INTERRUPT_LEVEL_7 | INTERRUPT_PRIORITY_7);
IC_IMRL_0 &= ~(SW_WDG_PIF_INT_L | MASK_ALL_INT);

2. I am putting the "while (1)" at the end of the application task "fnApplication" and I think now the main interrupts have already been started.

3. My interruption _sw_wdog_timeout () is using the command RESET_RCR = SOFT_RST to restart.

Everything seems to be as it should be, but the watchdog is never restart...
It would have a different configuration or test that I could do?

Regards..
   
Renan   

14
NXPTM M522XX, KINETIS and i.MX RT / Watchdog enable
« on: January 02, 2008, 08:26:25 PM »
Hi Mark,

I am not able to use the Watchdog to restart my processor, created a infinite loop "while (1)" and it appears that the watchdog was not triggered because my plate not restarted.
The configurations were made as shown in the tutorial for Coldfire M5223X.

    INIT_WATCHDOG_LED ();
     INIT_WATCHDOG_DISABLE ();
     If (! WATCHDOG_DISABLE ()) (
         CWCR = CONFIGURE_WATCHDOG;
     )
     Else (
         CWCR = WATCHDOG_DISABLED;
     )

I think I am setting up something wrong.
I would also like to know how I can create delays simple without using the timers, it is possible?

Regards...

Renan André Canello

15
NXPTM M522XX, KINETIS and i.MX RT / ICMP - Echo ping request and reply.
« on: November 16, 2007, 01:41:06 PM »
Hello,

I am starting to work with uTasker and I am sending through function fnSendPing ECHO PING REQUEST, I wonder how do I identify the echo ping reply returned.

Regards,

Renan André Canello

Pages: [1]