Adafruit printer on Arduino via Raspberry Pi

Breakout boards, sensors, other Adafruit kits, etc.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
mypitboss
 
Posts: 63
Joined: Wed Jun 25, 2014 6:23 pm

Adafruit printer on Arduino via Raspberry Pi

Post by mypitboss »

I've been trying to control the Adafruit Thermal Printer on the Arduino Uno via a USB connection to the Raspberry Pi B. Been having compiling problems with the printertest example in the library (run through VNC server):

https://github.com/adafruit/Adafruit-Th ... er-Library

To isolate the problem:
> Successfully ran the printertest example through my Uno connected to a PC
> Successfully ran the Nrf8001 example on the Uno via a USB connection to the RPI B

Since the printer and Bluetooth examples were installed in the same manner & at the same time, I'm wondering why the compile comes out like this:

Code: Select all

In file included from printertest.cpp:20:0
adalogo.h:7:16: error: 'prog_uchar" does not name a type
In file included from printertest.cpp:21:0
adaqrcode.h:7:16: error: 'prog_uchar" does not name a type
printertest.cpp: In function 'void setup()':
printertest.cpp:93:54: error: 'adalogo_data" was not declared in this scope
printertest.cpp:96:58: error: 'adaqrcode_data" was not declared in this scope

mypitboss
 
Posts: 63
Joined: Wed Jun 25, 2014 6:23 pm

Re: Adafruit printer on Arduino via Raspberry Pi

Post by mypitboss »

It works when I remove the reference to the graphics files. I wonder if these .h files need to be manually placed somewhere?

User avatar
adafruit_support_mike
 
Posts: 67446
Joined: Thu Feb 11, 2010 2:51 pm

Re: Adafruit printer on Arduino via Raspberry Pi

Post by adafruit_support_mike »

Those files need to be in the same folder as the library, like they are in the Github repo.

mypitboss
 
Posts: 63
Joined: Wed Jun 25, 2014 6:23 pm

Re: Adafruit printer on Arduino via Raspberry Pi

Post by mypitboss »

Great. Will try. Thanks!

mypitboss
 
Posts: 63
Joined: Wed Jun 25, 2014 6:23 pm

Re: Adafruit printer on Arduino via Raspberry Pi

Post by mypitboss »

Okay, I actually had these files in the right place. The error persists.

They're located in:

(Just like Github)
/home/pi/sketchbook/libraries/Adafruit_Printer/examples/printertest

(Also, for good measure)
/home/pi/sketchbook/libraries/Adafruit_Printer/examples
/home/pi/sketchbook/libraries/Adafruit_Printer

Again, this is an Arduino I'm accessing via Raspberry Pi USB. I've now replicated this problem on both a B and B+.

User avatar
adafruit_support_mike
 
Posts: 67446
Joined: Thu Feb 11, 2010 2:51 pm

Re: Adafruit printer on Arduino via Raspberry Pi

Post by adafruit_support_mike »

Hm.. what version of the Arduino IDE are you using?

mypitboss
 
Posts: 63
Joined: Wed Jun 25, 2014 6:23 pm

Re: Adafruit printer on Arduino via Raspberry Pi

Post by mypitboss »

Sorry for the delayed response.

Hard to say the version, since I've wiped the card and re-started. I followed the video instructions from Simon Monk's book, so I assume it was pretty current. I'm always apt-get updating and upgrading, so I doubt an old version is the issue. Since the .h files are located in the same folder (as well as all parent folders), I don't think this is a user error on my part.

My theory is that Arduino is using a bad profile that causes it to look for some folders as if it's still in a Windows (or non-Linux) environment. So, on my next try, I'm going to create two Arduino directory structures: one that mimics Windows and the correct Linux one.

I've seen dumber bugs--so it's worth a shot.


Will do a fresh install and see what happens.

User avatar
adafruit_support_mike
 
Posts: 67446
Joined: Thu Feb 11, 2010 2:51 pm

Re: Adafruit printer on Arduino via Raspberry Pi

Post by adafruit_support_mike »

Go for version 1.04 or 1.05 if you can.

The 1.5 versions are experimental, and known to have a lot of quirks. If you don't specifically need 1.5 for a Due or Yun, the stable branch will work much better.

mypitboss
 
Posts: 63
Joined: Wed Jun 25, 2014 6:23 pm

Re: Adafruit printer on Arduino via Raspberry Pi

Post by mypitboss »

Cool. I'll do that. Many thanks.

Locked
Please be positive and constructive with your questions and comments.

Return to “Other Products from Adafruit”