How to porting efax to MPY

C programming, build, interpreter/VM.
Target audience: MicroPython Developers.
Post Reply
skylin008
Posts: 54
Joined: Wed Mar 11, 2015 6:21 am

How to porting efax to MPY

Post by skylin008 » Fri Dec 23, 2016 3:27 am

Hello,every one ! I had seen the efax software at this web,https://www.cce.com/efax/download/,how to porting it to micropython to esp8266 or pyboard!TKS!

User avatar
dhylands
Posts: 3227
Joined: Mon Jan 06, 2014 6:08 pm
Location: Peachland, BC, Canada
Contact:

Re: How to porting efax to MPY

Post by dhylands » Fri Dec 23, 2016 5:16 am

My first guess is that its probably too big.

skylin008
Posts: 54
Joined: Wed Mar 11, 2015 6:21 am

Re: How to porting efax to MPY

Post by skylin008 » Fri Dec 23, 2016 6:01 am

@Thank you dhylands! Follows as efax introduction:

efax is a small ANSI C/POSIX program that sends and receives faxes using any fax modem (Class 1, 2 or 2.0).

efax is smaller and easier to install than HylaFAX or mgetty+sendfax. As one user put it ``EFAX is a nice simple program for single user systems.''

The ``fax'' command, a shell script, lets you send, receive, view and print faxes. In larger systems, faxes can be sent by printing to a ``fax'' printer and received faxes can be e-mailed as MIME attachments to an administrator for distribution. efax can also pass incoming data calls to a getty program.

The efax package includes ``efix,'' a program to convert between various image file formats. To fax Postscript files you will need Ghostscript. To view faxes you can use any program tha displays PGM files (e.g. xloadimage or xv). efix can also convert received files to Postscript or HP Laserjet formats for printing.

Version 0.9 of the program was written and tested under Linux 2.0. Previous versions have been compiled and used under most versions of Unix and should work with minor changes on any UNIX with an ANSI C compiler and libraries that include select(2) and termios(4).

User avatar
dhylands
Posts: 3227
Joined: Mon Jan 06, 2014 6:08 pm
Location: Peachland, BC, Canada
Contact:

Re: How to porting efax to MPY

Post by dhylands » Fri Dec 23, 2016 6:08 am

So the first challenge you'll have is to identify all of the places in the code that rely on linux stuff, since linux isn't available on esp8266 or pyboard, and figure out how you're going to implement that functionality in MicroPython.

You'll also need to identify all of the dependencies and include those in your porting calculations. There are no shared libraries in MicroPython (except perhaps when running under linux). So you'll also need to figure out how to compile all of this using static libraries. Once you've done that, you'l have a rough idea of how big your code is, and you can then decide if it will fit.

User avatar
platforma
Posts: 258
Joined: Thu May 28, 2015 5:08 pm
Location: Japan

Re: How to porting efax to MPY

Post by platforma » Fri Dec 23, 2016 9:47 am

Please don't cross-post. I have merged your topic under esp8266, but since the posts are identical, I'll remove the duplicate.

Post Reply