industrialNETworXnetx

Rainer Versteeg

Rainer Versteeg

| 25.08.2008 | 09:02 | 13 replies

Bring netx over software in bootmode

HI,

Give´s there a API or DRV call to bring the netX in boot mode :?:

Our UART0 output is a RS422 or RS485 interface. Is it possible to flash a file over UART0 with the bootwizard :?:

Br,
Rainer

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 25.08.2008 | 09:25

Hi,

Rainer Versteeg wrote:
Give´s there a API or DRV call to bring the netX in boot mode :?:

Yes, that is possible.
First of all you have to disable the MMU at first before you proceed to bring the netX into the bootmode.
Bring the System Status Register into a defined condition.
Now simulate the RDY/RUN pins for the needed bootmode.
Jump now to the 0 vector of the netX.

Here are some code snippets:

/* Bring the System Status Register into a defined condition */
  s_ptSYSSTAT->uiSYS_STAT = 0x00000000;
   
  /* now simulate the RDY/RUN pins for the needed bootmode */
  s_ptSYSSTAT->uiSYS_STAT = MSK_SYS_STAT_REGISTER_RDY_DRV |   /* Driver enable for RDY LED. Enables output driver when set. */  
                            MSK_SYS_STAT_REGISTER_RUN_DRV |   /* Physical input signal level at RDY pin                     */ 
                            MSK_SYS_STAT_REGISTER_RUN;        /* Signal Level of the RUN LED output                         */

/* jump to the 0 vector of the netX */
__asm__ __volatile__("LDR pc, =0x00000000");

Rainer Versteeg wrote:
Our UART0 output is a RS422 or RS485 interface. Is it possible to flash a file over UART0 with the bootwizard :?:

The Bootwizard can only handle RS232 communication.

Rainer Versteeg

Rainer Versteeg

| 25.08.2008 | 09:42

HI AJ,

Thank you for the fast answer.

Is there a description or sourcecode availlable to communicate with the netX over USB or UART0 when it is in bootmode :?:

Br,
Rainer

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 25.08.2008 | 09:49

Only what is available in the Bootwizard documentation.

Rainer Versteeg

Rainer Versteeg

| 25.08.2008 | 10:05

HI AJ,

I have tested your code snippset.

When i do that

/* jump to the 0 vector of the netX */
  __asm__ __volatile__("LDR pc, =0x00000000");

the netX makes a reset :?:

Br
Rainer

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 25.08.2008 | 10:09

Yes, it is like a reset, because you jump back to the 0 Vector.

Rainer Versteeg

Rainer Versteeg

| 25.08.2008 | 11:02

HI AJ,

I mean the netX makes a reset and did not go in boot mode :!:
It restart my programs from the Paralel flash.

Here is my procedure :

TLR_VOID SET_INTO_BOOTMODE()
{
 __asm__ __volatile__("MCR	 p15, 0, r1, c1, c0, 0");   
 
 TLR_UINT32 ulVal;   
 POKE(NETX_SYS_STAT,0x00000000);
 ulVal=PEEK(NETX_SYS_STAT);
 ulVal=0x03000001;
 POKE(NETX_SYS_STAT,ulVal);
 __asm__ __volatile__("LDR pc, =0x00000000");

}

Br,
Rainer

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 25.08.2008 | 11:10

Maybe you have to change the needed settings for the RDY/RUN pins.

Rainer Versteeg

Rainer Versteeg

| 25.08.2008 | 11:54

HI AJ,

Sorry i have set the Signal level of the RDY LED instead of RUN LED. :oops:

Now it works :P

What commando i must send after download to reset the netX :?:

Br,
Rainer

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 25.08.2008 | 11:56

Please have a look into the Program Reference Guide for the Reset Register.

Rainer Versteeg

Rainer Versteeg

| 25.08.2008 | 12:15

HI AJ,

I mean over UART or USB, when the netX is in Bootmode :!:

I want to flash the file and after that a reset to start my program.

Br,
Rainer

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 25.08.2008 | 12:20

Hi Rainer,

sorry misunderstanding.

When you are in the serial boot mode and you have finished your flash procedure it is enough to type the word "BOOT" into the command line.

The boot command exits the Serial Port Bootmode and continues the boot sequence. It has no parameters.

:!: Please note: This function leaves the Serial Port Bootmode and thus unconfigures the uart and usb port. If the uart's pins are multiplexed with other functions, they are reset to their default function.

Rainer Versteeg

Rainer Versteeg

| 25.08.2008 | 17:16

HI AJ,

How is the configuration of the UART0 when it is in bootmode. :?:

Baudrate, Parity, Databits :?:

Use it RTS, CTS or DTR for handshake :?:

I have configured it with 9600, Parity even and send the string "BOOT". The netX answered it with 80 HEX, but make no reset :!:

Br,
Rainer

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 25.08.2008 | 17:20

Hi Rainer,
The settings are:
115k 8N1; no RTS, CTS or DTR.

Login