Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Special Interest Groups
  3. C++ Gurus
  4. Serial port print for html
QtWS25 Last Chance

Serial port print for html

Scheduled Pinned Locked Moved C++ Gurus
11 Posts 2 Posters 3.0k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    guru
    wrote on 11 Jul 2013, 13:36 last edited by
    #1

    Is this possible to print a dynamic html file through serial port printer line by line...?

    1 Reply Last reply
    0
    • J Offline
      J Offline
      janfaroe
      wrote on 20 Jul 2013, 08:21 last edited by
      #2

      Since a HTML file (and dynamic content generated by PHP etc) is text content, sure.

      1 Reply Last reply
      0
      • G Offline
        G Offline
        guru
        wrote on 20 Jul 2013, 08:33 last edited by
        #3

        thanks for your reply jan.. im generate a html at run time using sethtml( ) and show it in a dialog through text browser, then how can i print this into serial port printer which was connected to my linux system..

        1 Reply Last reply
        0
        • J Offline
          J Offline
          janfaroe
          wrote on 20 Jul 2013, 08:57 last edited by
          #4

          There's a new class in Qt5 that makes it fairly easy to deal with serial ports: "QtSerialPort":https://qt-project.org/doc/qt-5.1/qtserialport/qtserialport-index.html

          That should get you going.

          1 Reply Last reply
          0
          • G Offline
            G Offline
            guru
            wrote on 22 Jul 2013, 05:34 last edited by
            #5

            Im using Qt5.0, it does not have any class QtSerialPort. so im download source code from some other website and compile. it shows read and write function errors.. im follow instructions using this website(http://qt-project.org/wiki/QtSerialPort)..

            1 Reply Last reply
            0
            • J Offline
              J Offline
              janfaroe
              wrote on 22 Jul 2013, 05:39 last edited by
              #6

              Ah, yes. I hope you got it from http://qt.gitorious.org/qt/qtserialport .

              1 Reply Last reply
              0
              • G Offline
                G Offline
                guru
                wrote on 22 Jul 2013, 06:33 last edited by
                #7

                yep.. i almost reached but i need little more help.. after debug it show a popup that needs command and working directory options wat will i give these.. i include that popup as image see it... !http://i44.tinypic.com/2wr0k0g.png(screenshots)!

                1 Reply Last reply
                0
                • J Offline
                  J Offline
                  janfaroe
                  wrote on 22 Jul 2013, 07:08 last edited by
                  #8

                  Seems like you tried to run it? You should use QtSerialPort as a library.

                  If I recall correctly, after building it in Creator, go to the build directory in your terminal and type "make install"

                  1 Reply Last reply
                  0
                  • G Offline
                    G Offline
                    guru
                    wrote on 22 Jul 2013, 07:37 last edited by
                    #9

                    i went to terminal window of specified build folder and i type make install or sudo make install, but shows make: nothing to be done for 'install', i also tried qmake... nothing happen, wats wrong with my code..!http://i41.tinypic.com/zmeb93.png(screenshot1)!

                    1 Reply Last reply
                    0
                    • J Offline
                      J Offline
                      janfaroe
                      wrote on 22 Jul 2013, 08:21 last edited by
                      #10

                      Well, perhaps it's already good to go.

                      Did you try using the library as described under "Usage" in the Wiki?

                      1 Reply Last reply
                      0
                      • G Offline
                        G Offline
                        guru
                        wrote on 24 Jul 2013, 04:52 last edited by
                        #11

                        yeah.. its working now.. thanks jan

                        1 Reply Last reply
                        0

                        • Login

                        • Login or register to search.
                        • First post
                          Last post
                        0
                        • Categories
                        • Recent
                        • Tags
                        • Popular
                        • Users
                        • Groups
                        • Search
                        • Get Qt Extensions
                        • Unsolved