In the file: iostructures.h dated: 2/26/2003 (latest Win32 release),
there is a mistake in the struct definition for port 3. I didn't notice
it until I started to use it. The struct should start at memory
location 0x18, not 0x1b. Correct yours by replacing the struct
definition w/ this:
/****************************************************************/
#ifdef __msp430_have_port3
struct {
ioregister_t in; /* Input */
ioregister_t out; /* Output */
ioregister_t dir; /* Direction */
ioregister_t sel; /* Selection */
//} port3 asm("0x001b"); // <-- Incorrect
} port3 asm("0x0018");
#endif
Enjoy
-Mark
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Marc
Wetzel
Sent: Wednesday, February 26, 2003 2:40 AM
To: [email protected]
Subject: RE: [Mspgcc-users] alternative main()
Hi Matthew,
A common approach is do include a main() with your library, with calls
after some sort of initialization another main, in this case your
XM_main().
Create some kind of startup.c and a startup.h with the definition of
extern int XM_main(argc,argv...) in it.
Afaik this is done in MFC/Win32 (-> WinMain() ) or NutMain (on NutOs
<V3.0)
But what do you dislike in overriding with the help of the .init
segment?
Greetings
/Marc
> -----Original Message-----
> From: [email protected]
> [mailto:[email protected]] On Behalf
> Of [email protected]
> Sent: Wednesday, February 26, 2003 6:13 AM
> To: [email protected]
> Subject: [Mspgcc-users] alternative main()
>
>
> Is there any way I can redefine the call to main() with
> another function
> without over riding the startup proceedure ? At the end of the
> application startup I would like to call my own function
> XM_main() instead of main(). Is this possible, am I making sense ?
>
> Cheers
>
> Matthew
> Design Engineer
> ----------------------------------------------------------------------
> Tekelek Pty Ltd
> Australia
>
>
>
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: Scholarships for Techies!
> Can't afford IT training? All 2003 ictp students receive
> scholarships. Get hands-on training in Microsoft, Cisco, Sun,
> Linux/UNIX, and more. www.ictp.com/training/sourceforge.asp
> _______________________________________________
> Mspgcc-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/mspgcc-users
>
-------------------------------------------------------
This SF.net email is sponsored by: Scholarships for Techies!
Can't afford IT training? All 2003 ictp students receive scholarships.
Get hands-on training in Microsoft, Cisco, Sun, Linux/UNIX, and more.
www.ictp.com/training/sourceforge.asp
_______________________________________________
Mspgcc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mspgcc-users