473,387 Members | 1,705 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Help Converting a C file into Jscript

joe
Hello, I have some code written in C that I want to transfer over to
JScript so I can run within my project to "burn" my DSP code into
EEPROM(Non-volatile RAM). I want to generate an .ldr file (a loader
file) of the .dxe to burn into NovRAM. Then I can load the .ldr file
into the TigerSharc's internal memory and then run a .js JScript and
it will load the boot kernal into the 8-bit NOV-RAM. Sounds very
simple, but currently we have to create the .ldr file and then close
the project and load another project that has the C code to do the
burn it process. It would be nice to create a script that can do this
is the same project directory. Here's the C code I want to transfer
into JScript:

#include <stdio.h>
#include <libsim.h>
#include <sysreg.h>
#include <signal.h>
#include <builtins.h>
#include <math.h>
#include <defTS101.h>
#include "Nov_Burn.h"
unsigned int *pINTMEM, *pNOVRAM;

unsigned int MemLen, loaderData, dummyRead;

unsigned int *pBurnAdd[6];

void main()
{
unsigned int i;
pINTMEM = (unsigned int *) INT_MEM; // load .ldr file to dsp
internal memory

pNOVRAM = (unsigned int *) NOVAD; // pointer to external NOV-RAM
(8-bit device)

MemLen = 8540;

//pINTMEM++;

for (i=0; i<MemLen; i++) // write 8-bits at a time to NOV-RAM
{
loaderData = *pINTMEM; // read from internal memory
*pNOVRAM++ = loaderData; // write 8-bits to external memory
*pNOVRAM++ = loaderData >> 8;
*pNOVRAM++ = loaderData >> 16;
*pNOVRAM++ = loaderData >> 24;
*pINTMEM++;

}

//burn sequence

pBurnAdd[0] = (unsigned int *) 0x10304E38;
pBurnAdd[1] = (unsigned int *) 0x1030B1C7;
pBurnAdd[2] = (unsigned int *) 0x103083E0;
pBurnAdd[3] = (unsigned int *) 0x10307C1F;
pBurnAdd[4] = (unsigned int *) 0x1030703F;
pBurnAdd[5] = (unsigned int *) 0x10304C63;

for (i=0; i<6; i++)
{
dummyRead = *pBurnAdd[i];
}
}
I've been looking over some JScript documentation from Analog Devices
web site but I don't know how to write to address's in JScript. I'm
hoping some one has done something like this and can give me some
ideas.

Thanks,
joe
Jul 23 '05 #1
1 1304
joe wrote:
Hello, I have some code written in C that I want to transfer over to
JScript so I can run within my project to "burn" my DSP code into
EEPROM(Non-volatile RAM). I want to generate an .ldr file (a loader
file) of the .dxe to burn into NovRAM. Then I can load the .ldr file
into the TigerSharc's internal memory and then run a .js JScript and
it will load the boot kernal into the 8-bit NOV-RAM. Sounds very
simple, but currently we have to create the .ldr file and then close

[...]

No, sounds stupidly complex!! ;-)

I think you are looking for a Java forum, not JavaScript. JScript is
Microsoft's version of JavaScript, you may want to try one of the
Microsoft JScript groups.

Cheers, Fred.

Jul 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: junk | last post by:
I am converting a large website with VBScript include files and JScript also included as <script language="jscript" runat="server"> in other include files. I would like to convert the VBScript to...
3
by: j.a. harriman | last post by:
Hi, On MSDN I know there is a JScript example (Upgrading Visual C++ Projects to Visual Studio .NET in Batch Mode) to upgrade VS6 C++ projects to .NET solutions. It converts the project files...
2
by: junk | last post by:
I am converting a large website with VBScript include files and JScript also included as <script language="jscript" runat="server"> in other include files. I would like to convert the VBScript to...
3
by: j.a. harriman | last post by:
Hi, On MSDN I know there is a JScript example (Upgrading Visual C++ Projects to Visual Studio .NET in Batch Mode) to upgrade VS6 C++ projects to .NET solutions. It converts the project files...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.