Go Down

Topic: Interfacing arduino to Power Point (Read 2 times) previous topic - next topic

wizdum





By default, Power Point lets you change slides by pressing keys on the keyboard, or by clicking a mouse. The simplest solution would be to use an arduino leonardo to emulate a keyboard or mouse.


Hi,
Well I wish to learn along the way, leanardo seems to be the simplest solution, but I am planning to build my own stand alone slide changer, and in the process want to learn all this.
The hardware is actually ready, I have a standalone pcb with atmega 328 smd, and a bluetooth which can send data to pc's serial port.
What I would like to do is to use that data (data can be sent according to wish or requirement) being recieved at serial port to run a slide show.
can you guide me?


Depending on how the serial port is set up, Gobetwino should allow you to do this.

Also, keep in mind that bluetooth has a fairly limited range, 30 feet in low power mode IIRC.
"Anyone who isn't confused really doesn't understand the situation."

Electronic props for Airsoft, paintball, and laser tag -> www.nightscapetech.com

ea123

Quote
Now I know arudino can send data to the serial port of the pc, but how can I interface the serial port to power point?


Hi,
if you know any .NET programming language (i.e. VB, C#) there is an easy way for controlling a power point presentation from code:

Code: [Select]

         string presPath = "c:/Temp/test_pps.ppt";
         //Create an instance of PowerPoint.
         Microsoft.Office.Interop.PowerPoint.Application app = new Microsoft.Office.Interop.PowerPoint.Application();

         // Show PowerPoint.
         app.Visible = Microsoft.Office.Core.MsoTriState.msoTrue;

         // Open a presentation.
         Microsoft.Office.Interop.PowerPoint.Presentations ppPres = app.Presentations;
         Microsoft.Office.Interop.PowerPoint.Presentation pres = ppPres.Open(presPath, MsoTriState.msoFalse, MsoTriState.msoTrue, MsoTriState.msoTrue);

         // Show presentation.
         pres.SlideShowSettings.Run();

// Here read a command from serial port (for example the ASCII char 'N' for next and 'P' for previous) and call
// pres.SlideShowWindow.View.Next(); or pres.SlideShowWindow.View.Next();


The previous code is in C# and some exception control should be added but is an example.


satinssoldier




Hi,
if you know any .NET programming language (i.e. VB, C#) there is an easy way for controlling a power point presentation from code:



Hi,
Well I do not know VB or C#, but I do know C++. Although I got a few ways to do it now, but I would still like to learn to create my own program to do such stuff. Is there a way where I can do something using C++, and which languages would you recommend I learn for being able to interface embedded hardware with windows or other operating systems, where I can control the programs in the OS using the hardware I build.

Udo Klein

Quote

By default, Power Point lets you change slides by pressing keys on the keyboard, or by clicking a mouse. The simplest solution would be to use an arduino leonardo to emulate a keyboard or mouse.


Actually the simplest solution is to crack open an old keyboard and rewire the keyboard chip accordingly. This is trivial. It is also very simple to add some transistors to make the Arduino "push the buttons". Of course it is not considered very elegant but it is definitely much simpler than USB programming.
Check out my experiments http://blog.blinkenlight.net

ea123

Quote

Is there a way where I can do something using C++, and which languages would you recommend I learn for being able to interface embedded hardware with windows or other operating systems, where I can control the programs in the OS using the hardware I build


Yes, you can program in C++ but some knowledge of Windows environment is necessary (WIN32, MFC, COM), here is explained how to do an MFC application to automate Power Point using MFC (Microsoft Foundation Classes):

http://support.microsoft.com/kb/237554/en-us?fr=1

If you learn how to open a serial port on Windows and read/write data, you can easily create a communication link between Arduino and a client application on the PC.
If you already know C++ and object oriented programming, I suggest you to learn C# language for programming Windows applications.

Go Up