Click here to Skip to main content
15,891,657 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: SetTimer Pin
Mark Salsbery31-Oct-11 14:48
Mark Salsbery31-Oct-11 14:48 
GeneralRe: SetTimer Pin
Chuck O'Toole31-Oct-11 15:00
Chuck O'Toole31-Oct-11 15:00 
GeneralRe: SetTimer Pin
Erudite_Eric31-Oct-11 21:08
Erudite_Eric31-Oct-11 21:08 
GeneralRe: Thanks!!! Pin
columbos1492731-Oct-11 21:44
columbos1492731-Oct-11 21:44 
AnswerRe: example code with PumpMessages() Pin
App_1-Nov-11 8:53
App_1-Nov-11 8:53 
Questionalternative function for MCIWndCreate API Pin
VCProgrammer31-Oct-11 1:17
VCProgrammer31-Oct-11 1:17 
AnswerRe: alternative function for MCIWndCreate API Pin
Code-o-mat31-Oct-11 2:02
Code-o-mat31-Oct-11 2:02 
Question[SOLVED] Inline assembly syntax error.. Pin
CodingLover30-Oct-11 21:59
CodingLover30-Oct-11 21:59 
Hi all,

I start to do a simple application to control the P2LTCH(to blink a LED). So the toggle function as follow,

C++
void  toggleLed(unsigned char ledMask)
{
	asm
 	(
		mov dx, P2LTCH		/* Load the address of the register. */
		//in al, dx 		/* Read the contents of the register. */
		//mov ah, ledMask 	/* Move the ledMask into a register. */
		//xor al, ah 		/* Toggle the requested bits. */
		//out dx, al 		/* Write the new register contents. */
	);
}


However, it returns the following error.

C++
Error   [318] D:\Profiles\PC\WorkOnProjects\PIC\Demo\led_blink.c; 41.1 string expected
Error   [194] D:\Profiles\PC\WorkOnProjects\PIC\Demo\led_blink.c; 41.1 ")" expected
Error   [312] D:\Profiles\PC\WorkOnProjects\PIC\Demo\led_blink.c; 41.1 ";" expected


I do the coding on MPLAB IDE. Any comments really appreciate.
I appreciate your help all the time...
CodingLover Smile | :)


modified 1-Nov-11 5:54am.

AnswerRe: Inline assembly syntax error.. Pin
Malli_S30-Oct-11 22:39
Malli_S30-Oct-11 22:39 
GeneralRe: Inline assembly syntax error.. Pin
CodingLover30-Oct-11 23:41
CodingLover30-Oct-11 23:41 
AnswerRe: Inline assembly syntax error.. Pin
Richard MacCutchan30-Oct-11 23:50
mveRichard MacCutchan30-Oct-11 23:50 
GeneralRe: Inline assembly syntax error.. Pin
CodingLover30-Oct-11 23:56
CodingLover30-Oct-11 23:56 
GeneralRe: Inline assembly syntax error.. Pin
enhzflep31-Oct-11 0:51
enhzflep31-Oct-11 0:51 
GeneralRe: Inline assembly syntax error.. Pin
CodingLover31-Oct-11 1:02
CodingLover31-Oct-11 1:02 
GeneralRe: Inline assembly syntax error.. Pin
enhzflep31-Oct-11 1:18
enhzflep31-Oct-11 1:18 
GeneralRe: Inline assembly syntax error.. Pin
David Crow31-Oct-11 3:13
David Crow31-Oct-11 3:13 
GeneralRe: Inline assembly syntax error.. Pin
enhzflep31-Oct-11 3:19
enhzflep31-Oct-11 3:19 
GeneralRe: Inline assembly syntax error.. Pin
Richard MacCutchan31-Oct-11 0:54
mveRichard MacCutchan31-Oct-11 0:54 
GeneralRe: Inline assembly syntax error.. Pin
CodingLover31-Oct-11 1:03
CodingLover31-Oct-11 1:03 
GeneralRe: Inline assembly syntax error.. Pin
Snorri Kristjansson31-Oct-11 1:09
professionalSnorri Kristjansson31-Oct-11 1:09 
GeneralRe: Inline assembly syntax error.. Pin
CodingLover31-Oct-11 1:12
CodingLover31-Oct-11 1:12 
AnswerRe: Inline assembly syntax error.. Pin
CodingLover31-Oct-11 23:53
CodingLover31-Oct-11 23:53 
JokeRe: Inline assembly syntax error.. Pin
David Crow1-Nov-11 2:57
David Crow1-Nov-11 2:57 
QuestionHow to get the current active document of MDI application? Pin
rahul.kulshreshtha30-Oct-11 20:41
rahul.kulshreshtha30-Oct-11 20:41 
AnswerRe: How to get the current active document of MDI application? Pin
«_Superman_»30-Oct-11 21:55
professional«_Superman_»30-Oct-11 21:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.