Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » Console Input under windows / use windows console
Console Input under windows / use windows console [message #947614] Wed, 17 October 2012 04:43
Eclipse UserFriend
Hi,


i was able to get the console output working using

setvbuf(stdout, NULL, _IONBF, 0);
setvbuf(stderr, NULL, _IONBF, 0);


Now i got the problem, that also the input doesnt work.
I've tried _kbhit() and getch() - they don't get anything from the console.

I got a workaround running using:

#include <windows.h>
#define KEY_DOWN(vk_code) ((GetKeyState(vk_code) & 0x8000) ? 1 : 0)


but I hope there is another way.

Is there a way to use the windows console?
Previous Topic:Incorrect Cortex M3 code disassembly in eclipse
Next Topic:Subprojects give me grief when using cmake
Goto Forum:
  


Current Time: Mon Jul 07 00:05:46 EDT 2025

Powered by FUDForum. Page generated in 0.03716 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top