tags:

views:

172

answers:

5

What would be the best programming language for a self service kiosk, it needs to respond to touch screen (just touches not gestures - yet). No keyboard or mouse so a virtual keyboard will be part of the application. Interface to third party payment solution using TCP socket. Print a receipt (without showing any windows printer spool messages etc...). Interface to third party hardware using RS232 serial interface and also USB. Connect either to a server or SQL database.

My first languages are C++ and C# but I have noticed a lot of people seem to be doing kiosk stuff in flash - i guess mainly for the fancy animations and graphics - which I also want to acheive, clearly this would require a lot more coding in C

Also the application will be expected to run 24/7 possibly for up to 1 month at a time with no restart so it has got to be rock solid, use minimal memory and cpu power.

The hardware will have between 128MB and 256MB of Ram so more than enough to run Windows, CLR and our application.

Our concern with flash type applications is based on two system we have tried that over a period of a week or so when run for 24/7 seemed to use up all of the memory slowly until the system just hung. The other thing we noticed again only after a very long period was an excessive amount of heat generated by the CPU just on the idle / welcome screen.

Our other applications (not self service) that are all C# based can run for these periods of times without exhibiting any of these problems. However I have to admit that building the slick graphics would be easier in flash (although far from impossible in C#).

Seems this maybe a memory management issue, which in C++/C# I have plenty of experience managing but know very little about this area in flash.

+1  A: 

C++ or C# for backend. You won't do much reliable TCP transactions, SQL or printing receipts in Flash. OTOH frontend with all the flashy gfx - yep, flash is quite a good choice.

You should be able to restart the flash frontend after each transaction (customer) and, say, once a hour in a screen blanker mode to avoid hidden memory leaks.

SF.
just looking around on net has raised the question of Silverlight
Silverlight is a valid option but it -is- more computationally heavy, and has much less support than Flash. 3D is about the only thing it does better. Nevertheless, the frontend can be discussed. It can easily be C++ or C# as well, or a web app in JS, or mostly anything to suit your needs. But you need a separate "low-level" backend to handle all the business logic and hardware interfacing. Neither Flash nor Silverlight can talk over RS232.
SF.
If I used C# to acheive a similar level of graphical animation at the front end, how would this compare overhead wise with Flash etc...
+1. just wanted to know, you can do TCP in flash without problems. TCP is provided by the OS, and the flash player exposes this API since flash player 9. I'd personally use TCP for the interface.
back2dos
@microkid: you can use C#. you could also write it in assembly :-P ... C# is a powerful language, .NET is a great framework. But they don't have the focus, flash has, and as such are less suited for the job.
back2dos
A: 

How about a C# application using WPF for presentation? That would give you access to the local machine in a way that wouldn't be possible using Flash or Silverlight, the ability to create nice visual effects and communicate securely with the database. Plus you don't have to know different languages for presentation and backend.

Anders Fjeldstad
Yes I must admit I have only just come accros WPF. How would this integrate with a C# back end
WPF is an alternative to WinForms when building Windows GUI applications with C#. So it's integrated by default.
Anders Fjeldstad
...and to clarify, if you're writing a distributed system with lightweight clients (the kiosks) and a central server software, the best way to solve the communication between them would probably be WCF services.
Anders Fjeldstad
I think this is the way im going to go - thanks!
If you're happy with the answer, consider marking it as "accepted".
Anders Fjeldstad
A: 

My initial thought was, like Anders, C# with WPF although I'd be worried by your 256MB limit as I'm not sure how 'light' WPF is. Also, doesn't some of the fancier WPF stuff require, or at least perform a lot better, with a DirectX capable card? A base kiosk system might have a low end graphics chip, so something else to look into.

Gareth Wilson
Hardware can be tweaked. But base unit is a 1GHz CPU, 128MB Ram, and shared intel graphics. We can specify memory up to 512MB and CPUT upto 2.4GHz if required but this is all at cost.
I guess it comes down to how proficient you are with C++ then, and how many kiosks you're rolling out. The C#/WPF route is probably the easiest, and therefore lowest development cost, but possibly offset by higher hardware specs/cost to get the same level of performance.Do you have a MSDN subscription? The Microsoft Expression series of tools will give you a good start with the WPF layout, and the back end code is just standard C# so you can use any existing class libraries you have, and the full .Net framework.
Gareth Wilson
Also, in addition to the development cost, I would consider the maintenance cost. My guess is that a C#/WPF solution would be more maintainable than a C++ or C#/Flash one which affects the total cost over the product lifecycle in a positive way.
Anders Fjeldstad
A: 

You should not measure flash by apps created with flash. One of the reasons flash is so popular, is that it's dead simple to create UIs with it. That's great for prototyping.

Many people using flash lack essential skills and understanding, because in "everyday" use of flash, they don't need it. If you get a decent flash developer, than he can, without any problems, create a UI that won't leak. Also be sure, to use a new player version. Maybe even flash player 10.1. which is currently available as a pre-release.

The approach suggested by SF is the best to go. To communicate between flash and the backend, you can use TCP or HTTP.

greetz

back2dos

back2dos
A: 

I worked on just such a system. C#/Winforms/SQL Server application with custom workflow engine/editor to handle different customers workflow requirements. We almost used WWF/WPF but I was just too new at the time and the in-house workflow engine was already written.

I also got a gig on a Flash front end C# back end app but ended up turning it down in favour of something better paid. They used XML to pass data between C# and flash. It seemd to work OK from what I saw.

kpollock