»
S
I
D
E
B
A
R
«
Objective C compiler errors: translations for newbs
Mar 4th, 2010 by admin

I’m pretty new at Xcode and Objective C, so there may not be a one-to-one correspondence here between errors and the most probable cause, but this helps me so it may help you.

This will be a work in progress; I’ll keep adding as I go.

#1.

CODE (from header declarations):
CreatorHuntView *detailController;

ERROR:
error: expected specifier-qualifier-list before ‘CreatorHuntView’

TRANSLATION/PROBABLE CAUSE:
You forgot to import the file in the header file; e.g.
#import “CreatorHuntView.h”

There You Go Again, Apple: Reagan App Hits App Store
Dec 5th, 2009 by alec

As you all know by now,, Apple banned our Bush countdown timer for being political: lightly satirizing an almost universally despised leader was in the word of Steve Jobs, potentially offensive to half his customers. That smacked of censorship to us, but at least we figured this would also be applied to all sides equally. We were wrong, as app after app of pro-conservative, right-wing propaganda gets into the App Store.

Here’s the latest, an app for worshippers of one of the most divisive presidents before Bush, Ronald Reagan.

According to a post on Credo Mobile’s Facebook feed:

When Apple banned an iPhone app counting down the days until Bush was out of office, Steve Jobs said “I think this app will be offensive to roughly half our customers.” (Clearly, Steve hadn’t seen W’s approval #s). How does Apple justify this hagiography of Ronald Reagan? We think THAT is offensive.

Right-wing Propaganda OK in App Store
Oct 8th, 2009 by alec

So, it’s not acceptable to poke gentle fun at a politician, and it’s not acceptable to make an app that helps people promote health care reform.

But it is perfectly all right to make an app that spreads the “talking points” (a nice phrase for propaganda) generated by a handful of cable TV news hosts, Washington columnists, and think-tank lobbyists.

Sounds like crazy talk, yes? See this story in the Atlantic.

Here’s an excerpt:

America’s political civil war has hit the iPhone… The First Shot over the Liberal Bow has been fired!… Be armed with the Conservative Talking Points iPhone App as your powerful arsenal to debate those emotional and ill-prepared liberals… conduct this war on ignorance and liberal idiocy.

This is practically an incitement to violence, especially compared to the light-hearted harmless mocking of President Bush that was in our app. Steve Jobs dismissed our iPhone app as possibly alienating “half” of his customer base and said “what’s the point?” I have to ask if our Mickey Mouse cartoon of Bush was incindiary, what’s the point of this app that derides people while referring to an ideological “civil war” using violence as its only metaphor?

Furthermore, a screen shot from the Atlantic page shows an article on Fascism, trying to paint the current administration as fascist. This is the worst kind of right-wing propaganda that redefines the terms to their opposite. Another screen shot says:

Help us defeat the liberal fascists attempting to take over America!

To date this is perhaps the best example to date of Apple’s myopic App Store policies. What are we to think, that Apple only approves “politically charged” apps associated with extreme right-wing causes? Has Ann Coulter infiltrated Cupertino? Is Steve Jobs staying up late watching Glenn Beck? It’s really, really hard to imagine a universe in which Apple allows this kind of evil crap through, but not something as harmless as Freedom Time.

I have never seen a more obvious case of bias in my life.

App Store Fail. Once again.

[Edit: I just added more detail describing the content of the App.]

Apple rejects health care app for being “politically charged”
Sep 30th, 2009 by alec

Even more shame-worthy behavior from Apple. I thought it was being mean to politicians that Apple didn’t like—apparently now, it’s being “politically charged?” What the hell are Apple’s standards here? Whoops, I just said “hell,” which in the iPhone’s Disney-like dictionary, gets auto-corrected to “heal” or “hello.”

Here’s the link: http://lambdajive.wordpress.com/2009/09/26/isinglepayer-iphone-app-censored-by-apple/

mySQL to SQLite cheatsheet for iPhone developers
Sep 2nd, 2009 by alec

Although I started writing this as a cheat-sheet for myself (after many hours of struggling with this by trial-and-error), I figured it would be helpful for other iPhone developers who’d like to take a mySQL database online and migrate it to their current iPhone project. While other tutorials cover how to read the database into the application from the coding point-of-view, this is just to make sure you get your data uncompromised from your existing mySQL database into a new SQLite DB that your iPhone app can read.

First of all, here’s what I am currently using; I am including versions in case that’s relevant to your situation:

  • MySQL 5.0.81
  • MySQL charset: UTF8-Unicode (utf8)
  • MySQL connection collation: utf8_unicode_ci
  • phpMyAdmin – 2.11.9.5
  • SQLite Database Browser 1.3 (includes 3.3.5 of the SQLite database engine)
  • iPhone Dev Kit – 3.0
  • XCode 3.1.3
  • SQLite 3 framework found at /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.0.sdk/usr/lib/libsqlite3.dylib

You can try other solutions for importing the data into a SQLite format, but I’ve had the best luck with Mauricio Piacentini’s SQLite Database Browser. Other options you might want to try include a Firefox plugin.

Here are the steps, using SQLite Database Browser:

  1. phpMyAdmin options for exporting to SQLitelog into phpMyAdmin, select your database and go to Database> Export.
  2. On the export tab, make sure all databases are selected, and the “SQL” radio button is selected.
  3. Select ANSI from the pulldown for export compatibility.
  4. Uncheck all options under Structure and Data, but leave each section checked.
  5. Save as file should be checked, and probably be via ZIP or GZIP, just in case.
  6. Click the Go button to download your file.
  7. Extract the file and open it up in your favorite text editor (I use BBEdit).
  8. Find the first CREATE TABLE line. We need to modify these by hand to simplify the table creation so that SQLite doesn’t get confused. For example, my file came down looking like this after the comment section ended:

    CREATE TABLE dictionary (
    id int(11) NOT NULL auto_increment,
    word varchar(100) NOT NULL,
    adjective tinyint(1) NOT NULL default '0' COMMENT 'is an adjective',
    noun tinyint(1) NOT NULL default '0' COMMENT 'is a noun ',
    intro tinyint(1) NOT NULL default '0' COMMENT 'is an intro',
    PRIMARY KEY  (id),
    UNIQUE KEY words (word)
    );

    You’ll want to edit this to remove pretty much everything but the most basic information and normalize the data types to SQLite 3 Data Types, which are TEXT, NUMERIC, INTEGER, REAL, or BLOB. Your CREATE TABLE should look something like this:

    CREATE TABLE dictionary(
    id INTEGER PRIMARY KEY ASC,
    word TEXT,
    adjective INTEGER,
    noun INTEGER,
    intro TEXT
    );

    I was using id as a primary key so I’ve added “PRIMARY KEY ASC” after “id INTEGER”. (Primary Keys are aliases to row IDs in SQLite, if you have questions read this.)

    However, I’ve noticed that the SQLite Database browser exports SQL in the even more simplified format with no datatype specification as such, which also seemed to work for me and may work just as well for your needs:

    CREATE TABLE dictionary (id, word, adjective, noun, intro);

  9. Continue going through your text file and fix all CREATE TABLE lines as in #8, above.
  10. Check your file text encoding. BBEdit may default to Western (Mac OS Roman), which worked for me, but if you have problems you may need to set it to Unicode, depending on your character set.
  11. Check your file for suspicious characters that might cause the import to choke. Single quotation marks used as apostrophes show up as escaped by themselves; for example you're becomes you''re. This seemed to import fine as long as the other guidelines are followed. Here’s what an example INSERT should look like:

    INSERT INTO dictionary VALUES(305, 'ne''er-do-well', 0, 1, 0);

  12. Check your line endings. BBEdit defaulted to Unix (LF) which worked for me.
  13. Open up SQLite Database Browser, create a new database (.db) file, and import your SQL text file by selecting File> Import> Database From SQL File from the menu.
  14. Check your data by clicking the Browse Data tab and make sure everything came in all right. If not, go back over the steps. Look for weird characters, text and line encoding issues, and syntax issues. The only two commands in your file should be CREATE TABLE and INSERT, although technically it should probably begin with BEGIN TRANSACTION; and end with COMMIT;

Again these steps were derived mostly by trial-and-error, so there may be issues particular to your DB that these guidelines didn’t solve. Please feel free to add any corrections, tips, and questions to the comments area.

Also, I know that with the iPhone OS 3.0, Core Data can take care of a lot of database functionality for you. I’d love to hear how people made the transition, and especially how anyone got a pre-existing SQL database into a Core Data store.

Apple tries to defend its App Store to the FCC
Aug 25th, 2009 by alec

I just saw that Apple has put on its home page now has a public response to justify its App Store policies.

http://www.apple.com/hotnews/apple-answers-fcc-questions/

Of course the FCC is primarily interested in its rejection of big, important apps like Google Voice, and not indie developer apps, so Apple was able to gloss over its political censorship of apps like Freedom Time (See section 5, above), and not even include any rejected political content app in its list of “representative applications.”

To me, rejecting an app for speech reasons is much worse than for technological competition reasons, but maybe that’s because I am someone who cares about the first Amendment, something that has been shoved to the back of the bus while greasing the wheels of the free market machine.

Thanks to Brad at Bent Media for pointing me to this excellent essay by Joe Hewitt demanding the end of the App Store approval process as we know it.

Hurrah for Freedom!
Oct 1st, 2008 by alec

Apple redacted the NDA (Non-disclosure Agreement) that has been such a thorn in the iPhone Developer community’s side. “Thanks to everyone who provided us constructive feedback on this matter,” they say.

So, in the spirit of open-ness I am hereby un-censoring the blog entry I removed last week, at least for the moment.

For more information see this story on CNET.

Now, let’s hope they keep going forward, and find a place for apps like Freedom Time.

Freedom Time: free for first 100 users.
Sep 23rd, 2008 by alec

FreedomTime for iPhoneWell since we can’t sell it for 99 cents on the App Store, we’re going to give it away for free via Apple’s Ad Hoc distribution model.

Send us your iphone’s UDID (unique device ID) on the contact form on this page.

And we’ll send you a link with install instructions. 

Why do we need your UDID? Because we have to authorize your specific device to run the app. 

Where to find your UDID:

Make sure you have a recent version of iTunes (version 7.6.2 or later).

Connect your iPhone to your computer.

When your iPhone appears in iTunes, select it.

Click the summary tab. The name and other information including the serial number for your iPhone will display.

Click on the Serial Number field. It will change to the Identifier, also known as the UDID number.

Steve Jobs responds
Sep 23rd, 2008 by alec

Wow, although I’m not happy with Apple right now, I have to give Apple’s CEO some serious credit for answering the email I wrote yesterday:

Dear Steve,
 
A quick note to let you know what kinds of apps are being rejected for the App Store.
 
This app is not defamatory, harmful or speaking untruth. It is lighthearted and humorous. Does it imply critique? Of course it does, but not without crossing any lines of decency or the boundaries agreement. 
 
For a quick screen shot:
Alec Vance
juggleware llc

Mr. Jobs replied :

Even though my personal political leanings are democratic, I think this app will be offensive to roughly half our customers.  What’s the point?

Steve

 

I’m not sure if he’s asking what’s the point of the app (not much—just poking fun and a time-killer), or what’s the point of letting me risk alienating a portion of his customer base (which is what I think he’s asking, rhetorically).

My friend John Barousse (the guy who convinced me to write Mr. Jobs) makes the point that the market should decide. And why not? No one thinks this is an Apple app, it’s clearly from an independent developer. Why would Apple lose business because of this app? As John says, “It’s not Apple’s application; they’re the store.”

Here’s a link to a good article that John sent me, and I recommend you read it; it says a lot of things I’ve been trying to say, but better:

Of course the fact that Steve Jobs wrote me back, even in a pithy manner, can be taken only as a good omen. Juggleware wasn’t planning on developing only political apps of course (although a “W” voodoo doll would have been fun!)—most of the ideas we’re talking about are for games with a purely non-political angle. 
Freedom Time won’t be in App Store (censored version)
Sep 21st, 2008 by alec
»  Substance: WordPress   »  Style: Ahren Ahimsa
© 2009 Juggleware LLC, New Orleans, Louisiana. All Rights Reserved.