Page 3 of 3

Re: imprimir en una pidion BIP-1300

PostPosted: Thu Jun 25, 2009 8:18 am
by pymsoft
Wilson,

Me alegra mucho que hayas logrado compilar y montar tu aplicacion :)
Imagino que como yo, antes de tener el PDA en mano, pensaste fuera mucho mas facil la impresion y luego descubres todo esto... bueno, menos mal que esta el foro... y Antonio.

las librerias no se si son de libre distribucion, pero cuando programas para el pidion, viene un cd con esas librerias y basta copiarlas a una carpeta y luego ponerla en el path de tu batch file, los wrappers que armé no hay problema, Antonio me enseño como hacerlos y es justo que queden aqui en el foro para uso de todos y si alquien quiere y puede mejorarlo, bienvenido sea.
Para el pidion hice solo lo que me servia para imprimir, faltan muchisimas cosas que no he tenido tiempo de hacer.


Saludos

Re: imprimir en una pidion BIP-1300

PostPosted: Thu Jun 25, 2009 1:48 pm
by wilsongamboa
Pedro gracias x todo y Antonio podria enviarte por email el zip con las librerias includes y un ejemplo de uso para que lo pongas como ejemplo ?
despues de unas 3 horas inicio la demostracion del sistema gracias a todos y en verdad Fwppc es un contrincante formidable en esta plataforma hemos logrado bajar los costos del proyecto en un 60% gracias a tan magnifica herramienta Antonio gracias x poner tu genio al servicio de los menos afortunados como nosotros
att

Re: imprimir en una pidion BIP-1300

PostPosted: Thu Jan 21, 2010 9:04 pm
by Antonio Linares
Wilson,

Podrias por favor proporcionar el fichero ZIP con todo lo necesario ya que Julio Perez lo necesita ? gracias :-)

Re: imprimir en una pidion BIP-1300

PostPosted: Thu Jan 21, 2010 10:32 pm
by wilsongamboa
Antonio les he contestado a ti y al Sr Perez
Perdon por no hacerlo antes es que he estado un tanto ocupado

saludos


Wilson

Re: imprimir en una pidion BIP-1300

PostPosted: Fri Jan 22, 2010 8:43 am
by Antonio Linares
Wilson,

Muchas gracias :-)

Si no tienes inconveniente vamos a copiar aqui el código para que le sea de utilidad a otros usuarios :-)

pidion.prg
Code: Select all  Expand view
#define __TEST__

//definiciones para la pidion

#define BB_PRINTER_SEORO            0
#define BB_PRINTER_SEIKO            1
#define BB_PRINTER_NONE             2

#define BB_PRINT_DEFAULT            0
#define BB_PRINT_EMPHASIZE          1
#define BB_PRINT_CENTERALIGN        2
#define BB_PRINT_RIGHTALIGN         4
#define BB_PRINT_DOUBLEWIDTH        8
#define BB_PRINT_DOUBLEHEIGHT       16
#define BB_PRINT_DOUBLESIZE         24
#define BB_PRINT_UNDERLINE          32

#define BB_PRINT_DENSITY_60PERCENT  0
#define BB_PRINT_DENSITY_70PERCENT  1
#define BB_PRINT_DENSITY_80PERCENT  2
#define BB_PRINT_DENSITY_90PERCENT  3
#define BB_PRINT_DENSITY_100PERCENT 4
#define BB_PRINT_DENSITY_110PERCENT 5
#define BB_PRINT_DENSITY_120PERCENT 6
#define BB_PRINT_DENSITY_130PERCENT 7
#define BB_PRINT_DENSITY_140PERCENT 8
#define BB_PRINT_DENSITY_DEFAULT    BB_PRINT_DENSITY_90PERCENT
#define BB_PRINT_DENSITY_MIN        BB_PRINT_DENSITY_60PERCENT
#define BB_PRINT_DENSITY_MAX        BB_PRINT_DENSITY_140PERCENT

#define BB_PRINT_LINESPACING_ONESIXTH   24
#define BB_PRINT_LINESPACING_DEFAULT    24
#define BB_PRINT_LINESPACING_MAX        255

#define BB_PRINT_BARCODE_UPCA       65
#define BB_PRINT_BARCODE_JAN13      67
#define BB_PRINT_BARCODE_JAN8       68
#define BB_PRINT_BARCODE_CODE39     69
#define BB_PRINT_BARCODE_ITF        70
#define BB_PRINT_BARCODE_CODABAR    71
#define BB_PRINT_BARCODE_CODE93     72
#define BB_PRINT_BARCODE_CODE128    73
#define BB_PRINT_BARCODE_CODE128A   73
#define BB_PRINT_BARCODE_CODE128B   74
#define BB_PRINT_BARCODE_CODE128C   75

#define BB_PRINT_BARCODE_WIDTH_THIN         2
#define BB_PRINT_BARCODE_WIDTH_NORMAL       3
#define BB_PRINT_BARCODE_WIDTH_THICK        4
#define BB_PRINT_BARCODE_WIDTH_MORETHICK    5
#define BB_PRINT_BARCODE_WIDTH_MOSTTHICK    6

#define BB_PRINT_BARCODE_ALIGN_LEFT         0
#define BB_PRINT_BARCODE_ALIGN_CENTER       2
#define BB_PRINT_BARCODE_ALIGN_RIGHT        4

#define BB_PRINT_BITMAP_NORMAL              0
#define BB_PRINT_BITMAP_DOUBLE_HEIGHT       1
#define BB_PRINT_BITMAP_DOUBLE_WIDTH        2
#define BB_PRINT_BITMAP_DOUBLE              3
#define BB_PRINT_BITMAP_ALIGN_CENTER        4
#define BB_PRINT_BITMAP_ALIGN_RIGHT         8

#define BB_PRINT_FONTTYPE_42                0
#define BB_PRINT_FONTTYPE_40                1
#define BB_PRINT_FONTTYPE_32                2

#define BB_PRINT_FONTSET_ASCII              0
#define BB_PRINT_FONTSET_HANGUL             1
#define BB_PRINT_FONTSET_SYMBOL             2
#define BB_PRINT_FONTSET_THAI               3

#include "FWCE.ch"
#include "vKey.ch"
#include "winapi.ch"
#include "DbInfo.ch"

#define SISTEMA "Jose-Pocket-Pc"

#define RDD_SISTEMA      'DbfCdx'

#ifdef __TEST__

    Function Main
        ProvaStampaPidion()
    Return Nil

#endif

FUNCTION ProvaStampaPidion()

  LOCAL i

  //Prt_ProvaStampa()

  Prt_Open()
  Prt_Init()
  Prt_PrintText( AnsiToWide( "Prova Riga 1"  + CRLF ), BB_PRINT_DEFAULT )
  Prt_PrintText( AnsiToWide( "Prova Riga 2"  + CRLF ), BB_PRINT_CENTERALIGN )
  Prt_PrintText( AnsiToWide( "Prova Riga 3"  + CRLF ), BB_PRINT_RIGHTALIGN )
  Prt_PrintText( AnsiToWide( "Prova Riga 4"  + CRLF ), BB_PRINT_DOUBLEWIDTH )
  Prt_PrintText( AnsiToWide( "Prova Riga 5"  + CRLF ), BB_PRINT_DOUBLEHEIGHT )
  Prt_PrintText( AnsiToWide( "Prova Riga 6"  + CRLF ), BB_PRINT_DOUBLESIZE )
  Prt_PrintText( AnsiToWide( "Prova Riga 7"  + CRLF ), BB_PRINT_UNDERLINE )
  Prt_PrintText( AnsiToWide( "Prova Riga 8"  + CRLF ), BB_PRINT_CENTERALIGN + BB_PRINT_UNDERLINE )

/*
#define BB_PRINT_EMPHASIZE          1
#define BB_PRINT_CENTERALIGN        2
#define BB_PRINT_RIGHTALIGN         4
#define BB_PRINT_DOUBLEWIDTH        8
#define BB_PRINT_DOUBLEHEIGHT       16
#define BB_PRINT_DOUBLESIZE         24
#define BB_PRINT_UNDERLINE          32
*/


  FOR i := 1 TO 4
    Prt_PrintText( AnsiToWide( CRLF ), BB_PRINT_DEFAULT )
  NEXT
  //Sleep(100)
  Prt_Close()

  msginfo("Chiusa")

RETURN NIL

    ********
    FUNCTION Prt_LineFeedByLine( nRighe )
    ********
    LOCAL i
      DEFAULT nRighe := 1
      FOR i := 1 TO nRighe
          Prt_PrintText( AnsiToWide( CRLF ), BB_PRINT_DEFAULT )
      NEXT
    RETURN NIL

/// programas para comunicarsze con la impresora de pidion

    #pragma BEGINDUMP

        #include "hbapi.h"
        #include "windows.h"
        #include "bbappapi.h"
        #include "bberror.h"

        static HBBPRINTER hPrinter;

        HB_FUNC( PRT_OPEN )
        {
            hPrinter = BBPrinterOpen( 0 );

            if ( !hPrinter )
            {
                return;
            }
        }

        HB_FUNC( PRT_CLOSE )
        {
            DWORD dwRet = BBPrinterWaitUntilPrintEnd( hPrinter );
            BBPrinterClose( hPrinter );
        }

        HB_FUNC( PRT_INIT )
        {
            BBPrinterSetLineSpacing( hPrinter, 8 );                     // Set line spacing 1/18 inch.
            BBPrinterSetDensity( hPrinter, BB_PRINT_DENSITY_100PERCENT );   // Set density 100%
            BBPrinterInit( hPrinter );
        }

        HB_FUNC( PRT_PRINTBITMAP )
        {
            BBPrinterPrintBitmap( hPrinter, (LPCTSTR) hb_parc(1), BB_PRINT_BITMAP_NORMAL );
        }

        HB_FUNC( PRT_PRINTTEXT )
        {
            BBPrinterPrint( hPrinter, (LPCTSTR)hb_parc(1), (DWORD)hb_parnl(2) );
        }

        HB_FUNC( PRT_PROVASTAMPA )
        {
            HBBPRINTER hPrinter = BBPrinterOpen( 0 );

            if ( !hPrinter )
            {
                return;
            }

            BBPrinterSetLineSpacing( hPrinter, 8 );                     // Set line spacing 1/18 inch.
            BBPrinterSetDensity( hPrinter, BB_PRINT_DENSITY_100PERCENT );   // Set density 100%
            BBPrinterInit( hPrinter );
            BBPrinterPrint( hPrinter, _T("LineSpacing 1/6, Density 60% \n"), BB_PRINT_DEFAULT );
            BBPrinterPrint( hPrinter, _T("LineSpacing 1/6, Density 60% \n"), BB_PRINT_DEFAULT );
            BBPrinterPrint( hPrinter, _T("LineSpacing 1/6, Density 60% \n"), BB_PRINT_DEFAULT );
            BBPrinterPrint( hPrinter, _T("LineSpacing 1/6, Density 60% \n"), BB_PRINT_DEFAULT );
            BBPrinterPrint( hPrinter, _T("LineSpacing 1/6, Density 60% \n"), BB_PRINT_DEFAULT );
          DWORD dwRet = BBPrinterWaitUntilPrintEnd( hPrinter );
            BBPrinterClose( hPrinter );

        }

    //LPCTSTR

        //BBPrinterPrint( hPrinter, _T("LineSpacing 1/6, Density 60% \n"), BB_PRINT_DEFAULT );
          //BBPrinterInit( hPrinter );
        //BBPrinterWaitUntilPrintEnd( hPrinter );
        //BBPrinterClose( hPrinter );

    #pragma ENDDUMP
 

Aqui está el fichero completo de Wilson con las librerías necesarias para la pidion:
http://www.fivetechsoft.com/files/utilities/pidion.zip

Re: imprimir en una pidion BIP-1300

PostPosted: Fri Jan 22, 2010 12:12 pm
by Julio Perez
Muchas Gracias Wilson y Antonio

Excelentes Profesionales ... seguimos en contacto

Re: imprimir en una pidion BIP-1300

PostPosted: Fri Jan 22, 2010 2:05 pm
by wilsongamboa
Julio me alegro que te haya servido en realidad es un trabajo del Sr Pedro Gonzalez de Italia quien me salvo cuando lo necesite y claro la siempre atenta ayuda de nuestro guru Don Antonio Linares
saludos

Re: imprimir en una pidion BIP-1300

PostPosted: Mon Jan 10, 2011 8:00 pm
by mikemetal
Buen dia, yo tambien tengo una de esas impresoras y no he podido hacerla que pueda imprimir, estuve leyendo todos los comentarios, y ya mire que varias personas pudieron hacerla trabajar, yo soy un poco principiante y no se por donde empezar, ya me descargue el pack con las librerias pero no entiendo como usarlas, no se si me podrias ayudar con eso, una pequeña explicacion de como usarlas, que parametros utiliza, como mandarlas a llamar, seria de muchisima ayuda.

De antemano Gracias y saludos

Re: imprimir en una pidion BIP-1300

PostPosted: Sun Aug 11, 2019 6:43 am
by usulr2019
Buenas noches, tengo una pidion bip-1300 , estoy intentando imprimir a la impresora integrada de este dispositivo, he leido en este foro que han podido hacer que imprima, baje los archivos que pusieron en el foro. pero en el script tiene set fwdir=c:\fwppc
set hdir=c:\harbour_ce

estos directorios no los tengo en mi maquina, descargue el Harbour 3.0.0 (r16951) , pero no he podido descargar el fwppc, si me pueden colaborar para lograr hacer que esta impresora funcione se los agradeceria mucho.